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

Log client_ip with real ip value #209

Closed
sk1m opened this issue Sep 8, 2022 · 2 comments · Fixed by #210
Closed

Log client_ip with real ip value #209

sk1m opened this issue Sep 8, 2022 · 2 comments · Fixed by #210
Labels
enhancement New feature or request
Projects
Milestone

Comments

@sk1m
Copy link

sk1m commented Sep 8, 2022

Log client_ip with real ip value

Summary

Set field value "client_ip" to real ip when logging.

Why?

Currently, field client_ip has value of RemoteAddr, which can be unuseful if gatekeeper placed behind another proxy.

How

Use utils.RealIP result for "client_ip" field value.

Acceptance criteria

Additional Information

sk1m pushed a commit to sk1m/gatekeeper that referenced this issue Sep 8, 2022
sk1m pushed a commit to sk1m/gatekeeper that referenced this issue Sep 8, 2022
sk1m pushed a commit to sk1m/gatekeeper that referenced this issue Sep 8, 2022
@p53
Copy link

p53 commented Sep 9, 2022

@sk1m understand why it is useful but what if you want to e.g. log both

@p53 p53 added the enhancement New feature or request label Sep 9, 2022
@p53 p53 added this to To do in Gatekeeper via automation Sep 9, 2022
@p53 p53 added this to the 1.7.0 milestone Sep 9, 2022
sk1m pushed a commit to sk1m/gatekeeper that referenced this issue Sep 9, 2022
@sk1m
Copy link
Author

sk1m commented Sep 9, 2022

@p53 agree, much better will be write both

sk1m pushed a commit to sk1m/gatekeeper that referenced this issue Sep 9, 2022
sk1m pushed a commit to sk1m/gatekeeper that referenced this issue Sep 9, 2022
@p53 p53 linked a pull request Sep 9, 2022 that will close this issue
2 tasks
@p53 p53 closed this as completed Sep 9, 2022
Gatekeeper automation moved this from To do to Done Sep 9, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
Development

Successfully merging a pull request may close this issue.

2 participants