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 certificate normalizer openssl rsa #292

Merged
merged 2 commits into from
Mar 1, 2023

Conversation

zcrt
Copy link
Contributor

@zcrt zcrt commented Feb 21, 2023

Changes

Fixes the Pythonerror that cryptography.hazmat.backends.openssl has no attribute x509, resulting in a failed normalizer.

Issue ticket number and link

#116

Proof

Trivial

Extra instructions for others

It looks like the bit responsible for verifying that a certificate is still not triggered after this fix.

Checklist for author(s):

  • All the commits in this PR are properly PGP-signed and verified;
  • This PR comes from a feature or hotfix branch, in line with our git branching strategy;
  • This PR is "bite-sized" and only focuses on a single issue, problem, or feature;
  • I am not reinventing the wheel: there is no high-quality library that already has this feature;
  • I have changed the example .env files if I added, removed, or changed any config options, and I have informed others that they need to modify their .env files if required;
  • I have performed a self-review of my own code;
  • I have commented my code, particularly in hard-to-understand areas;
  • I have made corresponding changes to the documentation, if necessary;
  • I have written unit, integration, and end-to-end tests for the change that I made;

If a non-trivial PR:

  • This PR is part of a milestone and has appropriate labels;
  • This PR is properly linked to the project board (either directly or via an issue);
  • I have added screenshots or some other proof that my code does what it is supposed to do;
## Checklist for functional reviewer(s):
- [ ] If a non-trivial PR: This PR is properly linked to an issue on the project board;
- [ ] I have checked out this branch, and successfully ran `make kat`;
- [ ] I have ran `make test-rf` and all end-to-end Robot Framework tests pass;
- [ ] I confirmed that the PR's advertised `feature` or `hotfix` works as intended;
- [ ] I confirmed that there are no unintended functional regressions in this branch;

### What works:
* _bullet point + screenshot (if useful) per tested functionality_

### What doesn't work:
* _bullet point + screenshot (if useful) per tested functionality_

### Bug or feature?:
* _bullet point + screenshot (if useful) if it is unclear whether something is a bug or an intended feature._
## Checklist for code reviewer(s):
- [ ] The code passes the CI tests and linters;
- [ ] The code does not bypass authentication or security mechanisms;
- [ ] The code does not introduce any dependency on a library that has not been properly vetted;
- [ ] The code does not violate Model-View-Template and our other architectural principles;
- [ ] The code contains docstrings, comments, and documentation where needed;
- [ ] The code prioritizes readability over performance where appropriate;
- [ ] The code conforms to our agreed coding standards.

@zcrt zcrt requested a review from a team as a code owner February 21, 2023 16:01
@underdarknl
Copy link
Contributor

Hm, i Have not seen any errors around this, might this be a platform specific issue?

@ammar92
Copy link
Contributor

ammar92 commented Feb 21, 2023

Interesting. Do you have an example certificate/ input that triggers this and by any chance an output of the error?

@zcrt
Copy link
Contributor Author

zcrt commented Feb 22, 2023

@underdarknl it is found using make kat from the main branch on an Ubuntu 22.04 system
@ammar92 the linked issue contains the full error, it triggers for an ellipticcurve-certificate, as RSA is checked first.

@underdarknl
Copy link
Contributor

@underdarknl it is found using make kat from the main branch on an Ubuntu 22.04 system @ammar92 the linked issue contains the full error, it triggers for an ellipticcurve-certificate, as RSA is checked first.

Ah yes, that would make sense. Not every algorithm works the same. although i would think they at least would have a x509 attribute. Ill play around tomorrow.

@zcrt
Copy link
Contributor Author

zcrt commented Feb 28, 2023

@underdarknl did you manage to solve the problem?

@underdarknl underdarknl merged commit 8adccc7 into minvws:main Mar 1, 2023
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.

3 participants