Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix intermittent "Invalid EC key" error #198

Open
kislyuk opened this issue Sep 9, 2022 · 0 comments
Open

Fix intermittent "Invalid EC key" error #198

kislyuk opened this issue Sep 9, 2022 · 0 comments

Comments

@kislyuk
Copy link
Member

kislyuk commented Sep 9, 2022

Probably just an error in test setup/RNG:

======================================================================
ERROR: test_basic_signxml_statements (__main__.TestSignXML)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/Users/kislyuk/projects/signxml/test/test.py", line 128, in test_basic_signxml_statements
    XMLVerifier().verify(signed_data, **verify_kwargs)
  File "/Users/kislyuk/projects/signxml/signxml/__init__.py", line 963, in verify
    self._verify_signature_with_pubkey(
  File "/Users/kislyuk/projects/signxml/signxml/__init__.py", line 634, in _verify_signature_with_pubkey
    key = ecpn.public_key(backend=default_backend())
  File "/opt/homebrew/lib/python3.10/site-packages/cryptography/hazmat/primitives/asymmetric/ec.py", line 364, in public_key
    return ossl.load_elliptic_curve_public_numbers(self)
  File "/opt/homebrew/lib/python3.10/site-packages/cryptography/hazmat/backends/openssl/backend.py", line 1313, in load_elliptic_curve_public_numbers
    self._ec_key_set_public_key_affine_coordinates(
  File "/opt/homebrew/lib/python3.10/site-packages/cryptography/hazmat/backends/openssl/backend.py", line 1480, in _ec_key_set_public_key_affine_coordinates
    raise ValueError("Invalid EC key.")
ValueError: Invalid EC key.

----------------------------------------------------------------------
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

No branches or pull requests

1 participant