From a8a65cee083a27afe42cab360596e1453e7141b9 Mon Sep 17 00:00:00 2001 From: Michael Tokarev Date: Sun, 24 May 2009 17:23:24 +0400 Subject: [PATCH] tunnelserver: log which ADD_SUBNET was refused Add some logging about refused ADD_SUBNET (it causes subsequent client disconnect so it's important to know which subnet was at fault). Maybe we should just ignore it completely. --- src/protocol_subnet.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/protocol_subnet.c b/src/protocol_subnet.c index 3e5dadd1..d40b3a33 100644 --- a/src/protocol_subnet.c +++ b/src/protocol_subnet.c @@ -127,8 +127,11 @@ bool add_subnet_h(connection_t *c) free_subnet(allowed); } - if(!cfg) + if(!cfg) { + logger(LOG_WARNING, _("Unauthorized %s from %s (%s) for %s"), + "ADD_SUBNET", c->name, c->hostname, subnetstr); return false; + } free_subnet(allowed); } -- 2.39.5