invalidateToken();
- /* IMPORTANT
- * TODO: For "Log out" & "Remove account": Remove client CA certs and KEY!
- *
- * Disabled as long as selecting another cert is not supported by the UI.
- *
- * Being able to specify a new certificate is important anyway: expiry etc.
- */
- //deleteKeychainEntries();
+ deleteKeychainEntries();
}
void WebFlowCredentials::setAccount(Account *account) {
};
startDeleteJob(_user);
- startDeleteJob(_user + clientKeyPEMC);
- startDeleteJob(_user + clientCertificatePEMC);
- for (auto i = 0; i < _clientSslCaCertificates.count(); i++) {
- startDeleteJob(_user + clientCaCertificatePEMC + QString::number(i));
- }
+ /* IMPORTANT - remove later - FIXME MS@2019-12-07 -->
+ * TODO: For "Log out" & "Remove account": Remove client CA certs and KEY!
+ *
+ * Disabled as long as selecting another cert is not supported by the UI.
+ *
+ * Being able to specify a new certificate is important anyway: expiry etc.
+ *
+ * We introduce this dirty hack here, to allow deleting them upon Remote Wipe.
+ */
+ if(_account->isRemoteWipeRequested_HACK()) {
+ // <-- FIXME MS@2019-12-07
+ startDeleteJob(_user + clientKeyPEMC);
+ startDeleteJob(_user + clientCertificatePEMC);
+
+ for (auto i = 0; i < _clientSslCaCertificates.count(); i++) {
+ startDeleteJob(_user + clientCaCertificatePEMC + QString::number(i));
+ }
#if defined(Q_OS_WIN)
- // also delete key sub-chunks (Windows workaround)
- for (auto i = 1; i < _clientSslKeyChunkCount; i++) {
- startDeleteJob(_user + clientKeyPEMC + QString(".") + QString::number(i));
- }
+ // also delete key sub-chunks (Windows workaround)
+ for (auto i = 1; i < _clientSslKeyChunkCount; i++) {
+ startDeleteJob(_user + clientKeyPEMC + QString(".") + QString::number(i));
+ }
#endif
+ // FIXME MS@2019-12-07 -->
+ }
+ // <-- FIXME MS@2019-12-07
}
}
auto accountState = manager->account(_account->displayName()).data();
if(wipe){
+ /* IMPORTANT - remove later - FIXME MS@2019-12-07 -->
+ * TODO: For "Log out" & "Remove account": Remove client CA certs and KEY!
+ *
+ * Disabled as long as selecting another cert is not supported by the UI.
+ *
+ * Being able to specify a new certificate is important anyway: expiry etc.
+ *
+ * We introduce this dirty hack here, to allow deleting them upon Remote Wipe.
+ */
+ _account->setRemoteWipeRequested_HACK();
+ // <-- FIXME MS@2019-12-07
+
// delete account
manager->deleteAccount(accountState);
manager->save();
bool _wroteAppPassword = false;
friend class AccountManager;
+
+ /* IMPORTANT - remove later - FIXME MS@2019-12-07 -->
+ * TODO: For "Log out" & "Remove account": Remove client CA certs and KEY!
+ *
+ * Disabled as long as selecting another cert is not supported by the UI.
+ *
+ * Being able to specify a new certificate is important anyway: expiry etc.
+ *
+ * We introduce this dirty hack here, to allow deleting them upon Remote Wipe.
+ */
+ public:
+ void setRemoteWipeRequested_HACK() { _isRemoteWipeRequested_HACK = true; }
+ bool isRemoteWipeRequested_HACK() { return _isRemoteWipeRequested_HACK; }
+ private:
+ bool _isRemoteWipeRequested_HACK = false;
+ // <-- FIXME MS@2019-12-07
};
}