From cvs-return-65423-archive-asf-public=cust-asf.ponee.io@httpd.apache.org Wed May 22 09:54:13 2019 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [207.244.88.153]) by mx-eu-01.ponee.io (Postfix) with SMTP id DCCC2180651 for ; Wed, 22 May 2019 11:54:12 +0200 (CEST) Received: (qmail 2676 invoked by uid 500); 22 May 2019 09:54:11 -0000 Mailing-List: contact cvs-help@httpd.apache.org; run by ezmlm Precedence: bulk Reply-To: dev@httpd.apache.org list-help: list-unsubscribe: List-Post: List-Id: Delivered-To: mailing list cvs@httpd.apache.org Received: (qmail 2667 invoked by uid 99); 22 May 2019 09:54:11 -0000 Received: from Unknown (HELO svn01-us-west.apache.org) (209.188.14.144) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 22 May 2019 09:54:11 +0000 Received: from svn01-us-west.apache.org (localhost [127.0.0.1]) by svn01-us-west.apache.org (ASF Mail Server at svn01-us-west.apache.org) with ESMTP id 0D0B43A005B for ; Wed, 22 May 2019 09:54:06 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1859713 - /httpd/httpd/trunk/modules/proxy/proxy_util.c Date: Wed, 22 May 2019 09:54:05 -0000 To: cvs@httpd.apache.org From: rpluem@apache.org X-Mailer: svnmailer-1.0.9 Message-Id: <20190522095407.0D0B43A005B@svn01-us-west.apache.org> Author: rpluem Date: Wed May 22 09:54:05 2019 New Revision: 1859713 URL: http://svn.apache.org/viewvc?rev=1859713&view=rev Log: * Fix the logic to follow the comment. So far we only forwarded the header if we have NOT used it AND the env variable was set. But if we have not used it we should forward it in any case independent of the env variable setting. This aligns also with the behaviour in ap_proxy_create_hdrbrgd. Modified: httpd/httpd/trunk/modules/proxy/proxy_util.c Modified: httpd/httpd/trunk/modules/proxy/proxy_util.c URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/modules/proxy/proxy_util.c?rev=1859713&r1=1859712&r2=1859713&view=diff ============================================================================== --- httpd/httpd/trunk/modules/proxy/proxy_util.c (original) +++ httpd/httpd/trunk/modules/proxy/proxy_util.c Wed May 22 09:54:05 2019 @@ -2528,8 +2528,8 @@ ap_proxy_determine_connection(apr_pool_t proxy_auth = apr_table_get(r->headers_in, "Proxy-Authorization"); if (proxy_auth != NULL && proxy_auth[0] != '\0' && - r->user == NULL && /* we haven't yet authenticated */ - apr_table_get(r->subprocess_env, "Proxy-Chain-Auth")) { + (r->user == NULL || /* we haven't yet authenticated */ + apr_table_get(r->subprocess_env, "Proxy-Chain-Auth"))) { forward->proxy_auth = apr_pstrdup(conn->pool, proxy_auth); } }