]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
Supply ALE for note ACL (#463)
authorEduard Bagdasaryan <eduard.bagdasaryan@measurement-factory.com>
Thu, 5 Sep 2019 05:46:59 +0000 (05:46 +0000)
committerSquid Anubis <squid-anubis@squid-cache.org>
Fri, 6 Sep 2019 06:43:03 +0000 (06:43 +0000)
The following cache.log WARNING is a symptom of this bug:

    ACL is used in context without an ALE state. Assuming mismatch.

Commit cb36505 already covered many (but not all) similar cases.

src/cf.data.pre
src/client_side.cc

index 5abbf7e2fbf34f624bb5eb136bd4747cb3b3639f..56bcac5bd50da90acdf564135463981252228f68 100644 (file)
@@ -6777,6 +6777,9 @@ DOC_START
 
            note key value acl ...
            logformat myFormat ... %{key}note ...
+
+       This clause only supports fast acl types.
+       See http://wiki.squid-cache.org/SquidFaq/SquidAcl for details.
 DOC_END
 
 NAME: relaxed_header_parser
index f47c25d6752592d1c743f7fcb225fabc08c5c552..f053ede238312e52cabc0dab2fda76933bb32d26 100644 (file)
@@ -427,7 +427,7 @@ ClientHttpRequest::logRequest()
     if (request) {
         SBuf matched;
         for (auto h: Config.notes) {
-            if (h->match(request, al->reply, NULL, matched)) {
+            if (h->match(request, al->reply, al, matched)) {
                 request->notes()->add(h->key(), matched);
                 debugs(33, 3, h->key() << " " << matched);
             }