Skip to content

Commit 9a2fbe5

Browse files
authored
Build releases against the FIPS 140-3 validated Go crypto module (#6262)
## Changes Build released binaries with `GOFIPS140=v1.0.0`. This links the FIPS 140-3 validated Go Cryptographic Module into the binary and defaults FIPS 140-3 mode on, so no runtime flag is needed. ## Why Regulated environments (FedRAMP, IL5) require cryptography to come from a validated module. This has to be set at build time: the runtime `GODEBUG=fips140=on` only toggles the mode on whatever module was already linked, so without the build variable, there is no validated module in the binary and no certificate to cite. Pinned to a frozen version rather than an alias. `v1.0.0` is the version covered by CMVP certificate `#5247` This changes behavior for everyone, not just regulated users: the TLS client offers only FIPS-approved suites (6 instead of 13, dropping ChaCha20 and CBC) CI coverage for the FIPS build is added separately in #6193 ## Tests Ran the whole unit and acceptance suite against a FIPS build — no failures. Also confirmed all six release targets (linux/darwin/windows x amd64/arm64) cross-compile with the variable set; none of the platforms Go excludes from FIPS mode are in our matrix. _This PR was written by Claude Code._
1 parent 18bb9c1 commit 9a2fbe5

2 files changed

Lines changed: 8 additions & 0 deletions

File tree

.goreleaser.yaml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,13 @@ before:
77
builds:
88
- env:
99
- CGO_ENABLED=0
10+
# Link the Go Cryptographic Module and default FIPS 140-3 mode on. Pinned to
11+
# a frozen version rather than an alias: only v1.0.0 carries a CMVP
12+
# certificate, "latest" tracks the in-tree source with no fixed artifact to
13+
# cite, and "certified" is resolved by the toolchain so it moves on upgrade.
14+
# Callers who need the previous behaviour can start the binary with
15+
# GODEBUG=fips140=off.
16+
- GOFIPS140=v1.0.0
1017
mod_timestamp: '{{ .CommitTimestamp }}'
1118
flags:
1219
- -trimpath

.nextchanges/cli/fips140.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Released binaries are now built against the FIPS 140-3 validated Go Cryptographic Module, with FIPS 140-3 mode enabled by default. TLS connections negotiate only FIPS-approved cipher suites, which drops ChaCha20 and CBC from what the client offers. FIPS mode can be disabled at startup with `GODEBUG=fips140=off`, which restores the previous TLS behaviour ([#6262](https://github.com/databricks/cli/pull/6262)).

0 commit comments

Comments
 (0)