From 5cddf5e52aeb20e50c887356ad23aec354e04151 Mon Sep 17 00:00:00 2001 From: Guus Sliepen Date: Sun, 11 Oct 2009 13:51:10 +0200 Subject: [PATCH] Don't disconnect clients in TunnelServer mode who send unauthorised ADD_SUBNETs. So that we are liberal in what we accept. --- src/protocol_subnet.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/protocol_subnet.c b/src/protocol_subnet.c index e7ab8b24..f7ce53b9 100644 --- a/src/protocol_subnet.c +++ b/src/protocol_subnet.c @@ -112,7 +112,7 @@ bool add_subnet_h(connection_t *c) { for(cfg = lookup_config(c->config_tree, "Subnet"); cfg; cfg = lookup_config_next(c->config_tree, cfg)) { if(!get_config_subnet(cfg, &allowed)) - return false; + continue; if(!subnet_compare(&s, allowed)) break; @@ -121,9 +121,9 @@ bool add_subnet_h(connection_t *c) { } if(!cfg) { - logger(LOG_WARNING, "Unauthorized %s from %s (%s) for %s", - "ADD_SUBNET", c->name, c->hostname, subnetstr); - return false; + logger(LOG_WARNING, "Ignoring unauthorized %s from %s (%s): %s", + "ADD_SUBNET", c->name, c->hostname, subnetstr); + return true; } free_subnet(allowed); -- 2.39.5