rpm: assign a real shell to user monkeysphere
[monkeysphere.git] / man / man8 / monkeysphere-authentication.8
1 .TH MONKEYSPHERE-AUTHENTICATION "8" "January 2010" "monkeysphere" "System Commands"
2
3 .SH NAME
4
5 monkeysphere\-authentication - Monkeysphere authentication admin tool.
6
7 .SH SYNOPSIS
8
9 .B monkeysphere\-authentication \fIsubcommand\fP [\fIargs\fP]
10
11 .SH DESCRIPTION
12
13 \fBMonkeysphere\fP is a framework to leverage the OpenPGP Web of Trust
14 (WoT) for key-based authentication.  OpenPGP keys are tracked via
15 GnuPG, and added to the authorized_keys files used by OpenSSH for
16 connection authentication.
17
18 \fBmonkeysphere\-authentication\fP is a Monkeysphere server admin
19 utility for configuring and managing SSH user authentication through
20 the WoT.
21
22 .SH SUBCOMMANDS
23
24 \fBmonkeysphere\-authentication\fP takes various subcommands:
25 .TP
26 .B update\-users [ACCOUNT]...
27 Rebuild the monkeysphere-controlled authorized_keys files.  For each
28 specified account, the user ID's listed in the account's
29 authorized_user_ids file are processed.  For each user ID, gpg will be
30 queried for keys associated with that user ID, optionally querying a
31 keyserver.  If an acceptable key is found (see KEY ACCEPTABILITY in
32 monkeysphere(7)), the key is added to the account's
33 monkeysphere-controlled authorized_keys file.  If the
34 RAW_AUTHORIZED_KEYS variable is set, then a separate authorized_keys
35 file (usually ~USER/.ssh/authorized_keys) is appended to the
36 monkeysphere-controlled authorized_keys file.  If no accounts are
37 specified, then all accounts on the system are processed.  `u' may be
38 used in place of `update\-users'.
39 .TP
40 .B refresh\-keys
41 Refresh all keys in the monkeysphere-authentication keyring.  If no
42 accounts are specified, then all accounts on the system are processed.
43 `r' may be used in place of `refresh\-keys'.
44 .TP
45 .B add\-id\-certifier KEYID|FILE
46 Instruct system to trust user identity certifications made by KEYID.
47 The key ID will be loaded from the keyserver.  A file may be loaded
48 instead of pulling the key from the keyserver by specifying the path
49 to the file as the argument, or by specifying `\-' to load from stdin.
50 Using the `\-n' or `\-\-domain' option allows you to indicate that you
51 only trust the given KEYID to make identifications within a specific
52 domain (e.g. "trust KEYID to certify user identities within the
53 @example.org domain").  A certifier trust level can be specified with
54 the `\-t' or `\-\-trust' option (possible values are `marginal' and
55 `full' (default is `full')).  A certifier trust depth can be specified
56 with the `\-d' or `\-\-depth' option (default is 1).  `c+' may be used in
57 place of `add\-id\-certifier'.
58 .TP
59 .B remove\-id\-certifier KEYID
60 Instruct system to ignore user identity certifications made by KEYID.
61 `c\-' may be used in place of `remove\-id\-certifier'.
62 .TP
63 .B list\-id\-certifiers
64 List key IDs trusted by the system to certify user identities.  `c'
65 may be used in place of `list\-id\-certifiers'.
66 .TP
67 .B version
68 Show the monkeysphere version number.  `v' may be used in place of
69 `version'.
70 .TP
71 .B help
72 Output a brief usage summary.  `h' or `?' may be used in place of
73 `help'.
74
75
76 Other commands:
77 .TP
78 .B setup
79 Setup the server in preparation for Monkeysphere user authentication.
80 This command is idempotent and run automatically by the other
81 commands, and should therefore not usually need to be run manually.
82 `s' may be used in place of `setup'.
83 .TP
84 .B diagnostics
85 Review the state of the server with respect to authentication.  `d'
86 may be used in place of `diagnostics'.
87 .TP
88 .B gpg\-cmd
89 Execute a gpg command, as the monkeysphere user, on the monkeysphere
90 authentication `sphere' keyring.  This takes a single argument
91 (i.e. multiple gpg arguments need to be quoted all together).  Use
92 this command with caution, as modifying the authentication sphere
93 keyring can affect ssh user authentication.
94
95 .SH SETUP USER AUTHENTICATION
96
97 If the server will handle user authentication through
98 monkeysphere-generated authorized_keys files, the server must be told
99 which keys will act as identity certifiers.  This is done with the
100 \fBadd\-id\-certifier\fP command:
101
102 # monkeysphere\-authentication add\-id\-certifier KEYID
103
104 where KEYID is the key ID of the server admin, or whoever's
105 certifications should be acceptable to the system for the purposes of
106 authenticating remote users.  You can run this command multiple times
107 to indicate that multiple certifiers are trusted.  You may also
108 specify a filename instead of a key ID, as long as the file contains a
109 single OpenPGP public key.  Certifiers can be removed with the
110 \fBremove\-id\-certifier\fP command, and listed with the
111 \fBlist\-id\-certifiers\fP command.
112
113 A remote user will be granted access to a local account based on the
114 appropriately-signed and valid keys associated with user IDs listed in
115 that account's authorized_user_ids file.  By default, the
116 authorized_user_ids file for an account is
117 ~/.monkeysphere/authorized_user_ids.  This can be changed in the
118 monkeysphere\-authentication.conf file.
119
120 The \fBupdate\-users\fP command is used to generate authorized_keys
121 files for a local account based on the user IDs listed in the
122 account's authorized_user_ids file:
123
124 # monkeysphere\-authentication update\-users USER
125
126 Not specifying USER will cause all accounts on the system to updated.
127 The ssh server can use these monkeysphere-generated authorized_keys
128 files to grant access to user accounts for remote users.  In order for
129 sshd to look at the monkeysphere-generated authorized_keys file for
130 user authentication, the AuthorizedKeysFile parameter must be set in
131 the sshd_config to point to the monkeysphere\-generated
132 authorized_keys files:
133
134 AuthorizedKeysFile /var/lib/monkeysphere/authorized_keys/%u
135
136 It is recommended to add "monkeysphere\-authentication update\-users"
137 to a system crontab, so that user keys are kept up-to-date, and key
138 revocations and expirations can be processed in a timely manner.
139
140 .SH ENVIRONMENT
141
142 The following environment variables will override those specified in
143 the config file (defaults in parentheses):
144 .TP
145 MONKEYSPHERE_MONKEYSPHERE_USER
146 User to control authentication keychain. (monkeysphere)
147 .TP
148 MONKEYSPHERE_LOG_LEVEL
149 Set the log level.  Can be SILENT, ERROR, INFO, VERBOSE, DEBUG, in
150 increasing order of verbosity. (INFO)
151 .TP
152 MONKEYSPHERE_KEYSERVER
153 OpenPGP keyserver to use. (pool.sks\-keyservers.net)
154 .TP
155 MONKEYSPHERE_AUTHORIZED_USER_IDS
156 Path to user's authorized_user_ids file. %h gets replaced with the
157 user's homedir, %u with the username.
158 (%h/.monkeysphere/authorized_user_ids)
159 .TP
160 MONKEYSPHERE_RAW_AUTHORIZED_KEYS
161 Path to regular ssh-style authorized_keys file to append to
162 monkeysphere-generated authorized_keys.  `none' means not to add any
163 raw authorized_keys file.  %h gets replaced with the user's homedir,
164 %u with the username. (%h/.ssh/authorized_keys)
165 .TP
166 MONKEYSPHERE_PROMPT
167 If set to `false', never prompt the user for confirmation. (true)
168 .TP
169 MONKEYSPHERE_STRICT_MODES
170 If set to `false', ignore too-loose permissions on known_hosts,
171 authorized_keys, and authorized_user_ids files.  NOTE: setting this to
172 false may expose users to abuse by other users on the system. (true)
173
174 .SH FILES
175
176 .TP
177 /etc/monkeysphere/monkeysphere\-authentication.conf
178 System monkeysphere-authentication config file.
179 .TP
180 /etc/monkeysphere/monkeysphere\-authentication\-x509\-anchors.crt
181 If monkeysphere-authentication is configured to query an hkps
182 keyserver, it will use X.509 Certificate Authority certificates in
183 this file to validate any X.509 certificates used by the keyserver.
184 .TP
185 /var/lib/monkeysphere/authorized_keys/USER
186 Monkeysphere-generated user authorized_keys files.
187 .TP
188 ~/.monkeysphere/authorized_user_ids
189 A list of OpenPGP user IDs, one per line.  OpenPGP keys with an
190 exactly-matching User ID (calculated valid by the designated identity
191 certifiers), will have any valid authorization-capable keys or subkeys
192 added to the given user's authorized_keys file.
193
194 .SH AUTHOR
195
196 This man page was written by:
197 Jameson Rollins <jrollins@finestructure.net>,
198 Daniel Kahn Gillmor <dkg@fifthhorseman.net>,
199 Matthew Goins <mjgoins@openflows.com>
200
201 .SH SEE ALSO
202
203 .BR monkeysphere (1),
204 .BR monkeysphere\-host (8),
205 .BR monkeysphere (7),
206 .BR gpg (1),
207 .BR ssh (1),
208 .BR sshd (8),
209 .BR sshd_config (5)