The Wire · Showcase
CRYPTO/TLS PURGE: GO DUMPS UNSAFE RANDOMNESS KNOBS AND MLKEM WORKAROUNDS
By RepoJournal · Filed · About Go
Go is ripping out deprecated randomness controls from crypto/tls and cementing ML-KEM hybrid support as the forward path, signaling the end of an era of backwards compatibility knobs.
The core Go team deprecated Config.Rand and removed the tlsunsafeekm and tlsrsakex GODEBUG settings [1][2][3], cleaning up surface area that was already broken by design: ML-KEM encapsulation in X25519MLKEM768 never respected Config.Rand anyway, so the feature was fiction. In its place, crypto/tls now uses mlkem.GenerateKey directly [4], which better aligns with FIPS 140-3 compliance and kills the workaround pattern of passing random bytes to mlkem.NewDecapsulationKey. Over on pkgsite, the team shipped strict module path validation [5] that returns 400 BadRequest when a package path is submitted instead of a module path, plus added -goos and -goarch flags to the pkgsite-cli package command [6], improving discovery for cross-platform queries. vscode-go added a forrval snippet for single-variable range loops [7], reflecting Go 1.23+ patterns, and refactored form.ts to decouple from goCtx [8], making code more portable across extensions. The website tour now clarifies slice length semantics [9] to reduce confusion for learners. Build infrastructure tightened x-repo workflow closures [10] and pkgsite improved error messaging with fix suggestions [11]. These are all structural hygiene updates: Go is removing debt, not shipping features.
Action items
- → Audit internal code for Config.Rand usage before next Go release cycle; it will error golang/go [plan]
- → Remove any tlsunsafeekm or tlsrsakex GODEBUG workarounds from your TLS configs golang/go [immediate]
- → Monitor pkgsite API client code for 400 BadRequest changes if you pass package paths golang/pkgsite [monitor]
References
- [1] crypto/tls: deprecate Config.Rand golang/go
- [2] crypto/tls: remove the tlsunsafeekm GODEBUG setting golang/go
- [3] crypto/tls: remove tlsrsakex GODEBUG setting golang/go
- [4] crypto/tls: use mlkem.GenerateKey for ML-KEM hybrids golang/go
- [5] internal/api: strictly validate module paths golang/pkgsite
- [6] cmd/internal/pkgsite-cli: support -goos and -goarch flags in package command golang/pkgsite
- [7] snippets: add forrval snippet for single-variable range loops golang/vscode-go
- [8] extension/src: replace goCtx with vscode language client golang/vscode-go
- [9] _content/tour: clarify slice length wording in moretypes.article golang/website
- [10] internal/task: refactor closures in x-repo workflow golang/build
- [11] cmd/internal/pkgsite-cli/client: return fix suggestions golang/pkgsite
FAQ
- What changed in Go on May 20, 2026?
- Go is ripping out deprecated randomness controls from crypto/tls and cementing ML-KEM hybrid support as the forward path, signaling the end of an era of backwards compatibility knobs.
- What should Go teams do about it?
- Audit internal code for Config.Rand usage before next Go release cycle; it will error • Remove any tlsunsafeekm or tlsrsakex GODEBUG workarounds from your TLS configs • Monitor pkgsite API client code for 400 BadRequest changes if you pass package paths
- Which Go repositories shipped on May 20, 2026?
- golang/go, golang/pkgsite, golang/vscode-go, golang/website, golang/build