Score:0

Tx-Variable does not increment in modSecure

ca flag

I use Apache2.4 and mod_security 2.

SecRuleEngine On
SecRule REQUEST_METHOD "@streq put" "id:12345,phase:1,pass,log,t:lowercase,chain,logdata:'TX:PUT_COUNT=%{tx.put_count}'"
SecRule REQUEST_URI "@contains /session/" "t:lowercase,log,setvar:tx.put_count=+1"

So according to the docs, "setvar:tx.put_count=+1" should increase tx.put_count by one each request matching those criteria. But regardless how many i fire it stays at 1 as the log prove: [data "TX:PUT_COUNT=1"].

What am I doing wrong? My setup look very similar to the example in the docs.

I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.