From: hno <> Date: Mon, 19 Nov 2007 05:00:58 +0000 (+0000) Subject: Change priority of proxy auth and extacl provided username in login=*:pass X-Git-Tag: SQUID_3_0_STABLE1~30 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a8bc2b9ca25e92228ef1153160a90fc2818fd943;p=thirdparty%2Fsquid.git Change priority of proxy auth and extacl provided username in login=*:pass It's quite useful to be able to manipulate the forwarded username when using login=*:pass together with authentication. --- diff --git a/src/http.cc b/src/http.cc index 3f3cc40797..41913774a4 100644 --- a/src/http.cc +++ b/src/http.cc @@ -1,6 +1,6 @@ /* - * $Id: http.cc,v 1.540 2007/11/15 23:33:05 wessels Exp $ + * $Id: http.cc,v 1.541 2007/11/18 22:00:58 hno Exp $ * * DEBUG: section 11 Hypertext Transfer Protocol (HTTP) * AUTHOR: Harvest Derived @@ -1394,10 +1394,10 @@ HttpStateData::httpBuildRequestHeader(HttpRequest * request, char loginbuf[256]; const char *username = "-"; - if (orig_request->auth_user_request) - username = orig_request->auth_user_request->username(); - else if (orig_request->extacl_user.size()) + if (orig_request->extacl_user.size()) username = orig_request->extacl_user.buf(); + else if (orig_request->auth_user_request) + username = orig_request->auth_user_request->username(); snprintf(loginbuf, sizeof(loginbuf), "%s%s", username, orig_request->peer_login + 1);