Quantcast
Channel: HAProxy community - Latest topics
Viewing all articles
Browse latest Browse all 4849

ACL Regex problem

$
0
0

Hi,

I’m having trouble with recording a URL in a stick-table.
So, I’ve got an ACL with a regex and I want to trap any incoming request that would match regex in a stick-table

This is an extract of my HA Proxy file configuration.
acl rejetseancesV4 url_reg ^/depot/api/lra/wp/v1/seances/S_3[0-9]{10,40}?type=meta$
stick-table type string len 128 size 1m expire 10m store http_req_cnt
tcp-request content track-sc2 path if rejetseancesV4

And then, I’ve got this entry in HA Proxy log.
haproxy.log:10.97.3.50 “0A610332:F46E_0A2148F0:139C_672A363E_01C2:2A6F” - - [05/Nov/2024:16:14:06.587] "GET /depot/api/lra/wp/v1/seances/S_31300120234892?type=meta

I was expecting this request to be recorded in the stick table, but there’s nothing.
The regex match the request but nothing is recorded.
First I was using the path_reg keyword an then after reading the ticket here Acl regex problem with "?" in URL, I understood that I should use the keyword url_reg instead of path_reg (because of the question mark in the URL)

But it doesn’t solve the problem, the request is not recorded in the stick table.
Any idea what’s wrong ?

Regards,

Phil

3 posts - 2 participants

Read full topic


Viewing all articles
Browse latest Browse all 4849

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>