Trust, But Verify, Your SAML Service Providers

No ratings

Presented at BsidesNash 2017 by

BLUF: This talk will provide an overview of how SAML Authentication works, the basics of the open-source framework we're building to test SAML implementations, and our results to date using that framework. SAML (Security Assertion Markup Language) Authentication is widely used, particularly for internal Single Sign-On (SSO) and for using organizational (company or university) credentials to log into cloud services. Users can use their employer (or university) login for access to the service, and the employer gets better control and insight over cloud logins. SAML relies on public key cryptography and the service provider checking the integrity of the (signed) SAML assertion. A 2012 Usenix paper by Samorovsky et al claimed that 80% of SAML frameworks tested could be broken, allowing impersonation attacks, as a result of flaws in the integrity checking of the SAML signature. A recent Black Hat presentation showed similar flaws in many Android implementations of the related OAuth protocol. This is a serious concern, since a malicious actor could potentially impersonate any user to a flawed SAML Service Provider. We were unable to locate any working code, including from the authors of the above paper, for testing SAML implementations. So, as both a learning exercise to better understand the guts of SAML and a security tool to enable validation that our partners were using correct SAML implementations (both internally for single sign-on and externally for cloud applications), we set out to build an open-source set of tools for testing SAML service providers. We built this framework in Ruby, to complement the Cucumber testing framework in use for testing applications.