From owner-freebsd-bugs Thu Jul 19 7:10:10 2001 Delivered-To: freebsd-bugs@hub.freebsd.org Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by hub.freebsd.org (Postfix) with ESMTP id 63A7C37B401 for ; Thu, 19 Jul 2001 07:10:02 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.11.4/8.11.4) id f6JEA2s22106; Thu, 19 Jul 2001 07:10:02 -0700 (PDT) (envelope-from gnats) Date: Thu, 19 Jul 2001 07:10:02 -0700 (PDT) Message-Id: <200107191410.f6JEA2s22106@freefall.freebsd.org> To: freebsd-bugs@FreeBSD.org Cc: From: Peter Pentchev Subject: Re: bin/28988: We need more simple message digesting tools Reply-To: Peter Pentchev Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org The following reply was made to PR bin/28988; it has been noted by GNATS. From: Peter Pentchev To: Anders Nordby Cc: freebsd-gnats-submit@FreeBSD.org Subject: Re: bin/28988: We need more simple message digesting tools Date: Thu, 19 Jul 2001 17:05:00 +0300 On Thu, Jul 19, 2001 at 04:30:30AM -0700, Anders Nordby wrote: > The following reply was made to PR bin/28988; it has been noted by GNATS. > > From: Anders Nordby > To: Dima Dorfman > Cc: FreeBSD-gnats-submit@freebsd.org > Subject: Re: bin/28988: We need more simple message digesting tools > Date: Thu, 19 Jul 2001 13:28:57 +0200 > > On Mon, Jul 16, 2001 at 10:20:00PM -0700, Dima Dorfman wrote: > >> md5(1) is just a frontend for libmd. If I make md5(1) use > >> libcrypto instead, would that be better? > > Why? What's wrong with: > > > > ln -s /usr/bin/openssl md5 > > The fact that md5 dgst -sha1 does not make sence, and that md5(1) is > expected to output differently and have other options. It doesn't work, either. If openssl is invoked with an algorithm name, it accepts only filenames, not commands/options. Thus, it preserves md5(1)'s syntax (at least in this respect). [roam@edge:p1 /usr/src]$ ln -s /usr/bin/openssl /usr/tmp/md5 [roam@edge:p1 /usr/src]$ /usr/tmp/md5 /etc/passwd MD5(/etc/passwd)= dbcf40cb4677824638143626b514ad4e [roam@edge:p1 /usr/src]$ /usr/tmp/md5 dgst -sha1 /etc/passwd dgst: No such file or directory -sha1: No such file or directory MD5(/etc/passwd)= dbcf40cb4677824638143626b514ad4e [roam@edge:p1 /usr/src]$ > > works for sha, sha1, ripemd160, and a few other algorithms. The only > > thing wrong with it is that openssl doesn't support some of the > > options md5(1) does, and has a slightly different output format. > > Is there a problem with having both md5/rmd160/sha1(1) and openssl(1)? > As long as we have libmd and they all work/are correct, I think not. I think that there is an idea to remove libmd, since it only duplicates libcrypto functionality. Thus, the notion of using openssl(1) as md5(1). (And before phk jumps at me, yes, I know that libmd was introduced waay before libcrypto made it into the source tree, and yes, I know that they have slightly different functionality - actually I even contributed some of that difference, remember? :P .. and no, I'm not the one advocating libmd replacement with libcrypto, just stating that some people are :) G'luck, Peter -- Hey, out there - is it *you* reading me, or is it someone else? To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message