Skip to content

Commit

Permalink
Merge pull request #5067 from nextcloud/bugfix/e2e-do-not-generate-ke…
Browse files Browse the repository at this point in the history
…ys-without-request

E2EE. Do not generate keypair without user request.
  • Loading branch information
allexzander committed Nov 9, 2022
1 parent 5001cf4 commit 43d8ce6
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 23 deletions.
17 changes: 0 additions & 17 deletions src/gui/accountmanager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -412,23 +412,6 @@ AccountPtr AccountManager::createAccount()
return acc;
}

void AccountManager::displayMnemonic(const QString& mnemonic)
{
auto *widget = new QDialog;
Ui_Dialog ui;
ui.setupUi(widget);
widget->setWindowTitle(tr("End-to-End encryption mnemonic"));
ui.label->setText(tr("To protect your Cryptographic Identity, we encrypt it with a mnemonic of 12 dictionary words. "
"Please note these down and keep them safe. "
"They will be needed to add other devices to your account (like your mobile phone or laptop)."));
ui.textEdit->setText(mnemonic);
ui.textEdit->focusWidget();
ui.textEdit->selectAll();
ui.textEdit->setAlignment(Qt::AlignCenter);
widget->exec();
widget->resize(widget->sizeHint());
}

void AccountManager::shutdown()
{
const auto accountsCopy = _accounts;
Expand Down
2 changes: 1 addition & 1 deletion src/libsync/account.h
Original file line number Diff line number Diff line change
Expand Up @@ -296,7 +296,7 @@ class OWNCLOUDSYNC_EXPORT Account : public QObject
bool trustCertificates() const;

void setE2eEncryptionKeysGenerationAllowed(bool allowed);
[[nodiscard]] bool e2eEncryptionKeysGenerationAllowed() const;
bool e2eEncryptionKeysGenerationAllowed() const;

public slots:
/// Used when forgetting credentials
Expand Down
5 changes: 0 additions & 5 deletions src/libsync/clientsideencryption.h
Original file line number Diff line number Diff line change
Expand Up @@ -127,11 +127,6 @@ class OWNCLOUDSYNC_EXPORT ClientSideEncryption : public QObject {
public:
void forgetSensitiveData(const AccountPtr &account);

bool newMnemonicGenerated() const;

public slots:
void slotRequestMnemonic();

private slots:
void publicKeyFetched(QKeychain::Job *incoming);
void privateKeyFetched(QKeychain::Job *incoming);
Expand Down

0 comments on commit 43d8ce6

Please sign in to comment.