PGPDAEMON(8)

NAME
PGPdaemon - daemon for automatic signing and decryption with PGP

SYNOPSIS
pgpdaemon [ -mailwait ] [ -detach ] [ -nomail ] [ -no_filelocking ] [ -pgppath <path> ] [ -uid <uid> ]

DESCRIPTION
The pgpdaemon programme is a daemon, run by the user, which can automatically sign or decrypt PGP messages. PGPdaemon is part of the PGPsendmail/Unix Suite.

PGPdaemon will periodically read the users' incoming mail spool directory and will move the contents to another spool file, decrypting any messages that it can.

OPTIONS

-mailwait
    This option will prevent PGPdaemon from processing any incoming mail until it has received a passphrase from sendpgppass. If this option is not specified, upon startup PGPdaemon will process any mail in the users' spoolfile and will not decrypt any messages. This can be annoying.

-detach
    This option will detach PGPdaemon from the parent process. PGPdaemon will run until signalled with SIGTERM or SIGKILL. Note that PGPdaemon does not put itself in the background.

-nomail
    This option disables processing of the incoming mail spool area by PGPdaemon.

-no_filelocking
    This option disables file locking checks on the input and output spool files. PGPdaemon will only use lockfiles with this option. This option is useful with broken mail readers which lock their input spool (the output spool file for PGPdaemon) unecessarily.

-pgppath <path>
    This option sets the PGPPATH environment variable for PGPdaemon and all its child processes. This is an alternative to setting the PGPPATH environment variable externally. The value of <path> must be a directory containing the path specification.

-uid <uid>
    This option sets the real-user-id to uid. This is helpful in supporting encrypted mailing lists.

CONFIGURATION
The configuration file $PGPPATH/PGPdaemon.config (which must exist) configures the pgpdaemon programme. It is a simple ASCII file with one configuration option per line. Comment lines must start with a leading '#' character. Comment lines and blank lines are ignored. Each configuration option is a keyword followed by zero or more parameters, depending on the option. The following section details the configuration options. Below are the permitted keywords:

USERID PGPuserID
    PGPuserID specifies the PGP user ID to use when signing and decrypting. This option is mandatory. You may provide $env for the PGPuserID, in which case the value of the env environment variable is used. A typical use for this would be $LOGNAME which would set the PGP user ID to your username.

MAILWAIT
    This option will prevent PGPdaemon from processing any incoming mail until it has received a passphrase from sendpgppass. If this option is not specified, upon startup PGPdaemon will process any mail in the users' spoolfile and will not decrypt any messages. This can be annoying.

OUT_SPOOL_FILE spoolfile
    Processed mail will be written to the spoolfile. A leading "~/" is permitted. If this is not specified, mail is written to $HOME/decrypted-mail.

IN_SPOOL_DIR spooldir
    Incoming mail is read from spooldir/$LOGNAME. A leading "~/" is permitted. If this is not set, the contents of your MAIL environment variable, if it exists, is used for the entire file name. If neither exist, the default /usr/spool/mail/$LOGNAME is used for incoming mail.

MAIL_CHECK_INTERVAL interval
    Checks of the incoming spool file are done every interval seconds.

LOG_FILE logfile
    Specifies the logfile to write logging output to. logfile may be a plain filename, or a simple shell-like expression, where "~" and environment variable expansion is supported. Variable names may be enclosed in a matching pair of '{' and '}' braces. If this option is not specified, the default is $PGPPATH/PGPdaemon.log.<hostname>.

SIGNALS
PGPdaemon responds to signals in a variety of ways:

SIGINT
    PGPdaemon will exit cleanly.

SIGTERM
    PGPdaemon will exit cleanly.

SIGPIPE
    PGPdaemon will exit cleanly.

SIGHUP
    PGPdaemon will clean up and restart by calling exec(2).

SIGTTIN
    Caught and discarded.

SIGTTOU
    Caught and discarded.

SIGUSR1
    PGPdaemon will write the secret keyring file if it doesn't already exist and if PGPdaemon has it stored internally.

SIGUSR2
    PGPdaemon will perform an immediate check for incoming mail.

SIGIO
    PGPdaemon will read a request from its pipe.

SIGSEGV
    PGPdaemon attempts an emergency cleanup, logging the event if possible. This is for diagnostic purposes (a segmentation violation should never happen).

FILES
/usr/spool/mail/<user>
    the users' incoming mail spool
$HOME/decrypted-mail
    mail spool after decryption
$PGPPATH/pubring.pgp
    the users' public keyring file
$PGPPATH/randseed.bin
    the seed file for PGP
$PGPPATH/PGPdaemon.config
    the users' configuration file
$PGPPATH/PGPdaemon.log.<hostname>
    log of activity/errors
$PGPPATH/PGPsendmail.debug
    enable debugging if exists
/tmp/PGPsendmail.debug.<UID>
    debugging output file
pgpsendmail/doc/README.PGPdaemon
    distribution README (has more info.)

ENVIRONMENT
The PGPPATH environment variable must be set to the directory containing your secret keyring. The MAIL environment variable may contain the name of your input mail spool file.

SEE ALSO
sendmail(8), pgp(1), pgpsendmail(1), sendpgppass(1), pgppipe(1)

AUTHOR
Richard Gooch (rgooch@atnf.csiro.au)

AVAILABILITY
The PGPsendmail/Unix Suite is available for anonymous ftp from: ftp.atnf.csiro.au:pub/people/rgooch ftp.dhp.com:pub/crypto/pgp/PGPsendmail ftp.ox.ac.uk:pub/crypto/pgp/utils linux.nrao.edu:pub/src/pgp/PGPsendmail