google / google/go-attestation

Fails to parse malformed Nuvoton EK certs with leading 0s in serial number

Open
#362 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
Go
Stars
444
Forks
109
PR merge metrics
No merged PRs in 30d

Description

03018e682822c6294edf5d182abca218f341a46e switched from using certificate-transparency/x509 to crypto/x509. This means that x509 certificates are parsed more strictly. Nuvoton, at least, issued some EK certificates with leading 0s in the serial number - this is a spec violation and crypto/x509 rejects them. Unfortunately I'm not in a position to get all of these reissued, so would it be possible to switch back to using certificate-transparency? This has the unfortunate outcome that some of the x509 object API is visible to consumers, so consumers who already switched from certificate-transparency/x509 to crypto/x509 would have to switch back unless we find a reasonable way to abstract that.

Contributor guide

Open the contributing guide

Research direction

Start by examining commit 03018e682822c6294edf5d182abca218f341a46e and the current certificate parsing path to understand the switch from certificate-transparency/x509 to crypto/x509. Determine how malformed Nuvoton EK certificates could be accepted while preserving compatibility for consumers of the x509 object API; completion requires an agreed approach, not just a parser change.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
security
Issue type
Bug
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.