[Security] Refuse KDF downgrade; trim profile name and warn on silent credential drop

This commit is contained in:
Lukas Brübach 2026-09-02 20:12:45 +02:00 • committed by BruebachL
parent 4252f69d2b
commit e20846a88d
3 changed files with 20 additions and 1 deletions

View file

@ -151,6 +151,11 @@ void ServersSettings::setServerPassword(const QString &saveName, const QString &
const int index = getPrevioushostindex(saveName);
if (index >= 0) {
setValue(password, QString("password%1").arg(index), "server", "server_details");
} else {
// A credential write that silently no-ops is hard to diagnose from a
// bug report; surface a mismatched profile name instead.
qCWarning(ServersSettingsLog) << "setServerPassword() could not find profile:" << saveName
<< "- password not saved";
}
}