Skip to content

Commit 9b9afc2

Browse files
committed
add rules 22200003, 22200004, 22200040
1 parent cd598ff commit 9b9afc2

File tree

1 file changed

+46
-0
lines changed

1 file changed

+46
-0
lines changed

05-HARDENING.conf

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,35 @@ SecRule REQUEST_FILENAME "^/wp\-content(/.*\.txt(|[\/].*)|(|\/))$" "phase:1,id:2
2828
logdata:'Request Filename %{REQUEST_FILENAME}',\
2929
msg:'WordPress: TXT /wp-content access attempt'"
3030

31+
#wp-admin/ sensitive files
32+
SecRule REQUEST_FILENAME "^/wp-admin/(?:install|includes)" "phase:1,id:22200003,\
33+
t:lowercase,t:normalizePath,t:trim,\
34+
block,\
35+
log,\
36+
rev:'1',\
37+
severity:'6',\
38+
maturity:'9',\
39+
accuracy:'9',\
40+
ver:'%{tx.wprs_version}',\
41+
tag:'wordpress',\
42+
tag:'includes',\
43+
logdata:'Request Filename %{REQUEST_FILENAME}',\
44+
msg:'WordPress: File /wp-admin access attempt'"
45+
46+
SecRule REQUEST_FILENAME "^/(?:readme|license)\." "phase:1,id:22200004,\
47+
t:lowercase,t:normalizePath,t:trim,\
48+
block,\
49+
log,\
50+
rev:'1',\
51+
severity:'6',\
52+
maturity:'9',\
53+
accuracy:'9',\
54+
ver:'%{tx.wprs_version}',\
55+
tag:'wordpress',\
56+
tag:'includes',\
57+
logdata:'Request Filename %{REQUEST_FILENAME}',\
58+
msg:'WordPress: Readme or License file access attempt'"
59+
3160

3261
SecRule tx:wprs_allow_xmlrpc "@eq 1" \
3362
"phase:1,\
@@ -120,4 +149,21 @@ SecRule REQUEST_URI "@rx ^/wp\-admin/(load\-styles|load\-scripts)\.php.*load\[\]
120149
logdata:'Detected on script: %{TX:1}.php',\
121150
msg:'WordPress: DoS Attack Attempt'"
122151

152+
SecRule REQUEST_URI "@rx ^/(wp-cron\.php)" "phase:1,id:22200040,\
153+
t:lowercase,t:urlDecode,t:trim,t:normalizePath,t:removeWhitespace,\
154+
block,\
155+
log,\
156+
rev:'1',\
157+
severity:'6',\
158+
maturity:'9',\
159+
accuracy:'9',\
160+
capture,\
161+
ver:'%{tx.wprs_version}',\
162+
tag:'wordpress',\
163+
tag:'dos',\
164+
tag:'cve-2018-6389',\
165+
logdata:'Detected on script: %{TX:1}',\
166+
msg:'WordPress: DoS Attack Attempt'"
167+
168+
123169
SecMarker END_WPRS_DOS

0 commit comments

Comments
 (0)