]> git.ipfire.org Git - thirdparty/haproxy.git/commit
[MEDIUM] acl: when possible, report the name and requirements of ACLs in warnings
authorWilly Tarreau <w@1wt.eu>
Sun, 27 Jul 2008 20:02:32 +0000 (22:02 +0200)
committerWilly Tarreau <w@1wt.eu>
Sun, 3 Aug 2008 07:41:05 +0000 (09:41 +0200)
commitdd64f8d394330f04ccdf6081586c84feb5ff27ff
tree56ad5fb6e3dae4d4652d8b8371923e642cfed478
parent0ceba5af74e61b0da468c88b57e2410ae8a72026
[MEDIUM] acl: when possible, report the name and requirements of ACLs in warnings

When an ACL is referenced at a wrong place (eg: response during request, layer7
during layer4), try to indicate precisely the name and requirements of this ACL.

Only the first faulty ACL is returned. A small change consisting in iterating
that way may improve reports :
   cap = ACL_USE_any_unexpected
   while ((acl=cond_find_require(cond, cap))) {
     warning()
     cap &= ~acl->requires;
   }

This will report the first ACL of each unsupported type. But doing so will
mangle the error reporting a lot, so we need to rework error reports first.
include/proto/acl.h
src/acl.c
src/cfgparse.c
src/proto_tcp.c