mlightsaml/sp-bundle
Symfony bundle that adds SAML 2.0 Service Provider support using LightSAML. Configure identity providers, enable SSO login and logout, generate and consume metadata, and integrate SAML authentication into Symfony applications through flexible bundle configuration.
onelogin/php-saml, SimpleSAMLphp) on the dimensions that decide the contract — IdP interop breadth, Single Logout, encrypted assertions, IdP-initiated flows, metadata refresh, and who carries the pager.Consider it only as a reference implementation — a readable example of how the AuthnRequest → IdP redirect → POST to ACS → validate → establish session sequence is wired in Symfony. That use is nearly always safe and occasionally valuable for sanity-checking a design.
It becomes a candidate dependency only if all of the following hold:
Destination/Audience validation, clock skew, assertion replay — and who will fork and vendor the code rather than trust upstream.Look elsewhere if any of these are true:
Stronger defaults to evaluate instead: a maintained Laravel-native SAML SP for Laravel, onelogin/php-saml or SimpleSAMLphp for self-hosted PHP, or a broker if you would rather not own the trust boundary at all.
Executives. We evaluated a SAML 2.0 Service Provider bundle that could, in principle, unlock enterprise SSO. It is a Symfony bundle built on the legacy LightSAML library, MIT-licensed, with zero stars, zero dependents, and a single maintainer. It demonstrates the shape of the integration but is not a viable production dependency: it is unmaintained, its underlying SAML library is legacy, and it does not fit our Laravel stack. Authentication is our highest-trust boundary — an unpatched XML parser in front of login is an incident waiting to happen, and a breach costs far more than any code we'd save. Recommendation: do not adopt. If enterprise SSO is on the roadmap, budget for either a maintained SAML library we integrate and test against each customer's IdP, or a hosted SSO broker that offloads IdP certification, Single Logout, and SCIM. Integration effort is broadly similar either way; the difference is who owns the pager and the CVE feed.
Engineering. Treat this repo as a reference implementation, not a dependency. It is worth reading for how metadata exchange, assertion validation, and the ACS round trip are structured, and it gives us a concrete requirements list for the SSO epic. If we ever need a stopgap for a single Symfony service, we vendor it into our tree, pin it, and write our own tests around signature validation, audience/destination checks, and replay — with no expectation of upstream upgrades or upstream trust. For Laravel, start from a maintained Laravel-native SAML SP or a broker SDK, and fund the work as a small, security-reviewed project with a named owner, alerting on certificate rotation and validation failures, and the legacy login path kept warm for one full release cycle.
How can I help you explore Laravel packages today?