CVE-2026-18089: Net::SAML2 versions before 0.86 for Perl allow SAML authentication bypass by verifying responses against the response-embedded certificate in verify_xml when no trust anchor is configured
Net::SAML2 versions before 0.86 for Perl allow SAML authentication bypass by verifying responses against the response-embedded certificate in verifyxml when no trust anchor is configured.
verifyxml in Net::SAML2::Role::VerifyXML runs "return if !$anchors && !$cacert;" as soon as the XML::Sig check succeeds, and that check uses the X.509 certificate taken from the response's own dsig:KeyInfo/dsig:X509Certificate element, so an unanchored response is checked only against the key it carries. Binding::POST declares cacert as an optional Maybe[Str] with no default, so a POST binding built without one takes that path, and verifyencryptedassertion returns early the same way with "return $xml unless $cacert;".
Any caller that constructs Binding::POST or calls Assertion->newfromxml without a cacert, certtext, or anchors argument accepts a response signed by an attacker generated key whose self-signed certificate is embedded in that response, authenticating an arbitrary assertion.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Upgrade
Upgrade
Net::SAML2 (Perl)to a version that resolves this vulnerability.Fixed in 0.86 - Configuration
Ensure any call that constructs Binding::POST and any call to Assertion->new_from_xml provides at least one trust anchor argument: cacert, cert_text, or anchors. Do not build a POST binding without cacert, and do not call Assertion->new_from_xml without a cacert/cert_text/anchors trust anchor, because Net::SAML2 skips verification early with return $xml unless $cacert / return if !$anchors && !$cacert.
Net::SAML2 cacert/cert_text/anchors trust anchor arguments = required (not omitted)
Event History
Frequently Asked Questions
What is the severity of CVE-2026-18089?
The severity of CVE-2026-18089 is rated at 82.
What is the impact of CVE-2026-18089?
CVE-2026-18089 allows for SAML authentication bypass in Net::SAML2 versions before 0.86 for Perl.
How do I fix CVE-2026-18089?
To fix CVE-2026-18089, upgrade to Net::SAML2 version 0.86 or later.
Which versions of Net::SAML2 are affected by CVE-2026-18089?
CVE-2026-18089 affects all versions of Net::SAML2 prior to 0.86.
What specific function is vulnerable in CVE-2026-18089?
The verify_xml function in Net::SAML2::Role::VerifyXML is vulnerable in CVE-2026-18089 when no trust anchor is configured.