]> git.ipfire.org Git - thirdparty/haproxy.git/commit
MEDIUM: acl: use the fetch syntax 'fetch(args),conv(),conv()' into the ACL keyword
authorThierry FOURNIER <tfournier@exceliance.fr>
Thu, 21 Nov 2013 09:50:10 +0000 (10:50 +0100)
committerWilly Tarreau <w@1wt.eu>
Mon, 2 Dec 2013 22:31:32 +0000 (23:31 +0100)
commit348971ea2811c0c18250b767aa91b5b5ac81e3e2
treec608d5bb0ba6ffeafc4725346332af237a1f7cc9
parent8af6ff12b53b618d6549e268c0ccf85c85e7558e
MEDIUM: acl: use the fetch syntax 'fetch(args),conv(),conv()' into the ACL keyword

If the acl keyword is a "fetch", the dedicated parsing function
"sample_parse_expr()" is used. Otherwise, the acl parsing function
"parse_acl_expr()" is extended to understand the syntax of a series
of converters placed after the "fetch" keyword.

Before this patch, each acl uses a "struct sample_fetch" and executes
it with the "<fetch>->process()" function. Now, the dedicated function
"sample_process()" is called.

These syntax are now avalaible:

   acl bad req.hdr(host),lower -m str www
   http-request redirect prefix /go-away if bad

   acl bad hdr_beg(host),lower www
   http-request redirect prefix /go-away if bad
include/proto/sample.h
include/types/acl.h
src/acl.c
src/sample.c