From bb6f02960b627126d5505e505da012443dcc5c9c Mon Sep 17 00:00:00 2001 From: deraadt Date: Fri, 6 Sep 1996 13:05:51 +0000 Subject: [PATCH] turn logging off again, it is still unsafe --- sbin/routed/Makefile | 5 ++++- sbin/routed/input.c | 9 +++++++-- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/sbin/routed/Makefile b/sbin/routed/Makefile index 35ebc319e4b..137c08c6c00 100644 --- a/sbin/routed/Makefile +++ b/sbin/routed/Makefile @@ -1,4 +1,4 @@ -# $OpenBSD: Makefile,v 1.4 1996/09/05 14:31:10 mickey Exp $ +# $OpenBSD: Makefile,v 1.5 1996/09/06 13:05:51 deraadt Exp $ # @(#)Makefile 8.1 (Berkeley) 6/19/93 PROG= routed @@ -10,6 +10,9 @@ SUBDIR= rtquery DPADD= ${LIBCOMPAT} LDADD= -lcompat +# Do *NOT* turn this flag on unless you like security holes +#CFLAGS+=-DPERMIT_TRACE + .PATH: ${.CURDIR}/../../sys/net .include diff --git a/sbin/routed/input.c b/sbin/routed/input.c index c17e4fd2a36..2cb959f83f7 100644 --- a/sbin/routed/input.c +++ b/sbin/routed/input.c @@ -1,4 +1,4 @@ -/* $OpenBSD: input.c,v 1.4 1996/09/05 14:31:27 mickey Exp $ */ +/* $OpenBSD: input.c,v 1.5 1996/09/06 13:05:52 deraadt Exp $ */ /* * Copyright (c) 1983, 1988, 1993 @@ -36,7 +36,7 @@ #if !defined(lint) static char sccsid[] = "@(#)input.c 8.1 (Berkeley) 6/5/93"; #else -static char rcsid[] = "$OpenBSD: input.c,v 1.4 1996/09/05 14:31:27 mickey Exp $"; +static char rcsid[] = "$OpenBSD: input.c,v 1.5 1996/09/06 13:05:52 deraadt Exp $"; #endif #include "defs.h" @@ -304,6 +304,7 @@ input(struct sockaddr_in *from, /* received from this IP address */ naddr_ntoa(FROM_NADDR)); return; } +#if PERMIT_TRACE if (rip->rip_cmd == RIPCMD_TRACEON) { rip->rip_tracefile[size-4] = '\0'; trace_on((char*)rip->rip_tracefile, 0); @@ -311,6 +312,10 @@ input(struct sockaddr_in *from, /* received from this IP address */ trace_off("tracing turned off by %s\n", naddr_ntoa(FROM_NADDR)); } +#else + msglog("trace command from %s ignored: %s\n", + rip->rip_tracefile); +#endif return; case RIPCMD_RESPONSE: -- 2.20.1