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

bpo-44611: Use BCryptGenRandom instead of CryptGenRandom on Windows #27168

Merged
merged 2 commits into from Jul 23, 2021

Conversation

corona10
Copy link
Member

@corona10 corona10 commented Jul 15, 2021

https://bugs.python.org/issue44611

FYI, this patch is written at Microsoft Azure system which I got the credits from Microsoft!
https://mail.python.org/archives/list/python-committers@python.org/message/LXXZ3F7MHCAULKYZADGAKZHE6FBLNZ62/

@corona10
Copy link
Member Author

Microsoft

CNG is supported beginning with Windows Server 2008 and Windows Vista

CPython

This means that Python 3.9 supports Windows 8.1 and newer. If you require Windows 7 support, please install Python 3.8.

@corona10 corona10 changed the title bpo-44611: Use BCryptGenRandom instead of CryptGenRandom on Windows [WIP] bpo-44611: Use BCryptGenRandom instead of CryptGenRandom on Windows Jul 15, 2021
@corona10 corona10 force-pushed the bpo-44611 branch 2 times, most recently from 0279db3 to 37660c6 Compare July 15, 2021 18:18
@corona10 corona10 changed the title [WIP] bpo-44611: Use BCryptGenRandom instead of CryptGenRandom on Windows bpo-44611: Use BCryptGenRandom instead of CryptGenRandom on Windows Jul 15, 2021
@corona10 corona10 requested review from tim-one and zooba July 15, 2021 18:20
@corona10
Copy link
Member Author

corona10 commented Jul 16, 2021

I am now waiting for @tim-one 's review.
(I will merge after review)

@corona10
Copy link
Member Author

PS C:\Users\corona10\cpython> PCbuild\amd64\python_d.exe -m test test_random -R 3:3
0:00:00 Run tests sequentially
0:00:00 [1/1] test_random
beginning 6 repetitions
123456
......

I checked the memory is not leaked with this patch :)

@corona10 corona10 merged commit 906fe47 into python:main Jul 23, 2021
@corona10 corona10 deleted the bpo-44611 branch July 23, 2021 14:04
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.

None yet

4 participants