1 .\" $NetBSD: netpgpverify.1,v 1.2 2009/06/08 08:02:32 wiz Exp $
3 .\" Copyright (c) 2009 The NetBSD Foundation, Inc.
4 .\" All rights reserved.
6 .\" This manual page is derived from software contributed to
7 .\" The NetBSD Foundation by Alistair Crooks (agc@NetBSD.org).
9 .\" Redistribution and use in source and binary forms, with or without
10 .\" modification, are permitted provided that the following conditions
12 .\" 1. Redistributions of source code must retain the above copyright
13 .\" notice, this list of conditions and the following disclaimer.
14 .\" 2. Redistributions in binary form must reproduce the above copyright
15 .\" notice, this list of conditions and the following disclaimer in the
16 .\" documentation and/or other materials provided with the distribution.
18 .\" THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
19 .\" ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
20 .\" TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
21 .\" PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
22 .\" BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
23 .\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
24 .\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
25 .\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
26 .\" CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
27 .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
28 .\" POSSIBILITY OF SUCH DAMAGE.
35 .Nd standalone program for digital signature verification
39 .Op Fl Fl output Ns = Ns Ar filename
43 where the options for all commands are:
47 .Op Fl Fl homedir Ns = Ns Ar home-directory
49 .Op Fl Fl keyring Ns = Ns Ar keyring
51 .Op Fl Fl userid Ns = Ns Ar userid
59 program, and duplicates its verification functionality in
60 a single standalone program.
61 The reason for this duplication is simply because verification
63 is such a common operation that a single, much smaller,
64 standalone program can be used.
66 The following commands are used to sign and verify signatures:
70 if an error occurs, the contents of memory are saved to disk, and can
71 be read using tools to analyse behaviour.
72 Unfortunately this can disclose information to people viewing
73 the core dump, such as secret keys, and passphrases protecting
77 will turn off the ability to save core dumps on persistent storage,
78 but selecting this option will allow core dumps to be written to disk.
79 This option should be used wisely, and any core dumps should
80 be deleted in a secure manner when no longer needed.
81 .It Fl Fl homedir Ar home-directory
82 Keyrings are normally located, for historical reasons, within
83 the user's home directory in a subdirectory called
85 and this option specifies an alternative location in which to
86 find that sub-directory.
87 .It Fl Fl keyring Ar keyring
88 This option specifies an alternative keyring to be used.
89 All keyring operations will be relative to this alternative keyring.
91 specifies a filename to which verified output from a signed file
93 The default is to send the verified output to stdout,
94 and this may also be specified using the
98 This option can be used to view information during
103 .Sh SIGNING AND VERIFICATION
104 Signing and verification of a file is best viewed using the following example:
106 % netpgp --sign --userid=agc@netbsd.org a
107 pub 2048/RSA (Encrypt or Sign) 1b68dcfcc0596823 2004-01-12
108 Key fingerprint: d415 9deb 336d e4cc cdfa 00cd 1b68 dcfc c059 6823
109 uid Alistair Crooks \*[Lt]agc@netbsd.org\*[Gt]
110 uid Alistair Crooks \*[Lt]agc@pkgsrc.org\*[Gt]
111 uid Alistair Crooks \*[Lt]agc@alistaircrooks.com\*[Gt]
112 uid Alistair Crooks \*[Lt]alistair@hockley-crooks.com\*[Gt]
115 Good signature for a.gpg made Thu Jan 29 03:06:00 2009
116 using RSA (Encrypt or Sign) key 1B68DCFCC0596823
117 pub 2048/RSA (Encrypt or Sign) 1b68dcfcc0596823 2004-01-12
118 Key fingerprint: d415 9deb 336d e4cc cdfa 00cd 1b68 dcfc c059 6823
119 uid Alistair Crooks \*[Lt]alistair@hockley-crooks.com\*[Gt]
120 uid Alistair Crooks \*[Lt]agc@pkgsrc.org\*[Gt]
121 uid Alistair Crooks \*[Lt]agc@netbsd.org\*[Gt]
122 uid Alistair Crooks \*[Lt]agc@alistaircrooks.com\*[Gt]
126 In the example above, a signature is made on a single file called
128 using a user identity corresponding to
133 The key located for the user identity is displayed, and
134 the user is prompted to type in their passphrase.
135 The resulting file, called
137 is placed in the same directory.
138 The second part of the example shows a verification
143 The time and user identity of the signatory is displayed, followed
144 by a fuller description of the public key of the signatory.
145 In both cases, the exit value from the utility was a successful one.
149 utility will return 0 for success,
150 1 if the file's signature does not match what was expected,
151 or 2 if any other error occurs.
161 utility is designed to conform to IETF RFC 4880.
165 command first appeared in
171 and was overhauled and rewritten by
172 .An Alistair Crooks Aq agc@NetBSD.org .
173 This manual page was written by
174 .An Alistair Crooks .