Update dependency pycryptodome to v4 #111
No reviewers
Labels
No labels
Security
TeX
auto-update
check
delete-eslint-rc-js
check
update-builddeps-package-json
check
update-eslint-rc-js
check
update-gitignore
check
update-merge-request-template
check
update-prettier-ignore
check
update-pyproject-toml
check
update-renovate-json
check
update-tox-ini
part
backend
part
ci
part
docs
part
frontend
part
i18n
part
non-technical
part
packaging
prio
1
prio
2
prio
3
release-mr-5.x
size
large
size
medium
size
small
source
customer
source
customer::fsmw
source
customer::fss
source
customer::teckids
source
downstream
type
bug
type
feature
type
refactoring
workflow
blocked
workflow
confirmed
workflow
current-todo
workflow
discussing
workflow
new-app
workflow
wontfix
source::aleksolotl
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
aleksis/AlekSIS-App-Kompjuter!111
Loading…
Reference in a new issue
No description provided.
Delete branch "renovate/pycryptodome-4.x"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
This PR contains the following updates:
^3.20.0→^4.0.0Release Notes
Legrandin/pycryptodome (pycryptodome)
v4.4.0: - LyonCompare Source
New features
Crypto.PublicKey.ECC: key generation,import and export, ECDSA with
Crypto.Signature.DSS, and ECDH withCrypto.Protocol.DH.'sec1'toCrypto.Signature.DSS.new, for randomized ECDSA on all Weierstrasscurves. Mode
'fips-186-3'does not accept secp256k1, which is not a curve of that standard.low_stoCrypto.Signature.DSS.new, for ECDSA signaturesin the low-S form (for all curves): signing normalizes
s, and verifying rejects a highs.Resolved issues
ECC.import_keyraisedTypeErrorinstead ofValueErrorfor an OpenSSH public keywith an unsupported curve or key type, or with a malformed body.
ECC.import_keyaccepted an OpenSSH key (public or private) whose curve did not match its key type.unseal()consumed a sequence number, so all latermessages of that context failed too. The sequence number now only advances when
unseal()succeeds (RFC 9180, Section 5.2). Thanks to Zulfareen Shaikh.
seal()that raised an exception also consumed a sequence number,so the receiver could not unseal the messages that followed.
v4.3.0: - KourouCompare Source
New features
on all platforms.
of the ARMv8 Cryptography Extensions (AES and PMULL), when available.
On a Graviton3, AES-ECB is about 35x faster, GCM 7x, OCB 10-12x,
and CTR, CBC, CFB and OFB 3-6x.
Integer.random_range()is about 2x faster when the bounds are public,with the same output: ECDSA signatures are about 13% faster (P-256),
DSA signatures about 4%, and ECC key generation about 35%.
The RSA modulus and the DSA subgroup order are now public
Integerobjects.(RSA-2048 to RSA-4096), verification and encryption 2-2.7x.
Modular exponentiation with a public exponent (like the RSA public exponent)
no longer uses the slower constant-time algorithm, which is only needed for
secret exponents, and the Montgomery context of a modulus is kept with it.
The RSA blinding factor is squared between uses (a new one every 32 uses,
and after a fork).
faster: DSA signatures and verification are about 25% faster.
uses the faster power for public exponents (the exponent p - 2 is public).
of the ARMv8 Cryptography Extensions, and SHA-384 and SHA-512 the SHA-512
instructions of ARMv8.2, when available.
On a Graviton3, SHA-256 is about 3.8x faster, and SHA-512 2x.
(2 with scalar code and 2 with NEON).
On a Graviton3, KangarooTwelve is 1.9x faster, ML-DSA 7-20% and ML-KEM 7-8%.
Crypto.Cipher.PKCS1_v1_5) performs implicit rejection,as defined in section 7.2 of
draft-irtf-cfrg-rsa-guidance,when
decrypt()is called without asentinel(which is now optional):when the padding of a ciphertext is not correct, it returns a pseudo-random
message, which only depends on the private key and on the ciphertext.
With a
sentinel,decrypt()behaves as before.Other changes
Ed25519tests and the newchacha20_counter_test.json).XChaCha20 keeps the construction of draft-irtf-cfrg-xchacha (HChaCha20 and the ChaCha20
of RFC 8439), with a 32-bit block counter: the key stream ends after 256 GiB,
whereas libsodium and Wycheproof use a 64-bit counter.
Resolved issues
through the
sentinelreturned for ciphertexts with incorrect padding.Calling
decrypt()withoutsentinel(implicit rejection) is nowrecommended. Thanks to tomato42 and eslerm.
decrypt()never returned asentinelthat is not a byte string(such as
None), and it returned an empty byte string instead.Crypto.Util.asn1.DerObjectIdaccepted an ASN.1 OBJECT IDENTIFIER where an arcis encoded with the initial octet 0x80 (invalid, as that would violate the minimal
encoding rule for BER) or where the last octet encoding the last arc has bit 7 set
(invalid, and that arc would also be dropped). In those cases, decoding now fails.
Thanks to Zulfareen Shaikh.
v4.2.0: - JuraCompare Source
New features
Crypto.PublicKey.MLKEM, for ML-KEM keys (FIPS 203).It is based on the portable C code of
mlkem-native <https://github.com/pq-code-package/mlkem-native>_ (v2.0.0),with the Keccak code of PyCryptodome, also compiled for AVX2 and BMI2 (with 4-way SHA-3).
The keys can be exported and imported as PKCS#8 DER or PEM files.
Crypto.PublicKey.Hybrid, to model hybrid keys (post-quantum + traditional).It supports the hybrid KEM MLKEM768-X25519 (X-Wing), which combines ML-KEM-768 and X25519.
For now, hybrid keys can only be generated and used with HPKE: they cannot be exported or imported.
Crypto.Protocol.HPKEaccepts ML-KEM keys and X-Wing keys,for post-quantum HPKE (draft-ietf-hpke-pq), in the Base and PSK modes.
v4.1.0: - Issy-les-MoulineauxCompare Source
New features
Crypto.PublicKey.MLDSA, for ML-DSA keys (FIPS 204).It is based on the portable C code of
mldsa-native <https://github.com/pq-code-package/mldsa-native>_ (v2.0.0), with the Keccak code of PyCryptodome. On CPUs with AVX2 and BMI2, a version compiled for them and with 4-way SHA-3 is used: compared to the portable version, key generation and verification are 30-45% faster, signing 15-30%.Crypto.Signature.mldsa, for ML-DSA and HashML-DSA signatures (FIPS 204), hedged (default) or deterministic, with an optional context. The newMLDSAMuHashcomputes the message representative mu (external mu), to sign or verify a large message in pieces.digest()in the modules of the SHA-2 and SHA-3 hashes, to hash a whole message with a single call, likeCrypto.Hash.KangarooTwelve.digest(). For messages up to 1 KiB, it is 1.5x to 3.4x faster thannew()followed bydigest().Crypto.IO.PKCS8.wrap()has a new parameterpublic_key, to create aOneAsymmetricKeyversion 2 (RFC 5958) with the fieldpublicKey.Crypto.IO.PKCS8.unwrap()returns anUnwrappedKey: still a tuple(oid, private_key, params),with the same items as attributes, plus
public_key(the fieldpublicKey, if present).Resolved issues
Crypto.PublicKey.ECC.import_key()checks that the fieldpublicKeyof a PKCS#8OneAsymmetricKeyversion 2 (RFC 5958), if present, matches the private key. Before, it was ignored.v4.0.1: - Le HavreCompare Source
New features
clang-cl(compatible with MSVC), so thecode for CPUs with AVX2, BMI2 and ADX is also used on Windows: SHA-3 and the other
Keccak-based functions, KangarooTwelve, ChaCha20, Salsa20, and the big integers of RSA,
DSA and the NIST curves. To build from source with
clang-cl, set the environmentvariable
PYCRYPTODOME_CLANG_CL(see the installation instructions).v4.0.0: - GrenobleCompare Source
Major release, with some breaking changes. See Changelog.
Configuration
📅 Schedule: (UTC)
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR has been generated by Mend Renovate CLI.
6ab1b186f71152e405a51152e405a5eaddb73441View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.