diff options
author | eik <eik@FreeBSD.org> | 2004-06-11 16:07:02 +0000 |
---|---|---|
committer | eik <eik@FreeBSD.org> | 2004-06-11 16:07:02 +0000 |
commit | 6ce46a0816813d4d69abd00d4820d640ddaa9bbc (patch) | |
tree | 1430582fd9c7ef7641be87f5097d224ce5e20c4b /sbin/md5/md5.1 | |
parent | ad8a1611c3afd38808fa8ebc76ca5128459c4efc (diff) | |
download | FreeBSD-src-6ce46a0816813d4d69abd00d4820d640ddaa9bbc.zip FreeBSD-src-6ce46a0816813d4d69abd00d4820d640ddaa9bbc.tar.gz |
Add sha1 and rmd160 checksum tools.
Since the algorithms are already supported in libmd,
the size increase is small when a dynamic root is used.
Approved by: joerg, ru
MFC after: 2 weeks
Diffstat (limited to 'sbin/md5/md5.1')
-rw-r--r-- | sbin/md5/md5.1 | 81 |
1 files changed, 62 insertions, 19 deletions
diff --git a/sbin/md5/md5.1 b/sbin/md5/md5.1 index 852f1d4..9d37731 100644 --- a/sbin/md5/md5.1 +++ b/sbin/md5/md5.1 @@ -1,20 +1,30 @@ .\" $FreeBSD$ -.Dd February 14, 1994 +.Dd June 6, 2004 .Dt MD5 1 .Os .Sh NAME -.Nm md5 +.Nm md5 , sha1 , rmd160 .Nd calculate a message-digest fingerprint (checksum) for a file .Sh SYNOPSIS -.Nm +.Nm md5 +.Op Fl pqrtx +.Op Fl s Ar string +.Op Ar +.Nm sha1 +.Op Fl pqrtx +.Op Fl s Ar string +.Op Ar +.Nm rmd160 .Op Fl pqrtx .Op Fl s Ar string .Op Ar .Sh DESCRIPTION -The -.Nm -utility takes as input a message of arbitrary length and produces -as output a 128-bit +The +.Nm md5 , sha1 +and +.Nm rmd160 +utilities take as input a message of arbitrary length and produce as +output a .Dq fingerprint or .Dq message digest @@ -22,17 +32,23 @@ of the input. It is conjectured that it is computationally infeasible to produce two messages having the same message digest, or to produce any message having a given prespecified target message digest. -The MD5 algorithm is intended for digital signature applications, where a +The +.Tn MD5 , SHA-1 +and +.Tn RIPEMD-160 +algorithms are intended for digital signature applications, where a large file must be .Dq compressed in a secure manner before being encrypted with a private (secret) key under a public-key cryptosystem such as -.Em RSA . +.Tn RSA . .Pp -MD5 has not yet (2001-09-03) been broken, but sufficient attacks have been +.Tn MD5 +has not yet (2001-09-03) been broken, but sufficient attacks have been made that its security is in some doubt. -The attacks on MD5 +The attacks on +.Tn MD5 are in the nature of finding .Dq collisions \(em that is, multiple @@ -41,17 +57,16 @@ to be able to determine the exact original input given a hash value. .Pp The following options may be used in any combination and must precede any files named on the command line. -The MD5 -sum of each file listed on the command line is printed after the options -are processed. +The hexadecimal checksum of each file listed on the command line is printed +after the options are processed. .Bl -tag -width indent .It Fl s Ar string Print a checksum of the given .Ar string . .It Fl p -Echo stdin to stdout and appends the MD5 sum to stdout. +Echo stdin to stdout and append the checksum to stdout. .It Fl q -Quiet mode - only the MD5 sum is printed out. +Quiet mode - only the checksum is printed out. Overrides the .Fl r option. @@ -69,16 +84,44 @@ Run a built-in test script. .El .Sh DIAGNOSTICS The -.Nm -utility exits 0 on success, +.Nm md5 , sha1 +and +.Nm rmd160 +utilities exit 0 on success, and 1 if at least one of the input files could not be read. .Sh SEE ALSO -.Xr cksum 1 +.Xr cksum 1 , +.Xr md5 3 , +.Xr ripemd 3 , +.Xr sha 3 .Rs .%A R. Rivest .%T The MD5 Message-Digest Algorithm .%O RFC1321 .Re +.Rs +.%A J. Burrows +.%T The Secure Hash Standard +.%O FIPS PUB 180-1 +.Re +.Rs +.%A D. Eastlake and P. Jones +.%T US Secure Hash Algorithm 1 +.%O RFC 3174 +.Re +.Pp +RIPEMD-160 is part of the ISO draft standard +.Qq ISO/IEC DIS 10118-3 +on dedicated hash functions. +.Pp +Secure Hash Standard (SHS): +.Pa http://csrc.nist.gov/cryptval/shs.html . +.Pp +The RIPEMD-160 page: +.Pa http://www.esat.kuleuven.ac.be/~bosselae/ripemd160.html . .Sh ACKNOWLEDGMENTS This program is placed in the public domain for free general use by RSA Data Security. +.Pp +Support for SHA-1 and RIPEMD-160 has been added by +.An Oliver Eikemeier Aq eik@FreeBSD.org . |