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

[Dependencies] Add cryptography backend for python-jose #311

Merged
merged 2 commits into from
Feb 15, 2024

Conversation

judysng
Copy link
Contributor

@judysng judysng commented Feb 14, 2024

Changes

How Has This Been Tested?

Ran pytest, deployed, created/deleted cluster

In order to increase the likelihood of your contribution being accepted, please make sure you have read both the Contributing Guidelines and the Project Guidelines

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

Signed-off-by: Judy Ng <njud@amazon.com>
@@ -4,10 +4,10 @@ Werkzeug==2.3.8
boto3==1.24.30
requests==2.31.0
urllib3==1.26.18
python-jose==3.3.0
python-jose[cryptography]==3.3.0
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor: let's add a comment here specifying why we are selecting the specific backend.
Explanation is in the official python-jose page: https://pypi.org/project/python-jose/

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Another potential solution is to move a production maintained package for this as they mention in this issue wazuh/wazuh#21590. I think we should move away from python-jose, since we are likely to run into this issue again with no resolution

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks Ryan for this solution, I think for now we will use this method since it would require more effort and possible appsec reviews to change the library whereas for now we just want to mitigate the CVE. I created a task in the backlog though

@gmarciani
Copy link
Collaborator

Installing python-jose with a specific backend was a very good approach to bypass the edcsa CVE.
Good job!

Signed-off-by: Judy Ng <njud@amazon.com>
@gmarciani gmarciani merged commit 3d99aca into aws:main Feb 15, 2024
2 checks passed
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