charon-cmd: Use %any as local address so IPv4 is not preferred
When resolving the remote host, we first determine if a particular address family is preferred locally. With `0.0.0.0` that's IPv4, with `%any` that's not the case. So we use the latter to allow resolvers to return an IPv6 address.
This commit is contained in:
@@ -150,7 +150,7 @@ static peer_cfg_t* create_peer_cfg(private_cmd_connection_t *this)
|
|||||||
peer_cfg_t *peer_cfg;
|
peer_cfg_t *peer_cfg;
|
||||||
proposal_t *proposal;
|
proposal_t *proposal;
|
||||||
ike_cfg_create_t ike = {
|
ike_cfg_create_t ike = {
|
||||||
.local = "0.0.0.0",
|
.local = "%any",
|
||||||
.remote = this->host,
|
.remote = this->host,
|
||||||
.remote_port = IKEV2_UDP_PORT,
|
.remote_port = IKEV2_UDP_PORT,
|
||||||
.fragmentation = FRAGMENTATION_YES,
|
.fragmentation = FRAGMENTATION_YES,
|
||||||
|
|||||||
Reference in New Issue
Block a user