Skip to content

Commit 0862451

Browse files
Update random and cryptography crates (RustPython#8010)
Redo of RustPython#7800. Bumping the random and crypto crates is not trivial. Both sets of crates have had API changes which require manual updates. AI use: I wrote all of the code myself but used AI to figure out the new APIs. AI explained SHAKE's block size and why the block_size() function doesn't exist in the new crate. I confirmed the block size, which is actually represented in the new types for SHAKE. `Shake128` is actually `Shake<168>` - 168 is the block size. I cited Wikipedia as it lists the SHAKE block size in bits. I also used AI to figure out HMAC for SHA3. Assisted-by: Codex:gpt-5.4
1 parent 6b2bdd9 commit 0862451

7 files changed

Lines changed: 147 additions & 122 deletions

File tree

.github/dependabot.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ updates:
2424
- "sha1"
2525
- "sha2"
2626
- "sha3"
27+
- "shake"
2728
- "blake2"
2829
- "hmac"
2930
- "pbkdf2"
@@ -88,6 +89,7 @@ updates:
8889
- "getrandom"
8990
- "mt19937"
9091
- "rand*"
92+
- "chacha20"
9193
rayon:
9294
patterns:
9395
- "rayon*"

Cargo.lock

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

0 commit comments

Comments
 (0)