Date: Tue, 10 Aug 2010 11:15:18 +0000 (UTC) From: Gabor Kovesdan <gabor@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r211141 - head/etc/periodic/security Message-ID: <201008101115.o7ABFIs0002027@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: gabor Date: Tue Aug 10 11:15:17 2010 New Revision: 211141 URL: http://svn.freebsd.org/changeset/base/211141 Log: - Fixes to the chkportsum script to handle better some special cases, like spaces in filename Submitted by: Alex Kozlov <spam@rm-rf.kiev.ua> Approved by: delphij (mentor) Modified: head/etc/periodic/security/460.chkportsum Modified: head/etc/periodic/security/460.chkportsum ============================================================================== --- head/etc/periodic/security/460.chkportsum Tue Aug 10 11:02:55 2010 (r211140) +++ head/etc/periodic/security/460.chkportsum Tue Aug 10 11:15:17 2010 (r211141) @@ -42,20 +42,20 @@ echo 'Checking for ports with mismatched case "${daily_status_security_chkportsum_enable}" in [Yy][Ee][Ss]) + set -f pkg_info -ga 2>/dev/null | \ - while read one two three; do - case ${one} in + while IFS= read -r line; do + set -- $line + case $1 in Information) - case ${two} in - for) name=${three%%:} ;; - *) name='??' ;; + case $2 in + for) name="${3%%:}" ;; + *) name='??' ;; esac ;; Mismatched|'') ;; - *) - if [ -n ${name} ]; then - echo ${name}: ${one} - fi + *) [ -n "${name}" ] && + echo "${name}: ${line%% fails the original MD5 checksum}" ;; esac done
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201008101115.o7ABFIs0002027>