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

TestGenerateSubjectKeyID fails #206

Open
pymnh opened this issue Sep 9, 2022 · 1 comment
Open

TestGenerateSubjectKeyID fails #206

pymnh opened this issue Sep 9, 2022 · 1 comment

Comments

@pymnh
Copy link

pymnh commented Sep 9, 2022

with go 1.19 on linux, TestGenerateSubjectKeyID fails:

% go test github.com/micromdm/scep/v2/cryptoutil
--- FAIL: TestGenerateSubjectKeyID (0.00s)
    --- FAIL: TestGenerateSubjectKeyID/ECDSA (0.00s)
panic: crypto/elliptic: attempted operation on invalid point [recovered]
	panic: crypto/elliptic: attempted operation on invalid point

goroutine 20 [running]:
testing.tRunner.func1.2({0x547d20, 0x5b80d0})
	/usr/lib/go-1.19/src/testing/testing.go:1396 +0x24e
testing.tRunner.func1()
	/usr/lib/go-1.19/src/testing/testing.go:1399 +0x39f
panic({0x547d20, 0x5b80d0})
	/usr/lib/go-1.19/src/runtime/panic.go:884 +0x212
crypto/elliptic.panicIfNotOnCurve({0x5b9768?, 0x681280?}, 0xc000103268?, 0xc00012a2f0?)
	/usr/lib/go-1.19/src/crypto/elliptic/elliptic.go:182 +0xa5
crypto/elliptic.Marshal({0x5b9768, 0x681280}, 0xc000128028?, 0x68a740?)
	/usr/lib/go-1.19/src/crypto/elliptic/elliptic.go:75 +0x31
github.com/micromdm/scep/v2/cryptoutil.GenerateSubjectKeyID({0x55dfa0?, 0xc000162660?})
	/home/schmu/projekte/code/scep/cryptoutil/cryptoutil.go:26 +0xb0
github.com/micromdm/scep/v2/cryptoutil.TestGenerateSubjectKeyID.func1(0xc000103040)
	/home/schmu/projekte/code/scep/cryptoutil/cryptoutil_test.go:23 +0x46
testing.tRunner(0xc000103040, 0xc0001243f0)
	/usr/lib/go-1.19/src/testing/testing.go:1446 +0x10b
created by testing.(*T).Run
	/usr/lib/go-1.19/src/testing/testing.go:1493 +0x35f
FAIL	github.com/micromdm/scep/v2/cryptoutil	0.005s
FAIL

I don't know much about the go crypto library, but might to have to do with go1.19?
see
nspcc-dev/neofs-crypto#15

@klubi
Copy link
Contributor

klubi commented Dec 5, 2022

I solved it by slightly changing the test -> jamf@ddc5064

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

No branches or pull requests

2 participants