Skip to content

x/crypto/sha3: TestKeccakKats failing on freebsd-amd64-race due to invalid unsafe pointer conversion #35173

@bcmills

Description

@bcmills

From the freebsd-amd64-race builder (https://build.golang.org/log/dbfde792a0d9d30fa34b24190b0023988ef2e63d):

--- FAIL: TestKeccakKats (1.95s)
panic: runtime error: unsafe pointer conversion [recovered]
	panic: runtime error: unsafe pointer conversion

goroutine 20 [running]:
testing.tRunner.func1(0xc0000ba100)
	/tmp/workdir/go/src/testing/testing.go:881 +0x69f
panic(0x6473e0, 0xc00009aac0)
	/tmp/workdir/go/src/runtime/panic.go:915 +0x370
golang.org/x/crypto/sha3.xorInUnaligned(0xc000104a80, 0xc000104b69, 0x90, 0xa8)
	/tmp/workdir/gopath/src/golang.org/x/crypto/sha3/xor_unaligned.go:13 +0x60
golang.org/x/crypto/sha3.(*state).permute(0xc000104a80)
	/tmp/workdir/gopath/src/golang.org/x/crypto/sha3/sha3.go:84 +0x1d3
golang.org/x/crypto/sha3.(*state).padAndPermute(0xc000104a80, 0xc000036706)
	/tmp/workdir/gopath/src/golang.org/x/crypto/sha3/sha3.go:117 +0x347
golang.org/x/crypto/sha3.(*state).Read(0xc000104a80, 0xc0000d45c0, 0x1c, 0x1c, 0x453700, 0xc0000818d0, 0x8)
	/tmp/workdir/gopath/src/golang.org/x/crypto/sha3/sha3.go:163 +0x2e0
golang.org/x/crypto/sha3.(*state).Sum(0xc0001048c0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0)
	/tmp/workdir/gopath/src/golang.org/x/crypto/sha3/sha3.go:190 +0x233
golang.org/x/crypto/sha3.TestKeccakKats.func1(0x661d91, 0x9)
	/tmp/workdir/gopath/src/golang.org/x/crypto/sha3/sha3_test.go:116 +0x5a9
golang.org/x/crypto/sha3.testUnalignedAndGeneric(0xc0000ba100, 0xc00008df00)
	/tmp/workdir/gopath/src/golang.org/x/crypto/sha3/sha3_test.go:84 +0x14f
golang.org/x/crypto/sha3.TestKeccakKats(0xc0000ba100)
	/tmp/workdir/gopath/src/golang.org/x/crypto/sha3/sha3_test.go:93 +0x5c
testing.tRunner(0xc0000ba100, 0x66bd20)
	/tmp/workdir/go/src/testing/testing.go:916 +0x1a9
created by testing.(*T).Run
	/tmp/workdir/go/src/testing/testing.go:967 +0x652
FAIL	golang.org/x/crypto/sha3	1.966s

CC @FiloSottile @mknyszek

Metadata

Metadata

Assignees

No one assigned

    Labels

    FrozenDueToAgeNeedsInvestigationSomeone must examine and confirm this is a valid issue and not a duplicate of an existing one.

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions