在mod_security中,发布& &quot“ Multipart/form-data”不起作用
我想否认Post& mod_security(modSecurity)中的request_body字符串条件。 但是它在“ Multipart/form-data”中失败。请帮助我...
详细信息
-
post& “ x-www-form-urlenCoded”不是问题。(拒绝)
- “ x-www-form-urlenceded ”
-
示例规则。
SecRule REQUEST_BODY "server" "id:1234,phase:2,t:none,deny"
> The above sample excludes POST conditions.
- debug log(“多部分/form-data”)
??????? Multipart: Added part header "Content-Disposition" "form-data; name=\"server\""
~~~
??????? Adding request argument (BODY): name "server", value "sample"
~~~
Starting phase REQUEST_BODY.
~~~
??????? SecRule REQUEST_BODY "@rx server" "id:1234,phase:2,t:none,deny"
??????? Rule returned 0. ---- Not found.
-
mod_security版本:版本2系列。
-
我尝试了其他许多测试。但是我不知道。
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
即使这是一个Modsecurity问题,而不是OWASP CRS问题,我也尝试回答并作为CRS Dev-on Duty:众所周知,在ModSecurity中
请参阅此处:
因此,您的解决方案
args
而不是request> request_body
是一个很好的解决方案。Even if this is a ModSecurity question and not an OWASP CRS question, I try to answer and help as CRS dev-on-duty: It is known that in ModSecurity the
REQUEST_BODY
variableSee here: https://github.com/SpiderLabs/ModSecurity/wiki/Reference-Manual-%28v2.x%29#request_body
So your solution to test for
ARGS
instead ofREQUEST_BODY
is a good solution.