postiefs/laravel-sso
postiefs/laravel-sso is a Laravel package for adding single sign-on to your app. It provides the building blocks to connect an SSO provider, streamline authentication, and keep login flows consistent across Laravel projects.
sexp deadline is adopted and never extended, which is a deliberate product stance on session control.check_interval seconds (and users stay signed in if the portal is down), you get near-real-time revocation with graceful degradation. Suitable for compliance-sensitive products where access must be withdrawn centrally.UserResolver contract (default: find-or-create by email, never mutate existing users) lets you keep your own user model and permission system; roles remain in your app (e.g. spatie/laravel-permission). This reduces migration and data-ownership risk — a meaningful plus in buy-vs-build evaluations.sso:check and sso:install lower setup cost and give a health/diagnostic path; events (SsoUserCreated, SsoLoggedIn, SsoSessionEnded) and the Sso facade support audit logging and analytics without forking the package. The browser guard (@ssoSessionGuard) supports UX decisions around deadline warnings and heartbeat-driven expiry.Adopt when:
/auth/check-access endpoint, so it is not a general-purpose OIDC/SAML client.sso:install.Look elsewhere when:
For executives: This package gives us enterprise single sign-on through the Postiefs portal and Microsoft Entra ID in one integration instead of a custom build. Sessions are controlled centrally — access can be revoked at the portal, and the local session cannot outlive the portal's deadline. It adds no database changes and no new source of truth for users or roles, so our data model and permission system stay ours. Time-to-value is short (composer require plus one install command), and the main dependency is a first-release package from a single provider.
For engineering: Laravel 11–13 / PHP 8.2+ package with a launch-token verification flow (HS256, issuer, audience, expiry, single use), a session check against the portal throttled to check_interval with fail-open behavior during portal outages, and callback/login/ended/heartbeat/logout routes protected by sso, sso.auth, and sso.session middleware. Extensibility is via the UserResolver contract, events, and the Sso facade; there is a LaunchToken test helper, a @ssoSessionGuard Blade directive for client-side deadline handling, sso:install / sso:check commands, and handling for stray tokens from a misconfigured Callback URL. No migrations, no schema changes. Risks to validate before GA: single-use token semantics under retries, fail-open window during portal downtime versus our security policy, heartbeat load, and v1.0.0 maturity — recommend a spike plus documented fallback to direct Entra ID integration if the package does not hold up.
How can I help you explore Laravel packages today?