From owner-freebsd-questions@FreeBSD.ORG Sat Dec 6 11:47:30 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 BFA2116A4CE for ; Sat, 6 Dec 2003 11:47:30 -0800 (PST) Received: from catseye.mine.nu (d154-5-166-198.bchsia.telus.net [154.5.166.198]) by mx1.FreeBSD.org (Postfix) with SMTP id 9EE6743FBD for ; Sat, 6 Dec 2003 11:47:29 -0800 (PST) (envelope-from catseye@catseye.mine.nu) Received: (qmail 87059 invoked by uid 1001); 6 Dec 2003 19:48:43 -0000 Date: Sat, 6 Dec 2003 11:48:43 -0800 From: Chris Pressey To: Marty Landman Message-Id: <20031206114843.6a37709e.cpressey@catseye.mine.nu> In-Reply-To: <6.0.0.22.0.20031206095611.01f550a0@pop.face2interface.com> References: <6.0.0.22.0.20031206095611.01f550a0@pop.face2interface.com> Organization: Cat's Eye Technologies X-Mailer: Sylpheed version 0.9.7 (GTK+ 1.2.10; i386-portbld-freebsd4.9) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit cc: FreeBSD-Questions@freebsd.org Subject: Re: md5 newbie question 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: Sat, 06 Dec 2003 19:47:30 -0000 On Sat, 06 Dec 2003 09:59:07 -0500 Marty Landman wrote: > Trying to verify a d/l before compiling: > > Swami: md5 -s 466c63bb71b710d20a5c353df8c1a19c /tmp/httpd-2.0.48.tar.gz > MD5 ("466c63bb71b710d20a5c353df8c1a19c") = 017b97dd023763b82a219bdfedd5cc29 > MD5 (/tmp/httpd-2.0.48.tar.gz) = 466c63bb71b710d20a5c353df8c1a19c > Swami: The "-s 466c63bb71b710d20a5c353df8c1a19c" part of your command is requesting an md5 hash of the literal string of characters "466c63bb71b710d20a5c353df8c1a19c". That's almost certainly not what you want, and will only serve to confuse. Try running just this instead: md5 /tmp/httpd-2.0.48.tar.gz and see "man md5" for more info. > By eyeballing the first part of line1 against the second part of line > 2 they appear equal so I guess my d/l's integrity is intact. What is > the more automated way to do this though, so that I get a line at the > end saying "ok" or "ah, phooey". Or am I supposed to extract and diff > these myself? Essentially, yes; many source tarballs come with an .md5 file which you can diff against the output of the md5 command. But FreeBSD's ports system will check md5's for you automatically. The ports tree is very, very convenient, and I'd recommend using it whenever possible. -Chris