ad36e698176cf3a6f0f0ace1c6b4e690fae2364c
[debian/amanda] / man / amgpgcrypt.8
1 .\"     Title: amgpgcrypt
2 .\"    Author: 
3 .\" Generator: DocBook XSL Stylesheets v1.73.2 <http://docbook.sf.net/>
4 .\"      Date: 08/22/2008
5 .\"    Manual: 
6 .\"    Source: 
7 .\"
8 .TH "AMGPGCRYPT" "8" "08/22/2008" "" ""
9 .\" disable hyphenation
10 .nh
11 .\" disable justification (adjust text to left margin only)
12 .ad l
13 .SH "NAME"
14 amgpgcrypt - reference crypt program for Amanda public-key data encryption
15 .SH "SYNOPSIS"
16 .HP 11
17 \fBamgpgcrypt\fR  to be called by \fIAmanda\fR only 
18 .SH "DESCRIPTION"
19 .PP
20
21 \fBamgpgcrypt\fR
22 calls
23 \fBgpg\fR
24 to perform public\-key data encryption on
25 \fIAmanda\fR
26 backup\.
27 \fBamgpgcrypt\fR
28 will search for the gpg program in the following directories: /usr/local/bin:/usr/bin:/usr/sbin:/bin:/sbin
29 .PP
30
31 \fBamgpgcrypt\fR
32 sets GNUPGHOME to $AMANDA_HOME/\.gnupg where gpg will look for the gpg keys\.
33 \fBamgpgcrypt\fR
34 uses the public key to encrypt the
35 \fIAmanda\fR
36 data and uses the private key to decrypt the
37 \fIAmanda\fR
38 backup data\. Thus, passphrase is only required at the time of data restore\.
39 .SH "KEY AND PASSPHRASE"
40 .PP
41
42 \fBamgpgcrypt\fR
43 uses the private key to decrypt
44 \fIAmanda\fR
45 backup data\.
46
47 It is very important to store, manage and  protect the key and the passphrase
48 properly\. Encrypted backup data can \fBonly\fR be recovered with the correct key and
49 passphrase\.
50 .SH "HOW TO CREATE ENCRYPTION KEYS AND PASSPHRASE FOR AMGPGCRYPT"
51 .PP
52 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:
53
54    echo my_secret_passphrase > ~$amanda_user/\.am_passphrase
55    chown $amanda_user:disk ~$amanda_user/\.am_passphrase
56    chmod 700 ~$amanda_user/\.am_passphrase
57 .PP
58 Run "gpg \-\-gen\-key"\. Below is an example:
59 .nf
60 $ gpg \-\-gen\-key
61 gpg (GnuPG) 1\.2\.6; Copyright (C) 2004 Free Software Foundation, Inc\.
62 This program comes with ABSOLUTELY NO WARRANTY\.
63 This is free software, and you are welcome to redistribute it
64 under certain conditions\. See the file COPYING for details\.
65
66 Please select what kind of key you want:
67    (1) DSA and ElGamal (default)
68    (2) DSA (sign only)
69    (4) RSA (sign only)
70 Your selection? 1
71 DSA keypair will have 1024 bits\.
72 About to generate a new ELG\-E keypair\.
73               minimum keysize is  768 bits
74               default keysize is 1024 bits
75     highest suggested keysize is 2048 bits
76 What keysize do you want? (1024)
77 Requested keysize is 1024 bits
78 Please specify how long the key should be valid\.
79          0 = key does not expire
80       (n)  = key expires in n days
81       (n)w = key expires in n weeks
82       (n)m = key expires in n months
83       (n)y = key expires in n years
84 Key is valid for? (0) 6m
85 Key expires at Sun 06 Aug 2006 03:51:25 PM PDT
86 Is this correct (y/n)? y
87
88 You need a User\-ID to identify your key; the software constructs the user id
89 from Real Name, Comment and Email Address in this form:
90     "Heinrich Heine (Der Dichter) (heinrichh@duesseldorf\.de)"
91
92 Real name: amandabackup
93 Email address:
94 Comment: gpg keys for amandabackup
95 You selected this USER\-ID:
96     "amandabackup (gpg keys for amandabackup)"
97
98 Change (N)ame, (C)omment, (E)mail or (O)kay/(Q)uit? o
99 You need a Passphrase to protect your secret key\.
100
101 We need to generate a lot of random bytes\. It is a good idea to perform
102 some other action (type on the keyboard, move the mouse, utilize the
103 disks) during the prime generation; this gives the random number
104 generator a better chance to gain enough entropy\.
105
106 We need to generate a lot of random bytes\. It is a good idea to perform
107 some other action (type on the keyboard, move the mouse, utilize the
108 disks) during the prime generation; this gives the random number
109 generator a better chance to gain enough entropy\.
110
111 public and secret key created and signed\.
112 key marked as ultimately trusted\.
113
114 pub  1024D/4417A8CB 2006\-02\-07 amandabackup (gpg keys for amandabackup)
115      Key fingerprint = 139C 6369 44FC 7F1A 655C  E5E9 7EAA 515A 4417 A8CB
116 sub  1024g/8C3A6A78 2006\-02\-07 [expires: 2006\-08\-06]
117 .fi
118 .SH "FILES"
119 .PP
120 \fB$AMANDA_HOME/\.gnupg/pubring\.gpg\fR
121 .RS 4
122 The public key\.
123 \fBamgpgcrypt\fR
124 encrypt data with this public key along with the cipher algorithm\.
125 .RE
126 .PP
127 \fB$AMANDA_HOME/\.gnupg/secring\.gpg\fR
128 .RS 4
129 The private/secret key\. It\'s only needed during amrecover/amrestore\. Store and protect it properly during other time\.
130 .RE
131 .PP
132 \fB$AMANDA_HOME/\.am_passphrase\fR
133 .RS 4
134 The passphrase\. It\'s only needed during amrecover/amrestore\. Store and protect it properly during other time\.
135 .RE
136 .SH "BUGS"
137 .PP
138 \fIAmanda\fR
139 has problem with gpg mdc(modification detection code) in the binary mode\.
140 \fBamgpgcrypt\fR
141 calls gpg with mdc disabled
142 .SH "AUTHOR"
143 .PP
144 The tool and its documentation was written by Zmanda, Inc (http://www\.zmanda\.com/)\.
145 .SH "SEE ALSO"
146 .PP
147
148 \fBamanda\fR(8),
149 \fBamanda.conf\fR(5),
150 \fBamcrypt\fR(8),
151 \fBamrestore\fR(8),
152 \fBgpg\fR(1),
153 : http://wiki.zmanda.com