@@ -100,8 +100,8 @@ Check if an array ($_POST['usernames'][]) contains any values from given array.
100100 "match" :{
101101 "type" :" array_in_array" ,
102102 "value" :[
103- " test" ,
104- " admin"
103+ " test" ,
104+ " admin"
105105 ]
106106 }
107107 }
@@ -116,7 +116,7 @@ Check if a value ($_GET['user']) is not in an array
116116 "match" :{
117117 "type" :" not_in_array" ,
118118 "value" :[
119- " admin"
119+ " admin"
120120 ]
121121 }
122122 }
@@ -203,8 +203,8 @@ Check if $_POST['payload'] contains a base64(json()) encoded payload with user_r
203203 "type" :" array_key_value" ,
204204 "key" :" user_role" ,
205205 "match" :{
206- "type" :" equals" ,
207- "value" :" administrator"
206+ "type" :" equals" ,
207+ "value" :" administrator"
208208 }
209209 }
210210 }
@@ -218,24 +218,24 @@ Check if $_GET['action'] or $_POST['action'] contains a value part of an array o
218218 "parameter" :" rules" ,
219219 "rules" :[
220220 {
221- "parameter" :" get.action" ,
222- "match" :{
223- "type" :" in_array" ,
224- "value" :[
225- " restaurant_system_customize_button" ,
226- " restaurant_system_insert_dialog"
227- ]
228- }
221+ "parameter" :" get.action" ,
222+ "match" :{
223+ "type" :" in_array" ,
224+ "value" :[
225+ " restaurant_system_customize_button" ,
226+ " restaurant_system_insert_dialog"
227+ ]
228+ }
229229 },
230230 {
231- "parameter" :" post.action" ,
232- "match" :{
233- "type" :" in_array" ,
234- "value" :[
235- " restaurant_system_customize_button" ,
236- " restaurant_system_insert_dialog"
237- ]
238- }
231+ "parameter" :" post.action" ,
232+ "match" :{
233+ "type" :" in_array" ,
234+ "value" :[
235+ " restaurant_system_customize_button" ,
236+ " restaurant_system_insert_dialog"
237+ ]
238+ }
239239 }
240240 ],
241241 "inclusive" :true
@@ -260,7 +260,7 @@ Note that the server.ip parameter is a special computed property and retrieves t
260260 "match" :{
261261 "type" :" in_array" ,
262262 "value" :[
263- " 127.0.0.1"
263+ " 127.0.0.1"
264264 ]
265265 }
266266 }
@@ -291,10 +291,33 @@ Check if an uploaded file ($_FILES['img']) contains the PHP opening tag in the c
291291 "match" :{
292292 "type" :" file_contains" ,
293293 "match" :{
294- "type" :" contains" ,
295- "value" :" <?php"
294+ "type" :" contains" ,
295+ "value" :" <?php"
296296 }
297297 }
298298 }
299299]
300+ ```
301+
302+ Check if the swp_debug parameter is set to load_options and the current user is not an administrator.
303+ https://patchstack.com/database/vulnerability/social-warfare/wordpress-social-warfare-plugin-3-5-2-unauthenticated-remote-code-execution-rce-vulnerability
304+ ``` json
305+ [
306+ {
307+ "parameter" :" get.swp_debug" ,
308+ "match" :{
309+ "type" :" equals" ,
310+ "value" :" load_options"
311+ },
312+ "inclusive" :true
313+ },
314+ {
315+ "parameter" :false ,
316+ "match" :{
317+ "type" :" current_user_cannot" ,
318+ "value" :" administrator"
319+ },
320+ "inclusive" :true
321+ }
322+ ]
300323```
0 commit comments