ruby-saml Libxml2 Canonicalization errors can bypass Digest/Signature validation
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.
- Products
- Not specified
- Affected versions
- Not specified
- Fixed versions
- Not specified
- CVEs
- CVE-2025-66568
- Confirmed fixed CVEs
- Not specified
- Updated in this feed
- 5 Nov 2026, 00:55 UTC · Revision 1
Source evidence
ruby-saml Libxml2 Canonicalization errors can bypass Digest/Signature validation
core-osv · Original sourcePublished 9 Dec 2025, 02:03 UTC
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.
osv:CVE-2025-66568
Complete source record
{
"id": "c8fb5a91879687248d7ec123dd3074b07129a7ebac73418dcba77a521ef19f64",
"url": "https://osv.dev/vulnerability/CVE-2025-66568",
"method": "structured",
"payload": {
"kind": "advisory",
"title": "ruby-saml Libxml2 Canonicalization errors can bypass Digest/Signature validation",
"summary": "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.",
"evidence": "osv:CVE-2025-66568",
"products": [],
"severity": "critical",
"structured": {
"id": "CVE-2025-66568",
"aliases": [
"CVE-2025-66568",
"GHSA-x4h9-gwv3-r4m4"
],
"metrics": [
{
"type": "CVSS_V4",
"score": "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"
}
],
"affected": [
{
"ranges": [
{
"repo": "https://github.com/saml-toolkits/ruby-saml",
"type": "GIT",
"events": [
{
"introduced": "0"
},
{
"fixed": "6a7c040049babe748ee1bb4ca13898c47189114c"
},
{
"fixed": "acac9e9cc0b9a507882c614f25d41f8b47be349a"
}
],
"database_specific": {
"extracted_events": [
{
"cpe": "cpe:2.3:a:onelogin:ruby-saml:*:*:*:*:*:*:*:*",
"range": [
{
"introduced": "0"
},
{
"fixed": "1.18.0"
}
],
"source": "CPE_RANGE"
},
{
"range": [
{
"fixed": "acac9e9cc0b9a507882c614f25d41f8b47be349a"
}
],
"source": "REFERENCES_COMMIT"
}
]
}
}
],
"versions": [
"v1.17.0",
"v1.12.2",
"v1.16.0",
"v1.15.0",
"v1.14.0",
"v1.12.1",
"v1.12.0",
"v1.11.0",
"v1.10.2",
"v1.10.1",
"v1.10.0",
"v1.9.0",
"v1.8.0",
"v1.7.2",
"v1.7.1",
"v1.7.0",
"v1.6.2",
"v1.6.1",
"v0.9.2",
"v1.6.0",
"1.4.3",
"1.5.0",
"1.4.2",
"1.4.1",
"1.4.0",
"1.3.1",
"v1.3.0",
"v1.2.0",
"v1.1.2",
"v1.1.1",
"v1.1.0",
"v1.0.0",
"v0.9.1",
"v0.9",
"0.8.1",
"0.8.0",
"0.7.3",
"v0.7.1",
"v0.6.0",
"v0.5.3",
"v0.5.2",
"v0.5.1",
"v0.5.0",
"v0.4.7",
"v0.4.6",
"v0.4.5",
"v0.4.4",
"v0.4.3",
"v0.4.2",
"v0.4.1",
"v0.4.0",
"v0.3.4",
"v0.3.3",
"v0.3.2",
"v0.3.1",
"v0.3.0",
"v0.2.3",
"v0.2.2",
"v0.2.1",
"v0.2.0"
],
"database_specific": {
"source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2025-66568.json"
}
}
],
"modified": "2026-10-28T02:30:41.096462572Z",
"provider": "osv",
"references": [
"https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/66xxx/CVE-2025-66568.json",
"https://github.com/SAML-Toolkits/ruby-saml/security/advisories/GHSA-x4h9-gwv3-r4m4",
"https://nvd.nist.gov/vuln/detail/CVE-2025-66568",
"https://github.com/SAML-Toolkits/ruby-saml/commit/acac9e9cc0b9a507882c614f25d41f8b47be349a"
],
"provider_metadata": {
"cwe_ids": [
"CWE-347"
],
"cna_assigner": "GitHub_M",
"osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/66xxx/CVE-2025-66568.json"
}
},
"related_cves": [
{
"value": "CVE-2025-66568",
"evidence": "/id"
}
],
"security_relevant": true,
"severity_evidence": "/severity/0/score"
},
"source_id": "core-osv",
"document_id": 508776,
"published_at": "2025-12-09T02:03:20.397+00:00"
}