43 lines
1.4 KiB
Diff
43 lines
1.4 KiB
Diff
From 98510efd0e2930d8924b47009945a0fb1bd75a29 Mon Sep 17 00:00:00 2001
|
|
From: Alexander Scheel <ascheel@redhat.com>
|
|
Date: Mon, 22 Apr 2019 14:38:19 -0400
|
|
Subject: [PATCH] Allow listen.ipaddr to reference an IPv6-only host
|
|
|
|
In 5452b13cefa3b30f1da467ff5d68b3c1aa471188, these lines were added
|
|
which effectively result in a listen.ipaddr only allowing hostnames to
|
|
resolve to IPv4 addresses. With a hostname with only a IPv6 address,
|
|
it'll bail with the error message:
|
|
|
|
radiusd: #### Opening IP addresses and Ports ####
|
|
listen {
|
|
type = "auth"
|
|
Failed resolving "ipv6.cipherboy.com" to IPv4 address:
|
|
Name or service not known
|
|
|
|
This directly contradicts the language in the default configuration
|
|
file, so support resolving both IPv4-only and IPv6-only hostnames.
|
|
|
|
Signed-off-by: Alexander Scheel <ascheel@redhat.com>
|
|
---
|
|
src/lib/misc.c | 7 -------
|
|
1 file changed, 7 deletions(-)
|
|
|
|
diff --git a/src/lib/misc.c b/src/lib/misc.c
|
|
index dff21e33f7..5520d8a0a4 100644
|
|
--- a/src/lib/misc.c
|
|
+++ b/src/lib/misc.c
|
|
@@ -607,13 +607,6 @@ int fr_pton(fr_ipaddr_t *out, char const *value, ssize_t inlen, int af, bool res
|
|
fr_strerror_printf("Invalid address");
|
|
return -1;
|
|
}
|
|
-
|
|
- /*
|
|
- * Fall through to resolving the address, using
|
|
- * whatever address family they prefer. If they
|
|
- * don't specify an address family, force IPv4.
|
|
- */
|
|
- if (af == AF_UNSPEC) af = AF_INET;
|
|
}
|
|
|
|
/*
|