aboutsummaryrefslogtreecommitdiff
path: root/src/browsertab.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/browsertab.cpp')
-rw-r--r--src/browsertab.cpp16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/browsertab.cpp b/src/browsertab.cpp
index 359fd7c..456af37 100644
--- a/src/browsertab.cpp
+++ b/src/browsertab.cpp
@@ -663,9 +663,25 @@ bool BrowserTab::startRequest(const QUrl &url)
if(answer != QMessageBox::Yes)
return false;
this->current_handler->disableClientCertificate();
+ this->ui->enable_client_cert_button->setChecked(false);
}
} else {
this->current_handler->disableClientCertificate();
+ this->ui->enable_client_cert_button->setChecked(false);
+ }
+
+ if(this->current_identitiy.isValid() and (url.host() != this->current_location.host())) {
+ auto answer = QMessageBox::question(
+ this,
+ "Kristall",
+ "You want to visit a new host, but have a client certificate enabled. This may be a risk to expose your identity to another host.\r\nDo you want to keep the certificate enabled?",
+ QMessageBox::Yes | QMessageBox::No,
+ QMessageBox::No
+ );
+ if(answer != QMessageBox::Yes) {
+ this->current_handler->disableClientCertificate();
+ this->ui->enable_client_cert_button->setChecked(false);
+ }
}
this->current_location = url;