ehn-sign-verify-python-trivial
ehn-sign-verify-python-trivial copied to clipboard
ModuleNotFoundError: No module named 'cose.curves'
Trying to execute echo "{'A': 1234}" | python3 hc1_sign.py | python3 hc1_verify.py
this error occurs
Traceback (most recent call last):
File "/home/pi/ehn-sign-verify-python-trivial/hc1_sign.py", line 13, in <module>
from cose.curves import P256
ModuleNotFoundError: No module named 'cose.curves'
Traceback (most recent call last):
File "/home/pi/ehn-sign-verify-python-trivial/hc1_verify.py", line 16, in <module>
from cose.curves import P256
ModuleNotFoundError: No module named 'cose.curves'
Of course module is installed via pip3 install cose
What is wrong here?
Hi @JsBergbau, I run into the same issue. Seems the cose library was reorganized with new version. So with new cose library you should include P256 like this:
from cose.keys.curves import P256
See also https://github.com/ehn-dcc-development/python-hcert for a ready to use library. Not yet on PyPi, but I'm happy to publish it if requested.