-
Notifications
You must be signed in to change notification settings - Fork 795
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
Update for FIPS Compliance #3291
Conversation
…on changed due to the different hash algorithm which is used for the dataset name
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for the PR and for the additional info in your comment at #3292 (comment)!
I pushed a small commit to fix the failing test. Looks good from my side! I'm also in favour of making Altair FIPS compliant. Based on my understanding of your comment and some reading, this might be the only change necessary but we can't say for sure. In your FIPS environment, can you pip install from GitHub to test this?
Waiting with the merge until @mattijn also had another look as he answered in #3292.
hello @binste yes I would be more than happy to test in our FIPS environment! I'll let you know how that goes so you can get feedback on that before merging. Thanks :) |
A comment here: these hashes are just a way to generate unique keys for data objects, and the hashes appear literally in the resulting vega-lite output. Changing from The concerns of FIPS don't really apply here, because we're not using the |
Thanks for chiming in Jake! From here, I read it is not a checker but a special "FIPS compliant" Python build:
Could we maybe use a non-cryptographic hash function that still produces hashes, but not doubles the length? |
Sure, a non-cryptographic hash would be fine. The history here (if I recall correctly) is that we previously used a counter within the runtime, but this occasionally produced collisions in notebooks that had chart outputs from different Python sessions. Then we switched to If we can find an alternative that produces short hashes that are consistent across runs, then that should be fine. Maybe slicing off the first 32 characters of the sha256 hash would be a good solution. |
Hello all! @mattijn you are correct, the md5 hash function is not available in a FIPS-compliant environment. @jakevdp given that the hash value is not used for security purposes, I've updated to truncate the sha256 to 32 bytes (128-bits). This should allow it to run in FIPS-compliant environments while also maintaining the same length as an md5 hash. Obviously chance of collision is there, but still 128-bits which is very very small (practically zero) Hope this helps! |
Thanks @mattijn I'll install main branch on my FIPS environment and let you know how it goes! |
I need to run altair in a FIPS compliance environment and currently unable to due to the use of
md5
as a hashing algorithm. I've updated these to FIPS-compliantsha256
in the hopes that we can get altair running in a FIPS-compliant environment.Example of error in FIPS environment: