bneradt commented on issue #6405:
URL: https://github.com/apache/trafficserver/issues/6405#issuecomment-898515718


   Thank you for filing this issue. I've reproduced this locally with the 
following tweak to the log-filter test:
   
   ```
   diff --git a/tests/gold_tests/logging/log-filter.test.py 
b/tests/gold_tests/logging/log-filter.test.py
   index ee1f6b33a..38b226ad0 100644
   --- a/tests/gold_tests/logging/log-filter.test.py
   +++ b/tests/gold_tests/logging/log-filter.test.py
   @@ -28,6 +28,9 @@ server = Test.MakeVerifierServerProcess("server", 
replay_file)
    nameserver = Test.MakeDNServer("dns", default='127.0.0.1')
    
    ts.Disk.records_config.update({
   +    'proxy.config.diags.debug.enabled': 1,
   +    'proxy.config.diags.debug.tags': 'log',
   +
        'proxy.config.net.connections_throttle': 100,
        'proxy.config.dns.nameservers': 
f"127.0.0.1:{nameserver.Variables.Port}",
        'proxy.config.dns.resolv_conf': 'NULL'
   @@ -41,6 +44,9 @@ ts.Disk.logging_yaml.AddLines(
        '''
    logging:
      filters:
   +    - name: only_localhost
   +      action: accept
   +      condition: chi MATCH 127.0.0.1
        - name: queryparamescaper_cquuc
          action: WIPE_FIELD_VALUE
          condition: cquuc CASE_INSENSITIVE_CONTAIN 
password,secret,access_token,session_redirect,cardNumber,code,query,search-query,prefix,keywords,email,handle
   @@ -52,6 +58,7 @@ logging:
          format: custom
          filters:
          - queryparamescaper_cquuc
   +      - only_localhost
    '''.split("\n")
    )
   ```
   
   Note that this simply adds the `only_localhost` filter which has the 
`condition: chi MATCH 127.0.0.1` condition as described by @jvgutierrez. The 
test's behavior should not change since the test client runs on 127.0.0.1, yet, 
with this condition, the log file is not written.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to