Skip to content

Instantly share code, notes, and snippets.

@zimmerle
Created June 28, 2018 19:19
Show Gist options
  • Save zimmerle/2e047fb9f60bce10a5596d1d2995bac4 to your computer and use it in GitHub Desktop.
Save zimmerle/2e047fb9f60bce10a5596d1d2995bac4 to your computer and use it in GitHub Desktop.
[
{
"enabled":1,
"version_min":300000,
"title":"ctl:requestBodyProcessor=URLENCODED",
"client":{
"ip":"200.249.12.31",
"port":123
},
"server":{
"ip":"200.249.12.31",
"port":80
},
"request":{
"headers":{
"Host":"localhost",
"User-Agent":"curl/7.38.0",
"Accept":"*/*",
"Content-Length":"330",
"Content-Type":"application/lhebs",
"Expect":"100-continue"
},
"uri":"/a=urlencoded",
"method":"POST",
"body":[
"param1=value1\r"
]
},
"response":{
"headers":{
"Date":"Mon, 13 Jul 2015 20:02:41 GMT",
"Last-Modified":"Sun, 26 Oct 2014 22:33:37 GMT",
"Content-Type":"text/html"
},
"body":[
"no need."
]
},
"expected":{
"debug_log":"Target value: \\\"value1",
"http_code": 403
},
"rules":[
"SecRuleEngine On",
"SecRequestBodyAccess On",
"SecRule REQUEST_HEADERS:Content-Type \"@contains lhebs\" \"phase:1,id:122,t:none,log,auditlog,pass,ctl:requestBodyProcessor=URLENCODED\"",
"SecRule ARGS_POST \"@contains value1\" \"phase:2,id:123,t:none,deny,log,auditlog\""
]
},
{
"enabled":1,
"version_min":300000,
"title":"ctl:requestBodyProcessor=URLENCODED",
"client":{
"ip":"200.249.12.31",
"port":123
},
"server":{
"ip":"200.249.12.31",
"port":80
},
"request":{
"headers":{
"Host":"localhost",
"User-Agent":"curl/7.38.0",
"Accept":"*/*",
"Content-Length":"330",
"Content-Type":"application/x-www-form-urlencoded",
"Expect":"100-continue"
},
"uri":"/a=urlencoded",
"method":"POST",
"body":[
"param1=value1\r"
]
},
"response":{
"headers":{
"Date":"Mon, 13 Jul 2015 20:02:41 GMT",
"Last-Modified":"Sun, 26 Oct 2014 22:33:37 GMT",
"Content-Type":"text/html"
},
"body":[
"no need."
]
},
"expected":{
"debug_log":"Target value: \\\"value1",
"http_code": 403
},
"rules":[
"SecRuleEngine On",
"SecRequestBodyAccess On",
"SecRule ARGS_POST \"@contains value1\" \"phase:2,id:123,t:none,deny,log,auditlog\""
]
}
]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment