From 98a1809a3fd2e2049e045b0716d4a6d5164255f5 Mon Sep 17 00:00:00 2001 From: Mike Karels Date: Sun, 13 Dec 1987 01:58:42 -0800 Subject: [PATCH] passive routes aren't trusted SCCS-vsn: sbin/routed/input.c 5.14 --- usr/src/sbin/routed/input.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/usr/src/sbin/routed/input.c b/usr/src/sbin/routed/input.c index 1b4abbbaf9..5f6bf310c2 100644 --- a/usr/src/sbin/routed/input.c +++ b/usr/src/sbin/routed/input.c @@ -5,7 +5,7 @@ */ #ifndef lint -static char sccsid[] = "@(#)input.c 5.13 (Berkeley) %G%"; +static char sccsid[] = "@(#)input.c 5.14 (Berkeley) %G%"; #endif not lint /* @@ -94,7 +94,8 @@ rip_input(from, size) if ((*afp->af_portcheck)(from) == 0) return; if ((ifp = if_iflookup(from)) == 0 || (ifp->int_flags & - (IFF_BROADCAST | IFF_POINTOPOINT | IFF_REMOTE)) == 0) { + (IFF_BROADCAST | IFF_POINTOPOINT | IFF_REMOTE)) == 0 || + ifp->int_flags & IFF_PASSIVE) { syslog(LOG_ERR, "trace command from unknown router, %s", (*afswitch[from->sa_family].af_format)(from)); return; @@ -140,7 +141,8 @@ rip_input(from, size) * and from those listed in /etc/gateways. */ if ((ifp = if_iflookup(from)) == 0 || (ifp->int_flags & - (IFF_BROADCAST | IFF_POINTOPOINT | IFF_REMOTE)) == 0) { + (IFF_BROADCAST | IFF_POINTOPOINT | IFF_REMOTE)) == 0 || + ifp->int_flags & IFF_PASSIVE) { if (bcmp((char *)from, (char *)&badfrom, sizeof(badfrom)) != 0) { syslog(LOG_ERR, -- 2.20.1