[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Call for test and some thoughts



On Sun, Apr 15, 2001 at 02:41:08AM +0200, Raphael Hertzog wrote:
> I commited today some changes to debian-cd wrt the latest bug
> about Packages and Release(.gpg) files. I haven't tested it much (only manty
> helped me debug it this night), and I'd welcome other results to be sure
> it's ok.

BTW, I've got a script to check a Release file is reasonably well formed.

#!/bin/sh -e

cat "$1" | (
  cd "$2"
  awk '/^MD5Sum:/,/^$/' | 
    while read md5 size file; do 
      if [ "$file" = "" ]; then continue; fi
      if [ ! -e "$file" ]; then 
        echo "W: no such file $file"; 
      else 
        m2=`md5sum < $file`; 
        s2=`wc -c < $file`; 
        if [ $s2 != "$size" -o "$m2" != "$md5" ]; then 
          echo "E: md5 check failed for $file"; 
          echo "  $md5 $size"; 
          echo "  $m2 $s2"; 
        fi
      fi
    done
)


Call it with:
	$ chkrel.sh woody/Release woody
and look for any E:'s or W:'s it might spit out.

Cheers,
aj

-- 
Anthony Towns <aj@humbug.org.au> <http://azure.humbug.org.au/~aj/>
I don't speak for anyone save myself. GPG signed mail preferred.

``_Any_ increase in interface difficulty, in exchange for a benefit you
  do not understand, cannot perceive, or don't care about, is too much.''
                      -- John S. Novak, III (The Humblest Man on the Net)



Reply to: