crowdsec appsec - access User-Agent header within hooks
Hello!
We use hooks to evaluate requests and add exceptions, currently the documentation is rather slim on this area. Is the any way to access "User-Agent" header for evaluation?
Example how we use it to check a request uri (appsec config)
3 Replies
Important Information
This post has been marked as resolved. If this is a mistake please press the red button below or type
/unresolve
© Created By WhyAydan for CrowdSec ❤️
I was able to dig it out from the source code, if anyone else is interested this is a working solution.
- filter: IsInBand == true && req.Header.Get("User-Agent") == "test"
Resolving crowdsec appsec - access User-Agent header within hooks
This has now been resolved. If you think this is a mistake please run
/unresolve