From 909a68c1216b6ea5dbeceaedecec16a0599793d1 Mon Sep 17 00:00:00 2001 From: Fabian Frank Date: Sun, 9 Feb 2014 23:38:55 -0800 Subject: NPN/ALPN: allow disabling via command line when using --http2 one can now selectively disable NPN or ALPN with --no-alpn and --no-npn. for now honored with NSS only. TODO: honor this option with GnuTLS and OpenSSL --- src/tool_getparam.c | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'src/tool_getparam.c') diff --git a/src/tool_getparam.c b/src/tool_getparam.c index e9ae7923a..d54df22d6 100644 --- a/src/tool_getparam.c +++ b/src/tool_getparam.c @@ -90,7 +90,9 @@ static const struct LongShort aliases[]= { #endif {"*F", "dns-servers", TRUE}, {"*g", "trace", TRUE}, + {"*G", "npn", FALSE}, {"*h", "trace-ascii", TRUE}, + {"*H", "alpn", FALSE}, {"*i", "limit-rate", TRUE}, {"*j", "compressed", FALSE}, {"*J", "tr-encoding", FALSE}, @@ -554,6 +556,9 @@ ParameterError getparameter(char *flag, /* f or -long-flag */ warnf(config, "--trace overrides an earlier trace/verbose option\n"); config->tracetype = TRACE_BIN; break; + case 'G': /* --npn */ + config->nonpn = (!toggle)?TRUE:FALSE; + break; case 'h': /* --trace-ascii */ GetStr(&config->trace_dump, nextarg); if(config->tracetype && (config->tracetype != TRACE_ASCII)) @@ -561,6 +566,9 @@ ParameterError getparameter(char *flag, /* f or -long-flag */ "--trace-ascii overrides an earlier trace/verbose option\n"); config->tracetype = TRACE_ASCII; break; + case 'H': /* --alpn */ + config->noalpn = (!toggle)?TRUE:FALSE; + break; case 'i': /* --limit-rate */ { /* We support G, M, K too */ -- cgit v1.2.3