Imported Upstream version 2.6.0p1
[debian/amanda] / man / xml-source / amgpgcrypt.8.xml
1 <?xml version="1.0" encoding="ISO-8859-1"?>
2 <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN"
3                    "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd"
4 [
5   <!-- entities files to use -->
6   <!ENTITY % global_entities SYSTEM '../entities/global.entities'>
7   %global_entities;
8 ]>
9
10 <refentry id='amgpgcrypt.8'>
11 <refmeta>
12 <refentrytitle>amgpgcrypt</refentrytitle>
13 <manvolnum>8</manvolnum>
14 </refmeta>
15 <refnamediv>
16 <refname>amgpgcrypt</refname>
17 <refpurpose>reference crypt program for &A; public-key data encryption</refpurpose>
18 </refnamediv>
19 <!-- body begins here -->
20 <refsynopsisdiv>
21 <cmdsynopsis>
22   <command>amgpgcrypt</command>  to be called by &A; only 
23 </cmdsynopsis>
24 </refsynopsisdiv>
25
26 <refsect1><title>DESCRIPTION</title>
27 <para>&amgpgcrypt;
28 calls <emphasis remap='B'>gpg</emphasis> to perform public-key data encryption
29 on &A; backup.
30 &amgpgcrypt; will search for the gpg program in the following directories:
31 /usr/local/bin:/usr/bin:/usr/sbin:/bin:/sbin</para>
32 <para>&amgpgcrypt; sets GNUPGHOME to $AMANDA_HOME/.gnupg where gpg will look for the
33 gpg keys.
34 &amgpgcrypt; uses the public key to encrypt the &A; data
35 and uses the private key to decrypt the &A; backup data. Thus, passphrase is only
36 required at the time of data restore.</para> 
37 </refsect1>
38
39
40 <refsect1><title>Key and Passphrase</title>
41 <para>&amgpgcrypt; uses the  private key to decrypt &A; backup data.</para>
42 It is very important to store, manage and  protect the key and the passphrase
43 properly. Encrypted backup data can <emphasis remap='B'>only</emphasis> be recovered with the correct key and
44 passphrase.
45 </refsect1>
46
47
48
49 <refsect1><title>How to create encryption keys and Passphrase for amgpgcrypt</title>
50
51 <para>Store the  passphrase that you used in following "gpg --gen-key" command  inside the home-directory of the AMANDA-user($amanda_user) and protect it with proper permissions:</para>
52    echo my_secret_passphrase > ~$amanda_user/.am_passphrase
53    chown $amanda_user:disk ~$amanda_user/.am_passphrase
54    chmod 700 ~$amanda_user/.am_passphrase
55 <para> Run "gpg --gen-key". Below is an example:</para>
56 <programlisting>
57 $ gpg --gen-key
58 gpg (GnuPG) 1.2.6; Copyright (C) 2004 Free Software Foundation, Inc.
59 This program comes with ABSOLUTELY NO WARRANTY.
60 This is free software, and you are welcome to redistribute it
61 under certain conditions. See the file COPYING for details.
62
63 Please select what kind of key you want:
64    (1) DSA and ElGamal (default)
65    (2) DSA (sign only)
66    (4) RSA (sign only)
67 Your selection? 1
68 DSA keypair will have 1024 bits.
69 About to generate a new ELG-E keypair.
70               minimum keysize is  768 bits
71               default keysize is 1024 bits
72     highest suggested keysize is 2048 bits
73 What keysize do you want? (1024)
74 Requested keysize is 1024 bits
75 Please specify how long the key should be valid.
76          0 = key does not expire
77       (n)  = key expires in n days
78       (n)w = key expires in n weeks
79       (n)m = key expires in n months
80       (n)y = key expires in n years
81 Key is valid for? (0) 6m
82 Key expires at Sun 06 Aug 2006 03:51:25 PM PDT
83 Is this correct (y/n)? y
84
85 You need a User-ID to identify your key; the software constructs the user id
86 from Real Name, Comment and Email Address in this form:
87     "Heinrich Heine (Der Dichter) (heinrichh@duesseldorf.de)"
88
89 Real name: amandabackup
90 Email address:
91 Comment: gpg keys for amandabackup
92 You selected this USER-ID:
93     "amandabackup (gpg keys for amandabackup)"
94
95 Change (N)ame, (C)omment, (E)mail or (O)kay/(Q)uit? o
96 You need a Passphrase to protect your secret key.
97
98 We need to generate a lot of random bytes. It is a good idea to perform
99 some other action (type on the keyboard, move the mouse, utilize the
100 disks) during the prime generation; this gives the random number
101 generator a better chance to gain enough entropy.
102
103 We need to generate a lot of random bytes. It is a good idea to perform
104 some other action (type on the keyboard, move the mouse, utilize the
105 disks) during the prime generation; this gives the random number
106 generator a better chance to gain enough entropy.
107
108 public and secret key created and signed.
109 key marked as ultimately trusted.
110
111 pub  1024D/4417A8CB 2006-02-07 amandabackup (gpg keys for amandabackup)
112      Key fingerprint = 139C 6369 44FC 7F1A 655C  E5E9 7EAA 515A 4417 A8CB
113 sub  1024g/8C3A6A78 2006-02-07 [expires: 2006-08-06]
114
115 </programlisting>
116 </refsect1>
117
118
119 <refsect1><title>Files</title>
120 <variablelist remap='TP'>
121  <varlistentry>
122  <term><option>$AMANDA_HOME/.gnupg/pubring.gpg</option></term>
123   <listitem>
124 <para>The public key. &amgpgcrypt; encrypt data with this public key along with the
125 cipher algorithm.</para>
126   </listitem>
127   </varlistentry>
128
129  <varlistentry>
130  <term><option>$AMANDA_HOME/.gnupg/secring.gpg</option></term>
131   <listitem>
132 <para>The private/secret key. It's only needed during amrecover/amrestore. Store
133 and protect it properly during other time.</para>
134   </listitem>
135   </varlistentry>
136
137  <varlistentry>
138  <term><option>$AMANDA_HOME/.am_passphrase</option></term>
139   <listitem>
140 <para>The passphrase. It's only needed during amrecover/amrestore. Store
141 and protect it properly during other time.</para>
142   </listitem>
143   </varlistentry>
144
145
146 </variablelist>
147 </refsect1>
148
149
150 <refsect1><title>BUGS</title>
151 <para>&A; has problem with gpg mdc(modification detection code) in the binary
152 mode. &amgpgcrypt; calls gpg with mdc disabled</para>
153 </refsect1>
154
155 <refsect1><title>AUTHOR</title>
156   <para>
157     The tool and its documentation was written by Zmanda, Inc (http://www.zmanda.com/). 
158   </para>
159 </refsect1>
160
161 <refsect1><title>SEE ALSO</title>
162 <para>
163   <citerefentry><refentrytitle>amanda</refentrytitle><manvolnum>8</manvolnum></citerefentry>,
164   <citerefentry><refentrytitle>amanda.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
165   <citerefentry><refentrytitle>amcrypt</refentrytitle><manvolnum>8</manvolnum></citerefentry>,
166   <citerefentry><refentrytitle>amrestore</refentrytitle><manvolnum>8</manvolnum></citerefentry>,
167   <citerefentry><refentrytitle>gpg</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
168   <ulink url="http://wiki.zmanda.com"/>
169 </para>
170 </refsect1>
171 </refentry>
172