+2007-06-07 Murray Cumming <murrayc@murrayc.com>
+
+ * src/modest-account-mgr-helpers.c: (get_security_for_conf_string),
+ (modest_server_account_set_security):
+ * src/modest-defs.h: Add comments explaining that our
+ UI spec means TLS when it says Normal, so these do not look like errors.
+
+ * src/modest-tny-account.c:
+ (modest_tny_account_new_from_server_account): Use the new tinymail
+ 'wrapped' option for regular SSL, and use the new tinymail 'tls' option
+ for TLS. This should fix projects.maemo.org bug NB#58460.
+
2007-06-06 Murray Cumming <murrayc@murrayc.com>
* src/maemo/easysetup/modest-easysetup-wizard.c:
if (value) {
if (strcmp(value, MODEST_ACCOUNT_SECURITY_VALUE_NONE) == 0)
result = MODEST_PROTOCOL_CONNECTION_NORMAL;
- else if (strcmp(value, MODEST_ACCOUNT_SECURITY_VALUE_NORMAL) == 0)
+ else if (strcmp(value, MODEST_ACCOUNT_SECURITY_VALUE_NORMAL) == 0) {
+ /* The UI has "Normal (TLS)": */
result = MODEST_PROTOCOL_CONNECTION_TLS;
- else if (strcmp(value, MODEST_ACCOUNT_SECURITY_VALUE_SSL) == 0)
+ } else if (strcmp(value, MODEST_ACCOUNT_SECURITY_VALUE_SSL) == 0)
result = MODEST_PROTOCOL_CONNECTION_SSL;
}
const gchar* str_value = NULL;
if (security == MODEST_PROTOCOL_CONNECTION_NORMAL)
str_value = MODEST_ACCOUNT_SECURITY_VALUE_NONE;
- else if (security == MODEST_PROTOCOL_CONNECTION_TLS)
+ else if (security == MODEST_PROTOCOL_CONNECTION_TLS) {
+ /* The UI has "Normal (TLS)": */
str_value = MODEST_ACCOUNT_SECURITY_VALUE_NORMAL;
- else if (security == MODEST_PROTOCOL_CONNECTION_SSL)
+ } else if (security == MODEST_PROTOCOL_CONNECTION_SSL)
str_value = MODEST_ACCOUNT_SECURITY_VALUE_SSL;
/* Set it in the configuration: */
#define MODEST_ACCOUNT_SECURITY "security"
#define MODEST_ACCOUNT_SECURITY_VALUE_NONE "none"
-#define MODEST_ACCOUNT_SECURITY_VALUE_NORMAL "normal"
+#define MODEST_ACCOUNT_SECURITY_VALUE_NORMAL "normal" /* Meaning "Normal (TLS)", as in our UI spec. */
#define MODEST_ACCOUNT_SECURITY_VALUE_SSL "ssl"
/* Macros for different text formats in mail editor */
*/
#define MODEST_ACCOUNT_OPTION_SSL "use_ssl"
#define MODEST_ACCOUNT_OPTION_SSL_NEVER "never"
-#define MODEST_ACCOUNT_OPTION_SSL_ALWAYS "always"
+/* This is a tinymail camel-lite specific option,
+ * roughly equivalent to "always" in regular camel,
+ * which is appropriate for a generic "SSL" connection option: */
+#define MODEST_ACCOUNT_OPTION_SSL_WRAPPED "wrapped"
+/* Not used in our UI so far: */
#define MODEST_ACCOUNT_OPTION_SSL_WHEN_POSSIBLE "when-possible"
+/* This is a tinymailcamel-lite specific option that is not in regular camel. */
+#define MODEST_ACCOUNT_OPTION_SSL_TLS "tls"
/* These seem to be listed in
* libtinymail-camel/camel-lite/camel/providers/imap/camel-imap-provider.c
option_security = MODEST_ACCOUNT_OPTION_SSL "=" MODEST_ACCOUNT_OPTION_SSL_NEVER;
break;
case MODEST_PROTOCOL_CONNECTION_SSL:
+ /* Apparently, use of "IMAPS" (specified in our UI spec), implies
+ * use of the "wrapped" option: */
+ option_security = MODEST_ACCOUNT_OPTION_SSL "=" MODEST_ACCOUNT_OPTION_SSL_WRAPPED;
+ break;
case MODEST_PROTOCOL_CONNECTION_TLS:
- option_security = MODEST_ACCOUNT_OPTION_SSL "=" MODEST_ACCOUNT_OPTION_SSL_ALWAYS;;
+ option_security = MODEST_ACCOUNT_OPTION_SSL "=" MODEST_ACCOUNT_OPTION_SSL_TLS;
break;
case MODEST_PROTOCOL_CONNECTION_TLS_OP:
+ /* This is not actually in our UI: */
option_security = MODEST_ACCOUNT_OPTION_SSL "=" MODEST_ACCOUNT_OPTION_SSL_WHEN_POSSIBLE;
break;
default: