Skip to content

Feature: Configurable Log Level #205

@jeremyjpj0916

Description

@jeremyjpj0916

Would like this to be a environment variable we can set:

https://github.com/SpiderLabs/ModSecurity-nginx/blob/master/src/ngx_http_modsecurity_log.c#L33

ngx_log_error(NGX_LOG_INFO, (ngx_log_t *)log, 0, "%s", msg);

NGX_LOG_INFO is nice and appropriate likely for warning messages generally speaking. But info in many NGX deployments is too noisy regarding other things, so it would be nice if this was default to INFO but I could pick ERROR or DEBUG or NOTICE etc. Right now I drop in a patch file and run this line as:

ngx_log_error(NGX_LOG_ERROR, (ngx_log_t *)log, 0, "%s", msg);

Because that is the log level I want WAF detection information to run on for my use case.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions