xref: /freebsd/sbin/md5/md5.1 (revision 9e18a3bdd2bc95562a604d1f12b39a9771406b7e)
19e18a3bdSDavid E. O'Brien.\" $FreeBSD$
246657c7eSJohn-Mark Gurney.Dd February 14, 1994
3f22592e7SJohn-Mark Gurney.Dt MD5 1
4f22592e7SJohn-Mark Gurney.Os
5f22592e7SJohn-Mark Gurney.Sh NAME
6f22592e7SJohn-Mark Gurney.Nm md5
7f22592e7SJohn-Mark Gurney.Nd calculate a message-digest fingerprint (checksum) for a file
8f22592e7SJohn-Mark Gurney.Sh SYNOPSIS
923b5892fSPhilippe Charnier.Nm md5
109e18a3bdSDavid E. O'Brien.Op Fl prtx
11716847a6SSteve Price.Op Fl s Ar string
12716847a6SSteve Price.Op Ar file ...
13f22592e7SJohn-Mark Gurney.Sh DESCRIPTION
1423b5892fSPhilippe Charnier.Nm Md5
15e1645093SPaul Trainatakes as input a message of arbitrary length and produces
16f22592e7SJohn-Mark Gurneyas output a 128-bit
17f22592e7SJohn-Mark Gurney.Dq fingerprint
18f22592e7SJohn-Mark Gurneyor
19f22592e7SJohn-Mark Gurney.Dq message digest
20f22592e7SJohn-Mark Gurneyof the input.  It is conjectured that it is computationally infeasible to
21f22592e7SJohn-Mark Gurneyproduce two messages having the same message digest, or to produce any
22e1645093SPaul Trainamessage having a given prespecified target message digest.
23e1645093SPaul TrainaThe MD5 algorithm is intended for digital signature applications, where a
24f22592e7SJohn-Mark Gurneylarge file must be
25f22592e7SJohn-Mark Gurney.Dq compressed
26f22592e7SJohn-Mark Gurneyin a secure manner before being encrypted with a private
27f22592e7SJohn-Mark Gurney.Pq secret
28f22592e7SJohn-Mark Gurneykey under a public-key cryptosystem such as
29f22592e7SJohn-Mark Gurney.Em RSA .
30f22592e7SJohn-Mark Gurney.Pp
31716847a6SSteve PriceThe following four options may be used in any combination and must
32716847a6SSteve Priceprecede any files named on the command line.  The MD5
33716847a6SSteve Pricesum of each file listed on the command line is printed after the options
34716847a6SSteve Priceare processed.
3523b5892fSPhilippe Charnier.Bl -tag -width indent
36716847a6SSteve Price.It Fl s Ar string
3723b5892fSPhilippe CharnierPrint a checksum of the given
38716847a6SSteve Price.Ar string .
39f22592e7SJohn-Mark Gurney.It Fl p
4023b5892fSPhilippe CharnierEcho stdin to stdout and appends the MD5 sum to stdout.
419e18a3bdSDavid E. O'Brien.It Fl r
429e18a3bdSDavid E. O'BrienReverses the format of the output.  This helps with visual diffs.  Does nothing
439e18a3bdSDavid E. O'Brienwhen combined with the
449e18a3bdSDavid E. O'Brien.Fl stpx
459e18a3bdSDavid E. O'Brienoptions.
46f22592e7SJohn-Mark Gurney.It Fl t
4723b5892fSPhilippe CharnierRun a built-in time trial.
48f22592e7SJohn-Mark Gurney.It Fl x
4923b5892fSPhilippe CharnierRun a built-in test script.
50f22592e7SJohn-Mark Gurney.El
51f22592e7SJohn-Mark Gurney.Sh SEE ALSO
52f22592e7SJohn-Mark Gurney.Xr cksum 1
53f22592e7SJohn-Mark Gurney.Rs
54f22592e7SJohn-Mark Gurney.%A R. Rivest
55f22592e7SJohn-Mark Gurney.%T The MD5 Message-Digest Algorithm
56f22592e7SJohn-Mark Gurney.%O RFC1321
57f22592e7SJohn-Mark Gurney.Re
5823b5892fSPhilippe Charnier.Sh ACKNOWLEDGMENTS
59e1645093SPaul TrainaThis program is placed in the public domain for free general use by
60e1645093SPaul TrainaRSA Data Security.
61