1PGPVERIFY(1) InterNetNews Documentation PGPVERIFY(1)
2
3
4
6 pgpverify - Cryptographically verify Usenet control messages
7
9 pgpverify [--findid=string] [--test] < message
10
12 The pgpverify program reads (on standard input) a Usenet control
13 message that has been cryptographically signed using the signcontrol
14 program (or some other program that produces a compatible format).
15 pgpverify then uses a PGP implementation to determine who signed the
16 control message. If the control message has a valid signature,
17 pgpverify prints (to stdout) the user ID of the key that signed the
18 message. Otherwise, it exits with a non-zero exit status.
19
20 If pgpverify is installed as part of INN, it uses INN's configuration
21 to determine what signature verification program to use, how to log
22 errors, what temporary directory to use, and what keyring to use.
23 Otherwise, all of those parameters can be set by editing the beginning
24 of this script.
25
26 By default, when running as part of INN, pgpverify expects the PGP key
27 ring to be found in pathetc/pgp (as either pubring.pgp or pubring.gpg
28 depending on whether PGP or GnuPG is used to verify signatures). If
29 that directory doesn't exist, it will fall back on using the default
30 key ring, which is in a .pgp or .gnupg subdirectory of the running
31 user's home directory.
32
33 INN, when using GnuPG, configures pgpverify to use gpg or gpgv, which
34 by default expects keys to be in a keyring named trustedkeys.gpg, since
35 it doesn't implement trust checking directly. pgpverify uses that file
36 if present but falls back to pubring.gpg if it's not found. This
37 bypasses the trust model for checking keys, but is compatible with the
38 way that pgpverify used to behave. Of course, if a keyring is found in
39 pathetc/pgp or configured at the top of the script, that overrides all
40 of this behavior.
41
43 --findid=string
44 The --findid flag causes pgpverify to explicitly search for string
45 in the output from PGP's analysis of the message. This option is
46 useful when several UIDs are defined on a single PGP key, and the
47 caller to pgpverify needs checking whether a given one is defined
48 on this key. In case the signature is valid but does not contain
49 string, pgpverify exits with exit status 4.
50
51 --test
52 The --test flag causes pgpverify to print out the input that it is
53 passing to PGP (which is a reconstructed version of the input that
54 supposedly created the control message) as well as the output from
55 PGP's analysis of the message.
56
58 pgpverify may exit with the following statuses:
59
60 0 The control message had a good PGP signature.
61
62 1 The control message had no PGP signature.
63
64 2 The control message had an unknown PGP signature.
65
66 3 The control message had a bad PGP signature.
67
68 4 The control message had a good PGP signature but the argument given
69 to the --findid flag had non been found in the output from PGP's
70 analysis of the message.
71
72 255 A problem occurred not directly related to PGP analysis of
73 signature.
74
76 pgpverify does not modify or otherwise alter the environment before
77 invoking the pgp, gpgv or gpg program. It is the responsibility of the
78 person who installs pgpverify to ensure that when pgp, gpgv or gpg
79 runs, it has the ability to locate and read a PGP key file that
80 contains the PGP public keys for the appropriate Usenet hierarchy
81 administrators. pgpverify can be pointed to an appropriate key ring by
82 editing variables at the beginning of this script.
83
85 Historically, Usenet news server administrators have configured their
86 news servers to automatically honor Usenet control messages based on
87 the originator of the control messages and the hierarchies for which
88 the control messages applied. For example, in the past, David Lawrence
89 always issued control messages for the "Big 8" hierarchies (comp,
90 humanities, misc, news, rec, sci, soc, talk). Usenet news
91 administrators would configure their news server software to
92 automatically honor newgroup and rmgroup control messages that
93 originated from David Lawrence and applied to any of the Big 8
94 hierarchies.
95
96 Unfortunately, Usenet news articles (including control messages) are
97 notoriously easy to forge. Soon, malicious users realized they could
98 create or remove (at least temporarily) any Big 8 newsgroup they wanted
99 by simply forging an appropriate control message in David Lawrence's
100 name. As Usenet became more widely used, forgeries became more common.
101
102 The pgpverify program was designed to allow Usenet news administrators
103 to configure their servers to cryptographically verify control messages
104 before automatically acting on them. Under the pgpverify system, a
105 Usenet hierarchy maintainer creates a PGP public/private key pair and
106 disseminates the public key. Whenever the hierarchy maintainer issues
107 a control message, he uses the signcontrol program to sign the control
108 message with the PGP private key. Usenet news administrators configure
109 their news servers to run the pgpverify program on the appropriate
110 control messages, and take action based on the PGP key User ID that
111 signed the control message, not the name and address that appear in the
112 control message's From: or Sender: headers.
113
114 Thus, appropriate use of the signcontrol and pgpverify programs
115 essentially eliminates the possibility of malicious users forging
116 Usenet control messages that sites will act upon, as such users would
117 have to obtain the PGP private key in order to forge a control message
118 that would pass the cryptographic verification step. If the hierarchy
119 administrators properly protect their PGP private keys, the only way a
120 malicious user could forge a validly-signed control message would be by
121 breaking the public key encryption algorithm, which (at least at this
122 time) is believed to be prohibitively difficult for PGP keys of a
123 sufficient bit length.
124
126 pgpverify was written by David C Lawrence <tale@isc.org>. Manual page
127 provided by James Ralston. It is currently maintained by Russ Allbery
128 <eagle@eyrie.org>.
129
131 David Lawrence wrote: "Our lawyer told me to include the following.
132 The upshot of it is that you can use the software for free as much as
133 you like."
134
135 Copyright (c) 1996 UUNET Technologies, Inc. All rights reserved.
136
137 Redistribution and use in source and binary forms, with or without
138 modification, are permitted provided that the following conditions are
139 met:
140
141 1. Redistributions of source code must retain the above copyright
142 notice, this list of conditions and the following disclaimer.
143
144 2. Redistributions in binary form must reproduce the above copyright
145 notice, this list of conditions and the following disclaimer in the
146 documentation and/or other materials provided with the
147 distribution.
148
149 3. All advertising materials mentioning features or use of this
150 software must display the following acknowledgement:
151
152 This product includes software developed by UUNET Technologies, Inc.
153
154 4. The name of UUNET Technologies ("UUNET") may not be used to endorse
155 or promote products derived from this software without specific
156 prior written permission.
157
158 THIS SOFTWARE IS PROVIDED BY UUNET "AS IS" AND ANY EXPRESS OR IMPLIED
159 WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
160 MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
161 IN NO EVENT SHALL UUNET BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
162 SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
163 LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
164 DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
165 THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
166 (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
167 OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
168
170 gpg(1), gpgv(1), pgp(1).
171
172 <https://ftp.isc.org/pub/pgpcontrol/> is where the most recent versions
173 of signcontrol and pgpverify live, along with PGP public keys used for
174 hierarchy administration.
175
176
177
178INN 2.6.3 2018-12-29 PGPVERIFY(1)