Roundcube Community Forum

 

How to disable 2FA for dedicated user

Started by cmonty14, February 21, 2020, 04:08:29 AM

Previous topic - Next topic

cmonty14

Hi,
I need to disable 2FA for a dedicated user because this user has lost his authentication code.
The intention is to allow this user to login with password only and then create a new 2FA authentication code.

Can you please advise how to disable 2FA for a user?

THX

JohnDoh

Please contact the author of the 2FA plugin you are using or your email provider.
Roundcube Plugins: Contextmenu, SpamAssassin Prefs, and more...

cmonty14

The author of the plugin provides this solution:
"Remove from the roundcube DB users.preferences the 2fa configuration."

However, I don't know the correct SQL syntax for this to apply.

Please advise.

THX

JohnDoh

There is a script called bin/moduserprefs.sh which is shipped with Roundcube which can be used to modify a specific users' preferences.
Roundcube Plugins: Contextmenu, SpamAssassin Prefs, and more...

cmonty14

Thanks.

But how must I use this script in order to disable 2FA for specific user?

JohnDoh

Perhaps if you tell us the name of the plugin you are using then if there is someone else here who also uses that plugin they can give you some pointers. Otherwise maybe the plugin author can give you some more specific advice.
Roundcube Plugins: Contextmenu, SpamAssassin Prefs, and more...

cmonty14

#6
Plugin name:
twofactor_gauthenticator https://plugins.roundcube.net/packages/alexandregz/twofactor_gauthenticator

Update:
Solved by deleting anything in field "preferences".

alec

Try bin/moduserprefs.sh --user=<user-id> --delete twofactor_gauthenticator