]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
Disallow pings for TCP sockets
authorAlan T. DeKok <aland@freeradius.org>
Wed, 29 Jun 2011 09:09:07 +0000 (11:09 +0200)
committerAlan T. DeKok <aland@freeradius.org>
Wed, 29 Jun 2011 09:09:07 +0000 (11:09 +0200)
The existing UDP ping code assumes that any socket can send to any
server.  This isn't true for TCP sockets.  For them, the pings
have to be specific to each socket.

The RFC 3539 Status-Server watchdog code will fix that.

src/main/realms.c

index 3727c78436e97f1347ac39f2903f121d83b15dd1..d5286ff11239960c296b775d407f3d2f006e3a94 100644 (file)
@@ -628,9 +628,9 @@ static int home_server_add(realm_config_t *rc, CONF_SECTION *cs)
                        hs_proto = NULL;
                        home->proto = IPPROTO_TCP;
                        
-                       if (home->ping_check == HOME_PING_CHECK_REQUEST) {
+                       if (home->ping_check != HOME_PING_CHECK_NONE) {
                                cf_log_err(cf_sectiontoitem(cs),
-                                          "Cannot use 'status_check = request' for home servers where 'proto = tcp'");
+                                          "Only 'status_check = none' is allowed for home servers with 'proto = tcp'");
                                goto error;
                        }