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

Add Special Regex for http_x_forwarded_for Var #37

Closed
wants to merge 2 commits into from

Conversation

jasonrogena
Copy link

Since there's the possibility for the http_x_forwarded_for Nginx
variable to contain a space (right after the comma separating two IP
addresses), create a regex for handling this variable. Change the way
the Nginx format regex is created by adding logic for including special
regexes.

Fixes #36

Signed-off-by: Jason Rogena jasonrogena@gmail.com

Since there's the possibility for the http_x_forwarded_for Nginx
variable to contain a space (right after the comma separating two IP
addresses), create a regex for handling this variable. Change the way
the Nginx format regex is created by adding logic for including special
regexes.

Fixes satyrius#36

Signed-off-by: Jason Rogena <jasonrogena@gmail.com>
@satyrius
Copy link
Owner

Please, add tests for your solution. And fix those which failed.

@jasonrogena
Copy link
Author

Will do.

Appears that remote_user might have spaces in it (like "mnchw monitor").
Cater for this by adding a special regex for remote_user.

Signed-off-by: Jason Rogena <jasonrogena@gmail.com>
@conradolega
Copy link

Hey @jasonrogena, any update on this?

@satyrius
Copy link
Owner

satyrius commented Sep 5, 2022

Does anyone want to wrap it up? Otherwise I'm closing the PR

@satyrius
Copy link
Owner

Closing in favor of the most recent #45

@satyrius satyrius closed this Sep 12, 2022
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.

Space between IP Addresses in $http_x_forwarded_for
3 participants