# CVE-2025-66568: ruby-saml Libxml2 Canonicalization errors can bypass Digest/Signature validation

- Severity: Critical 9.3 (CVSS:4.0, scored by GitHub_M) `CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:N/SC:N/SI:N/SA:N`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.27%, higher than 19% of CVEs (2026-12-01)
- Published: 2025-12-08T22:03:19.000Z
- Modified: 2026-10-14T21:10:00.183Z
- Also known as: GHSA-x4h9-gwv3-r4m4
- Weaknesses: CWE-347
- SSVC (CISA-ADP): exploitation none, automatable yes, technical impact total
- Assigned by: GitHub_M

## Description

The ruby-saml library implements the client side of an SAML authorization. Versions up to and including 1.12.4, are vulnerable to authentication bypass through the libxml2 canonicalization process used by Nokogiri for document transformation, which allows an attacker to execute a Signature Wrapping attack. When libxml2’s canonicalization is invoked on an invalid XML input, it may return an empty string rather than a canonicalized node. ruby-saml then proceeds to compute the DigestValue over this empty string, treating it as if canonicalization succeeded. This issue is fixed in version 1.18.0.

(As written by CVE List.)

## Affected

- SAML-Toolkits ruby-saml: < 1.18.0
- ruby-saml (RubyGems): before 1.18.0
- onelogin ruby-saml: before 1.18.0

## Every score

- GitHub_M: CVSS:4.0 9.3 Critical `CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:N/SC:N/SI:N/SA:N`
- GitHub: CVSS:4.0 Critical `CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:N/SC:N/SI:N/SA:N`
- NVD: CVSS:3.1 9.1 Critical `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N`

## References

- <https://github.com/SAML-Toolkits/ruby-saml/security/advisories/GHSA-x4h9-gwv3-r4m4> (vendor-advisory, web)
- <https://github.com/SAML-Toolkits/ruby-saml/commit/acac9e9cc0b9a507882c614f25d41f8b47be349a> (broken-link, web)
- <https://nvd.nist.gov/vuln/detail/CVE-2025-66568> (advisory)
- <https://github.com/SAML-Toolkits/ruby-saml> (package)
- <https://github.com/rubysec/ruby-advisory-db/blob/master/gems/ruby-saml/CVE-2025-66568.yml> (web)

## Sources

- CVE List: [CVE-2025-66568](https://www.cve.org/CVERecord?id=CVE-2025-66568), CVE Terms of Use, modified 2025-12-09
- GitHub Advisory Database: [GHSA-x4h9-gwv3-r4m4](https://github.com/advisories/GHSA-x4h9-gwv3-r4m4), CC-BY-4.0, modified 2025-12-12
- NVD: [CVE-2025-66568](https://nvd.nist.gov/vuln/detail/CVE-2025-66568), Public domain, modified 2026-10-14

---

Page: https://cve.day/CVE-2025-66568 · Whole record: https://cve.day/CVE-2025-66568.json · Rebuilt by cve.day 2026-11-25T22:59:08.540Z
