Skip to content

Commit fa3b7a1

Browse files
authored
Merge pull request #497 from ionut-arm/bump-imports
Switch imports to crates.io
2 parents 1287ba9 + d12d0e3 commit fa3b7a1

File tree

15 files changed

+155
-275
lines changed

15 files changed

+155
-275
lines changed

Cargo.lock

Lines changed: 25 additions & 45 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ name = "parsec"
1515
path = "src/bin/main.rs"
1616

1717
[dependencies]
18-
parsec-interface = { git = "https://github.com/parallaxsecond/parsec-interface-rs.git", rev = "6b951390791b398b76eb02c942e24d7c91acc980"}
18+
parsec-interface = "0.25.0"
1919
rand = { version = "0.8.3", features = ["small_rng"], optional = true }
2020
base64 = "0.13.0"
2121
uuid = "0.8.2"
@@ -26,16 +26,16 @@ toml = "0.5.8"
2626
serde = { version = "1.0.123", features = ["derive"] }
2727
env_logger = "0.8.3"
2828
log = { version = "0.4.14", features = ["serde"] }
29-
cryptoki = { git = "https://github.com/parallaxsecond/rust-cryptoki", rev = "2cd54bba7a00db93b3e9e2acf50726558a1784fc", optional = true, features = ["psa-crypto-conversions"] }
29+
cryptoki = { version = "0.2.0", optional = true, features = ["psa-crypto-conversions"] }
3030
picky-asn1-der = { version = "<=0.2.4", optional = true }
3131
picky-asn1 = { version = ">=0.3.1, <=0.3.1", optional = true }
32-
tss-esapi = { git = "https://github.com/parallaxsecond/rust-tss-esapi", rev = "1f68655e278b0319c080b9804a7bf3f6e11ff721", optional = true }
32+
tss-esapi = { version = "6.1.0", optional = true }
3333
bincode = "1.3.1"
3434
structopt = "0.3.21"
3535
derivative = "2.2.0"
3636
version = "3.0.0"
3737
hex = { version = "0.4.2", optional = true }
38-
psa-crypto = { git = "https://github.com/parallaxsecond/rust-psa-crypto.git", rev = "8605006d34944fa880edd3d4d347f460c5585747", default-features = false, features = ["operations"], optional = true }
38+
psa-crypto = { version = "0.9.0", default-features = false, features = ["operations"], optional = true }
3939
zeroize = { version = "1.2.0", features = ["zeroize_derive"] }
4040
picky-asn1-x509 = { version = "0.4.0", optional = true }
4141
users = "0.11.0"

ci.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ run_old_e2e_tests() {
9595
# /tmp/parsec/parsec.sock. This can not be created in the Dockerfile as this is where
9696
# the repository is checked out.
9797
ln -s /tmp/parsec.sock /tmp/parsec/parsec.sock
98-
RUST_BACKTRACE=1 cargo test --manifest-path /tmp/old_e2e_tests/Cargo.toml normal_tests
98+
RUST_BACKTRACE=1 cargo test --manifest-path /tmp/old_e2e_tests/Cargo.toml normal_tests -- --skip asym_verify_fail
9999
fi
100100
}
101101

e2e_tests/src/stress.rs

Lines changed: 20 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,24 @@ const KEY_DATA: [u8; 140] = [
2828
39, 22, 141, 173, 85, 26, 58, 9, 128, 27, 57, 131, 2, 3, 1, 0, 1,
2929
];
3030

31+
const SIGNATURE: [u8; 128] = [
32+
0x8c, 0xf8, 0x87, 0x3a, 0xb2, 0x9a, 0x18, 0xf9, 0xe0, 0x2e, 0xb9, 0x2d, 0xe7, 0xc8, 0x32, 0x12,
33+
0xd6, 0xd9, 0x2d, 0x98, 0xec, 0x9e, 0x47, 0xb7, 0x5b, 0x26, 0x86, 0x9d, 0xf5, 0xa2, 0x6b, 0x8b,
34+
0x6f, 0x00, 0xd3, 0xbb, 0x68, 0x88, 0xe1, 0xad, 0xcf, 0x1c, 0x09, 0x81, 0x91, 0xbf, 0xee, 0xce,
35+
0x4f, 0xb5, 0x83, 0x3c, 0xf5, 0xb0, 0xfa, 0x68, 0x69, 0xde, 0x7b, 0xe8, 0x49, 0x69, 0x40, 0xad,
36+
0x90, 0xf1, 0x7f, 0x31, 0xf2, 0x75, 0x4e, 0x1c, 0x52, 0x92, 0x72, 0x2e, 0x0b, 0x06, 0xe7, 0x32,
37+
0xb4, 0x5e, 0x82, 0x8b, 0x39, 0x72, 0x24, 0x5f, 0xee, 0x17, 0xae, 0x2d, 0x77, 0x53, 0xff, 0x1a,
38+
0xad, 0x12, 0x83, 0x4f, 0xb5, 0x52, 0x92, 0x6e, 0xda, 0xb2, 0x55, 0x77, 0xa7, 0x58, 0xcc, 0x10,
39+
0xa6, 0x7f, 0xc5, 0x26, 0x4e, 0x5b, 0x75, 0x9d, 0x83, 0x05, 0x9f, 0x99, 0xde, 0xc6, 0xf5, 0x12,
40+
];
41+
42+
const SIGNATURE_ECC: [u8; 64] = [
43+
0x0b, 0x4a, 0x00, 0xdb, 0xdb, 0x66, 0xb8, 0x60, 0xa5, 0xb9, 0x5b, 0x2d, 0x99, 0x66, 0xa6, 0x17,
44+
0x79, 0x89, 0x4f, 0xd2, 0x9b, 0x70, 0x12, 0x21, 0x7a, 0x7b, 0xeb, 0xfe, 0x37, 0x90, 0x2f, 0x13,
45+
0xe2, 0x51, 0x6e, 0xe4, 0xe6, 0x85, 0x62, 0x3a, 0xbe, 0x23, 0xb2, 0xde, 0x22, 0x87, 0x40, 0xf2,
46+
0xff, 0x65, 0xd2, 0xb8, 0xe7, 0x7b, 0x72, 0x21, 0x3a, 0x32, 0x7e, 0xd8, 0x80, 0x4e, 0x7a, 0xe3,
47+
];
48+
3149
#[derive(Copy, Clone, Debug)]
3250
pub struct StressTestConfig {
3351
pub no_threads: usize,
@@ -209,7 +227,7 @@ impl StressTestWorker {
209227
.verify_with_rsa_sha256(
210228
self.sign_key_name.clone(),
211229
HASH.to_vec(),
212-
vec![0xff; 128],
230+
SIGNATURE.to_vec(),
213231
)
214232
.expect_err("Verification should fail.");
215233
if !(status == ResponseStatus::PsaErrorInvalidSignature
@@ -245,7 +263,7 @@ impl StressTestWorker {
245263
.verify_with_ecdsa_sha256(
246264
self.ecc_key_name.as_ref().unwrap().clone(),
247265
HASH.to_vec(),
248-
vec![0xff; 64],
266+
SIGNATURE_ECC.to_vec(),
249267
)
250268
.expect_err("Verification should fail.");
251269
if !(status == ResponseStatus::PsaErrorInvalidSignature

0 commit comments

Comments
 (0)