summaryrefslogtreecommitdiff
path: root/tests/wycheproof
Commit message (Collapse)AuthorAgeFilesLines
* Stop validating keys in ECDH exchange (#8490)Alex Gaynor2023-03-111-7/+1
| | | | | The theory here is that we're already doing sufficient validation key loading, and this is purely duplicative. Note that there's at least _some_ validationg that was previously occurring only ECDH, the LowOrderPublic check that can be seen in wycheproof.
* cache ECDH values in wycheproof too (#8487)Paul Kehrer2023-03-103-23/+30
| | | | | this alters and renames the caching function a bit since it caches *to the group* object but the actual values (in ECDH) come from the testcase itself
* Cache some keys that are reused in wycheproof tests (#8479)Alex Gaynor2023-03-102-21/+39
|
* Update to the new wycheproof (#8403)Alex Gaynor2023-02-282-1/+25
|
* add support for centos9-fips (#8216)Paul Kehrer2023-02-061-10/+26
| | | | | | | | * add support for centos9-fips Requires a variety of new FIPS constraints on our tests, including the addition of rsa_encryption_supported * review comments
* don't run dsa wycheproof without dsa (#8201)Alex Gaynor2023-02-021-0/+4
|
* Use the ruff 'pyupgrade' checks (#8104)Alex Gaynor2023-01-202-2/+2
|
* Update formatting for new ruff (#7937)Alex Gaynor2022-12-261-1/+1
|
* Switch from flake8 to ruff (#7920)Alex Gaynor2022-12-218-9/+3
| | | It's more than 60x faster.
* Bump OpenSSL/BoringSSL and adapt for OpenSSL RSA bleichenbacher mitigation ↵Alex Gaynor2022-12-141-5/+15
| | | | | | | | | (#7895) * Bump BoringSSL and/or OpenSSL in CI * Attempt to work-around wycheproof tests Co-authored-by: pyca-boringbot[bot] <pyca-boringbot[bot]+106132319@users.noreply.github.com>
* add unsafe_skip_rsa_key_validation (#7667)Paul Kehrer2022-10-032-3/+4
| | | | | | | | | | | | | | | | | | | * add unsafe_skip_rsa_key_validation This allows users to skip RSA key validation when calling load_pem_private_key, load_der_private_key, and RSAPrivateNumbers.private_key. This is a significant performance improvement but is **only safe if you know the key is valid**. If you use this when the key is invalid OpenSSL makes no guarantees about what might happen. Infinite loops, crashes, and all manner of terrible things become possible if that occurs. Beware, beware, beware. * Apply suggestions from code review Co-authored-by: Alex Gaynor <alex.gaynor@gmail.com> * remove unneeded variable Co-authored-by: Alex Gaynor <alex.gaynor@gmail.com>
* fix typo in test name (#7426)Alex Gaynor2022-07-161-1/+1
|
* update comment now that we dropped 1.0.2 (#7242)Alex Gaynor2022-05-211-3/+3
| | | | | * remove error handling for 1.0.2 * Update test_ecdsa.py
* Drop supported for older LibreSSL (#6660)Alex Gaynor2021-11-261-8/+0
| | | | | | | | | | | | | * Drop supported for older LibreSSL 3.1 covers the oldest version used by versions of Alpine and OpenBSD that are supported by their upstreams. * Remove tests that are now unused * Update CHANGELOG.rst Co-authored-by: Paul Kehrer <paul.l.kehrer@gmail.com> Co-authored-by: Paul Kehrer <paul.l.kehrer@gmail.com>
* x509 tests for boring (#6590)Paul Kehrer2021-11-121-3/+0
|
* FIPS 3.0.0 support (#6012)Paul Kehrer2021-08-292-1/+8
| | | | | | | | | | | | | | | | | | | | | * FIPS 3.0.0 support * comments * remove unneeded error clear * review comments * small refactor * black * flake8 too * review feedback * oops * fix
* Speed up RSA tests in 3.0.0 (#6206)Paul Kehrer2021-08-111-1/+3
| | | | | | | | | | | | | | | | | | | | * Speed up RSA tests in 3.0.0 RSA_check_key is slower in OpenSSL 3.0.0 due to improved primality checking. In normal use this is unlikely to be a problem since users don't load new keys constantly, but we do in our tests. This adds some private flags to allow skipping those checks for performance reasons. On my laptop with this patch it takes 16s to run test_rsa.py. The previous commit takes 72s. * black * different approach * skip rsa key checks in wycheproof wycheproof's tets don't rely on broken keys
* Remove requires_backend_interface from tests because it was useless (#5884)Alex Gaynor2021-03-018-23/+0
|
* Added typing for a bunch of random stuff (#5743)Alex Gaynor2021-02-041-0/+2
|
* rsa type hinting (#5733)Paul Kehrer2021-02-011-0/+1
| | | | | | | | | | | | | | | | | | | * rsa type hinting * remove unused import * missed return type * type fixes * ignores no longer required * black gets me every time * Update src/cryptography/hazmat/backends/openssl/rsa.py Co-authored-by: Alex Gaynor <alex.gaynor@gmail.com> Co-authored-by: Alex Gaynor <alex.gaynor@gmail.com>
* add EC type hinting (#5729)Paul Kehrer2021-01-311-0/+2
|
* enable mypy over tests (#5721)Paul Kehrer2021-01-313-1/+9
| | | | | | | | | * clean mypy with tests dir * remove most no_type_check annotations * le sigh * remove unneeded comments
* fixes #5611 -- use subtests for wycheproof tests for speed (#5616)Alex Gaynor2020-12-0914-24/+64
|
* Remove __future__ import from our code (#5610)Alex Gaynor2020-12-0914-14/+0
|
* Simplify wycheproof pytest code (#5579)Alex Gaynor2020-11-201-10/+1
|
* GCM IV size limits (#5553)Paul Kehrer2020-11-091-6/+11
| | | | | | | | | | | | * GCM IV size limits OpenSSL 3.0.0 is going to enforce these size limits so we might as well put them in now. * fix the tests * black * these cases can't happen if we're limiting IV size already
* Delete all the 1.0.2 code (#5511)Alex Gaynor2020-10-251-16/+1
|
* new black, actually slightly different than the old black (#5429)Paul Kehrer2020-08-261-2/+4
|
* Paint it Black by the Rolling Stones (#5324)Alex Gaynor2020-07-2010-60/+47
|
* test FIPS mode on centos8 (#5323)Paul Kehrer2020-07-201-0/+8
| | | | | | | | | | | | | | | * test FIPS mode on centos8 * remove branch we don't take * simpler * better comment * rename * revert some things that don't matter * small cleanups
* Added wycheproof hmac vectors (#5238)Alex Gaynor2020-04-261-0/+66
|
* Refs #5075 -- added the remainder of the wycheproof rsa tests (#5237)Alex Gaynor2020-04-261-0/+28
|
* Added wycheproof RSA PKCSv1 encryption tests (#5234)Alex Gaynor2020-04-261-2/+34
|
* Dropped support for LibreSSL 2.7, 2.8, and 2.9.0 (2.9.1+ are still ↵Alex Gaynor2020-04-251-11/+1
| | | | supported) (#5231)
* Refs #5075 -- use ed448_test.json from wycheproof (#5191)Alex Gaynor2020-04-121-3/+27
|
* Refs #5075 -- use hkdf_*.json from wycheproof (#5190)Alex Gaynor2020-04-122-2/+52
|
* Refs #5075 -- use rsa_oaep_*.json from wycheproof (#5100)Alex Gaynor2020-04-111-0/+63
|
* Drop support for OpenSSL 1.0.1 (#5178)Alex Gaynor2020-04-042-4/+4
|
* Refs #5075 -- use ecdsa_*.json from wycheproof (#5099)Alex Gaynor2020-01-121-0/+17
|
* Refs #5075 -- use dsa_*.json from wycheproof (#5098)Alex Gaynor2020-01-121-0/+4
|
* Refs #5075 -- use rsa_signature_*.json from wycheproof (#5078)Alex Gaynor2020-01-121-0/+22
| | | | | | * Refs #5075 -- use rsa_signature_*.json from wycheproof * for azure
* Refs #5075 -- use x448_test.json from wycheproof (#5077)Alex Gaynor2020-01-121-0/+48
| | | | | | | | | | * Refs #5075 -- use x448_test.json from wycheproof * Fixed test * crypto libraries from people who can't math, it's fine * Skip teh weirdo 57 byte public keys
* Get tests passing with latest wycheproof clone (#5076)Alex Gaynor2019-11-262-1/+4
| | | | | | | | * Get tests passing with latest wycheproof clone * Fix x25519 wycheproof tests * Fix for acme repo changes
* Fix some backend feature checks in tests (#4931)David Benjamin2019-07-082-4/+0
| | | | | | | | | | | | | | | * Remove irrelevant DHBackend test conditions DHBackend provides functions for plain finite-field Diffie-Hellman. X25519 and X448 are their own algorithms, and Ed25519 and Ed448 aren't even Diffie-Hellman primitives. * Add missing backend support checks. Some new AES and EC tests did not check for whether the corresponding mode or curve was supported by the backend. * Add a DummyMode for coverage
* ed25519 support (#4114)Paul Kehrer2019-02-261-0/+45
| | | | | | * ed25519 support * review feedback
* Run wycheproof RSA tests on LibreSSL>=2.8 (#4737)Alex Gaynor2019-01-241-6/+6
| | | | | | | | * Run wycheproof RSA tests on LibreSSL>=2.8 * Define it this way * These are errors on libressl
* Serialization x25519 (#4688)Paul Kehrer2019-01-141-1/+1
| | | | | | | | | | | | | | | | | * modify x25519 serialization to match x448 supports raw and pkcs8 encoding on private_bytes supports raw and subjectpublickeyinfo on public_bytes deprecates zero argument call to public_bytes * add docs * this is public now * don't need that * review feedback
* Support compressed points in the wycheproof tests (#4648)Alex Gaynor2018-12-181-15/+5
| | | | | | | | * Support compressed points in the wycheproof tests * Handle entries with no public key * Ok, let's try this
* Refs #4375 -- added ECDH EC point wycheproof tests (#4384)Alex Gaynor2018-08-061-0/+41
|
* Refs #4375 -- added RSA PSS wycheproof tests (#4381)Alex Gaynor2018-08-031-1/+41
|