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

Change ActionDispatch::RemoteIp to not use HTTP_X_FORWARDED_FOR when REMOTE_ADDR is not a trusted proxy #51610

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Commits on Apr 19, 2024

  1. Change ActionDispatch::RemoteIp to not use HTTP_X_FORWARDED_FOR w…

    …hen `REMOTE_ADDR` is not a trusted proxy
    
    As pointed out in the documentation, using `RemoteIp` while accessible without a reverse proxy opens you to IP
    spoofing. Returning `REMOTE_ADDR` when that is not considered a trusted proxy should make that less likely.
    ClearlyClaire committed Apr 19, 2024
    Configuration menu
    Copy the full SHA
    30e14eb View commit details
    Browse the repository at this point in the history