[pan2] * changed cert accept dialog, now the choices are either auto-accept or deny.
- From: Heinrich MÃller <henmull src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [pan2] * changed cert accept dialog, now the choices are either auto-accept or deny.
- Date: Fri, 13 Apr 2012 09:13:17 +0000 (UTC)
commit f2d9b8a3af33b4a144a71206abef5a8435c104e2
Author: Heinrich MÃller <henmull src gnome org>
Date: Fri Apr 13 11:12:11 2012 +0200
* changed cert accept dialog, now the choices are either auto-accept or deny.
pan/data/cert-store.cc | 3 ---
pan/gui/gui.cc | 7 ++-----
2 files changed, 2 insertions(+), 8 deletions(-)
---
diff --git a/pan/data/cert-store.cc b/pan/data/cert-store.cc
index 512060c..081aea5 100644
--- a/pan/data/cert-store.cc
+++ b/pan/data/cert-store.cc
@@ -144,9 +144,6 @@ namespace pan
goto _fail;
}
- // for debugging SSL certs let through everything(!)
- if (_dbg_ssl) { fail = false; mydata->always_trust = 1; }
-
if (fail) goto _fail;
/* auto-add new cert if we always trust this server */
diff --git a/pan/gui/gui.cc b/pan/gui/gui.cc
index 0110048..af01567 100644
--- a/pan/gui/gui.cc
+++ b/pan/gui/gui.cc
@@ -1410,8 +1410,6 @@ bool GUI :: confirm_accept_new_cert_dialog(GtkWindow * parent, gnutls_x509_crt_t
GTK_MESSAGE_WARNING,
GTK_BUTTONS_NONE, NULL);
- gtk_dialog_add_button (GTK_DIALOG(d), _("Always trust"), -66);
-
HIG :: message_dialog_set_text (GTK_MESSAGE_DIALOG(d), buf,
_("Do you want to accept it permanently? (You can change this later.)"));
gtk_dialog_add_buttons (GTK_DIALOG(d),
@@ -1422,8 +1420,7 @@ bool GUI :: confirm_accept_new_cert_dialog(GtkWindow * parent, gnutls_x509_crt_t
gint ret_code = gtk_dialog_run (GTK_DIALOG(d));
- // magic number, sorry. can be externalized later....
- if (ret_code == -66)
+ if (ret_code == GTK_RESPONSE_YES)
{
debug_SSL("set server trust to enabled");
_data.set_server_trust (server, 1);
@@ -1432,7 +1429,7 @@ bool GUI :: confirm_accept_new_cert_dialog(GtkWindow * parent, gnutls_x509_crt_t
gtk_widget_destroy(d);
- return ret_code == GTK_RESPONSE_YES || ret_code == -66;
+ return ret_code == GTK_RESPONSE_YES;
}
#endif
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]