Skip to content

Commit

Permalink
tests: add import for python-cryptography >= 43.0.0
Browse files Browse the repository at this point in the history
write_pkcs12_container method raises following error message with
python-cryptography-43.0.0:

  Error: module 'cryptography.hazmat.primitives.serialization' has no attribute 'pkcs12'

Explicit import of the pkcs12 module resolves the issue.
  • Loading branch information
arkamar authored and mtrojnar committed Sep 2, 2024
1 parent 4dd836b commit 64305d6
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions tests/make_certificates.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@
from cryptography.hazmat.primitives import serialization
from cryptography.hazmat.primitives.asymmetric import rsa

import cryptography.hazmat.primitives.serialization.pkcs12

RESULT_PATH = os.getcwd()
CERTS_PATH = os.path.join(RESULT_PATH, "./Testing/certs/")

Expand Down

0 comments on commit 64305d6

Please sign in to comment.