Fail2Ban.WebExploits icon indicating copy to clipboard operation
Fail2Ban.WebExploits copied to clipboard

Custom Log Format

Open crebuh opened this issue 6 years ago • 1 comments

Hi,

how can I adjust the regex to match our custom log file format from nginx?

This is our logfile format (because we have multiple sites running on one instance):

log_format custom_format '$server_name $remote_addr - $remote_user [$time_local] ' '"$request" $status $body_bytes_sent ' '"$http_referer" "$http_user_agent" "$gzip_ratio"'

Thx!

crebuh avatar Aug 23 '18 14:08 crebuh

Hi @crebuh can you try this log format log_format custom_format '$server_name $remote_addr - $remote_user $host [$time_local] ' '"$request" $status $body_bytes_sent ' '"$http_referer" "$http_user_agent" "$gzip_ratio"'

mitchellkrogza avatar Aug 30 '18 11:08 mitchellkrogza