arkana 2.1.0 → 2.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/arkana/encoder.rb +2 -3
- data/lib/arkana/models/salt.rb +2 -3
- data/lib/arkana/templates/kotlin/arkana.kt.erb +2 -2
- data/lib/arkana/templates/kotlin/arkana_protocol.kt.erb +2 -2
- data/lib/arkana/templates/kotlin/arkana_tests.kt.erb +2 -2
- data/lib/arkana/templates/swift/arkana.swift.erb +2 -2
- data/lib/arkana/templates/swift/arkana_protocol.swift.erb +2 -2
- data/lib/arkana/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 52db8a00775241c44fa0e1768eb111a694e32215b505ec8122491db0700973c9
|
4
|
+
data.tar.gz: 0fee4f39353e59be30345847795a1017b547d9bfb6118edb85bc370e07bd76cc
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: dc8efcd05fd71b489a182688595d8fc8a29139cd7ca403c382940f9969cff1cb28fcd35b2a0998c9df588d9a88b155acd29d1963386b686f855c7d7ce0eec950
|
7
|
+
data.tar.gz: 182c8023f7b3d66bcda9e218d44ed0f78c79c9cfd8cc99f7861d8f74abe2484d699504a63bc71de5913f2c8357428d5fecfe1dba7efdd40e6f1b5b48236a5ffd
|
data/lib/arkana/encoder.rb
CHANGED
@@ -26,10 +26,9 @@ module Encoder
|
|
26
26
|
result << (byte ^ cipher[index % cipher.length]) # XOR operation with a value of the cipher array.
|
27
27
|
end
|
28
28
|
|
29
|
-
encoded_key =
|
30
|
-
result.each do |element|
|
29
|
+
encoded_key = result.map do |element|
|
31
30
|
# Warning: this might be specific to Swift implementation. When generating code for other languages, beware.
|
32
|
-
|
31
|
+
format("%#x", element) # Format the binary number to "0xAB" format.
|
33
32
|
end
|
34
33
|
|
35
34
|
encoded_key.join(", ")
|
data/lib/arkana/models/salt.rb
CHANGED
@@ -10,10 +10,9 @@ class Salt
|
|
10
10
|
|
11
11
|
def initialize(raw:)
|
12
12
|
@raw = raw
|
13
|
-
formatted_salt =
|
14
|
-
raw.each do |element|
|
13
|
+
formatted_salt = raw.map do |element|
|
15
14
|
# Warning: this might be specific to Swift implementation. When generating code for other languages, beware.
|
16
|
-
|
15
|
+
format("%#x", element)
|
17
16
|
end
|
18
17
|
@formatted = formatted_salt.join(", ")
|
19
18
|
end
|
@@ -1,5 +1,5 @@
|
|
1
|
-
<%
|
2
|
-
<%
|
1
|
+
<% require "arkana/helpers/string" %>
|
2
|
+
<% require "arkana/helpers/kotlin_template_helper" %>
|
3
3
|
<% # TODO: Sort these import statements alphabetically %>
|
4
4
|
// DO NOT MODIFY
|
5
5
|
// Automatically generated by Arkana (https://github.com/rogerluan/arkana)
|
@@ -1,5 +1,5 @@
|
|
1
|
-
<%
|
2
|
-
<%
|
1
|
+
<% require "arkana/helpers/string" %>
|
2
|
+
<% require "arkana/helpers/kotlin_template_helper" %>
|
3
3
|
// DO NOT MODIFY
|
4
4
|
// Automatically generated by Arkana (https://github.com/rogerluan/arkana)
|
5
5
|
package <%= @kotlin_package_name %>
|
@@ -1,5 +1,5 @@
|
|
1
|
-
<%
|
2
|
-
<%
|
1
|
+
<% require "arkana/helpers/string" %>
|
2
|
+
<% require "arkana/helpers/kotlin_template_helper" %>
|
3
3
|
// DO NOT MODIFY
|
4
4
|
// Automatically generated by Arkana (https://github.com/rogerluan/arkana)
|
5
5
|
package <%= @kotlin_package_name %>
|
@@ -1,5 +1,5 @@
|
|
1
|
-
<%
|
2
|
-
<%
|
1
|
+
<% require "arkana/helpers/string" %>
|
2
|
+
<% require "arkana/helpers/swift_template_helper" %>
|
3
3
|
<% # TODO: Sort these import statements alphabetically %>
|
4
4
|
// DO NOT MODIFY
|
5
5
|
// Automatically generated by Arkana (https://github.com/rogerluan/arkana)
|
@@ -1,5 +1,5 @@
|
|
1
|
-
<%
|
2
|
-
<%
|
1
|
+
<% require "arkana/helpers/string" %>
|
2
|
+
<% require "arkana/helpers/swift_template_helper" %>
|
3
3
|
// DO NOT MODIFY
|
4
4
|
// Automatically generated by Arkana (https://github.com/rogerluan/arkana)
|
5
5
|
|
data/lib/arkana/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: arkana
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.1.
|
4
|
+
version: 2.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Roger Oba
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-06-
|
11
|
+
date: 2024-06-13 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: dotenv
|
@@ -118,7 +118,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
118
118
|
- !ruby/object:Gem::Version
|
119
119
|
version: '0'
|
120
120
|
requirements: []
|
121
|
-
rubygems_version: 3.5.
|
121
|
+
rubygems_version: 3.5.11
|
122
122
|
signing_key:
|
123
123
|
specification_version: 4
|
124
124
|
summary: Store your keys and secrets away from your source code. Designed for Android
|