PHPackages                             mastersteelblade/google-authenticator - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Authentication &amp; Authorization](/categories/authentication)
4. /
5. mastersteelblade/google-authenticator

ActiveLibrary[Authentication &amp; Authorization](/categories/authentication)

mastersteelblade/google-authenticator
=====================================

v1.0.1(5y ago)0853MITPHPPHP ^8.0

Since Dec 8Pushed 5y ago1 watchersCompare

[ Source](https://github.com/MasterSteelblade/GoogleAuthenticator)[ Packagist](https://packagist.org/packages/mastersteelblade/google-authenticator)[ Docs](https://github.com/MasterSteelblade/GoogleAuthenticator)[ RSS](/packages/mastersteelblade-google-authenticator/feed)WikiDiscussions master Synced 1w ago

READMEChangelog (2)Dependencies (1)Versions (2)Used By (0)

Google Authenticator
====================

[](#google-authenticator)

This package provides Google Authenticator functionality to your sites.

Documentation is pending.

BranchGithub Actionsmaster[![Test](https://github.com/MasterSteelblade/GoogleAuthenticator/workflows/Test/badge.svg)](https://github.com/MasterSteelblade/GoogleAuthenticator/actions?query=workflow%3ATest+branch%3Amaster)Requirements
------------

[](#requirements)

This fork is built for PHP 8.0+.

Installation using Composer
---------------------------

[](#installation-using-composer)

```
composer require mastersteelblade/google-authenticator
```

Usage
-----

[](#usage)

See example.php for how to use it.

The original Sonata web app is present in web/, pending an overhaul. Please make users.dat writeable for the webserver, or the secret can't be saved. Try to login with chregu/foobar.

What's missing in the example:

- Prevent replay attacks. A token should only be used once in order to prevent the risk of shoulder surfing.
- Show QR Code only when providing password again (or not at all)
- Regenerate secret on user request.

Feel free to submit PRs to improve this, or wait until I get around to it myself.

Support
-------

[](#support)

Please use GitHub issues for support, as they're the easiest way to get in touch with me. Feel free to submit feature requests and bug reports, and I'll do what I can to implement them!

If you think you found a bug or you have a feature idea to propose, feel free to open an issue **after looking** at the [contributing guide](CONTRIBUTING.md).

License
-------

[](#license)

This package is available under the [MIT license](LICENSE), and was originally forked from the seemingly abandoned [Sonata Project](https://github.com/sonata-project/GoogleAuthenticator) fork.

###  Health Score

28

—

LowBetter than 54% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity15

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity58

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~0 days

Total

2

Last Release

1987d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/10645285?v=4)[Benjamin Clarke](/maintainers/MasterSteelblade)[@MasterSteelblade](https://github.com/MasterSteelblade)

---

Top Contributors

[![MasterSteelblade](https://avatars.githubusercontent.com/u/10645285?v=4)](https://github.com/MasterSteelblade "MasterSteelblade (12 commits)")

---

Tags

google authenticator

### Embed Badge

![Health badge](/badges/mastersteelblade-google-authenticator/health.svg)

```
[![Health](https://phpackages.com/badges/mastersteelblade-google-authenticator/health.svg)](https://phpackages.com/packages/mastersteelblade-google-authenticator)
```

###  Alternatives

[spomky-labs/otphp

A PHP library for generating one time passwords according to RFC 4226 (HOTP Algorithm) and the RFC 6238 (TOTP Algorithm) and compatible with Google Authenticator

1.5k46.1M119](/packages/spomky-labs-otphp)[scheb/2fa-google-authenticator

Extends scheb/2fa-bundle with two-factor authentication using Google Authenticator

298.2M30](/packages/scheb-2fa-google-authenticator)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
