{"id":3291,"date":"2025-05-22T11:23:32","date_gmt":"2025-05-22T11:23:32","guid":{"rendered":"https:\/\/cybersecurityinfocus.com\/?p=3291"},"modified":"2025-05-22T11:23:32","modified_gmt":"2025-05-22T11:23:32","slug":"samlify-bug-lets-attackers-bypass-single-sign-on","status":"publish","type":"post","link":"https:\/\/cybersecurityinfocus.com\/?p=3291","title":{"rendered":"Samlify bug lets attackers bypass single sign-on"},"content":{"rendered":"<div>\n<div class=\"grid grid--cols-10@md grid--cols-8@lg article-column\">\n<div class=\"col-12 col-10@md col-6@lg col-start-3@lg\">\n<div class=\"article-column__content\">\n<div class=\"container\"><\/div>\n<p>A critical vulnerability in the popular samlify library could potentially allow attackers to bypass Single Sign-On (SSO) protections and gain unauthorized access to systems relying on SAML for authentication.<\/p>\n<p>Tracked as CVE-2025-47949, the flaw affecting the widely used Node.js library can allow a Signature Wrapping attack with maximum impact, for which it received a critical rating of CVSS 9.9 out of 10.<\/p>\n<p>\u201cThe vulnerability affecting samlify versions prior to 2.10.0 is a severe weakness classified under CWE-347: Improper Verification of Cryptographic Signature,\u201d EndorLabs said in a blog post. \u201cIt allows an attacker to forge SAML Responses, leading to complete authentication bypass and arbitrary user impersonation (including administrators).\u201d<\/p>\n<p>Samlify is a library designed to simplify the implementation of <a href=\"https:\/\/www.csoonline.com\/article\/563215\/how-saml-works-and-enables-single-sign-on.html\">SAML<\/a> 2.0 for Single Sign-On (<a href=\"https:\/\/www.csoonline.com\/article\/510713\/sso-explained-single-sign-on-definition-examples-and-terminology.html\">SSO<\/a>) and Single Log-Out (SLO) by providing a high-level API. It has over 200,000 weekly downloads on npm and has 62 dependent packages that integrate to it.<\/p>\n<h2 class=\"wp-block-heading\">Exploiting weak XML signature validation<\/h2>\n<p>SAML depends on XML signatures to verify who is who in the authentication handshake between identity providers (IdP) and service providers (SP). But when an SAML parser isn\u2019t strict about what it checks, attackers can take advantage. That\u2019s what happens in a Signature Wrapping attack.<\/p>\n<p>The attack begins with obtaining a valid XML document signed by the identity provider, possibly by intercepting a login session using a man-in-the-middle setup or just grabbing a signature from publicly available IdP metadata.<\/p>\n<p>The attackers then insert a second, fake assertion\u2013claiming to be an admin\u2013into the already obtained, signed XML snippet. Owing to lax parsing rules in samlify versions prior to 2.10.0, the service provider ends up processing the attacker\u2019s fake, unsigned identity along with the original signature.<\/p>\n<p>Endor Labs researchers warned that this flaw <a href=\"https:\/\/www.endorlabs.com\/learn\/cve-2025-47949-reveals-flaw-in-samlify-that-opens-door-to-saml-single-sign-on-bypass\" target=\"_blank\" rel=\"noopener\">opens the door to SAML SSO bypass <\/a>and is easy to exploit as the \u201cattack complexity is low\u201d, \u201cno privileges are required\u201d, and \u201cno user interaction is needed\u201d. Additionally, the requirement for obtaining a signed XML was noted as \u201crealistic\u201d.<\/p>\n<h2 class=\"wp-block-heading\"><a><\/a>SAML authenticators should update to patched versions<\/h2>\n<p>The flaw has been addressed through patches in samlify versions 2.10.0 and later.<\/p>\n<p>Researchers have recommended that systems using SAML authentication must update to a fixed version and ensure \u201csecure SSO flows: implement HTTPS and avoid untrusted sources for SAML flows.\u201d<\/p>\n<p>SAML-powered SSO supports a range of use cases: enterprise applications, SaaS integrations with identity providers like Okta or Azure AD, <a href=\"https:\/\/www.csoonline.com\/article\/575435\/what-is-federated-identity-how-it-works-and-its-importance-to-enterprise-security.html\">federated identity<\/a> across organizations, and developer platforms needing secure user authentication. A full authentication bypass through this flaw could enable attackers to gain access to sensitive resources, private data, or privileged actions under the impersonated identity.<\/p>\n<\/div>\n<\/div>\n<\/div>\n<\/div>","protected":false},"excerpt":{"rendered":"<p>A critical vulnerability in the popular samlify library could potentially allow attackers to bypass Single Sign-On (SSO) protections and gain unauthorized access to systems relying on SAML for authentication. Tracked as CVE-2025-47949, the flaw affecting the widely used Node.js library can allow a Signature Wrapping attack with maximum impact, for which it received a critical [&hellip;]<\/p>\n","protected":false},"author":0,"featured_media":3287,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3],"tags":[],"class_list":["post-3291","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-education"],"_links":{"self":[{"href":"https:\/\/cybersecurityinfocus.com\/index.php?rest_route=\/wp\/v2\/posts\/3291"}],"collection":[{"href":"https:\/\/cybersecurityinfocus.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/cybersecurityinfocus.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"replies":[{"embeddable":true,"href":"https:\/\/cybersecurityinfocus.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=3291"}],"version-history":[{"count":0,"href":"https:\/\/cybersecurityinfocus.com\/index.php?rest_route=\/wp\/v2\/posts\/3291\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/cybersecurityinfocus.com\/index.php?rest_route=\/wp\/v2\/media\/3287"}],"wp:attachment":[{"href":"https:\/\/cybersecurityinfocus.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=3291"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/cybersecurityinfocus.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=3291"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/cybersecurityinfocus.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=3291"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}