Skip to content
harry-suryapambagya
Back to blog

WHMCS: Lost 2FA Password?

When a WHMCS admin loses their 2FA backup codes, the rescue path is a single UPDATE query against tbladmins to clear authmodule and authdata.

1 min read

Currently, I managed some WHMCS Dashboard.

For a security things, I force administrative users to enable 2FA. This 2FA usually comes with backup codes. Unexpectedly, some users lost their 2FA password, even lost their backup codes.

For this issue, I need to reset the authentication through database.

Just go to your database, then reset the following user.

mysql> UPDATE tbladmins SET authmodule = '' AND authdata = '' WHERE username = 'forgetfull';
Query OK, 1 row affected (0.00 sec)
Rows matched: 1 Changed: 1 Warnings: 0

Issue solved.

Reff: