roundly-consulting/sentinel-for-laravel
Sentinel for Laravel adds a lightweight security layer to your app, with configurable guards, role and permission checks, and audit-friendly logging so you can protect routes and track access with minimal setup.
Architecture fit
The package is a Laravel-oriented PHP library that performs key derivation (HKDF subkeys) as part of its cryptographic surface. Release 1.2.2 does not change the public API or the on-disk/wire format; it refactors the HKDF implementation to delegate to crypto-for-laravel's Hash\Hkdf rather than calling PHP's native hash_hkdf directly. Architecturally this is a consolidation play: crypto primitives move behind a single vetted dependency, which reduces duplicated security-sensitive code and centralizes future crypto fixes. For a TPM this is a positive direction — smaller internal crypto surface, clearer ownership boundary.
Integration feasibility
Integration remains a standard Composer drop-in: composer require the package, rely on Laravel package auto-discovery, no new configuration keys, no migrations, no changes to published config or env vars. The only material constraint introduced is crypto-for-laravel ^1.2.0. Feasibility is high unless the host application already pins crypto-for-laravel below 1.2, in which case Composer resolution must be resolved first. No PHP extension requirements change in practice (hash remains required transitively).
Technical risk
Low. The release is explicitly output-preserving: byte-identical derivation, RFC 5869 conformance unchanged, frozen format vectors unchanged. That means previously derived subkeys, encrypted payloads, and any persisted blobs remain valid — no re-keying, no re-encryption, no data migration. The residual risks are (a) a transitive dependency bump, and (b) trust transfer — correctness of HKDF now depends on crypto-for-laravel rather than the PHP runtime, so its release discipline and test coverage become part of our risk surface.
Key questions
crypto-for-laravel maintained under the same ownership/security review as this package, and what is its release cadence?^1.2.0 permit a future 1.x that could alter HKDF behavior, and do the frozen vectors run in this package's CI against the resolved dependency?crypto-for-laravel's Hash\Hkdf cover every hash algorithm and output-length case this package previously supported via hash_hkdf (including the 255×hash-length ceiling)?crypto-for-laravel added?crypto-for-laravel 1.0/1.1, and who owns that bump?Stack fit Standard Laravel package: PHP 8.x, Composer, service provider auto-discovery, no framework-version-specific code paths implied by this change. Fits existing application layout without new infrastructure, queues, or storage.
Migration path
Bump the package to 1.2.2 and ensure crypto-for-laravel >= 1.2.0 resolves. Because derivation output is byte-identical, the migration is dependency-only: no schema changes, no re-encryption job, no dual-write window, no key rotation. Existing ciphertext and derived material continue to decrypt/verify unchanged.
Compatibility
Verify that no other direct or transitive dependency constrains crypto-for-laravel to <1.2. Check PHP version floor and the hash extension in all target environments. Confirm composer.lock is committed and reviewed, and that CI runs the package's frozen format vectors against the newly resolved dependency graph rather than only against the previous lockfile.
Sequencing
Maintenance
Net reduction in maintenance burden: one fewer in-repo crypto implementation to review and patch. In exchange, crypto-for-laravel becomes a tracked dependency requiring version monitoring and participation in routine dependency-update cadence. Patch-level churn here is low and the change is behavior-neutral, so ongoing maintenance cost is effectively unchanged.
Support
Support and on-call need to know that HKDF-related exceptions may now originate inside crypto-for-laravel (e.g., invalid key-length or unsupported-hash errors) rather than from this package's own code. Error messages and stack traces will shift, so runbooks referencing prior exception text should be updated. First-line triage otherwise unchanged.
Scaling
Negligible impact. HKDF derivation is a small, CPU-bound, constant-cost operation and remains so through the library path; any delta versus native hash_hkdf is immaterial against typical request cost. No new I/O, network calls, or memory pressure introduced.
Failure modes
crypto-for-laravel constraint elsewhere.Hash\Hkdf.crypto-for-laravel 1.x change altering HKDF output — mitigated by frozen vectors but only if they run in CI against the resolved version.Ramp-up
Minimal. Engineers need one piece of context: the crypto primitives now live in crypto-for-laravel, and this package is a consumer. Document that dependency boundary and the CI-vector check in the repo README or onboarding notes so future debugging starts in the right place.
How can I help you explore Laravel packages today?