akymos / otp
PHP library that enable otp auth (2-step verification)
Installs: 41
Dependents: 0
Suggesters: 0
Security: 0
Stars: 1
Watchers: 2
Forks: 0
pkg:composer/akymos/otp
Requires
- php: >=5.3.0
- endroid/qrcode: 1.*@dev
This package is not auto-updated.
Last update: 2022-05-23 14:01:59 UTC
README
#otp
otp is PHP library that enable otp auth (2-step verification)
Installation
Add a dependency on akymos/otp
to your composer.json
file.
{
"require": {
"akymos/otp": "dev-master"
}
}
##Usage //Time Based $tb = new Akymos\Otp\TimeBased(); $tb->setSecretKey("yoursecretkey"); $tb->verify("457584");
//Counter Based
$cb = new Akymos\Otp\CounterBased();
$cb->setSecretKey("yoursecretkey");
$cb->verify("343434", 1);