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

Let crypto._cert_fingerprint pass bytes to load_pem_x509_certificate #77

Closed
wants to merge 1 commit into from

Conversation

zmousm
Copy link

@zmousm zmousm commented May 19, 2024

crypto._cert_fingerprint must ensure first parameter to load_pem_x509_certificate is bytes, as there are code paths which pass this as a string (such as crypto.from_keyspec -> crypto._load_keyspec -> crypto.XMLSecCryptoFromXML.__init__ -> crypto._cert_fingerprint).

All Submissions:

  • Have you checked to ensure there aren't other open Pull Requests for the same update/change?
  • Have you added an explanation of what problem you are trying to solve with this PR?
  • Have you added information on what your changes do and why you chose this as your solution?
  • Have you written new tests for your changes?
  • Does your submission pass tests?
  • This project follows PEP8 style guide. Have you run your code against the 'flake8' linter?

crypto._cert_fingerprint must ensure first parameter
to load_pem_x509_certificate is bytes, as there are
code paths which pass this as a string, such as
crypto.from_keyspec -> crypto._load_keyspec ->
crypto.XMLSecCryptoFromXML.__init__ ->
crypto._cert_fingerprint
@zmousm zmousm marked this pull request as draft May 22, 2024 09:00
@zmousm
Copy link
Author

zmousm commented May 22, 2024

The issue affecting crypto._cert_fingerprint also exists in other places where load_pem_x509_certificate is called, so I think #78 may be a better solution

@zmousm zmousm closed this May 22, 2024
@zmousm zmousm deleted the patch-1 branch May 22, 2024 09:09
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

Successfully merging this pull request may close these issues.

1 participant