summaryrefslogtreecommitdiff
path: root/bin/md5/md5.1
diff options
context:
space:
mode:
authorLawrence Teo <lteo@cvs.openbsd.org>2014-01-15 04:43:37 +0000
committerLawrence Teo <lteo@cvs.openbsd.org>2014-01-15 04:43:37 +0000
commitf041970e31cec8de25f3ac37c71742eb54cc3df3 (patch)
tree6ed1e54a30f6eff9325709c323e22a3c9be675ac /bin/md5/md5.1
parent86ad9ac721f74e4b2cf6c02acf8fe218f7059609 (diff)
Add support for a -C option. It works on a checklist like -c but only
does the checksum comparison for selected files that are specified on the command line. idea discussed with deraadt@ and tedu@ manpage feedback jmc@ feedback/OK deraadt@ millert@
Diffstat (limited to 'bin/md5/md5.1')
-rw-r--r--bin/md5/md5.118
1 files changed, 16 insertions, 2 deletions
diff --git a/bin/md5/md5.1 b/bin/md5/md5.1
index 06a965f0b95..097253a9bab 100644
--- a/bin/md5/md5.1
+++ b/bin/md5/md5.1
@@ -1,4 +1,4 @@
-.\" $OpenBSD: md5.1,v 1.41 2014/01/10 21:45:04 deraadt Exp $
+.\" $OpenBSD: md5.1,v 1.42 2014/01/15 04:43:36 lteo Exp $
.\"
.\" Copyright (c) 2003, 2004, 2006 Todd C. Miller <Todd.Miller@courtesan.com>
.\"
@@ -18,7 +18,7 @@
.\" Agency (DARPA) and Air Force Research Laboratory, Air Force
.\" Materiel Command, USAF, under agreement number F39502-99-1-0512.
.\"
-.Dd $Mdocdate: January 10 2014 $
+.Dd $Mdocdate: January 15 2014 $
.Dt MD5 1
.Os
.Sh NAME
@@ -27,21 +27,25 @@
.Sh SYNOPSIS
.Nm md5
.Op Fl bcpqrtx
+.Op Fl C Ar checklist
.Op Fl h Ar hashfile
.Op Fl s Ar string
.Op Ar
.Nm sha1
.Op Fl bcpqrtx
+.Op Fl C Ar checklist
.Op Fl h Ar hashfile
.Op Fl s Ar string
.Op Ar
.Nm sha256
.Op Fl bcpqrtx
+.Op Fl C Ar checklist
.Op Fl h Ar hashfile
.Op Fl s Ar string
.Op Ar
.Nm sha512
.Op Fl bcpqrtx
+.Op Fl C Ar checklist
.Op Fl h Ar hashfile
.Op Fl s Ar string
.Op Ar
@@ -61,6 +65,16 @@ The options for use with each command are as follows:
.Bl -tag -width Ds
.It Fl b
Output checksums in base64 notation, not hexadecimal.
+.It Fl C Ar checklist
+Compare the checksum of each
+.Ar file
+against the checksums in the
+.Ar checklist .
+Any specified
+.Ar file
+that is not listed in the
+.Ar checklist
+is ignored.
.It Fl c
If this option is specified, the
.Ar file