From 425b07fa747e1bd02a5bb86e207de172e65d580c Mon Sep 17 00:00:00 2001 From: Dan Winship Date: Wed, 22 Mar 2000 21:47:21 +0000 Subject: New function to query a service for the authentication protocols it * camel-service.c (camel_service_query_auth_types): New function to query a service for the authentication protocols it supports. * providers/pop3/camel-pop3-store.c (query_auth_types): implement svn path=/trunk/; revision=2147 --- camel/providers/pop3/camel-pop3-store.c | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) (limited to 'camel/providers/pop3') diff --git a/camel/providers/pop3/camel-pop3-store.c b/camel/providers/pop3/camel-pop3-store.c index 2d3f4cbb86..019e314ce7 100644 --- a/camel/providers/pop3/camel-pop3-store.c +++ b/camel/providers/pop3/camel-pop3-store.c @@ -46,6 +46,8 @@ static gboolean pop3_connect (CamelService *service, CamelException *ex); +static GList *query_auth_types (CamelService *service); + static CamelFolder *get_folder (CamelStore *store, const gchar *folder_name, CamelException *ex); @@ -60,6 +62,7 @@ camel_pop3_store_class_init (CamelPop3StoreClass *camel_pop3_store_class) /* virtual method overload */ camel_service_class->connect = pop3_connect; + camel_service_class->query_auth_types = query_auth_types; camel_store_class->get_root_folder = camel_pop3_folder_new; camel_store_class->get_default_folder = camel_pop3_folder_new; @@ -105,6 +108,23 @@ camel_pop3_store_get_type (void) } +static CamelServiceAuthType password_authtype = { + "Password/APOP", + + "This option will connect to the POP server using the APOP " + "protocol if possible, or a plaintext password if not.", + + "", + TRUE +}; + +static GList *query_auth_types (CamelService *service) +{ + GList *ret; + + ret = g_list_append (NULL, &password_authtype); + return ret; +} static gboolean pop3_connect (CamelService *service, CamelException *ex) -- cgit v1.2.3