From owner-freebsd-questions@FreeBSD.ORG Fri Jul 25 12:13:05 2003 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id AF07137B401 for ; Fri, 25 Jul 2003 12:13:05 -0700 (PDT) Received: from ns.pro.sk (proxy.pro.sk [195.80.161.199]) by mx1.FreeBSD.org (Postfix) with ESMTP id E007443F3F for ; Fri, 25 Jul 2003 12:13:03 -0700 (PDT) (envelope-from prosa@pro.sk) Received: from peter (Peter [192.168.1.53]) by ns.pro.sk (8.11.3/8.11.3) with SMTP id h6PJCxE87220; Fri, 25 Jul 2003 21:12:59 +0200 (CEST) (envelope-from prosa@pro.sk) Message-ID: <023301c352e0$b17fcac0$3501a8c0@pro.sk> From: "Peter Rosa" To: "Vitali Malicky" References: <020d01c352dc$0ef7a7e0$3501a8c0@pro.sk> <028101c352dd$d87ee230$2401010a@zone3000.net> Date: Fri, 25 Jul 2003 21:12:30 +0200 Organization: PRO, s.r.o. MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 5.50.4807.1700 X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4807.1700 cc: freebsd-questions Subject: Re: Problem with periodically done scripts X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Jul 2003 19:13:06 -0000 It is doing xactly the same as my scripts (unexpected operator). Everything gone well until April 20. Scripts my machine use are from standard FBSD installation, so why they are not working now ? Peter Rosa ----- Original Message ----- From: "Vitali Malicky" To: "freebsd-questions" Sent: Friday, July 25, 2003 8:52 PM Subject: Re: Problem with periodically done scripts > > > > I'm asking again, as there is no response up now. > > You forgot to say "please", sir... 8-| > > > > > As for me, now it seems as.... I don't know what's the error here, I have > > never seen that listings (using -x switch). > > try my scripts, I never have any problems with them, so don't even understan > what you're about... > > 300.chkuid0 > ========= > #!/bin/sh - > if [ -r /etc/defaults/periodic.conf ] > then > . /etc/defaults/periodic.conf > source_periodic_confs > fi > > case "$daily_status_security_chkuid0_enable" in > [Yy][Ee][Ss]) > echo "" > echo 'Checking for uids of 0:' > n=$(awk -F: '/^#/ {next} $3==0 {print $1,$3}' /etc/master.passwd | > tee /dev/stderr | > sed -e '/^root 0$/d' -e '/^toor 0$/d' | > wc -l) > [ $n -gt 0 ] && rc=1 || rc=0;; > *) rc=0;; > ============ > > 400.passwdless > ============ > #!/bin/sh - > if [ -r /etc/defaults/periodic.conf ] > then > . /etc/defaults/periodic.conf > source_periodic_confs > fi > > case "$daily_status_security_passwdless_enable" in > [Yy][Ee][Ss]) > echo "" > echo 'Checking for passwordless accounts:' > n=$(awk -F: 'NF > 1 && $1 !~ /^[#+-]/ && $2=="" {print $0}' > /etc/master.passwd | > tee /dev/stderr | wc -l) > [ $n -gt 0 ] && rc=1 || rc=0;; > *) rc=0;; > esac > > exit "$rc" > > > =========================== > > > > > > > > Peter Rosa > > > > > > > > ----- Original Message ----- > > From: "Peter Rosa" > > To: > > Cc: "freebsd-questions" > > Sent: Friday, July 25, 2003 6:59 PM > > Subject: Re: Problem with periodically done scripts > > > > > > > Here is complete listing. Do you have any idea ? > > > > > > + echo Checking for uids of 0: > > > Checking for uids of 0: > > > + awk -F: $3==0 {print $1,$3} /etc/master.passwd > > > + tee /dev/stderr > > > root 0 > > > toor 0 > > > + sed -e /^root 0$/d -e /^toor 0$/d > > > + wc -l > > > + n= > > > + [ -gt 0 -a -lt 1 ] > > > [: 0: unexpected operator > > > + echo Checking for passwordless accounts: > > > Checking for passwordless accounts: > > > + awk -F: NF > 1 && $1 !~ /^[#+-]/ && $2=="" {print $0} > /etc/master.passwd > > > + tee /dev/stderr > > > + wc -l > > > + n= > > > + [ -gt 0 -a -lt 1 ] > > > [: 0: unexpected operator > > > > > > > > > Peter Rosa > > > > _______________________________________________ > > freebsd-questions@freebsd.org mailing list > > http://lists.freebsd.org/mailman/listinfo/freebsd-questions > > To unsubscribe, send any mail to > "freebsd-questions-unsubscribe@freebsd.org" > > _______________________________________________ > freebsd-questions@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-questions > To unsubscribe, send any mail to "freebsd-questions-unsubscribe@freebsd.org" >