Add Nginx Log to IPBan #147
Answered
by
fahmiegerton
fahmiegerton
asked this question in
Q&A
|
Hello , How can I add nginx log to IPBan?. Here's the log. I tried with this regex https://regex101.com/r/eZgTH3/1 but didn't work. It give me an error How can I fix this? I don't understand anything about regex, but I tried it with regex101 the rule is work, but not with IPBan. Thanks! |
Answered by
fahmiegerton
Apr 30, 2021
Replies: 3 comments
|
Nevermind, this is the correct regex I just remove the |
0 replies
Answer selected by
fahmiegerton
|
Hello, I'm trying to configure ipban for nginx file from recipes for windows. but the suggested regular expression does not pass the test into regex101 (pattern error)
|
0 replies
|
Change to Java regex or if you use .net you are forced to use double quotes.
…-- Jeff
On Thu, Oct 10, 2024 at 6:46 AM rozhkovets ***@***.***> wrote:
Hello, I'm trying to configure ipban for nginx file from recipes for
windows. but the suggested regular expression does not pass the test into
regex101 (pattern error)
^(?<timestamp>[^\[]+)\[.*\s(?:(?<log>system\scannot\sfind).*|user\s"(?<username>[^"]+)"\swas\s(?<log>not\sfound).*)\sclient:\s(?<ipaddress>[^\s,]+)[^\n]*$
(?<log> A subpattern name must be unique) A subpattern name must be unique
—
Reply to this email directly, view it on GitHub
<#147 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAJWQGAW5PIPFOVQ3DFN753Z2ZLG7AVCNFSM6AAAAABPWPR2TKVHI2DSMVQWIX3LMV43URDJONRXK43TNFXW4Q3PNVWWK3TUHMYTAOJQGI4DEMA>
.
You are receiving this because you are subscribed to this thread.Message
ID: ***@***.***>
|
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Nevermind, this is the correct regex
I just remove the
Pon?p<name>