rcrypto 1.0 → 1.0.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (4) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +4 -0
  3. metadata +6 -21
  4. data/lib/RCrypto/encode.rb +0 -32
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 3af4e1f11c1db798442da56a2f451abd4f77ea7b6ab51d3a8714a055fc77552e
4
- data.tar.gz: f39a0a959480d573e635a31c9e9ae70f69dbbd97c53569c2361e44e3dea164da
3
+ metadata.gz: 474280879e7e70f104e7c806a9bd9740671deca7e0baa2303a15c12745e31288
4
+ data.tar.gz: f690176489717f16e30f13732cfd92a58937f9931033d1a49620995dcffbea36
5
5
  SHA512:
6
- metadata.gz: c567ca02115e156bd8cf620089ea97e6cc3ca0994c160d85a87eee68bda90111c7df839de7528757bee2f855e000a40aba077edbef3dc23234f4dfc345bfa63c
7
- data.tar.gz: 60499a2a310c8d9292cbbbc9fc7e95713f7b731b297efeb00353cd82be024f0de2373df87c4b4dbe73e384033117532ca362117add2ebbf7b58a05b90f9761a3
6
+ metadata.gz: 94c4d1e82ea600f6285fb850529dd33e4dfc001c206cedcc5089a6fd82c52fabf35caa5a3623540dda8589fc0318969b41be8ffb9b20d2247c1da900eb3a2e80
7
+ data.tar.gz: 848f7a7426aa1c36f5098d0ef4b08bca8324a6c5ac0139b38ef19d94c1eadf1f7a2e71db32b2a12824dd3d447e64e578a45f8672864b0e27c0757b7fb904abc1
data/README.md CHANGED
@@ -191,3 +191,7 @@ If you encounter any issues or have suggestions for improvements, please feel fr
191
191
  - Special thanks to the open-source community for their continuous support.
192
192
  - Inspired by classic encryption techniques and the need for secure communication in Ruby applications.
193
193
 
194
+ # rcrypto
195
+ # rcrypto
196
+ # rcrypto
197
+ # rcrypto
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rcrypto
3
3
  version: !ruby/object:Gem::Version
4
- version: '1.0'
4
+ version: 1.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - MAVEN
8
- autorequire:
8
+ autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2024-08-14 00:00:00.000000000 Z
11
+ date: 2024-08-19 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: openssl
@@ -52,20 +52,6 @@ dependencies:
52
52
  - - "~>"
53
53
  - !ruby/object:Gem::Version
54
54
  version: '3.0'
55
- - !ruby/object:Gem::Dependency
56
- name: securerandom
57
- requirement: !ruby/object:Gem::Requirement
58
- requirements:
59
- - - "~>"
60
- - !ruby/object:Gem::Version
61
- version: '3.0'
62
- type: :runtime
63
- prerelease: false
64
- version_requirements: !ruby/object:Gem::Requirement
65
- requirements:
66
- - - "~>"
67
- - !ruby/object:Gem::Version
68
- version: '3.0'
69
55
  - !ruby/object:Gem::Dependency
70
56
  name: bundler
71
57
  requirement: !ruby/object:Gem::Requirement
@@ -119,7 +105,6 @@ files:
119
105
  - README.md
120
106
  - lib/RCrypto.rb
121
107
  - lib/RCrypto/decode.rb
122
- - lib/RCrypto/encode.rb
123
108
  - lib/RCrypto/version.rb
124
109
  - spec/rcrypto_spec.rb
125
110
  - spec/spec_helper.rb
@@ -128,7 +113,7 @@ licenses:
128
113
  - MIT
129
114
  metadata:
130
115
  allowed_push_host: https://rubygems.org
131
- post_install_message:
116
+ post_install_message:
132
117
  rdoc_options: []
133
118
  require_paths:
134
119
  - lib
@@ -143,8 +128,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
143
128
  - !ruby/object:Gem::Version
144
129
  version: '0'
145
130
  requirements: []
146
- rubygems_version: 3.5.16
147
- signing_key:
131
+ rubygems_version: 3.0.3.1
132
+ signing_key:
148
133
  specification_version: 4
149
134
  summary: A custom encryption library for Ruby.
150
135
  test_files: []
@@ -1,32 +0,0 @@
1
- # lib/RCrypto/encode.rb
2
-
3
- module RCrypto
4
- module Encode
5
- def self.xor_encrypt(text, key)
6
- text.bytes.map.with_index do |byte, i|
7
- (byte ^ key.bytes[i % key.length]).chr
8
- end.join
9
- end
10
-
11
- def self.base64_custom_encode(text)
12
- Base64.strict_encode64(text)
13
- end
14
-
15
- def self.caesar_cipher_encrypt(text, shift)
16
- text.chars.map do |char|
17
- if char.match(/[a-zA-Z]/)
18
- base = char =~ /[a-z]/ ? 'a'.ord : 'A'.ord
19
- ((char.ord - base + shift) % 26 + base).chr
20
- else
21
- char
22
- end
23
- end.join
24
- end
25
-
26
- def self.add_fake_token(text)
27
- fake_token = "$" + SecureRandom.alphanumeric(10)
28
- insertion_point = SecureRandom.random_number(text.length)
29
- text.insert(insertion_point, fake_token)
30
- end
31
- end
32
- end