|
Previous | Table of Contents | Next |
Many times it is useful to see what keys exist on a key ring. PGP enables users to view key rings in multiple formats. The first format, -kv, is a short format, where only the key information and userids are printed. The second format, -kvv, is the long format, and it also shows signatures on keys.
~> pgp -kv Pretty Good Privacy(tm) 2.6.2 - Public-key encryption for the masses. (c) 1990-1994 Philip Zimmermann, Phils Pretty Good Software. 11 Oct 94 Uses the RSAREF(tm) Toolkit, which is copyright RSA Data Security, Inc. Distributed by the Massachusetts Institute of Technology. Export of this software may be restricted by the U.S. government. Current time: 1995/11/21 19:02 GMT Key ring: /tmp/pubring.pgp Type bits/keyID Date User ID pub 1024/0DBF906D 1994/08/27 Jeffrey I. Schiller <jis@mit.edu> pub 512/4D0C4EE1 1992/09/10 Jeffrey I. Schiller <jis@mit.edu> pub 1024/0778338D 1993/09/17 Philip L. Dubois <dubois@csn.org> pub 1024/FBBB8AB1 1994/05/07 Colin Plumb <colin@nyx.cs.du.edu> pub 1024/C7A966DD 1993/05/21 Philip R. Zimmermann <prz@acm.org> pub 1024/8DE722D9 1992/07/22 Branko Lankester <branko@hacktic.nl> pub 1024/9D997D47 1992/08/02 Peter Gutmann <pgut1@cs.aukuni.ac.nz> pub 1019/7D63A5C5 1994/07/04 Hal Abelson <hal@mit.edu> pub 512/97D45291 1995/11/14 William Clinton <President@Whitehouse.GOV> pub 709/C1B06AF1 1992/09/25 Derek Atkins <warlord@MIT.EDU> pub 1024/D0C6326D 1995/11/14 Ruth Thomas <tara@mail.Free.NET> 11 matching keys found.
One interesting quirk you should know about the user interface is that PGP will print out all keys that match the userid, whereas most other functions will choose the first key that matches the userid. In other words, the userid is treated as a substring that is matched against the keys in the key ring. This capability lets you print out a set of keys. For example, you can print out all the keys for people at mit.edu.
~> pgp -kvv mit.edu Pretty Good Privacy(tm) 2.6.2 - Public-key encryption for the masses. (c) 1990-1994 Philip Zimmermann, Phils Pretty Good Software. 11 Oct 94 Uses the RSAREF(tm) Toolkit, which is copyright RSA Data Security, Inc. Distributed by the Massachusetts Institute of Technology. Export of this software may be restricted by the U.S. government. Current time: 1995/11/21 19:05 GMT Key ring: /tmp/pubring.pgp, looking for user ID mit.edu. Type bits/keyID Date User ID pub 1024/0DBF906D 1994/08/27 Jeffrey I. Schiller <jis@mit.edu> sig C7A966DD Philip R. Zimmermann <prz@acm.org> sig C1B06AF1 Derek Atkins <warlord@MIT.EDU> sig 4D0C4EE1 Jeffrey I. Schiller <jis@mit.edu> pub 512/4D0C4EE1 1992/09/10 Jeffrey I. Schiller <jis@mit.edu> sig 4D0C4EE1 Jeffrey I. Schiller <jis@mit.edu> sig C1B06AF1 Derek Atkins <warlord@MIT.EDU> sig C7A966DD Philip R. Zimmermann <prz@acm.org> pub 1019/7D63A5C5 1994/07/04 Hal Abelson <hal@mit.edu> sig 0DBF906D Jeffrey I. Schiller <jis@mit.edu> sig C7A966DD Philip R. Zimmermann <prz@acm.org> pub 709/C1B06AF1 1992/09/25 Derek Atkins <warlord@MIT.EDU> sig D0C6326D Ruth Thomas <tara@mail.Free.NET> sig 0DBF906D Jeffrey I. Schiller <jis@mit.edu> sig 4D0C4EE1 Jeffrey I. Schiller <jis@mit.edu> sig C7A966DD Philip R. Zimmermann <prz@acm.org> 4 matching keys found.
You can also list every key in a key ring other than the default. Leaving off the userid works for the default key ring. However, if an alternate key ring is supplied, you need to supply a userid. A NULL userid, , will match all keys, which will list the full contents.
Previous | Table of Contents | Next |