ModSecurity:MediaWiki Rules: Difference between revisions
No edit summary |
No edit summary |
||
| Line 13: | Line 13: | ||
*Pada log error terdapat ID rules yang memblokir yaitu ID 959100 | *Pada log error terdapat ID rules yang memblokir yaitu ID 959100 | ||
*Ganti baris pada baris deny ke allow | *Ganti baris pada baris deny ke allow | ||
<syntaxhighlight lang="nginx"> | |||
SecRule TX:OUTBOUND_ANOMALY_SCORE "@ge %{tx.outbound_anomaly_score_threshold}" \ | |||
"id:959100,\ | |||
phase:4,\ | |||
allow,\ | |||
t:none,\ | |||
msg:'Outbound Anomaly Score Exceeded (Total Score: %{TX.OUTBOUND_ANOMALY_SCORE})',\ | |||
tag:'anomaly-evaluation',\ | |||
ver:'OWASP_CRS/3.4.0-dev',\ | |||
setvar:'tx.anomaly_score=+%{tx.outbound_anomaly_score}'" | |||
</syntaxhighlight> | |||
*Setelah itu buka file selanjutnya di <code>REQUEST-949-BLOCKING-EVALUATION.conf</code>, dengan cara yang sama | *Setelah itu buka file selanjutnya di <code>REQUEST-949-BLOCKING-EVALUATION.conf</code>, dengan cara yang sama | ||
<syntaxhighlight lang="shell"> | |||
vim REQUEST-949-BLOCKING-EVALUATION.conf | |||
</syntaxhighlight><syntaxhighlight lang="nginx"> | |||
SecRule TX:ANOMALY_SCORE "@ge %{tx.inbound_anomaly_score_threshold}" \ | |||
"id:949110,\ | |||
phase:2,\ | |||
allow,\ | |||
t:none,\ | |||
msg:'Inbound Anomaly Score Exceeded (Total Score: %{TX.ANOMALY_SCORE})',\ | |||
tag:'application-multi',\ | |||
tag:'language-multi',\ | |||
tag:'platform-multi',\ | |||
tag:'attack-generic',\ | |||
ver:'OWASP_CRS/3.4.0-dev',\ | |||
severity:'CRITICAL',\ | |||
setvar:'tx.inbound_anomaly_score=%{tx.anomaly_score}'" | |||
</syntaxhighlight> | |||
*Setelah dirubah cek kembali server nginx dan restart | *Setelah dirubah cek kembali server nginx dan restart | ||
<syntaxhighlight lang="shell"> | |||
sudo nginx -t | |||
</syntaxhighlight><syntaxhighlight lang="shell"> | |||
systemctl restart nginx | |||
</syntaxhighlight> | |||
[[Category:Security]] | [[Category:Security]] | ||
[[Category:Server]] | [[Category:Server]] | ||
[[Category:ModSecurity]] | [[Category:ModSecurity]] | ||