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

hostip: make 'localhost' return fixed values #7039

Closed
wants to merge 2 commits into from
Closed

Conversation

@bagder
Copy link
Member

@bagder bagder commented May 10, 2021

Resolving the case insensitive host name 'localhost' now returns the
addresses 127.0.0.1 and (if IPv6 is enabled) ::1 without using any
resolver.

This removes the risk that users accidentally resolves 'localhost' to
something else. By making sure 'localhost' is always local, we can
assume a "secure context" for such transfers (for cookies etc).

@bagder
Copy link
Member Author

@bagder bagder commented May 12, 2021

Tagged for merge after 7.77.0 ships.

bagder added 2 commits May 31, 2021
Resolving the case insensitive host name 'localhost' now returns the
addresses 127.0.0.1 and (if IPv6 is enabled) ::1 without using any
resolver.

This removes the risk that users accidentally resolves 'localhost' to
something else. By making sure 'localhost' is always local, we can
assume a "secure context" for such transfers (for cookies etc).
@bagder bagder force-pushed the bagder/fixed-localhost branch from 2662b69 to c7997d6 May 31, 2021
@bagder bagder closed this in 1a0ebf6 May 31, 2021
@bagder bagder deleted the bagder/fixed-localhost branch May 31, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

1 participant