wg: make [$HOST]:$PORT notation for an endpoint imply AF_INET6.#31
Open
klihub wants to merge 1 commit intoWireGuard:masterfrom
Open
wg: make [$HOST]:$PORT notation for an endpoint imply AF_INET6.#31klihub wants to merge 1 commit intoWireGuard:masterfrom
klihub wants to merge 1 commit intoWireGuard:masterfrom
Conversation
Signed-off-by: Krisztian Litkey <krisztian.litkey@intel.com>
Member
|
Will this have weird interactions with [hostname] resolving to ipv6 when the [] notion is actually meant for IP addresses only? |
Author
@zx2c4 Sorry, for not stating the intent of the PR clearly in the original description. So that is exactly my intent with this PR. To allow forcing hostname to be resolved to an IPv6 address if the used endpoint notation is The syntax is already allowed/there, it just does not have any effect when a hostname is used. And I haven't found an existing way in the current implementation to force wg to pick and IPv6 address in the case of an IPv4/IPv6 multihomed host. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
parse_endpoint()for wg lets users specify an endpoint using a[$HOSTNAME]:$PORTnotation. However, it has no effect on the address family chosen for hostname resolution. Updateparse_endpointto pass anAF_INET6hint togetaddrinfowhen such a notation is used which allows users to force selecting an IPv6 address.