aboutsummaryrefslogtreecommitdiffstats
path: root/camel/camel-tcp-stream-ssl.c
diff options
context:
space:
mode:
authorDan Winship <danw@src.gnome.org>2001-04-28 05:08:08 +0800
committerDan Winship <danw@src.gnome.org>2001-04-28 05:08:08 +0800
commit63e96e100291b330e75cc3b3b49795c720e5ffa0 (patch)
treee87946a64b23a35dacb190c43676f14691187b98 /camel/camel-tcp-stream-ssl.c
parentd06ca412e46d6b4fc2ecd3e1e956b1e8970c8867 (diff)
downloadgsoc2013-evolution-63e96e100291b330e75cc3b3b49795c720e5ffa0.tar
gsoc2013-evolution-63e96e100291b330e75cc3b3b49795c720e5ffa0.tar.gz
gsoc2013-evolution-63e96e100291b330e75cc3b3b49795c720e5ffa0.tar.bz2
gsoc2013-evolution-63e96e100291b330e75cc3b3b49795c720e5ffa0.tar.lz
gsoc2013-evolution-63e96e100291b330e75cc3b3b49795c720e5ffa0.tar.xz
gsoc2013-evolution-63e96e100291b330e75cc3b3b49795c720e5ffa0.tar.zst
gsoc2013-evolution-63e96e100291b330e75cc3b3b49795c720e5ffa0.zip
Redo this a lot so that instead of having a class full of callbacks, we
* camel-session.c: Redo this a lot so that instead of having a class full of callbacks, we have a subclassable class. Also, replace the increasingly horrifying camel_session_query_authenticator with three new routines, camel_session_get_password, camel_session_forget_password, and camel_session_alert_user. * camel-pgp-context.c: * camel-pkcs7-context.c: * camel-smime-context.c: * providers/imap/camel-imap-store.c: * providers/pop3/camel-pop3-store.c: * providers/smtp/camel-smtp-transport.c: Use camel_session_get_password / camel_session_forget_password. * camel-tcp-stream-ssl.c (ssl_bad_cert): Use camel_session_alert_user. svn path=/trunk/; revision=9617
Diffstat (limited to 'camel/camel-tcp-stream-ssl.c')
-rw-r--r--camel/camel-tcp-stream-ssl.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/camel/camel-tcp-stream-ssl.c b/camel/camel-tcp-stream-ssl.c
index 7e521b0a4d..7fa81484da 100644
--- a/camel/camel-tcp-stream-ssl.c
+++ b/camel/camel-tcp-stream-ssl.c
@@ -336,7 +336,7 @@ ssl_bad_cert (void *data, PRFileDesc *sockfd)
CERTCertificate *cert;
CamelService *service;
char *prompt, *cert_str;
- gpointer accept;
+ gboolean accept;
g_return_val_if_fail (data != NULL, SECFailure);
g_return_val_if_fail (CAMEL_IS_SERVICE (data), SECFailure);
@@ -366,12 +366,10 @@ ssl_bad_cert (void *data, PRFileDesc *sockfd)
g_free (cert_str);
/* query the user to find out if we want to accept this certificate */
- accept = camel_session_query_authenticator (service->session, CAMEL_AUTHENTICATOR_ACCEPT,
- prompt, FALSE, service, NULL, NULL);
-
+ accept = camel_session_alert_user (service->session, CAMEL_SESSION_ALERT_WARNING, prompt, TRUE, NULL);
g_free (prompt);
- if (GPOINTER_TO_INT (accept))
+ if (accept)
return SECSuccess;
return SECFailure;