]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
finish getting new proxy auth working--but still untested
authorwessels <>
Tue, 26 Aug 1997 10:21:17 +0000 (10:21 +0000)
committerwessels <>
Tue, 26 Aug 1997 10:21:17 +0000 (10:21 +0000)
src/acl.cc
src/defines.h
src/http.cc

index 2b9eddc070bb8aa8a764db65b7a507edac1abc83..a6afccad4ab93350dc864cebc8e0a229a7f58d9e 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * $Id: acl.cc,v 1.106 1997/08/25 23:45:22 wessels Exp $
+ * $Id: acl.cc,v 1.107 1997/08/26 04:21:17 wessels Exp $
  *
  * DEBUG: section 28    Access Control
  * AUTHOR: Duane Wessels
@@ -1141,7 +1141,7 @@ aclMatchTime(struct _acl_time_data *data, time_t when)
 int
 aclMatchAcl(struct _acl *acl, aclCheck_t * checklist)
 {
-    const request_t *r = checklist->request;
+    request_t *r = checklist->request;
     const ipcache_addrs *ia = NULL;
     const char *fqdn = NULL;
     int k;
@@ -1228,6 +1228,7 @@ aclMatchAcl(struct _acl *acl, aclCheck_t * checklist)
        } else {
            /* register that we used the proxy authentication header */
            checklist->state[ACL_PROXY_AUTH] = ACL_LOOKUP_DONE;
+           BIT_SET(r->flags, REQ_USED_PROXY_AUTH);
            return 1;
        }
        /* NOTREACHED */
index 6cf05db3f11f60c91741ceabaefb55bbc1106123..83b21d44a9a39b41174d37a6c15c23c19814fc5b 100644 (file)
 #define MAX_URL  4096
 #define MAX_LOGIN_SZ  128
 
-/* bitfields for the flags member */
+/* bitfields for request_t->flags */
 #define REQ_RANGE              0x01
 #define REQ_NOCACHE            0x02
 #define REQ_IMS                        0x04
 #define REQ_PROXY_KEEPALIVE    0x100
 #define REQ_PROXYING           0x200
 #define REQ_REFRESH            0x400
+#define REQ_USED_PROXY_AUTH    0x800
 #define PEER_MAX_ADDRESSES 10
 #define RTT_AV_FACTOR      1000
 
index afe70ac577b49ba2149dd60c5b93dea275fae4f5..9b2185bd022bf67353944ca4463622027a3b8353 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * $Id: http.cc,v 1.186 1997/08/25 23:45:27 wessels Exp $
+ * $Id: http.cc,v 1.187 1997/08/26 04:21:19 wessels Exp $
  *
  * DEBUG: section 11    Hypertext Transfer Protocol (HTTP)
  * AUTHOR: Harvest Derived
@@ -809,7 +809,7 @@ httpBuildRequestHeader(request_t * request,
            continue;
        if (strncasecmp(xbuf, "Proxy-authorization:", 20) == 0)
            /* If we're not going to do proxy auth, then it must be passed on */
-           if (Config.proxyAuth.File)
+           if (BIT_TEST(request->flags, REQ_USED_PROXY_AUTH))
                continue;
        if (strncasecmp(xbuf, "Connection:", 11) == 0)
            continue;