summaryrefslogtreecommitdiff
path: root/pith
diff options
context:
space:
mode:
Diffstat (limited to 'pith')
-rw-r--r--pith/conf.c66
-rw-r--r--pith/conf.h2
-rw-r--r--pith/conftype.h2
-rw-r--r--pith/pine.hlp6
4 files changed, 55 insertions, 21 deletions
diff --git a/pith/conf.c b/pith/conf.c
index cbbe7558..f856c961 100644
--- a/pith/conf.c
+++ b/pith/conf.c
@@ -756,10 +756,8 @@ static struct variable variables[] = {
NULL, cf_text_disable_drivers},
{"disable-these-authenticators", 0, 1, 0, 1, 1, 1, 0, 0, 0, 1, 0,
NULL, cf_text_disable_auths},
-#ifdef DF_ENCRYPTION_RANGE
{"encryption-protocol-range", 0, 1, 0, 1, 1, 0, 0, 0, 0, 1, 0,
NULL, cf_text_encryption_range},
-#endif
{"remote-abook-metafile", 0, 1, 0, 1, 0, 0, 0, 0, 1, 1, 0,
NULL, cf_text_remote_abook_metafile},
{"remote-abook-history", 0, 1, 0, 1, 1, 0, 0, 0, 0, 1, 0,
@@ -1621,9 +1619,7 @@ init_vars(struct pine *ps, void (*cmds_f) (struct pine *, char **))
GLO_PRINTER = cpystr(DF_DEFAULT_PRINTER);
GLO_ELM_STYLE_SAVE = cpystr(DF_ELM_STYLE_SAVE);
-#ifdef DF_ENCRYPTION_RANGE
GLO_ENCRYPTION_RANGE = cpystr(DF_ENCRYPTION_RANGE);
-#endif
GLO_SAVE_BY_SENDER = cpystr(DF_SAVE_BY_SENDER);
GLO_HEADER_IN_REPLY = cpystr(DF_HEADER_IN_REPLY);
GLO_INBOX_PATH = cpystr("inbox");
@@ -2353,9 +2349,7 @@ init_vars(struct pine *ps, void (*cmds_f) (struct pine *, char **))
set_current_val(&vars[V_FORCED_ABOOK_ENTRY], TRUE, TRUE);
set_current_val(&vars[V_DISABLE_DRIVERS], TRUE, TRUE);
set_current_val(&vars[V_DISABLE_AUTHS], TRUE, TRUE);
-#ifdef DF_ENCRYPTION_RANGE
set_current_val(&vars[V_ENCRYPTION_RANGE], TRUE, TRUE);
-#endif
set_current_val(&vars[V_VIEW_HEADERS], TRUE, TRUE);
/* strip spaces and colons */
@@ -7893,10 +7887,8 @@ config_help(int var, int feature)
return(h_config_disable_drivers);
case V_DISABLE_AUTHS :
return(h_config_disable_auths);
-#ifdef DF_ENCRYPTION_RANGE
case V_ENCRYPTION_RANGE :
return(h_config_encryption_range);
-#endif
case V_REMOTE_ABOOK_METADATA :
return(h_config_abook_metafile);
case V_REPLY_STRING :
@@ -8218,6 +8210,12 @@ printer_value_check_and_adjust(void)
return(!ok);
}
+#ifdef _WINDOWS
+#include <schannel.h>
+#include <Schnlsp.h>
+#else
+#include <openssl/ssl.h>
+#endif /* _WINDOWS */
char **
get_supported_options(void)
@@ -8269,14 +8267,50 @@ get_supported_options(void)
config[cnt] = cpystr(_(" TLS and SSL"));
tmp[0] = tmp[1] = ' ';
tmp[2] = '\0';
- strcat(tmp, "TLSv1, ");
- strcat(tmp, "TLSv1.1, ");
- strcat(tmp, "TLSv1.2, ");
-#ifdef TLS1_3_VERSION
- strcat(tmp, "TLSv1.3, ");
-#endif /* TLS1_3_VERSION */
- tmp[strlen(tmp)-2] = '.';
- tmp[strlen(tmp)-1] = '\0';
+#ifdef _WINDOWS
+ #ifdef SP_PROT_SSL3
+ strcat(tmp, "SSLv3, ");
+ #endif /* SP_PROT_SSL3 */
+ #ifdef SP_PROT_TLS1
+ strcat(tmp, "TLSv1, ");
+ #endif /* SP_PROT_TLS1 */
+ #ifdef SP_PROT_TLS1_1
+ strcat(tmp, "TLSv1.1, ");
+ #endif /* SP_PROT_TLS1 */
+ #ifdef SP_PROT_TLS1_2
+ strcat(tmp, "TLSv1.2, ");
+ #endif /* SP_PROT_TLS1_2 */
+ #ifdef SP_PROT_TLS1_3
+ strcat(tmp, "TLSv1.3, ");
+ #endif /* SP_PROT_TLS1_3 */
+#else
+ #ifdef SSL3_VERSION
+ #ifndef OPENSSL_NO_SSL3_METHOD
+ strcat(tmp, "SSLv3, ");
+ #endif /* OPENSSL_NO_SSL3_METHOD */
+ #endif /* SSL3_VERSION */
+ #ifdef TLS1_VERSION
+ #ifndef OPENSSL_NO_TLS1_METHOD
+ strcat(tmp, "TLSv1, ");
+ #endif /* OPENSSL_NO_TLS1_METHOD */
+ #endif /* TLS1_VERSION */
+ #ifdef TLS1_1_VERSION
+ #ifndef OPENSSL_NO_TLS1_1_METHOD
+ strcat(tmp, "TLSv1.1, ");
+ #endif /* OPENSSL_NO_TLS1_1_METHOD */
+ #endif /* TLS1_1_VERSION */
+ #ifdef TLS1_2_VERSION
+ #ifndef OPENSSL_NO_TLS1_2_METHOD
+ strcat(tmp, "TLSv1.2, ");
+ #endif /* OPENSSL_NO_TLS1_2_METHOD */
+ #endif /* TLS1_2_VERSION */
+ #ifdef TLS1_3_VERSION
+ #ifndef OPENSSL_NO_TLS1_3_METHOD
+ strcat(tmp, "TLSv1.3, ");
+ #endif /* OPENSSL_NO_TLS1_3_METHOD */
+ #endif /* TLS1_3_VERSION */
+#endif /* _WINDOWS */
+ tmp[strlen(tmp)-2] = '\0';
}
else
config[cnt] = cpystr(_(" None (no TLS or SSL)"));
diff --git a/pith/conf.h b/pith/conf.h
index bd72563b..100224bc 100644
--- a/pith/conf.h
+++ b/pith/conf.h
@@ -267,10 +267,8 @@
#define GLO_REMOTE_ABOOK_HISTORY vars[V_REMOTE_ABOOK_HISTORY].global_val.p
#define VAR_REMOTE_ABOOK_VALIDITY vars[V_REMOTE_ABOOK_VALIDITY].current_val.p
#define GLO_REMOTE_ABOOK_VALIDITY vars[V_REMOTE_ABOOK_VALIDITY].global_val.p
-#ifdef DF_ENCRYPTION_RANGE
#define GLO_ENCRYPTION_RANGE vars[V_ENCRYPTION_RANGE].global_val.p
#define VAR_ENCRYPTION_RANGE vars[V_ENCRYPTION_RANGE].current_val.p
-#endif
/* Elm style save is obsolete in Pine 3.81 (see saved msg name rule) */
#define VAR_ELM_STYLE_SAVE vars[V_ELM_STYLE_SAVE].current_val.p
#define GLO_ELM_STYLE_SAVE vars[V_ELM_STYLE_SAVE].global_val.p
diff --git a/pith/conftype.h b/pith/conftype.h
index 3f0f1e3c..4ea7993e 100644
--- a/pith/conftype.h
+++ b/pith/conftype.h
@@ -174,9 +174,7 @@ typedef enum { V_PERSONAL_NAME = 0
, V_NEW_VER_QUELL
, V_DISABLE_DRIVERS
, V_DISABLE_AUTHS
-#ifdef DF_ENCRYPTION_RANGE
, V_ENCRYPTION_RANGE
-#endif
, V_REMOTE_ABOOK_METADATA
, V_REMOTE_ABOOK_HISTORY
, V_REMOTE_ABOOK_VALIDITY
diff --git a/pith/pine.hlp b/pith/pine.hlp
index 2435d516..c6c1a2e4 100644
--- a/pith/pine.hlp
+++ b/pith/pine.hlp
@@ -140,7 +140,7 @@ with help text for the config screen and the composer that didn't have any
reasonable place to be called from.
Dummy change to get revision in pine.hlp
============= h_revision =================
-Alpine Commit 493 2020-07-10 00:56:09
+Alpine Commit 494 2020-07-17 01:43:03
============= h_news =================
<HTML>
<HEAD>
@@ -237,6 +237,10 @@ problems you find with this release.
<LI> Alpine will not write debug files unless started with the option -d,
so for example &quot;alpine -d 2&quot; will generate a debug file at level 2,
but just issuing the alpine command will not write any debug to a file.
+
+<LI> Experimental: Attempt to implement the Encryption Range in Windows. It works
+ in Windows 10, and it should work in Windows 8.1. It needs testing in
+ Windows 7 and Windows Vista.
</UL>
<P>