Skip to content

Instantly share code, notes, and snippets.

@airween
Created January 7, 2020 13:20
Show Gist options
  • Save airween/7afda23a9979e2add46228c8f2f2d316 to your computer and use it in GitHub Desktop.
Save airween/7afda23a9979e2add46228c8f2f2d316 to your computer and use it in GitHub Desktop.
[
{
"enabled":1,
"version_min":300000,
"title":"Testing error log output :: example 1",
"client":{
"ip":"200.249.12.31",
"port":123
},
"server":{
"ip":"200.249.12.31",
"port":80
},
"request":{
"headers":{
"Host":"localhost",
"Accept":"*/*"
},
"uri":"/?foo=bar",
"method":"GET"
},
"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":{
"http_code":200
},
"rules":[
"SecRuleEngine On",
"SecDefaultAction \"phase:2,deny,status:400,log\"",
"SecRule ARGS \"@rx bar\" \"id:1234,phase:2,block,ver:'OWASP-CRS',severity:'CRITICAL',msg:'Test message',accuracy:'9',maturity:'9',logdata:'Test logdata'\""
]
}
]
[
{
"enabled":1,
"version_min":300000,
"title":"Testing error log output :: example 2",
"client":{
"ip":"200.249.12.31",
"port":123
},
"server":{
"ip":"200.249.12.31",
"port":80
},
"request":{
"headers":{
"Host":"localhost",
"Accept":"*/*"
},
"uri":"/?foo=bar",
"method":"GET"
},
"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":{
"http_code":400
},
"rules":[
"SecRuleEngine On",
"SecRule &TX:inbound_anomaly_score_threshold \"@eq 0\" \"id:901100,phase:1,pass,nolog"
]
}
]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment