-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* build image: use coraza.cfg as updated in 8f29491 * coraza.cfg: haproxy configs must end with a LF A missing LF on the end of config files is a hard error starting with haproxy 2.3
- Loading branch information
Showing
2 changed files
with
14 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,26 @@ | ||
# https://github.com/haproxy/haproxy/blob/master/doc/SPOE.txt | ||
# /etc/haproxy/coraza.cfg | ||
[coraza] | ||
spoe-agent coraza-agent | ||
messages coraza-req coraza-res | ||
# Process HTTP requests only (the responses are not evaluated) | ||
messages coraza-req | ||
# Comment the previous line and add coraza-res, to process responses also. | ||
# NOTE: there are still some memory & caching issues, so use this with care | ||
#messages coraza-req coraza-res | ||
option var-prefix coraza | ||
option set-on-error error | ||
timeout hello 100ms | ||
timeout hello 2s | ||
timeout idle 2m | ||
timeout processing 500ms | ||
use-backend coraza-spoa | ||
log global | ||
|
||
spoe-message coraza-req | ||
args app=fe_name id=unique-id src-ip=src src-port=src_port dst-ip=dst dst-port=dst_port method=method path=path query=query version=req.ver headers=req.hdrs body=req.body | ||
args app=str(sample_app) id=unique-id src-ip=src src-port=src_port dst-ip=dst dst-port=dst_port method=method path=path query=query version=req.ver headers=req.hdrs body=req.body | ||
event on-frontend-http-request | ||
|
||
spoe-message coraza-res | ||
args app=fe_name id=unique-id version=res.ver status=status headers=res.hdrs body=res.body | ||
args app=str(sample_app) id=unique-id version=res.ver status=status headers=res.hdrs body=res.body | ||
event on-http-response | ||
|
||
|