FIPS readme: streamline FIPS preference eval#2247
Merged
dagood merged 2 commits intomicrosoft/mainfrom Apr 23, 2026
Merged
Conversation
Co-authored-by: Copilot <copilot@github.com>
Member
Author
|
I considered a mermaid diagram for the sequence: flowchart LR
A[Program starts] --> B{GODEBUG fips140\nsetting present?}
B -- Yes --> B2{fips140 value?}
B2 -- "off" --> Disabled["Disabled ❌"]
B2 -- "on | only | debug" --> Enabled["Enabled ✅"]
B2 -- "[other]" --> C
B -- No --> C{GOFIPS=1 or\nGOLANG_FIPS=1?}
C -- Yes --> Enabled
C -- No --> D{Platform-specific\npreference detected?}
D -- Yes --> Enabled
D -- No --> E{requirefips\nbuild option?}
E -- Yes --> Enabled
E -- No --> NoPref["No preference ❔"]
...But ultimately, I think it's simple enough already. |
Contributor
There was a problem hiding this comment.
Pull request overview
Updates the FIPS documentation to make the runtime “FIPS preference evaluation” logic easier to follow and to better explain the rationale for explicitly disabling FIPS preference.
Changes:
- Rewrites the runtime preference-evaluation list into a shorter, ordered set of rules.
- Adds a “Disabled ❌” behavior section and an explanatory note (container scenario) for why disabling may be desirable.
- Adds a version-scoping note indicating when
GODEBUG=fips140=offbehavior applies.
qmuntal
approved these changes
Apr 23, 2026
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.
Streamline the FIPS mode preference eval list to (try to) make it easier to take in. Expand on why someone would potentially want
Disabled ❌. Clarify(-ish) that the fix isn't in yet by specifying(As of Go 1.27, 1.26.3-1, and 1.25.10-1.).