Skip to content

Allow pycryptodome 4 - #133

Open
itzzdev09 wants to merge 1 commit into
hdwallet-io:masterfrom
itzzdev09:allow-pycryptodome-4
Open

itzzdev09 wants to merge 1 commit into
hdwallet-io:masterfrom
itzzdev09:allow-pycryptodome-4

Conversation

@itzzdev09

Copy link
Copy Markdown

requirements.txt caps pycryptodome at <4. pycryptodome 4.0.0 was released on 14 Oct, so hdwallet can't be installed next to packages that need it.

hdwallet uses keccak, ChaCha20_Poly1305 and PBKDF2 from pycryptodome. None of the 4.0 changes affect those calls:

  • PBKDF2 already gets an explicit count and hmac_hash_module (4.0 deprecates leaving them out), and is only a fallback when hashlib.pbkdf2_hmac is missing.
  • The Cardano ChaCha20-Poly1305 nonce is 12 bytes; the 4.0 change only applies to 8-byte nonces on messages over ~256 GiB.
  • The rest of 4.0 (dropping Python 2.7/3.8, ending pycryptodomex, ECC/ElGamal/RSA-size changes) doesn't touch hdwallet.

This raises the cap to <5.

Tests on Python 3.12, pytest tests: 253 passed with both pycryptodome 3.23.0 and 4.0.0. The same 5 setup errors happen on both on my machine.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant