-
CVSS Score
-The vulnerability stems from inconsistent XML parsing between REXML and Nokogiri. The valid_saml? method in SamlMessage lacked proper malformed XML checks (via check_malformed_doc), allowing attackers to craft documents parsed differently by the two libraries. In XMLSecurity::BaseDocument, signature validation used REXML for element selection but Nokogiri for canonicalization, creating a mismatch between what was verified and what was actually signed. The patches introduced XMLSecurity::BaseDocument.safe_load_xml with strict parsing rules and check_malformed_doc flags to enforce consistent parsing, confirming these were the vulnerable points.
| Package Name | Ecosystem | Vulnerable Versions | First Patched Version |
|---|---|---|---|
| ruby-saml | rubygems | >= 1.13.0, < 1.18.0 | 1.18.0 |
| ruby-saml | rubygems | < 1.12.4 | 1.12.4 |