summaryrefslogtreecommitdiffstats
path: root/util/net_help.c
diff options
context:
space:
mode:
authordes <des@FreeBSD.org>2015-01-05 14:55:52 +0000
committerdes <des@FreeBSD.org>2015-01-05 14:55:52 +0000
commitbb89a5dd46465ec3bcf4ab8f158c959b3bb7a75c (patch)
tree3b39302660451fc317bd1ffae0cd574e24c2dbdb /util/net_help.c
parent66adf32aa226b0a370ce7df84ac814cbc72ae63b (diff)
downloadFreeBSD-src-bb89a5dd46465ec3bcf4ab8f158c959b3bb7a75c.zip
FreeBSD-src-bb89a5dd46465ec3bcf4ab8f158c959b3bb7a75c.tar.gz
Add support for using a local socket for the remote control connection
by specifying uts path instead of (or in addition to) an IP address as an argument to the control-interface configuration variable. Add support for unencrypted and unauthenticated control connections through a new configuration variable, control-use-cert. To avoid the complexity of supporting both SSL socket and plain socket descriptors in the same code, we just use an unencrypted SSL context and forego authentication. The downside is that we still have to perform DH kex when establishing the connection. This patch was derived (with significant modifications) from the contrib/unbound_unixsock.diff patch originally submitted by Ilya Bakulin of Genua mbH.
Diffstat (limited to 'util/net_help.c')
-rw-r--r--util/net_help.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/util/net_help.c b/util/net_help.c
index 8c2bac7..335ee74 100644
--- a/util/net_help.c
+++ b/util/net_help.c
@@ -156,7 +156,7 @@ log_addr(enum verbosity_value v, const char* str,
case AF_INET6: family="ip6";
sinaddr = &((struct sockaddr_in6*)addr)->sin6_addr;
break;
- case AF_UNIX: family="unix"; break;
+ case AF_LOCAL: family="local"; break;
default: break;
}
if(inet_ntop(af, sinaddr, dest, (socklen_t)sizeof(dest)) == 0) {
@@ -313,7 +313,7 @@ void log_name_addr(enum verbosity_value v, const char* str, uint8_t* zone,
case AF_INET6: family="";
sinaddr = &((struct sockaddr_in6*)addr)->sin6_addr;
break;
- case AF_UNIX: family="unix_family "; break;
+ case AF_LOCAL: family="local "; break;
default: break;
}
if(inet_ntop(af, sinaddr, dest, (socklen_t)sizeof(dest)) == 0) {
OpenPOWER on IntegriCloud