aboutsummaryrefslogtreecommitdiffstats
path: root/options.c
diff options
context:
space:
mode:
authorMatthias Andree <matthias.andree@gmx.de>2008-03-07 13:16:58 +0000
committerMatthias Andree <matthias.andree@gmx.de>2008-03-07 13:16:58 +0000
commit3948bb44ff30ebda9837480c42de7f0d384e4cb9 (patch)
treef81308db46bc55ae85e531f285481fd9966a0ea7 /options.c
parentee75486152cf3ded79d3aa5dfe8158f42472eb78 (diff)
downloadfetchmail-3948bb44ff30ebda9837480c42de7f0d384e4cb9.tar.gz
fetchmail-3948bb44ff30ebda9837480c42de7f0d384e4cb9.tar.bz2
fetchmail-3948bb44ff30ebda9837480c42de7f0d384e4cb9.zip
Merge Daniel Richard G.'s --sslcommonname option.
Exception from no-features policy on 6.3.X is made to keep people away from doing more dangerous things in order to get rid of CommonName mismatch warnings. svn path=/branches/BRANCH_6-3/; revision=5165
Diffstat (limited to 'options.c')
-rw-r--r--options.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/options.c b/options.c
index 87a308c7..56569bcb 100644
--- a/options.c
+++ b/options.c
@@ -46,6 +46,7 @@ enum {
LA_SSLPROTO,
LA_SSLCERTCK,
LA_SSLCERTPATH,
+ LA_SSLCOMMONNAME,
LA_SSLFINGERPRINT,
LA_FETCHSIZELIMIT,
LA_FASTUIDL,
@@ -125,6 +126,7 @@ static const struct option longoptions[] = {
{"sslproto", required_argument, (int *) 0, LA_SSLPROTO },
{"sslcertck", no_argument, (int *) 0, LA_SSLCERTCK },
{"sslcertpath", required_argument, (int *) 0, LA_SSLCERTPATH },
+ {"sslcommonname", required_argument, (int *) 0, LA_SSLCOMMONNAME },
{"sslfingerprint", required_argument, (int *) 0, LA_SSLFINGERPRINT },
#endif
@@ -539,6 +541,10 @@ int parsecmdline (int argc /** argument count */,
ctl->sslcertpath = prependdir(optarg, currentwd);
break;
+ case LA_SSLCOMMONNAME:
+ ctl->sslcommonname = xstrdup(optarg);
+ break;
+
case LA_SSLFINGERPRINT:
ctl->sslfingerprint = xstrdup(optarg);
break;
@@ -611,6 +617,7 @@ int parsecmdline (int argc /** argument count */,
P(GT_(" --sslcert ssl client certificate\n"));
P(GT_(" --sslcertck do strict server certificate check (recommended)\n"));
P(GT_(" --sslcertpath path to ssl certificates\n"));
+ P(GT_(" --sslcommonname expect this CommonName from server (discouraged)\n"));
P(GT_(" --sslfingerprint fingerprint that must match that of the server's cert.\n"));
P(GT_(" --sslproto force ssl protocol (SSL2/SSL3/TLS1)\n"));
#endif