alexandregz / twofactor_gauthenticator

This RoundCube plugin adds the 2-step verification(OTP) to the login proccess
MIT License
214 stars 74 forks source link

The pluggin activated and configured but 2fa is not used - login directly #172

Open andrewhack opened 1 year ago

andrewhack commented 1 year ago

Hi,

I have RC 1.4.13 on debian 11 and the latest twofactor_gauthenticator plugin. As shown in the pictures, the plugin is configured, including the user. No field to enter the code on the login screen and after authentication, goes directly to the mailbox.

Any suggestions?

image image image

SKB-CGN commented 1 year ago

Hi, please have a look into the file: config.inc.php or if you do not have the file rename config.inc.php.dist into it. Then open the file and add your email address to the array in line: 20

$rcmail_config['users_allowed_2FA'] = array('you@me.com','me@you.com');

Logout and re-login. This should work.

You can also force all users to use 2FA in line 3.

andrewhack commented 1 year ago

2FA is forced. Adding specific users in users_allowed_2FA don't solve the issue. Direct login, no 2FA

SKB-CGN commented 1 year ago

On my end it was working perfectly. Further, if have the version: 2022-11-15 11_00_26-Kreyenborg koeln - Webmail __ Posteingang – Mozilla Firefox

GwynethLlewelyn commented 1 year ago

One silly question: what is the best regexp for allowing all users to use the plugin, but not force them to do so?

I'm using $rcmail_config['users_allowed_2FA'] = array('*'); but, since it's supposed to be a regexp, it's probably better to use .* instead?

I'm just asking because after upgrading today (it's been quite a while since I did an upgrade!), I noticed that the 2FA functionality stopped appearing on user profiles — even those who had it correctly set up.

GwynethLlewelyn commented 1 year ago

GwynethLlewelyn

I'm using $rcmail_config['users_allowed_2FA'] = array('*'); but, since it's supposed to be a regexp, it's probably better to use .* instead?

Quoting myself: indeed, that makes all the difference. Silly me!