~ubuntu-branches/ubuntu/quantal/gnupg2/quantal-security

« back to all changes in this revision

Viewing changes to doc/tools.texi

  • Committer: Bazaar Package Importer
  • Author(s): Marc Deslauriers
  • Date: 2011-05-25 14:27:35 UTC
  • mfrom: (1.1.15 upstream) (7.1.7 sid)
  • Revision ID: james.westby@ubuntu.com-20110525142735-jccyw0fopnyv728q
Tags: 2.0.17-2ubuntu1
* Merge from debian unstable. Remaining changes:
  - Add udev rules to give gpg access to some smartcard readers;
    Debian #543217.
    . debian/gnupg2.dev: udev rules to set ACLs on SCM smartcard readers.
    . debian/rules: Call dh_installudev.
  - debian/control: Rename Vcs-* to XS-Debian-Vcs-*.

Show diffs side-by-side

added added

removed removed

Lines of Context:
16
16
* gpgsm-gencert.sh::      Generate an X.509 certificate request.
17
17
* gpg-preset-passphrase:: Put a passphrase into the cache.
18
18
* gpg-connect-agent::     Communicate with a running agent.
 
19
@ifset gpgtwoone
 
20
* dirmngr-client::        How to use the Dirmngr client tool.
 
21
@end ifset
19
22
* gpgparsemail::          Parse a mail message into an annotated format
20
23
* symcryptrun::           Call a simple symmetric encryption tool.
21
24
* gpg-zip::               Encrypt or sign files into an archive.
41
44
@end ifset
42
45
 
43
46
@mansect description
44
 
Most of the main utilities are able to write their log files to a
45
 
Unix Domain socket if configured that way.  @command{watchgnupg} is a simple
46
 
listener for such a socket.  It ameliorates the output with a time
47
 
stamp and makes sure that long lines are not interspersed with log
48
 
output from other utilities.
 
47
Most of the main utilities are able to write their log files to a Unix
 
48
Domain socket if configured that way.  @command{watchgnupg} is a simple
 
49
listener for such a socket.  It ameliorates the output with a time stamp
 
50
and makes sure that long lines are not interspersed with log output from
 
51
other utilities.  This tool is not available for Windows.
 
52
 
49
53
 
50
54
@noindent
51
55
@command{watchgnupg} is commonly invoked as
69
73
@opindex force
70
74
Delete an already existing socket file.
71
75
 
 
76
@anchor{option watchgnupg --tcp}
 
77
@item --tcp @var{n}
 
78
Instead of reading from a local socket, listen for connects on TCP port
 
79
@var{n}.
 
80
 
72
81
@item --verbose
73
82
@opindex verbose
74
83
Enable extra informational output.
83
92
 
84
93
@end table
85
94
 
 
95
@noindent
 
96
@mansect examples
 
97
@chapheading Examples
 
98
 
 
99
@example
 
100
$ watchgnupg --force /home/foo/.gnupg/S.log
 
101
@end example
 
102
 
 
103
This waits for connections on the local socket
 
104
@file{/home/foo/.gnupg/S.log} and shows all log entries.  To make this
 
105
work the option @option{log-file} needs to be used with all modules
 
106
which logs are to be shown.  The value for that option must be given
 
107
with a special prefix (e.g. in the conf file):
 
108
 
 
109
@example
 
110
log-file socket:///home/foo/.gnupg/S.log
 
111
@end example
 
112
 
 
113
For debugging purposes it is also possible to do remote logging.  Take
 
114
care if you use this feature because the information is send in the
 
115
clear over the network.  Use this syntax in the conf files:
 
116
 
 
117
@example
 
118
log-file tcp://192.168.1.1:4711
 
119
@end example
 
120
 
 
121
You may use any port and not just 4711 as shown above; only IP addresses
 
122
are supported (v4 and v6) and no host names.  You need to start
 
123
@command{watchgnupg} with the @option{tcp} option.  Note that under
 
124
Windows the registry entry @var{HKCU\Software\GNU\GnuPG:DefaultLogFile}
 
125
can be used to change the default log output from @code{stderr} to
 
126
whatever is given by that entry.  However the only useful entry is a TCP
 
127
name for remote debugging.
 
128
 
 
129
 
86
130
@mansect see also
87
131
@ifset isman
88
132
@command{gpg}(1), 
255
299
Run a syntax check on the global configuration file.  If @var{filename}
256
300
is given, check that file instead.
257
301
 
 
302
@item --reload [@var{component}]
 
303
@opindex reload
 
304
Reload all or the given component. This is basically the sam as sending
 
305
a SIGHUP to the component.  Components which don't support reloading are
 
306
ignored.
 
307
 
258
308
@end table
259
309
 
260
310
 
1129
1179
 
1130
1180
@include opt-homedir.texi
1131
1181
 
 
1182
@item --agent-program @var{file}
 
1183
@opindex agent-program
 
1184
Specify the agent program to be started if none is running.
 
1185
 
 
1186
 
1132
1187
@item -S
1133
1188
@itemx --raw-socket @var{name}
1134
1189
@opindex S        
1381
1436
@include see-also-note.texi
1382
1437
@end ifset
1383
1438
 
 
1439
@ifset gpgtwoone
 
1440
@c
 
1441
@c   DIRMNGR-CLIENT
 
1442
@c
 
1443
@node dirmngr-client
 
1444
@section The Dirmngr Client Tool
 
1445
 
 
1446
@manpage dirmngr-client.1
 
1447
@ifset manverb
 
1448
.B dirmngr-client
 
1449
\- Tool to access the Dirmngr services
 
1450
@end ifset
 
1451
 
 
1452
@mansect synopsis
 
1453
@ifset manverb
 
1454
.B  dirmngr-client
 
1455
.RI [ options ]  
 
1456
.RI [ certfile | pattern ]  
 
1457
@end ifset
 
1458
 
 
1459
@mansect description
 
1460
The @command{dirmngr-client} is a simple tool to contact a running
 
1461
dirmngr and test whether a certificate has been revoked --- either by
 
1462
being listed in the corresponding CRL or by running the OCSP protocol.
 
1463
If no dirmngr is running, a new instances will be started but this is
 
1464
in general not a good idea due to the huge performance overhead.
 
1465
 
 
1466
@noindent
 
1467
The usual way to run this tool is either:
 
1468
 
 
1469
@example
 
1470
dirmngr-client @var{acert}
 
1471
@end example
 
1472
 
 
1473
@noindent
 
1474
or
 
1475
 
 
1476
@example
 
1477
dirmngr-client <@var{acert}
 
1478
@end example
 
1479
 
 
1480
Where @var{acert} is one DER encoded (binary) X.509 certificates to be
 
1481
tested. 
 
1482
@ifclear isman
 
1483
The return value of this command is
 
1484
@end ifclear
 
1485
 
 
1486
@mansect return value
 
1487
@ifset isman
 
1488
@command{dirmngr-client} returns these values:
 
1489
@end ifset
 
1490
@table @code
 
1491
 
 
1492
@item 0 
 
1493
The certificate under question is valid; i.e. there is a valid CRL
 
1494
available and it is not listed tehre or teh OCSP request returned that
 
1495
that certificate is valid.
 
1496
 
 
1497
@item 1
 
1498
The certificate has been revoked
 
1499
 
 
1500
@item 2 (and other values)
 
1501
There was a problem checking the revocation state of the certificate.
 
1502
A message to stderr has given more detailed information.  Most likely
 
1503
this is due to a missing or expired CRL or due to a network problem.
 
1504
 
 
1505
@end table
 
1506
 
 
1507
@mansect options
 
1508
@noindent
 
1509
@command{dirmngr-client} may be called with the following options:
 
1510
 
 
1511
 
 
1512
@table @gnupgtabopt
 
1513
@item --version
 
1514
@opindex version
 
1515
Print the program version and licensing information.  Note that you cannot
 
1516
abbreviate this command.
 
1517
 
 
1518
@item --help, -h
 
1519
@opindex help
 
1520
Print a usage message summarizing the most useful command-line options.
 
1521
Note that you cannot abbreviate this command.
 
1522
 
 
1523
@item --quiet, -q
 
1524
@opindex quiet
 
1525
Make the output extra brief by suppressing any informational messages.
 
1526
 
 
1527
@item -v
 
1528
@item --verbose
 
1529
@opindex v
 
1530
@opindex verbose
 
1531
Outputs additional information while running.
 
1532
You can increase the verbosity by giving several
 
1533
verbose commands to @sc{dirmngr}, such as @samp{-vv}.
 
1534
 
 
1535
@item --pem
 
1536
@opindex pem
 
1537
Assume that the given certificate is in PEM (armored) format.
 
1538
 
 
1539
@item --ocsp
 
1540
@opindex ocsp
 
1541
Do the check using the OCSP protocol and ignore any CRLs.
 
1542
 
 
1543
@item --force-default-responder
 
1544
@opindex force-default-responder
 
1545
When checking using the OCSP protocl, force the use of the default OCSP
 
1546
responder.  That is not to use the Reponder as given by the certificate.
 
1547
 
 
1548
@item --ping
 
1549
@opindex ping
 
1550
Check whether the dirmngr daemon is up and running.
 
1551
 
 
1552
@item --cache-cert
 
1553
@opindex cache-cert
 
1554
Put the given certificate into the cache of a running dirmngr.  This is
 
1555
mainly useful for debugging.
 
1556
 
 
1557
@item --validate
 
1558
@opindex validate
 
1559
Validate the given certificate using dirmngr's internal validation code.
 
1560
This is mainly useful for debugging.
 
1561
 
 
1562
@item --load-crl
 
1563
@opindex load-crl
 
1564
This command expects a list of filenames with DER encoded CRL files.
 
1565
With the option @option{--url} URLs are expected in place of filenames
 
1566
and they are loaded directly from the given location.  All CRLs will be
 
1567
validated and then loaded into dirmngr's cache.
 
1568
 
 
1569
@item --lookup
 
1570
@opindex lookup
 
1571
Take the remaining arguments and run a lookup command on each of them.
 
1572
The results are Base-64 encoded outputs (without header lines).  This
 
1573
may be used to retrieve certificates from a server. However the output
 
1574
format is not very well suited if more than one certificate is returned.
 
1575
 
 
1576
@item --url
 
1577
@itemx -u
 
1578
@opindex url
 
1579
Modify the @command{lookup} and @command{load-crl} commands to take an URL.
 
1580
 
 
1581
@item --local
 
1582
@itemx -l
 
1583
@opindex url
 
1584
Let the @command{lookup} command only search the local cache.
 
1585
 
 
1586
@item --squid-mode
 
1587
@opindex squid-mode
 
1588
Run @sc{dirmngr-client} in a mode suitable as a helper program for
 
1589
Squid's @option{external_acl_type} option.
 
1590
 
 
1591
 
 
1592
@end table
 
1593
 
 
1594
@ifset isman
 
1595
@mansect see also
 
1596
@command{dirmngr}(8),
 
1597
@command{gpgsm}(1)
 
1598
@include see-also-note.texi
 
1599
@end ifset
 
1600
@end ifset
1384
1601
 
1385
1602
@c
1386
1603
@c   GPGPARSEMAIL