Skip to content

Commit fb64844

Browse files
authored
Merge pull request #10205 from holtrop-wolfssl/rust-fenrir-fixes
Rust fenrir fixes
2 parents 755a90b + 4f31ff9 commit fb64844

File tree

26 files changed

+1102
-656
lines changed

26 files changed

+1102
-656
lines changed

wolfcrypt/src/kdf.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -984,7 +984,7 @@ static int wc_srtp_kdf_derive_key(byte* block, int idxSz, byte label,
984984
* @param [in] saltSz Size of random in bytes.
985985
* @param [in] kdrIdx Key derivation rate. kdr = 0 when -1, otherwise
986986
* kdr = 2^kdrIdx.
987-
* @param [in] index Index value to XOR in.
987+
* @param [in] idx Index value to XOR in.
988988
* @param [out] key1 First key. Label value of 0x00.
989989
* @param [in] key1Sz Size of first key in bytes.
990990
* @param [out] key2 Second key. Label value of 0x01.
@@ -1069,7 +1069,7 @@ int wc_SRTP_KDF(const byte* key, word32 keySz, const byte* salt, word32 saltSz,
10691069
* @param [in] saltSz Size of random in bytes.
10701070
* @param [in] kdrIdx Key derivation rate index. kdr = 0 when -1, otherwise
10711071
* kdr = 2^kdrIdx. See wc_SRTP_KDF_kdr_to_idx()
1072-
* @param [in] index Index value to XOR in.
1072+
* @param [in] idx Index value to XOR in.
10731073
* @param [out] key1 First key. Label value of 0x03.
10741074
* @param [in] key1Sz Size of first key in bytes.
10751075
* @param [out] key2 Second key. Label value of 0x04.
@@ -1171,7 +1171,7 @@ int wc_SRTCP_KDF(const byte* key, word32 keySz, const byte* salt, word32 saltSz,
11711171
* @param [in] saltSz Size of random in bytes.
11721172
* @param [in] kdrIdx Key derivation rate index. kdr = 0 when -1, otherwise
11731173
* kdr = 2^kdrIdx. See wc_SRTP_KDF_kdr_to_idx()
1174-
* @param [in] index Index value to XOR in.
1174+
* @param [in] idx Index value to XOR in.
11751175
* @param [in] label Label to use when deriving key.
11761176
* @param [out] outKey Derived key.
11771177
* @param [in] outKeySz Size of derived key in bytes.
@@ -1244,7 +1244,7 @@ int wc_SRTP_KDF_label(const byte* key, word32 keySz, const byte* salt,
12441244
* @param [in] saltSz Size of random in bytes.
12451245
* @param [in] kdrIdx Key derivation rate index. kdr = 0 when -1, otherwise
12461246
* kdr = 2^kdrIdx. See wc_SRTP_KDF_kdr_to_idx()
1247-
* @param [in] index Index value to XOR in.
1247+
* @param [in] idx Index value to XOR in.
12481248
* @param [in] label Label to use when deriving key.
12491249
* @param [out] outKey Derived key.
12501250
* @param [in] outKeySz Size of derived key in bytes.

wrapper/rust/wolfssl-wolfcrypt/Cargo.lock

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

wrapper/rust/wolfssl-wolfcrypt/Cargo.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ cipher = ["dep:cipher"]
2020
rand_core = { version = "0.10", optional = true, default-features = false }
2121
aead = { version = "0.5", optional = true, default-features = false }
2222
cipher = { version = "0.5", optional = true, default-features = false }
23+
zeroize = { version = "1.3", default-features = false, features = ["derive"] }
2324

2425
[dev-dependencies]
2526
aead = { version = "0.5", features = ["alloc", "dev"] }

wrapper/rust/wolfssl-wolfcrypt/build.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -461,8 +461,6 @@ fn scan_cfg() -> Result<()> {
461461
check_cfg(&binding, "DILITHIUM_LEVEL2_KEY_SIZE", "dilithium_level2");
462462
check_cfg(&binding, "DILITHIUM_LEVEL3_KEY_SIZE", "dilithium_level3");
463463
check_cfg(&binding, "DILITHIUM_LEVEL5_KEY_SIZE", "dilithium_level5");
464-
check_cfg(&binding, "DILITHIUM_SEED_SZ", "dilithium_make_key_seed_sz");
465-
check_cfg(&binding, "DILITHIUM_RND_SZ", "dilithium_rnd_sz");
466464

467465
/* mlkem / ML-KEM */
468466
check_cfg(&binding, "wc_MlKemKey_Init", "mlkem");

0 commit comments

Comments
 (0)