Page 1 of 1
[SOLVED] Disable TOTP - 2FA
Published: May 21, 2025 - 4:05 PM
by dsi_oll
Hello,
I would like to disable 2FA but I can't find the option.
I'm using Discovery version 2.6.0.17226.
The documentation says I need to go to user management to remove it, but I don't have that menu in my version.
Sincerely,
Fabien
Re: Disabling TOTP - 2FA
Published: May 21, 2025 - 5:50 PM
by dcardon
Hello Fabien,
On the server, you can run the following command.
Code: Select all
sqlite3 /opt/wapt/conf/security.sqlite "update waptusers set otp_key=NULL where otp_key is not null;"
In fact the menu should have been greyed out, the OTP function is not available in Discovery.
Sincerely,
Denis
Re: Disabling TOTP - 2FA
Published: May 23, 2025 - 08:37
by dsi_oll
Hello,
thank you for your reply.
WAPT is hosted on Windows with a PostgreSQL server, I believe.
Can you tell me if it's the same command?
Thank you in advance.
Re: Disabling TOTP - 2FA
Published: May 23, 2025 - 12:38
by blemoigne
Good morning,
This one would be best for a WAPT Windows server:
Code: Select all
wapt-get run "import sqlite3; db = sqlite3.connect(r'c:\wapt\conf\security.sqlite'); cur = db.execute('select name,otp_key from waptusers where otp_key is not null'); print(cur.fetchall())"
Have a good weekend,
Bertrand
Re: Disabling TOTP - 2FA
Published: May 23, 2025 - 1:47 PM
by dsi_oll
Hello,
the print function correctly outputs the OTP value but doesn't change it to NULL.
Is there perhaps another way to replace the current value with NULL?
Thank you
Re: Disabling TOTP - 2FA
Published: May 23, 2025 - 2:11 PM
by blemoigne
oops :
Code: Select all
wapt-get run "import sqlite3; db = sqlite3.connect(r'c:\wapt\conf\security.sqlite'); cur = db.execute('update waptusers set otp_key=NULL where otp_key is not null'); "
Re: Disabling TOTP - 2FA
Published: May 23, 2025 - 2:45 PM
by dsi_oll
Sorry, but that doesn't work.
It doesn't modify the "admin" entry.
Re: Disabling TOTP - 2FA
Published: May 26, 2025 - 10:09
by htouvet
add a db.commit();
after the SQL update query
Code: Select all
wapt-get run "import sqlite3; db = sqlite3.connect(r'c:\wapt\conf\security.sqlite'); cur = db.execute('update waptusers set otp_key=NULL where otp_key is not null'); db.commit();"
Re: Disabling TOTP - 2FA
Published: May 26, 2025 - 10:37
by dsi_oll
Perfect,
thank you. Have
a good day.