From 3fce584ad134fd80d30e8a5bacc0076be119dece Mon Sep 17 00:00:00 2001 From: Christophe Jaillet Date: Tue, 21 Apr 2020 10:18:08 +0000 Subject: [PATCH] r1876779 follow-up. strcmp returns 0 if strings match, i.e. TLS/1.0 is found. ap_find_token returns 1 if TLS/1.0 is found. So the test has to be reversed to keep the same behavior git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1876783 13f79535-47bb-0310-9956-ffa450edef68 --- modules/arch/netware/mod_nw_ssl.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/arch/netware/mod_nw_ssl.c b/modules/arch/netware/mod_nw_ssl.c index ae0ef023088..67d0e8c8cd4 100644 --- a/modules/arch/netware/mod_nw_ssl.c +++ b/modules/arch/netware/mod_nw_ssl.c @@ -1143,7 +1143,7 @@ char *ssl_var_lookup(apr_pool_t *p, server_rec *s, conn_rec *c, request_rec *r, #define SWITCH_STATUS_LINE "HTTP/1.1 101 Switching Protocols" #define UPGRADE_HEADER "Upgrade: TLS/1.0, HTTP/1.1" -#define CONNECTION_HEADER "Connection: Upgrade" +#define CONNECTION_HEADER "Connection: upgrade" static apr_status_t ssl_io_filter_Upgrade(ap_filter_t *f, apr_bucket_brigade *bb) @@ -1178,7 +1178,7 @@ static apr_status_t ssl_io_filter_Upgrade(ap_filter_t *f, upgrade = apr_table_get(r->headers_in, "Upgrade"); if (upgrade == NULL - || ap_find_token(r->pool, upgrade, "TLS/1.0")) { + || !ap_find_token(r->pool, upgrade, "TLS/1.0")) { /* "Upgrade: TLS/1.0, ..." header not found, don't do Upgrade */ return ap_pass_brigade(f->next, bb); } -- 2.47.3