enveloperb 0.3.0 → 0.3.1.2.gb499423
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/enveloperb.gemspec +4 -0
- data/ext/enveloperb/Cargo.lock +56 -5
- data/ext/enveloperb/Cargo.toml +2 -1
- data/ext/enveloperb/src/lib.rs +3 -3
- metadata +18 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e278648e662b564dda4c2b1a9dc53c61890f564df7cce1099ea29cc04c59dc1a
|
4
|
+
data.tar.gz: 126fa8387fd2d16ba2a86a1239d2e74dbc49b4358f7519a8bf4267b7c4b175d7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3a40f4900e250c5bba740843bacc8b592ce593d0ba87f78e618da364f795d4ba087f0fecddfa4ce9560a2704ed5b471453cd2ae9531af8a244b7cc9071402a5f
|
7
|
+
data.tar.gz: c1d98937468fd52290b2e1613752643442a2fd213c8062c39c138747f4e258475b063accc00da5c3035f6a8ee2dcdc1b0ba7fe5e2dcf3af422c885d8d9994839
|
data/enveloperb.gemspec
CHANGED
@@ -31,6 +31,10 @@ Gem::Specification.new do |s|
|
|
31
31
|
s.metadata["documentation_uri"] = "https://rubydoc.info/gems/enveloperb"
|
32
32
|
s.metadata["mailing_list_uri"] = "https://discuss.cipherstash.com"
|
33
33
|
|
34
|
+
unless ENV.key?("GVB_VERSION_OVERRIDE")
|
35
|
+
s.add_runtime_dependency 'rb_sys', '~> 0.1'
|
36
|
+
end
|
37
|
+
|
34
38
|
s.add_development_dependency 'bundler'
|
35
39
|
s.add_development_dependency 'github-release'
|
36
40
|
s.add_development_dependency 'guard-rspec'
|
data/ext/enveloperb/Cargo.lock
CHANGED
@@ -37,6 +37,17 @@ dependencies = [
|
|
37
37
|
"subtle",
|
38
38
|
]
|
39
39
|
|
40
|
+
[[package]]
|
41
|
+
name = "ahash"
|
42
|
+
version = "0.7.6"
|
43
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
44
|
+
checksum = "fcb51a0695d8f838b1ee009b3fbf66bda078cd64590202a864a8f3e8c4315c47"
|
45
|
+
dependencies = [
|
46
|
+
"getrandom",
|
47
|
+
"once_cell",
|
48
|
+
"version_check",
|
49
|
+
]
|
50
|
+
|
40
51
|
[[package]]
|
41
52
|
name = "aho-corasick"
|
42
53
|
version = "0.7.18"
|
@@ -556,18 +567,19 @@ dependencies = [
|
|
556
567
|
|
557
568
|
[[package]]
|
558
569
|
name = "envelopers"
|
559
|
-
version = "0.
|
560
|
-
source = "
|
561
|
-
checksum = "23dbd85a683aabc899b8d9d2c891077e0f5f9dd20ae62b989d038fc241ab9257"
|
570
|
+
version = "0.3.0"
|
571
|
+
source = "git+https://github.com/cipherstash/envelopers.git#7bf15d2e417ef23975042c0e6f863b85693024e3"
|
562
572
|
dependencies = [
|
563
573
|
"aes-gcm",
|
564
574
|
"async-trait",
|
565
575
|
"aws-sdk-kms",
|
576
|
+
"lru",
|
566
577
|
"rand",
|
567
578
|
"rand_chacha",
|
568
579
|
"serde",
|
569
580
|
"serde_cbor",
|
570
581
|
"thiserror",
|
582
|
+
"zeroize",
|
571
583
|
]
|
572
584
|
|
573
585
|
[[package]]
|
@@ -714,6 +726,9 @@ name = "hashbrown"
|
|
714
726
|
version = "0.11.2"
|
715
727
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
716
728
|
checksum = "ab5ef0d4909ef3724cc8cce6ccc8572c5c817592e9285f5464f8e86f8bd3726e"
|
729
|
+
dependencies = [
|
730
|
+
"ahash",
|
731
|
+
]
|
717
732
|
|
718
733
|
[[package]]
|
719
734
|
name = "hermit-abi"
|
@@ -888,6 +903,15 @@ dependencies = [
|
|
888
903
|
"cfg-if",
|
889
904
|
]
|
890
905
|
|
906
|
+
[[package]]
|
907
|
+
name = "lru"
|
908
|
+
version = "0.7.7"
|
909
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
910
|
+
checksum = "c84e6fe5655adc6ce00787cf7dcaf8dc4f998a0565d23eafc207a8b08ca3349a"
|
911
|
+
dependencies = [
|
912
|
+
"hashbrown",
|
913
|
+
]
|
914
|
+
|
891
915
|
[[package]]
|
892
916
|
name = "matches"
|
893
917
|
version = "0.1.9"
|
@@ -1349,6 +1373,18 @@ dependencies = [
|
|
1349
1373
|
"unicode-xid",
|
1350
1374
|
]
|
1351
1375
|
|
1376
|
+
[[package]]
|
1377
|
+
name = "synstructure"
|
1378
|
+
version = "0.12.6"
|
1379
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
1380
|
+
checksum = "f36bdaa60a83aca3921b5259d5400cbf5e90fc51931376a9bd4a0eb79aa7210f"
|
1381
|
+
dependencies = [
|
1382
|
+
"proc-macro2",
|
1383
|
+
"quote",
|
1384
|
+
"syn",
|
1385
|
+
"unicode-xid",
|
1386
|
+
]
|
1387
|
+
|
1352
1388
|
[[package]]
|
1353
1389
|
name = "termcolor"
|
1354
1390
|
version = "1.1.3"
|
@@ -1728,6 +1764,21 @@ checksum = "114ba2b24d2167ef6d67d7d04c8cc86522b87f490025f39f0303b7db5bf5e3d8"
|
|
1728
1764
|
|
1729
1765
|
[[package]]
|
1730
1766
|
name = "zeroize"
|
1731
|
-
version = "1.5.
|
1767
|
+
version = "1.5.5"
|
1768
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
1769
|
+
checksum = "94693807d016b2f2d2e14420eb3bfcca689311ff775dcf113d74ea624b7cdf07"
|
1770
|
+
dependencies = [
|
1771
|
+
"zeroize_derive",
|
1772
|
+
]
|
1773
|
+
|
1774
|
+
[[package]]
|
1775
|
+
name = "zeroize_derive"
|
1776
|
+
version = "1.3.2"
|
1732
1777
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
1733
|
-
checksum = "
|
1778
|
+
checksum = "3f8f187641dad4f680d25c4bfc4225b418165984179f26ca76ec4fb6441d3a17"
|
1779
|
+
dependencies = [
|
1780
|
+
"proc-macro2",
|
1781
|
+
"quote",
|
1782
|
+
"syn",
|
1783
|
+
"synstructure",
|
1784
|
+
]
|
data/ext/enveloperb/Cargo.toml
CHANGED
@@ -4,7 +4,8 @@ version = "0.0.0"
|
|
4
4
|
edition = "2021"
|
5
5
|
|
6
6
|
[dependencies]
|
7
|
-
envelopers = "
|
7
|
+
envelopers = { git = "https://github.com/cipherstash/envelopers.git" }
|
8
|
+
#envelopers = "0.2"
|
8
9
|
lazy_static = "^0.2.2"
|
9
10
|
rb-sys = "0.8.0"
|
10
11
|
rutie = { git = "https://github.com/mpalmer/rutie", branch = "rb_sys" }
|
data/ext/enveloperb/src/lib.rs
CHANGED
@@ -10,7 +10,7 @@ extern crate lazy_static;
|
|
10
10
|
use aws_config;
|
11
11
|
use aws_sdk_kms;
|
12
12
|
use aws_types;
|
13
|
-
use envelopers::{EncryptedRecord, EnvelopeCipher, KMSKeyProvider, SimpleKeyProvider};
|
13
|
+
use envelopers::{CacheOptions, EncryptedRecord, EnvelopeCipher, KMSKeyProvider, SimpleKeyProvider};
|
14
14
|
use std::borrow::Cow;
|
15
15
|
use tokio::runtime::Runtime;
|
16
16
|
use rutie::{Class, Encoding, Hash, Module, Object, RString, Symbol, VerifiedObject, VM};
|
@@ -55,7 +55,7 @@ methods!(
|
|
55
55
|
key.clone_from_slice(rbkey.unwrap().to_bytes_unchecked());
|
56
56
|
|
57
57
|
let provider = SimpleKeyProvider::init(key);
|
58
|
-
let cipher = EnvelopeCipher::init(provider);
|
58
|
+
let cipher = EnvelopeCipher::init(provider, CacheOptions::default());
|
59
59
|
|
60
60
|
let klass = Module::from_existing("Enveloperb").get_nested_class("Simple");
|
61
61
|
return klass.wrap_data(SimpleCipher{ cipher: cipher, runtime: Runtime::new().unwrap() }, &*SIMPLE_CIPHER_WRAPPER);
|
@@ -121,7 +121,7 @@ methods!(
|
|
121
121
|
|
122
122
|
let kmsclient = aws_sdk_kms::Client::new(&kmsclient_config);
|
123
123
|
let provider = KMSKeyProvider::new(kmsclient, rbkey.unwrap().to_string());
|
124
|
-
let cipher = EnvelopeCipher::init(provider);
|
124
|
+
let cipher = EnvelopeCipher::init(provider, CacheOptions::default().with_max_bytes(100_000));
|
125
125
|
|
126
126
|
let klass = Module::from_existing("Enveloperb").get_nested_class("AWSKMS");
|
127
127
|
return klass.wrap_data(AWSKMSCipher{ cipher: cipher, runtime: rt }, &*AWSKMS_CIPHER_WRAPPER);
|
metadata
CHANGED
@@ -1,15 +1,29 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: enveloperb
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.1.2.gb499423
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Matt Palmer
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-
|
11
|
+
date: 2022-06-28 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: rb_sys
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - "~>"
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '0.1'
|
20
|
+
type: :runtime
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - "~>"
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '0.1'
|
13
27
|
- !ruby/object:Gem::Dependency
|
14
28
|
name: bundler
|
15
29
|
requirement: !ruby/object:Gem::Requirement
|
@@ -221,9 +235,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
221
235
|
version: 2.7.0
|
222
236
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
223
237
|
requirements:
|
224
|
-
- - "
|
238
|
+
- - ">"
|
225
239
|
- !ruby/object:Gem::Version
|
226
|
-
version:
|
240
|
+
version: 1.3.1
|
227
241
|
requirements: []
|
228
242
|
rubygems_version: 3.1.6
|
229
243
|
signing_key:
|