From sjr@home.net  Sun Aug 13 08:05:34 2000
Return-Path: <sjr@home.net>
Received: from cc158233-a.catv1.md.home.com (cc158233-a.catv1.md.home.com [24.3.25.17])
	by hub.freebsd.org (Postfix) with ESMTP id 8682A37B5F3
	for <FreeBSD-gnats-submit@freebsd.org>; Sun, 13 Aug 2000 08:05:33 -0700 (PDT)
	(envelope-from sjr@home.net)
Received: (from sjr@localhost)
	by cc158233-a.catv1.md.home.com (8.9.3/8.9.3) id LAA57065;
	Sun, 13 Aug 2000 11:05:31 -0400 (EDT)
	(envelope-from sjr)
Message-Id: <200008131505.LAA57065@cc158233-a.catv1.md.home.com>
Date: Sun, 13 Aug 2000 11:05:31 -0400 (EDT)
From: sjr@home.com
Sender: sjr@home.net
Reply-To: sjr@home.com
To: FreeBSD-gnats-submit@freebsd.org
Subject: /etc/security errors if no old compressed files
X-Send-Pr-Version: 3.2

>Number:         20575
>Category:       misc
>Synopsis:       /etc/security errors if no old compressed files
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-bugs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sun Aug 13 08:10:01 PDT 2000
>Closed-Date:    Wed Sep 20 14:29:04 PDT 2000
>Last-Modified:  Wed Sep 20 14:29:37 PDT 2000
>Originator:     Stephen J. Roznowski
>Release:        FreeBSD 4.1-STABLE i386
>Organization:
>Environment:

	

>Description:

	When /etc/security is run on a new install, it errors
	since there are no old zgipped files:

	XXX login failures:
	/var/log/messages.0*.gz: No such file or directory

	XXX refused connections:
	/var/log/messages.0*.gz: No such file or directory

>How-To-Repeat:

	

>Fix:

	There are probably two different solutions to this problem, either
	redirect error output to /dev/null, or implement a similiar
	solution to the one in 460.status-mail-rejects.

	See PR (http://www.freebsd.org/cgi/query-pr.cgi?pr=20514)

>Release-Note:
>Audit-Trail:

From: Brian Somers <brian@Awfulhak.org>
To: sjr@home.com
Cc: FreeBSD-gnats-submit@FreeBSD.org, brian@Awfulhak.org
Subject: Re: misc/20575: /etc/security errors if no old compressed files 
Date: Mon, 14 Aug 2000 00:16:38 +0100

 > >Number:         20575
 > >Category:       misc
 > >Synopsis:       /etc/security errors if no old compressed files
 
 Perhaps zcat needs a -s option (as cat(1) has).
 -- 
 Brian <brian@Awfulhak.org>                        <brian@[uk.]FreeBSD.org>
       <http://www.Awfulhak.org>                   <brian@[uk.]OpenBSD.org>
 Don't _EVER_ lose your sense of humour !
 
 
 

From: Sheldon Hearn <sheldonh@uunet.co.za>
To: Brian Somers <brian@Awfulhak.org>
Cc: freebsd-gnats-submit@FreeBSD.org
Subject: Re: misc/20575: /etc/security errors if no old compressed files 
Date: Mon, 14 Aug 2000 12:06:53 +0200

 On Sun, 13 Aug 2000 16:30:05 MST, Brian Somers wrote:
 
 >  > >Number:         20575
 >  > >Category:       misc
 >  > >Synopsis:       /etc/security errors if no old compressed files
 >  
 >  Perhaps zcat needs a -s option (as cat(1) has).
 
 Perhaps, but you could get around this problem quite easily with the
 following patch.
 
 Ciao,
 Sheldon.
 
 Index: security
 ===================================================================
 RCS file: /home/ncvs/src/etc/security,v
 retrieving revision 1.41
 diff -u -d -r1.41 security
 --- security	2000/08/07 09:08:35	1.41
 +++ security	2000/08/14 10:05:05
 @@ -136,16 +136,22 @@
  	fi
  fi
  
 +msgfiles="`ls $LOG/messages.0* $LOG/messages 2>/dev/null`"
 +
  # Show login failures
  #
  separator
  echo "${host} login failures:"
 -zcat -f $LOG/messages.0* $LOG/messages | grep -i "^$yesterday.*login failure"
 +if [ -n "${msgfiles}" ]; then
 +	zcat -f ${msgfiles} | grep -i "^$yesterday.*login failure"
 +fi
  
  # Show tcp_wrapper warning messages
  #
  separator
  echo "${host} refused connections:"
 -zcat -f $LOG/messages.0* $LOG/messages | grep -i "^$yesterday.*refused connect"
 +if [ -n "${msgfiles}" ]; then
 +	zcat -f ${msgfiles} | grep -i "^$yesterday.*refused connect"
 +fi
  
  rm -f ${TMP}
 
State-Changed-From-To: open->closed 
State-Changed-By: brian 
State-Changed-When: Wed Sep 20 14:29:04 PDT 2000 
State-Changed-Why:  
This was fixed with the latest version of /etc/security in -stable and -current 

http://www.freebsd.org/cgi/query-pr.cgi?pr=20575 
>Unformatted:
