mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2024-12-26 15:59:50 -05:00
parent
6a8b070b0a
commit
7cb2991a13
@ -46,7 +46,7 @@ void TotpSetupDialog::saveSettings()
|
||||
{
|
||||
// Secret key sanity check
|
||||
// Convert user input to all uppercase and remove '='
|
||||
auto key = m_ui->seedEdit->text().toUpper().remove(" ").remove("=").toLatin1();
|
||||
auto key = m_ui->seedEdit->text().toUpper().remove(" ").remove("=").trimmed().toLatin1();
|
||||
auto sanitizedKey = Base32::sanitizeInput(key);
|
||||
// Use startsWith to ignore added '=' for padding at the end
|
||||
if (!sanitizedKey.startsWith(key)) {
|
||||
|
Loading…
Reference in New Issue
Block a user