Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Lightsaml Laravel Package

aerialship/lightsaml

SAML 2.0 toolkit for Laravel/PHP to add SSO and identity federation to your apps. Provides helpers for SAML authentication flows, metadata, and certificate handling, making it easier to integrate with common IdPs and SPs.

View on GitHub
Deep Wiki
Context7

SIGNING AND CERTIFICATES

The LightSaml relies on the xmlseclibs regarding signing and certificates functionality. LightSaml has helper methods and was tested using xmlseclibs with PEM format only.

Creating self signed certificates

Run the following command to generate pem certificate and key

$ openssl req -new -x509 -days 3652 -nodes -out saml.crt -keyout saml.pem

Loading certificate from file and creating public key

$certificate = new X509Certificate();
$certificate->loadFromFile($crtFilename);

$publicKey = KeyHelper::createPublicKey($certificate);

Creating private key

$privateKey = KeyHelper::createPrivateKey($filename, $pass, true);

Signing SAML messages

You would require private key for signing SAML messages.

$message->sign($certificate, $privateKey);

Exposing certificate in metadata

If your SP supports signing you would need to expose your certificate in your SP's metadata entity descriptor

$ed = new EntityDescriptor();
$sp = new SpSsoDescriptor();
$sp->addKeyDescriptor(new KeyDescriptor('signing', $certificate));
$ed->->addItem($sp);
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
symfony/ai-symfony-mate-extension
aashan/pimcore-mcp-bundle
nexmo/api-specification
capell-app/block-library
axium/identity
cetria/laravel-dummy-models
cetria/reflection-helper
agropredict/sso-auth-bundle
evolvestudio/spam-protection
datacore/hub-sdk
develia/commons
cuci/prototurk-sdk
cuci/prototurk-sdk-symfony
develia/geo-bundle
dreamzy/livewire-charts
touchestate-sdk/php-sdk
22h/doctrine-garbage-collection-bundle
agtp/agtp-php
agtp/mod-php
splash/sonata-admin