dev-master
9999999-devYubikey for Laravel 5
MIT
The Requires
- php >=5.4.0
- illuminate/support ~5
laravel laravel5 yubikey
Wallogit.com
2017 © Pedro Peláez
Yubikey for Laravel 5
Yubikey for Laravel 5, (*1)
This package contain fixes which have been found on the bitbeans/Yubikey Repository., (*2)
Buy a Yubikey, (*3)
Yubico API Key Generator, (*4)
Add marcinkozak/yubikey to composer.json., (*5)
"marcinkozak/yubikey": "dev-master"
Run composer update to pull down the latest version of Yubikey., (*6)
Now open up PROJECTFOLDER/config/app.php and add the service provider to your providers array., (*7)
'providers' => array(
'MarcinKozak\Yubikey\YubikeyServiceProvider',
)
And also the alias., (*8)
'aliases' => array(
'Yubikey' => 'MarcinKozak\Yubikey\YubikeyFacade',
)
You can easily integrate the Yubikey Verification into your authentication system in two steps :
- Add a field (eg yubikey_identity) in your user table
- now check your user with username/email + password + yubikey_identity, (*9)
Run php artisan vendor:publish and modify the config file (PROJECTFOLDER/config/yubikey.php) with your own information., (*10)
use YubiKey;
try
{
$yubikey_auth = Yubikey::verify(Input::get('otp'));
$yubikey_params = Yubikey::getParameters();
$yubikey_identity = Yubikey::getParameter('identity');
}
catch (\Exception $e)
{
$error = $e->getMessage();
}
Yubikey for Laravel 5
MIT
laravel laravel5 yubikey