Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Fix: Replace blake2b with FIPS-compatible hash fallback to support secure environments#2357

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Open
sumit-gupta-sgt wants to merge3 commits intosodadata:main
base:main
Choose a base branch
Loading
fromsumit-gupta-sgt:fix/fips-hash-fallback

Conversation

@sumit-gupta-sgt
Copy link

Summary

This PR replaces all direct uses ofhashlib.blake2b() with a utility functionfips_safe_hasher() that falls back to a truncatedsha256() hash in FIPS-enabled environments.

This resolves failures such as:

...which occur becauseblake2b is disabled when Python is compiled against OpenSSL in FIPS mode.

Key Changes

  • Introducedfips_safe_hasher() insoda/common/utils/hash_utils.py.
  • Replacedblake2b usage across the codebase with this safe wrapper.
  • Added a test for fallback behavior.

Why This Matters

In regulated or security-hardened systems (e.g., federal workloads, STIG-compliant Linux), FIPS mode is required and disables non-compliant hash functions like BLAKE2. This change ensures Soda Core works in those environments without modification or monkey-patching.

Compatibility

  • Backwards compatible (keeps digest length intact)
  • No external dependencies introduced
  • Safe fallback behavior

Related

  • Fixes compatibility issue reported with FIPS-mode Python
  • Builds on community request to support hardened deployments

Happy to adjust or expand test coverage as needed!

@CLAassistant
Copy link

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign ourContributor License Agreement before we can accept your contribution.


Sumit Gupta seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, pleaseadd the email address used for this commit to your account.
You have signed the CLA already but the status is still pending? Let usrecheck it.

@sonarqubecloud
Copy link

Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

No reviews

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

2 participants

@sumit-gupta-sgt@CLAassistant

[8]ページ先頭

©2009-2025 Movatter.jp