- What is rozmarbeka/simplesamlphp used for?
- It is a lightweight Laravel integration for SimpleSAMLphp, the PHP application used for SAML 2.0 authentication. It helps Laravel developers connect an identity provider, handle SAML login flows, and protect routes with less boilerplate. It does not replace SimpleSAMLphp itself; it makes it easier to use from a Laravel application.
- How do I install rozmarbeka/simplesamlphp in Laravel?
- Install it with Composer using composer require rozmarbeka/simplesamlphp. Then follow the package setup steps, which typically include publishing configuration and registering the service provider if Laravel package auto-discovery is not available. Because the README excerpt is not provided here, verify the exact publish tags and environment variables in the package documentation.
- Does this package support Laravel 10 or Laravel 11?
- The provided context describes it as a Laravel integration but does not list supported Laravel versions. Check the package composer.json requirements or its Packagist metadata before installing. That will show the PHP and illuminate/support constraints you need for Laravel 10 or 11.
- How do I configure an identity provider with this package?
- You configure the identity provider through SimpleSAMLphp metadata and authsource settings, then point the Laravel integration at that configuration. The IdP entity ID, SSO URL, and signing certificate still come from your identity provider. Keep certificates and secrets out of version control and use environment-specific configuration.
- How do I protect Laravel routes with SAML authentication?
- Use the package's middleware or authentication guard to require SAML login on selected routes. The exact middleware alias and guard name should be confirmed in the package documentation. A common pattern is to protect an admin or dashboard route group while leaving public routes open.
- Can I use this package for SP-initiated and IdP-initiated SSO?
- SimpleSAMLphp supports SAML 2.0 SSO flows, and this package is intended to make those flows easier to use from Laravel. Whether both SP-initiated and IdP-initiated login are exposed out of the box depends on the package routes and configuration, so verify that in its docs. Test both flows against your identity provider before relying on them.
- How do I test SAML login locally with this Laravel package?
- Use a local test identity provider or a SimpleSAMLphp test IdP, and configure a test service provider entry for your Laravel application. Keep test certificates separate from production and verify the assertion consumer service URL. Check the package docs for any built-in test helpers, since none are confirmed in the provided context.
- Is rozmarbeka/simplesamlphp suitable for production?
- SimpleSAMLphp is widely used for SAML authentication, but production readiness depends on correct certificate handling, HTTPS, metadata validation, and logging. This lightweight wrapper does not remove the need to secure the underlying SimpleSAMLphp configuration. Pin versions and review the package's maintenance activity before deploying.
- How is this different from Laravel Socialite or other SAML packages?
- Socialite is mainly for OAuth providers and is not a drop-in SAML 2.0 solution. Alternatives include other Laravel SAML packages, direct SimpleSAMLphp integration, or identity-provider SDKs. Choose based on whether you need a Laravel-native API, maintained releases, and support for your IdP's specific SAML features.
- How do I handle SAML logout with this package?
- SAML single logout depends on both your identity provider and SimpleSAMLphp configuration. Check whether this package exposes logout routes or helpers, and confirm that your IdP supports SLO if you need global session termination. Local Laravel logout alone does not end the identity provider session.