crowdsec icon indicating copy to clipboard operation
crowdsec copied to clipboard

Where I can find HTTPD_ERRORLOG pattern?

Open AdzerKI opened this issue 4 years ago • 4 comments

What would you like to be added?

Hi.

Where I can find pattern HTTPD_ERRORLOG in my linux files in dir /etc/crowdsec/patterns/ its absent

Why is this needed?

I have a bug with detect correct client IP in PHP error, want to try change pattern

AdzerKI avatar Aug 16 '22 15:08 AdzerKI

All default patterns are documented on the docs here: https://doc.crowdsec.net/docs/next/parsers/patterns

LaurenceJJones avatar Aug 16 '22 15:08 LaurenceJJones

Hello,

It's defined in https://github.com/crowdsecurity/grokky/blob/master/base.go#L150

You can overload existing expressions directly in your parsers if needed !

buixor avatar Aug 16 '22 15:08 buixor

but where is httpd? all other from logstash i see

AdzerKI avatar Aug 16 '22 15:08 AdzerKI

We dont use a default pattern for that, the parser uses these ones here: https://hub.crowdsec.net/author/crowdsecurity/configurations/apache2-logs

More specifically this one

(%{IPORHOST:target_fqdn} )?%{COMMONAPACHELOG}( "%{NOTDQUOTE:referrer}" "%{NOTDQUOTE:http_user_agent}")?

LaurenceJJones avatar Aug 16 '22 15:08 LaurenceJJones