summaryrefslogtreecommitdiffstats
path: root/framework/src
diff options
context:
space:
mode:
Diffstat (limited to 'framework/src')
-rw-r--r--framework/src/keyring.cpp7
1 files changed, 1 insertions, 6 deletions
diff --git a/framework/src/keyring.cpp b/framework/src/keyring.cpp
index 7bd406c0..26da66c1 100644
--- a/framework/src/keyring.cpp
+++ b/framework/src/keyring.cpp
@@ -55,17 +55,12 @@ AccountKeyring::AccountKeyring(const QByteArray &accountId, QObject *parent)
55 55
56void AccountKeyring::storePassword(const QByteArray &resourceId, const QString &password) 56void AccountKeyring::storePassword(const QByteArray &resourceId, const QString &password)
57{ 57{
58 QSettings settings{mAccountIdentifier + ".keyring", QSettings::IniFormat};
59 settings.setValue(resourceId, password);
60 Sink::SecretStore::instance().insert(resourceId, password); 58 Sink::SecretStore::instance().insert(resourceId, password);
61 Keyring::instance()->unlock(mAccountIdentifier); 59 Keyring::instance()->unlock(mAccountIdentifier);
62} 60}
63 61
64void AccountKeyring::unlock() 62void AccountKeyring::unlock()
65{ 63{
66 QSettings settings{mAccountIdentifier + ".keyring", QSettings::IniFormat}; 64 //TODO load passwords from an on disk keyring
67 for (const auto &resourceId : settings.allKeys()) {
68 Sink::SecretStore::instance().insert(resourceId.toLatin1(), settings.value(resourceId).toString());
69 }
70} 65}
71 66