jonasarts/google-authenticator-bundle
Symfony bundle for adding Google Authenticator two-factor authentication to your app. Provides TOTP secret generation and code validation, with configurable services for integrating 2FA into login flows.
Architecture fit — mismatch with the stated stack. The ticket frames this as a Laravel/PHP package; it is a Symfony bundle. It ships a bundle class, a DI extension, and a configuration tree that only resolve inside a Symfony kernel. Laravel has no bundle registration or config merging, so the package's primary delivery mechanism is inert in our stack. What has residual value is the wrapped RFC 6238 TOTP logic — secret generation, otpauth:// provisioning URIs, time-window verification — which is a small, self-contained PHP class. The correct mental model is "a TOTP implementation we could vendor," not "a component we install."
Integration feasibility — low but non-zero, and probably not worth it. Two paths exist: (1) bypass the bundle, take the underlying TOTP class, and wire it through a Laravel service provider (roughly 2–4 engineering days including tests, config, and QR provisioning); or (2) drop the bundle and standardize on a Laravel-native option (p pragmarx/google2fa-laravel) or the maintained OTP core (spomky-labs/otphp). Path 2 is almost certainly correct — the bundle's only differentiator is Symfony wiring we cannot use.
Technical risk — high, driven by adoption signals. Four stars, zero dependents, composite score 0.05. That means no downstream consumers have validated it in production, no community pressure to fix security defects, and effectively a single maintainer. For an authentication primitive, an unmaintained wrapper is a liability independent of code quality. The MIT license is clean — the one unambiguous positive.
Key questions before any commitment:
pragmarx/google2fa-laravel or otphp does not? If the answer is "nothing," close the ticket.Stack fit. Assume Laravel 10/11 on PHP 8.2+. The bundle targets Symfony 4/5-era Flex conventions. There is no supported path to composer require this into a Laravel app and have it function. The work is a refactor, not an install — and that reframe should be explicit in the ticket before engineering time is allocated.
Recommended migration path:
verifyCode() against Google Authenticator, Authy, and 1Password. Confirm drift-window behavior.app/Support/ or a first-party package, wrap it behind a TotpService interface, and bind it in a service provider. Keep the upstream dependency out of composer.json entirely so a dead project cannot block a framework upgrade.Compatibility. The immediate unknown is PHP constraint declarations — a Symfony 4-era composer.json may not declare PHP 8.2+ support, producing a resolution conflict before any code runs. Framework coupling is the deeper issue: config arrives via Symfony's Configuration tree, so every behavior toggle (window size, digit count, issuer) must be re-expressed as Laravel config with its own defaults and validation.
Sequencing. Do not let this block the 2FA roadmap. Run the evaluation spike in parallel with the standard adoption track and timebox it to one sprint. If the outcome is "use the Laravel-native package," the assessment closes with zero production code — which is a successful outcome, not a wasted sprint.
Maintenance — this becomes ours. With zero dependents and near-zero community, there is no realistic expectation of upstream fixes. Every future PHP upgrade becomes an internal ticket. Budget a named owner and an annual review; if we cannot commit that, we should not ship it. Vendoring rather than depending is the mitigation, and it should be a stated condition of adoption rather than a discovery after the fact.
Support. No forum, no meaningful issue-tracker velocity, no vendor. On-call engineers will debug from source. That is tolerable for the TOTP algorithm itself, which is stable by RFC, and intolerable for the surrounding surfaces — secret storage, provisioning, recovery — where real incidents actually occur.
Scaling. The algorithm is stateless and cheap; there is no scaling concern at any realistic user volume. The operational load sits in what we must build ourselves: encrypted-at-rest secret storage, per-user rate limiting on verification attempts, single-use code enforcement, clock-drift tolerance, recovery codes, and an admin reset path. None of that ships with this bundle, and scoping it is the real cost of the feature.
Failure modes to design for:
Ramp-up. Low for a PHP developer to read the code (~half a day — small surface area). The real cost is security review: any 2FA implementation we own should get an internal review of secret handling and verification logic before production, which is 3–5 days of a security engineer's time and should be in the estimate from day one.
Bottom line. This is a mis-scoped candidate. The wrapper is unusable in Laravel, the adoption signals indicate an unmaintained project, and a mature Laravel-native alternative exists. Recommend closing the bundle evaluation and redirecting effort to the Laravel-native path, reserving the one-day spike solely to confirm no unique capability is lost.
How can I help you explore Laravel packages today?