]> Cypherpunks repositories - gostls13.git/commitdiff
crypto/internal/fips140: mark OpenBSD unsupported
authorFilippo Valsorda <filippo@golang.org>
Wed, 1 Jan 2025 14:08:28 +0000 (15:08 +0100)
committerGopher Robot <gobot@golang.org>
Fri, 3 Jan 2025 18:53:43 +0000 (10:53 -0800)
Since OpenBSD 7.3, external linking uses -fexecute-only, which breaks
the integrity check. Since we are not validating on OpenBSD anyway,
mark it as unsupported at least for now.

Fixes #70880

Change-Id: I6a6a4656b6c7a97c0962b4158d920f9e6b19678e
Reviewed-on: https://go-review.googlesource.com/c/go/+/639337
Auto-Submit: Filippo Valsorda <filippo@golang.org>
Reviewed-by: Daniel McCarney <daniel@binaryparadox.net>
Reviewed-by: Roland Shoemaker <roland@golang.org>
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com>
Reviewed-by: Joel Sing <joel@sing.id.au>
Reviewed-by: صادق <sadq04724@gmail.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>

src/cmd/dist/test.go
src/crypto/internal/fips140/fips140.go

index bfed14c9152a260814d5a6e9f486638527059c11..0c992118f4287b57d9442342c20555e599b1a9f3 100644 (file)
@@ -1812,6 +1812,7 @@ func (t *tester) fipsSupported() bool {
        case goarch == "wasm",
                goos == "windows" && goarch == "386",
                goos == "windows" && goarch == "arm",
+               goos == "openbsd",
                goos == "aix":
                return false
        }
index cf015db644738f4cfd60764cbb33644a80539440..c7b167b82a14129f0101f97f6768307a1fe7c486 100644 (file)
@@ -46,6 +46,7 @@ func Supported() error {
        case runtime.GOARCH == "wasm",
                runtime.GOOS == "windows" && runtime.GOARCH == "386",
                runtime.GOOS == "windows" && runtime.GOARCH == "arm",
+               runtime.GOOS == "openbsd", // due to -fexecute-only, see #70880
                runtime.GOOS == "aix":
                return errors.New("FIPS 140-3 mode is not supported on " + runtime.GOOS + "-" + runtime.GOARCH)
        }