summaryrefslogtreecommitdiff
path: root/man/man8/monkeysphere-server.8
blob: 74e9a10109b8353945fec28f3c5c7458eb75a9d0 (plain)
  1. .TH MONKEYSPHERE-SERVER "8" "June 2008" "monkeysphere" "User Commands"
  2. .SH NAME
  3. monkeysphere-server \- Monkeysphere server admin user interface
  4. .SH SYNOPSIS
  5. .B monkeysphere-server \fIsubcommand\fP [\fIargs\fP]
  6. .SH DESCRIPTION
  7. \fBMonkeysphere\fP is a framework to leverage the OpenPGP web of trust
  8. for OpenSSH authentication. OpenPGP keys are tracked via GnuPG, and
  9. added to the authorized_keys and known_hosts files used by OpenSSH for
  10. connection authentication.
  11. \fBmonkeysphere-server\fP is the Monkeysphere server admin utility.
  12. .SH SUBCOMMANDS
  13. \fBmonkeysphere-server\fP takes various subcommands:
  14. .TP
  15. .B update-users [ACCOUNT]...
  16. Rebuild the monkeysphere-controlled authorized_keys files. For each
  17. specified account, the user ID's listed in the account's
  18. authorized_user_ids file are processed. For each user ID, gpg will be
  19. queried for keys associated with that user ID, optionally querying a
  20. keyserver. If an acceptable key is found (see KEY ACCEPTABILITY in
  21. monkeysphere(5)), the key is added to the account's
  22. monkeysphere-controlled authorized_keys file. If the
  23. RAW_AUTHORIZED_KEYS variable is set, then a separate authorized_keys
  24. file (usually ~USER/.ssh/authorized_keys) is appended to the
  25. monkeysphere-controlled authorized_keys file. If no accounts are
  26. specified, then all accounts on the system are processed. `u' may be
  27. used in place of `update-users'.
  28. .TP
  29. .B gen-key [HOSTNAME]
  30. Generate a OpenPGP key pair for the host. If HOSTNAME is not
  31. specified, then the system fully-qualified domain name will be user.
  32. An alternate key bit length can be specified with the `-l' or
  33. `--length' option (default 2048). An expiration length can be
  34. specified with the `-e' or `--expire' option (prompt otherwise). A
  35. key revoker fingerprint can be specified with the `-r' or `--revoker'
  36. option. `g' may be used in place of `gen-key'.
  37. .TP
  38. .B show-fingerprint
  39. Show the fingerprint for the host's OpenPGP key. `f' may be used in place of
  40. `show-fingerprint'.
  41. .TP
  42. .B publish-key
  43. Publish the host's OpenPGP key to the keyserver. `p' may be used in
  44. place of `publish-key'.
  45. .TP
  46. .B diagnostics
  47. Review the state of the server with respect to the MonkeySphere in
  48. general and report on suggested changes. Among other checks, this
  49. includes making sure there is a valid host key, that the key is
  50. published, that the sshd configuration points to the right place, and
  51. that there are at least some valid identity certifiers. `d' may be
  52. used in place of `diagnostics'.
  53. .TP
  54. .B add-identity-certifier KEYID
  55. Instruct system to trust user identity certifications made by KEYID.
  56. Using the `-n' or `--domain' option allows you to indicate that you
  57. only trust the given KEYID to make identifications within a specific
  58. domain (e.g. "trust KEYID to certify user identities within the
  59. @example.org domain"). A certifier trust level can be specified with
  60. the `-t' or `--trust' option (possible values are `marginal' and
  61. `full' (default is `full')). A certifier trust depth can be specified
  62. with the `-d' or `--depth' option (default is 1). `c+' may be used in
  63. place of `add-identity-certifier'.
  64. .TP
  65. .B remove-identity-certifier KEYID
  66. Instruct system to ignore user identity certifications made by KEYID.
  67. `c-' may be used in place of `remove-identity-certifier'.
  68. .TP
  69. .B list-identity-certifiers
  70. List key IDs trusted by the system to certify user identities. `c'
  71. may be used in place of `list-identity-certifiers'.
  72. .TP
  73. .B gpg-authentication-cmd
  74. Execute a gpg command on the gnupg-authentication keyring as the
  75. monkeysphere user. This takes a single command (multiple gpg
  76. arguments need to be quoted). Use this command with caution, as
  77. modifying the gnupg-authentication keyring can affect ssh user
  78. authentication.
  79. .TP
  80. .B help
  81. Output a brief usage summary. `h' or `?' may be used in place of
  82. `help'.
  83. .SH SETUP
  84. In order to start using the monkeysphere, you must first generate an
  85. OpenPGP key for the server and convert that key to an ssh key that can
  86. be used by ssh for host authentication. This can be done with the
  87. \fBgen-key\fP subcommand:
  88. $ monkeysphere-server gen-key
  89. To enable host verification via the monkeysphere, you must then
  90. publish the host's key to the Web of Trust using the \fBpublish-key\fP
  91. command to push the key to a keyserver. You must also modify the
  92. sshd_config on the server to tell sshd where the new server host key
  93. is located:
  94. HostKey /var/lib/monkeysphere/ssh_host_rsa_key
  95. In order for users logging into the system to be able to verify the
  96. host via the monkeysphere, at least one person (e.g. a server admin)
  97. will need to sign the host's key. This is done using standard key
  98. signing techniquies, usually by pulling the key from the keyserver,
  99. signing the key, and re-publishing the signature. Once that is done,
  100. users logging into the host will be able to certify the host's key via
  101. the signature of the host admin.
  102. If the server will also handle user authentication through
  103. monkeysphere-generated authorized_keys files, the server must be told
  104. which keys will act as user certifiers. This is done with the
  105. \fBadd-certifier\fP command:
  106. $ monkeysphere-server add-certifier KEYID
  107. where KEYID is the key ID of the server admin, or whoever's signature
  108. will be certifying users to the system. Certifiers can be removed
  109. with the \fBremove-certifier\fP command, and listed with the
  110. \fBlist-certifiers\fP command.
  111. Remote user's will then be granted access to a local user account
  112. based on the appropriately signed and valid keys associated with user
  113. IDs listed in the authorized_user_ids file of the local user. By
  114. default, the authorized_user_ids file for local users is found in
  115. ~/.config/monkeysphere/authorized_user_ids. This can be changed in
  116. the monkeysphere-server.conf file.
  117. The \fBupdate-users\fP command can then be used to generate
  118. authorized_keys file for local users based on the authorized user IDs
  119. listed in the various local user's authorized_user_ids file:
  120. $ monkeysphere-server update-users USER
  121. Not specifying a specific user will cause all users on the system to
  122. updated. sshd can then use these monkeysphere generated
  123. authorized_keys files to grant access to user accounts for remote
  124. users. You must also tell sshd to look at the monkeysphere-generated
  125. authorized_keys file for user authentication by setting the following
  126. in the sshd_config:
  127. AuthorizedKeysFile /var/lib/monkeysphere/authorized_keys/%u
  128. It is recommended to add "monkeysphere-server update-users" to a
  129. system crontab, so that user keys are kept up-to-date, and key
  130. revocations and expirations can be processed in a timely manor.
  131. .SH ENVIRONMENT
  132. The following environment variables will override those specified in
  133. the monkeysphere-server.conf configuration file (defaults in
  134. parentheses):
  135. .TP
  136. MONKEYSPHERE_KEYSERVER
  137. OpenPGP keyserver to use (subkeys.pgp.net).
  138. .TP
  139. MONKEYSPHERE_AUTHORIZED_USER_IDS
  140. Path to user authorized_user_ids file
  141. (%h/.config/monkeysphere/authorized_user_ids).
  142. .TP
  143. MONKEYSPHERE_RAW_AUTHORIZED_KEYS
  144. Path to user-controlled authorized_keys file. `-' means not to add
  145. user-controlled file (%h/.ssh/authorized_keys).
  146. .TP
  147. MONKEYSPHERE_MONKEYSPHERE_USER
  148. User to control authentication keychain (monkeysphere).
  149. .SH FILES
  150. .TP
  151. /etc/monkeysphere/monkeysphere-server.conf
  152. System monkeysphere-server config file.
  153. .TP
  154. /etc/monkeysphere/monkeysphere.conf
  155. System-wide monkeysphere config file.
  156. .TP
  157. /var/lib/monkeysphere/authorized_keys/USER
  158. Monkeysphere-generated user authorized_keys files.
  159. .TP
  160. /var/lib/monkeysphere/ssh_host_rsa_key
  161. Copy of the host's private key in ssh format, suitable for use by
  162. sshd.
  163. .TP
  164. /var/lib/monkeysphere/gnupg-host
  165. Monkeysphere host GNUPG home directory.
  166. .TP
  167. /var/lib/monkeysphere/gnupg-authentication
  168. Monkeysphere authentication GNUPG home directory.
  169. .SH AUTHOR
  170. Written by Jameson Rollins <jrollins@fifthhorseman.net>, Daniel Kahn
  171. Gillmor <dkg@fifthhorseman.net>
  172. .SH SEE ALSO
  173. .BR monkeysphere (1),
  174. .BR monkeysphere (5),
  175. .BR gpg (1),
  176. .BR ssh (1)