← Back to Two Factor Authentication Support
To configure this plugin execute the following command:
php artisan vendor:publish --provider="Vdlp\TwoFactorAuthentication\ServiceProvider" --tag="config"
This will create a config/twofactorauthentication.php
file in your app where you can modify the configuration.
Thanks for a prompt response. I ran the command, the file was created, and was able to set the parameters to Require Two Factor Authentication for all administrators. I then tried to login as a user who hasn't enabled two factor, was able to login with no enforcing prompt or error. Is there anything else I need to do?
Please make sure both are set to true
:
/*
|--------------------------------------------------------------------------
| Require Two Factor Authentication for all super users (recommended).
|--------------------------------------------------------------------------
|
| All super users are required to set up Two Factor Authentication upon
| next login.
|
*/
'force_all_super_users' => true,
/*
|--------------------------------------------------------------------------
| Require Two Factor Authentication for all administrators.
|--------------------------------------------------------------------------
|
| All administrators (super users included) are required to set up Two
| Factor Authentication upon next login.
|
*/
'force_all_users' => true,
To be clear, this only affects backend users.
I managed to spot the issue, my bad! There is two files created, one under plugins, and the other on the app itself, I was changing the one under the plugin (plugins/vdlp/twofactorauthentication/config.php ). You should change this file config/twofactorauthentication.php
Thanks.
1-6 of 6