diff options
author | hiro <hiro@ee746299-78ed-0310-b773-934348b2243d> | 2008-02-15 07:32:30 +0000 |
---|---|---|
committer | hiro <hiro@ee746299-78ed-0310-b773-934348b2243d> | 2008-02-15 07:32:30 +0000 |
commit | a1a045c7a465405af54717703a11877dd67067dc (patch) | |
tree | 8146a78cda3924822a866a501d0771ad33121a72 /src | |
parent | 25f5d0a44e80165a68afbf9b6f03141636c2aead (diff) |
added the feature to save SSL peer certificate and always accept it.
git-svn-id: svn://sylpheed.sraoss.jp/sylpheed/trunk@1952 ee746299-78ed-0310-b773-934348b2243d
Diffstat (limited to 'src')
-rw-r--r-- | src/sslmanager.c | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/src/sslmanager.c b/src/sslmanager.c index 45845357..eaed7786 100644 --- a/src/sslmanager.c +++ b/src/sslmanager.c @@ -1,6 +1,6 @@ /* * Sylpheed -- a GTK+ based, lightweight, and fast e-mail client - * Copyright (C) 1999-2007 Hiroyuki Yamamoto + * Copyright (C) 1999-2008 Hiroyuki Yamamoto * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -139,13 +139,15 @@ gint ssl_manager_verify_cert(SockInfo *sockinfo, const gchar *hostname, if (prefs_common.comply_gnome_hig) gtk_dialog_add_buttons(GTK_DIALOG(dialog), - GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL, - GTK_STOCK_OK, GTK_RESPONSE_OK, + _("_Reject"), GTK_RESPONSE_REJECT, + _("_Temporarily accept"), GTK_RESPONSE_OK, + _("Always _accept"), GTK_RESPONSE_ACCEPT, NULL); else gtk_dialog_add_buttons(GTK_DIALOG(dialog), - GTK_STOCK_OK, GTK_RESPONSE_OK, - GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL, + _("Always _accept"), GTK_RESPONSE_ACCEPT, + _("_Temporarily accept"), GTK_RESPONSE_OK, + _("_Reject"), GTK_RESPONSE_REJECT, NULL); gtk_dialog_set_default_response(GTK_DIALOG(dialog), GTK_RESPONSE_OK); @@ -155,9 +157,11 @@ gint ssl_manager_verify_cert(SockInfo *sockinfo, const gchar *hostname, gtk_widget_destroy(dialog); switch (result) { + case GTK_RESPONSE_ACCEPT: + return 0; case GTK_RESPONSE_OK: return 1; - case GTK_RESPONSE_CANCEL: + case GTK_RESPONSE_REJECT: default: break; } |