sinemacula / laravel-iam
Identity and access management for Laravel: installs the authentication, authorization, MFA, SSO and audit log packages and binds them together.
Requires
- php: ^8.3
- ext-bcmath: *
- ext-curl: *
- ext-dom: *
- ext-hash: *
- ext-libxml: *
- ext-mbstring: *
- ext-openssl: *
- ext-zlib: *
- laravel/framework: ^12.40|^13.3
- sinemacula/laravel-audit-log: ~0.1
- sinemacula/laravel-authentication: ~0.1
- sinemacula/laravel-authorization: ~0.1
- sinemacula/laravel-mfa: ~0.1
- sinemacula/laravel-sso: ~0.1
Requires (Dev)
- brianium/paratest: ^7.20
- doctrine/coding-standard: ^14.0
- friendsofphp/php-cs-fixer: ^3.95.19
- infection/infection: ^0.33.2
- larastan/larastan: ^3.9
- mockery/mockery: ^1.6
- orchestra/testbench: ^10.2|^11.0
- phpbench/phpbench: ^1.6.1
- phpstan/extension-installer: ^1.4
- phpstan/phpdoc-parser: ^2.3
- phpstan/phpstan: ^2.1
- phpstan/phpstan-deprecation-rules: ^2.0
- phpstan/phpstan-mockery: ^2.0
- phpstan/phpstan-phpunit: ^2.0
- phpstan/phpstan-strict-rules: ^2.0
- phpunit/phpunit: ^12.5
- sinemacula/coding-standards-laravel: ^1.7.1
- slevomat/coding-standard: ^8.28
- squizlabs/php_codesniffer: ^3.13.6 || ^4.0.2
Suggests
None
Provides
None
Conflicts
None
Replaces
None
- dev-master
- v0.1.0
- dev-fix/inheritance-path-locks
- dev-feat/freshness-minimum-level
- dev-feat/abandoned-enrolment-cause
- dev-feat/passkey-gateway-client
- dev-fix/pending-session-guard
- dev-refactor/sso-name-id-format
- dev-fix/exemption-reported-once
- dev-test/break-glass-decisions
- dev-test/sso-policy-fingerprint
- dev-refactor/sso-verified-identifier-lookup
- dev-test/proof-order-by-sequence
- dev-refactor/factor-code-counters-client
- dev-refactor/tenant-policy-context-client
- dev-refactor/authentication-identity-references
- dev-refactor/mfa-replayed-code-outcome
- dev-refactor/passkey-credentials-by-application
- dev-refactor/use-mfa-level-evidence
- dev-test/tenant-tree-contract-kit
This package is auto-updated.
Last update: 2026-11-21 18:02:03 UTC
README
Identity and access management for Laravel: installs the authentication, authorization, MFA, SSO and audit log packages and binds them together. Each of the five works alone; this package provides the glue between them: it binds each one's contracts to the others' services, translates between their shapes, maps their events to the audit trail and checks that the whole is configured safely.
| Package | Owns |
|---|---|
sinemacula/laravel-authentication |
Who the caller is: identities, principals, sessions, credentials and tokens |
sinemacula/laravel-authorization |
What the principal may do: roles, permissions, policies and their evaluation |
sinemacula/laravel-mfa |
Further factors, their enrolment, recovery codes, the factor combination policy and step-up |
sinemacula/laravel-sso |
Sign-in through a tenant's own identity provider, over SAML 2.0 or OpenID Connect |
sinemacula/laravel-audit-log |
Recording security-relevant activity |
Each package references no other and exposes its own contracts with defaults that fail closed. This package is the one place that knows them all. It decides nothing the packages leave to your application: your identity, principal and tenant models, your tenant tree, your membership rules, your message senders and every route stay yours.
Features
- One install: every package's configuration, language files and migrations published in a working order, safe to run twice, and a list of what remains for your application to bind.
- Bridging configuration only: one file for what crosses packages (the shared storage connection, which adapters are on, provisioning, SSO's evidence policy, the audit, retry and worker options); each package's own settings stay in its own file.
- Adapters: each package's contracts bound to the others' services, every binding a default your application can replace through configuration or the container.
- Fail closed: an adapter that cannot translate refuses inside the transaction, never by skipping.
- One transaction: a change that spans packages commits or rolls back as one on the shared storage connection, with a helper that retries the whole of it on a serialisation failure or deadlock.
- The audit trail: every package's events mapped to audit entries, and nothing else enforced through events.
- Partial suites: a package's features stay off until configured, and a feature that is off is not checked; the adapters stay bound, so turning it on later needs nothing more.
- Ready for production: safe under Octane and in queue workers, with a combined reset as each Octane worker starts and before each queued job, one call that registers the scheduled work, and a configuration check for a deploy pipeline.
Installation
composer require sinemacula/laravel-iam
Quick Start
Publish every package's configuration and migrations, then set the connections under The storage connection and migrate:
php artisan iam:install php artisan migrate
The install command lists what remains for your application: the contracts it binds, its routes, its audit-log and freshness settings, and its schedule. Then check the whole configuration, for example as a deploy step:
php artisan iam:check
It runs every package's own check and this package's, and exits non-zero on any failure.
Documentation
The guides live in docs/guides. The security and lifecycle contracts behind them, for maintainers and reviewers, are in docs/design.
Requirements
- PHP ^8.3 (extensions: bcmath, curl, dom, hash, libxml, mbstring, openssl, zlib)
- Laravel ^12.40 || ^13.3
Testing
composer test # all suites in parallel (Paratest) composer test:coverage # all suites with clover coverage composer test:unit # unit suite only composer test:feature # feature suite only composer test:integration # integration suite only composer test:performance # performance budget suite (serial) composer test:mutation # scoped mutation gate composer test:mutation:full # full mutation suite (no thresholds) composer bench # PHPBench hot-path benchmarks composer check # static analysis + style composer format # format the codebase composer smells # advisory code smells (duplication, complexity)
Changelog
See CHANGELOG.md for a list of notable changes.
Contributing
Contributions are welcome. Please read CONTRIBUTING.md for guidelines on branching, commits, code quality, and pull requests.
Security
If you discover a security vulnerability, please report it responsibly. See SECURITY.md for the disclosure policy and contact details.
License
Licensed under the Apache License, Version 2.0.