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: narrow acceptable RSA versions to maintain Python 2 compatability #528

Merged
merged 5 commits into from
Jun 11, 2020
Merged
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,9 @@
DEPENDENCIES = (
"cachetools>=2.0.0,<5.0",
"pyasn1-modules>=0.2.1",
"rsa>=3.1.4,<5.0",
# rsa 4.1, 4.1.1, 4.2 are broken on Py2: https://github.com/sybrenstuvel/python-rsa/issues/152
"rsa>=3.1.4,!=4.1,!=4.1.1,!=4.2,<5; python_version < 3",

Choose a reason for hiding this comment

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

I think "3" may need to be in quotes as in:
'rsa>=3.1.4,!=4.1,!=4.1.1,!=4.2,<5; python_version<"3"'
'rsa>=3.1.4,<5; python_version>="3"'

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Currently fixing and testing locally

Choose a reason for hiding this comment

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

My motivation for rsa>=3.1.4,!=4.1,!=4.1.1,!=4.2 was that there maybe another Py2 release (which we had) with additional fixes (there were security backports), and the range would be able to pick it up.
I also was hoping that new releases won't be broken on Py2, however, looks like 4.4 is installable and broken on Py2, so we'd have to exclude it.

Copy link
Contributor

Choose a reason for hiding this comment

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

Narrowed in in #532

'rsa<4.1; python_version < "3"',
'rsa>=3.1.4,<5; python_version >= "3"',

Copy link
Contributor

Choose a reason for hiding this comment

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

Released 1.17.2 with the pin above

"rsa>=3.1.4,<5; python_version >= 3",
"setuptools>=40.3.0",
"six>=1.9.0",
)
Expand Down