apache - Updating an arugement of a ModSecurity Core Rule -


i have big form needs send 1000 post data arguments @ most. triggers false alarm rule 960335 of owasp core rulset. looked rule in modsecurity_crs_23_request_limits.conf can't figure out how set max_num_args higher on specific form.

in modsecurity_crs_60_customrules.conf, have tried:

<locationmatch "/form.php">     secruleupdatetargetbyid 960335 args:"@gt %1000"  </locationmatch> 

but syntax check gave me error

`updating target id no ruleset in context` 

can tell me how set max_num_args higher?

here's rule 960335:

secrule &tx:max_num_args "@eq 1" "chain,phase:2,t:none,block, msg:'too many arguments in request',id:'960335', severity:'4',rev:'2',ver:'owasp_crs/2.2.9',maturity:'9', accuracy:'9',tag:'owasp_crs/policy/size_limit'"  secrule &args "@gt %{tx.max_num_args}" "t:none,setvar:'tx.msg=%{rule.msg}', setvar:tx.anomaly_score=+%{tx.notice_anomaly_score}, setvar:tx.%{rule.id}-owasp_crs/policy/size_limit-%{matched_var_name}=%{matched_var}" 

this set in modsecurity_crs_10_setup.conf file:

# -- maximum number of arguments in request limited secaction \   "id:'900006', \   phase:1, \   t:none, \   setvar:tx.max_num_args=255, \   nolog, \   pass" 

Comments

Popular posts from this blog

php - Admin SDK -- get information about the group -

dns - How To Use Custom Nameserver On Free Cloudflare? -

Python Error - TypeError: input expected at most 1 arguments, got 3 -