GO-2026-6909
not scored yetNil-pointer panic in validateAssertion and namespace-blind Subject.NameID in github.com/crewjam/saml
github.com/crewjam/saml before v0.5.2 contains two vulnerabilities in SAML assertion processing:
ServiceProvider.validateAssertion dereferences assertion.Subject, assertion.Conditions, and SubjectConfirmationData without nil checks. A signed SAML assertion that omits any of these optional elements causes a nil-pointer dereference panic after signature verification.
Subject uses the bare XML struct tag xml:"NameID", which matches <NameID> elements in any XML namespace. When a signed assertion omits and includes a <NameID> element in a foreign namespace inside , encoding/xml populates Subject.NameID from the foreign element, allowing an authenticated principal to spoof Subject.NameID.Value.
Affected
| Source | Vendor / ecosystem | Product / package | Affected versions | Fixed in |
|---|---|---|---|---|
| OSV | Go | github.com/crewjam/saml | < 0.5.2 | 0.5.2 |
References
- https://github.com/crewjam/saml/commit/2a4c1a630a7d53ff99a1fa2216308d6cef61ad78 · FIX
- https://github.com/crewjam/saml/commit/e05a6f148c4eda7b5f6b3b2737085cf72b680456 · FIX
- https://github.com/golang/vulndb/issues/6909 · REPORT
History
- 25 Nov 2026 20:14 UTC · OSV: first stored (published 5 Nov 2026)