{
  "id": "CVE-2025-25291",
  "url": "https://poc.griffinguard.io/cve/CVE-2025-25291",
  "published_at": "2025-03-12T20:16:12.181Z",
  "title": "ruby-saml vulnerable to SAML authentication bypass due to DOCTYPE handling (parser differential)",
  "vendor": "SAML-Toolkits",
  "product": "ruby-saml",
  "cvss": {
    "score": 9.8,
    "source": "nvd",
    "vector": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H"
  },
  "kev": {
    "in_kev": false,
    "added_at": null,
    "days_after_publication": null
  },
  "first_poc": null,
  "poc_repo_count": 0,
  "exploit_count": 0,
  "suspicious_repo_count": 0,
  "edge_device": null,
  "description": "ruby-saml provides security assertion markup language (SAML) single sign-on (SSO) for Ruby. An authentication bypass vulnerability was found in ruby-saml prior to versions 1.12.4 and 1.18.0 due to a parser differential. ReXML and Nokogiri parse XML differently; the parsers can generate entirely different document structures from the same XML input. That allows an attacker to be able to execute a Signature Wrapping attack. This issue may lead to authentication bypass. Versions 1.12.4 and 1.18.0 fix the issue.",
  "cwe": "CWE-347",
  "cpes": [
    "cpe:2.3:a:netapp:storagegrid:-:*:*:*:*:*:*:*",
    "cpe:2.3:a:omniauth:omniauth_saml:*:*:*:*:*:ruby:*:*",
    "cpe:2.3:a:onelogin:ruby-saml:*:*:*:*:*:*:*:*"
  ],
  "cvss_by_source": {
    "cna": 9.3,
    "nvd": 9.8
  },
  "repos": [],
  "remediation": {
    "affected": [
      {
        "vendor": "SAML-Toolkits",
        "product": "ruby-saml",
        "ranges": [
          "\u003c 1.12.4",
          "\u003e= 1.13.0, \u003c 1.18.0"
        ],
        "fixed_in": [
          "1.12.4",
          "1.18.0"
        ]
      }
    ],
    "upgrade": [
      "Upgrade ruby-saml to 1.12.4 or 1.18.0 or later."
    ],
    "references": [
      {
        "kind": "Vendor advisory",
        "url": "https://github.com/SAML-Toolkits/ruby-saml/security/advisories/GHSA-4vc4-m8qh-g8jm"
      },
      {
        "kind": "Vendor advisory",
        "url": "https://github.com/omniauth/omniauth-saml/security/advisories/GHSA-hw46-3hmr-x9xv"
      },
      {
        "kind": "Patch",
        "url": "https://github.com/SAML-Toolkits/ruby-saml/commit/e76c5b36bac40aedbf1ba7ffaaf495be63328cd9"
      },
      {
        "kind": "Patch",
        "url": "https://github.com/SAML-Toolkits/ruby-saml/commit/e9c1cdbd0f9afa467b585de279db0cbd0fb8ae97"
      },
      {
        "kind": "Release notes",
        "url": "https://github.com/SAML-Toolkits/ruby-saml/releases/tag/v1.12.4"
      },
      {
        "kind": "Release notes",
        "url": "https://github.com/SAML-Toolkits/ruby-saml/releases/tag/v1.18.0"
      }
    ]
  },
  "exploit_refs": [],
  "hunt_profile": [],
  "rules": []
}
