Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(cli): Regex based IP detection #48

Merged

Conversation

open-dynaMIX
Copy link
Member

@open-dynaMIX open-dynaMIX commented Oct 19, 2020

This commit implements regex based IP detection. This is intended to use
for logfiles where column based detection doesn't work.

See RFC (#44) for more information.

Closes #42, closes #44

@open-dynaMIX open-dynaMIX force-pushed the regex_detection branch 3 times, most recently from dd15c09 to f40e228 Compare October 19, 2020 15:02
tests.py Show resolved Hide resolved
anonip.py Show resolved Hide resolved
@open-dynaMIX open-dynaMIX force-pushed the regex_detection branch 2 times, most recently from 71322b6 to a1bec7a Compare November 4, 2020 14:36
@aomader
Copy link

aomader commented Jan 25, 2021

I use this on my server to properly anonymize the error logs of nginx. Works flawlessly.

Note though, that you have to use a slightly different regex pattern (--regex ".*, client: ([^,]+), .*") in order to ONLY match IP.

@open-dynaMIX
Copy link
Member Author

I use this on my server to properly anonymize the error logs of nginx. Works flawlessly.

Thanks a lot @aomader for giving this a try!

@rettichschnidi Have you been able to test this as well?

@open-dynaMIX open-dynaMIX force-pushed the regex_detection branch 2 times, most recently from 3257d20 to 93a2952 Compare December 26, 2021 09:08
This commit implements regex based IP detection. This is intended to use
for logfiles where column based detection doesn't work.

See RFC (DigitaleGesellschaft#44) for more information.

Closes DigitaleGesellschaft#42, closes DigitaleGesellschaft#44
@open-dynaMIX
Copy link
Member Author

I've opened this PR more than a year ago. Due to a lack of internal feedback, I've decided to just merge it ¯\_(ツ)_/¯

@open-dynaMIX open-dynaMIX merged commit 895dacd into DigitaleGesellschaft:main Dec 26, 2021
@open-dynaMIX open-dynaMIX deleted the regex_detection branch December 26, 2021 09:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[RFC] Regex based IP detection nginx error logs not masked
3 participants