Repository navigation
Use SHA1 hash for kernel cache key to support Linux in FIPS-compliant mode - #5988
Merged
Merged
Conversation
Member
Author
|
pfnCI, test this please. |
Member
|
For some reason I can't get consistent timing with different ways of launching In [8]: %timeit hashlib.md5(a).hexdigest()
5.15 µs ± 1.85 ns per loop (mean ± std. dev. of 7 runs, 100000 loops each)
In [9]: %timeit hashlib.sha256(a).hexdigest()
2.29 µs ± 1.05 ns per loop (mean ± std. dev. of 7 runs, 100000 loops each)
In [10]: %timeit hashlib.sha1(a).hexdigest()
2.15 µs ± 0.303 ns per loop (mean ± std. dev. of 7 runs, 100000 loops each)
In [11]: timeit('hashlib.md5(a).hexdigest()')
4.6 ns ± 0.0011 ns per loop (mean ± std. dev. of 7 runs, 100000000 loops each)
In [12]: timeit('hashlib.sha1(a).hexdigest()')
4.61 ns ± 0.0055 ns per loop (mean ± std. dev. of 7 runs, 100000000 loops each)
In [13]: timeit('hashlib.sha256(a).hexdigest()')
4.79 ns ± 0.396 ns per loop (mean ± std. dev. of 7 runs, 100000000 loops each) |
Member
|
Jenkins CI test (for commit a3cf5d6, target branch master) failed with status FAILURE. |
Member
Author
|
All test failures are timeout, I believe they're harmless. |
Member
|
Jenkins, test this please |
Member
|
Jenkins CI test (for commit a3cf5d6, target branch master) succeeded! |
Member
Author
|
Test failure are timeout and known one (#5678). |
kmaehashi
disabled auto-merge
November 5, 2021 02:44
Member
Author
|
Merging as this is review approved and test failures are unrelated to this PR. |
Member
|
@jch1996 Those were fixed in #6023. |
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #5959.
I chose SHA1 based on the quick micro benchmark:
Under Python 3.6.8 on CentOS 8 stream with FIPS-compilant mode enabled:
(seems
usedforsecurityis available in any versions of Python installed via RHEL/CentOS 7/8 RPM)