Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tests fail on 32bit architectures. #177

Closed
mdosch opened this issue Jul 7, 2023 · 2 comments · Fixed by #178
Closed

Tests fail on 32bit architectures. #177

mdosch opened this issue Jul 7, 2023 · 2 comments · Fixed by #178

Comments

@mdosch
Copy link
Contributor

mdosch commented Jul 7, 2023

Dear go-crypto devs,

I realized that building a current go-crypto (3fbb1f1) for debian fails checks on armel, armhf and i386.
I checked out the current master on my amd64 laptop running debian stable and could reproduce it:

~/build/go-crypto/openpgp/s2k (git)-[main] % GOARCH=386 go test
--- FAIL: TestParseIntoParams (0.12s)
panic: runtime error: makeslice: len out of range [recovered]
	panic: runtime error: makeslice: len out of range

goroutine 301 [running]:
testing.tRunner.func1.2({0x8162f60, 0x81a547c})
	/usr/lib/go-1.19/src/testing/testing.go:1396 +0x2ab
testing.tRunner.func1()
	/usr/lib/go-1.19/src/testing/testing.go:1399 +0x41f
panic({0x8162f60, 0x81a547c})
	/usr/lib/go-1.19/src/runtime/panic.go:884 +0x1c3
golang.org/x/crypto/argon2.initBlocks(0x9116000, 0x400000, 0x4)
	/home/martin/build/go/pkg/mod/golang.org/x/crypto@v0.7.0/argon2/argon2.go:158 +0x49
golang.org/x/crypto/argon2.deriveKey(0x2, {0x9018290, 0x5, 0x8}, {0x909c13a, 0x10, 0x10}, {0x0, 0x0, 0x0}, ...)
	/home/martin/build/go/pkg/mod/golang.org/x/crypto@v0.7.0/argon2/argon2.go:113 +0x183
golang.org/x/crypto/argon2.IDKey(...)
	/home/martin/build/go/pkg/mod/golang.org/x/crypto@v0.7.0/argon2/argon2.go:97
github.com/ProtonMail/go-crypto/openpgp/s2k.Argon2({0x9018288, 0x4, 0x4}, {0x9018290, 0x5, 0x8}, {0x909c13a, 0x10, 0x10}, 0x3, ...)
	/home/martin/build/go-crypto/openpgp/s2k/s2k.go:178 +0xb9
github.com/ProtonMail/go-crypto/openpgp/s2k.(*Params).Function.func4({0x9018288, 0x4, 0x4}, {0x9018290, 0x5, 0x8})
	/home/martin/build/go-crypto/openpgp/s2k/s2k.go:352 +0xae
github.com/ProtonMail/go-crypto/openpgp/s2k.TestParseIntoParams(0xd201c20)
	/home/martin/build/go-crypto/openpgp/s2k/s2k_test.go:172 +0x50d
testing.tRunner(0xd201c20, 0x8182ae4)
	/usr/lib/go-1.19/src/testing/testing.go:1446 +0x113
created by testing.(*T).Run
	/usr/lib/go-1.19/src/testing/testing.go:1493 +0x374
exit status 2
FAIL	github.com/ProtonMail/go-crypto/openpgp/s2k	2.156s
@mdosch mdosch changed the title Fails to build on 32bit architectures Tests fail on 32bit architectures. Jul 7, 2023
@twiss
Copy link
Member

twiss commented Jul 10, 2023

(Thanks for the report!)

@mdosch
Copy link
Contributor Author

mdosch commented Jul 10, 2023 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants