/mandos/trunk

To get this branch, use:
bzr branch http://bzr.recompile.se/loggerhead/mandos/trunk

« back to all changes in this revision

Viewing changes to mandos-options.xml

  • Committer: Teddy Hogeborn
  • Date: 2019-02-09 23:23:26 UTC
  • Revision ID: teddy@recompile.se-20190209232326-z1z2kzpgfixz7iaj
Add support for using raw public keys in TLS (RFC 7250)

Since GnuTLS removed support for OpenPGP keys in TLS (RFC 6091), and
no other library supports it, we have to change the protocol to use
something else.  We choose to use "raw public keys" (RFC 7250).  Since
we still use OpenPGP keys to decrypt the secret password, this means
that each client will have two keys: One OpenPGP key and one TLS
public/private key, and the key ID of the latter key is used to
identify clients instead of the fingerprint of the OpenPGP key.

Note that this code is still compatible with GnuTLS before version
3.6.0 (when OpenPGP key support was removed).  This commit merely adds
support for using raw pulic keys instead with GnuTLS 3.6.6. or later.

* DBUS-API (Signals/ClientNotFound): Change name of first parameter
                                     from "Fingerprint" to "KeyID".
  (Mandos Client Interface/Properties/KeyID): New.
* INSTALL: Document conflict with GnuTLS 3.6.0 (which removed OpenPGP
           key support) up until 3.6.6, when support for raw public
           keys was added.  Also document new dependency of client on
           "gnutls-bin" package (for certtool).
* Makefile (run-client): Depend on TLS key files, and also pass them
                         as arguments to client.
  (keydir/tls-privkey.pem, keydir/tls-pubkey.pem): New.
  (confdir/clients.conf): Add dependency on TLS public key.
  (purge-client): Add removal of TLS key files.
* clients.conf ([foo]/key_id, [bar]/key_id): New.
* debian/control (Source: mandos/Build-Depends): Also allow
                                                 libgnutls30 (>= 3.6.6)
  (Package: mandos/Depends): - '' -
  (Package: mandos/Description): Alter description to match new
                                 design.
  (Package: mandos-client/Description): - '' -
  (Package: mandos-client/Depends): Move "gnutls-bin | openssl" to
                                    here from "Recommends".
* debian/mandos-client.README.Debian: Add --tls-privkey and
                                      --tls-pubkey options to test
                                      command.
* debian/mandos-client.postinst (create_key): Renamed to "create_keys"
                                             (all callers changed),
                                             and also create TLS key.
* debian/mandos-client.postrm (purge): Also remove TLS key files.
* intro.xml (DESCRIPTION): Describe new dual-key design.
* mandos (GnuTLS): Define different functions depending on whether
                   support for raw public keys is detected.
  (Client.key_id): New attribute.
  (ClientDBus.KeyID_dbus_property): New method.
  (ProxyClient.__init__): Take new "key_id" parameter.
  (ClientHandler.handle): Use key IDs when using raw public keys and
                          use fingerprints when using OpenPGP keys.
  (ClientHandler.peer_certificate): Also handle raw public keys.
  (ClientHandler.key_id): New.
  (MandosServer.handle_ipc): Pass key ID over the pipe IPC.  Also
                             check for key ID matches when looking up
                             clients.
  (main): Default GnuTLS priority string depends on whether we are
          using raw public keys or not.  When unpickling clients, set
          key_id if not set in the pickle.
  (main/MandosDBusService.ClientNotFound): Change name of first
                                           parameter from
                                           "Fingerprint" to "KeyID".
* mandos-clients.conf.xml (OPTIONS): Document new "key_id" option.
  (OPTIONS/secret): Mention new key ID matchning.
  (EXPANSION/RUNTIME EXPANSION): Add new "key_id" option.
  (EXAMPLE): - '' -
* mandos-ctl (tablewords, main/keywords): Add new "KeyID" property.
* mandos-keygen: Create TLS key files.  New "--tls-keytype" (-T)
                 option.  Alter help text to be more clear about key
                 types.  When in password mode, also output "key_id"
                 option.
* mandos-keygen.xml (SYNOPSIS): Add new "--tls-keytype" (-T) option.
  (DESCRIPTION): Alter to match new dual-key design.
  (OVERVIEW): - '' -
  (FILES): Add TLS key files.
* mandos-options.xml (priority): Document new default priority string
                                 when using raw public keys.
* mandos.xml (NETWORK PROTOCOL): Describe new protocol using key ID.
  (BUGS): Remove issue about checking expire times of OpenPGP keys,
          since TLS public keys do not have expiration times.
  (SECURITY/CLIENT): Alter description to match new design.
  (SEE ALSO/GnuTLS): - '' -
  (SEE ALSO): Add reference to RFC 7250, and alter description of when
              RFC 6091 is used.
* overview.xml: Alter text to match new design.
* plugin-runner.xml (EXAMPLE): Add --tls-pubkey and --tls-privkey
                               options to mandos-client options.
* plugins.d/mandos-client.c: Use raw public keys when compiling with
                             supporting GnuTLS versions. Add new
                             "--tls-pubkey" and "--tls-privkey"
                             options (which do nothing if GnuTLS
                             library does not support raw public
                             keys).  Alter text throughout to reflect
                             new design.  Only generate new DH
                             parameters (based on size of OpenPGP key)
                             when using OpenPGP in TLS.  Default
                             GnuTLS priority string depends on whether
                             we are using raw public keys or not.
* plugins.d/mandos-client.xml (SYNOPSIS): Add new "--tls-privkey" (-t)
                                          and "--tls-pubkey" (-T)
                                          options.
  (DESCRIPTION): Describe new dual-key design.
  (OPTIONS): Document new "--tls-privkey" (-t) and "--tls-pubkey" (-T)
             options.
  (OPTIONS/--dh-bits): No longer necessarily depends on OpenPGP key
                       size.
  (FILES): Add default locations for TLS public and private key files.
  (EXAMPLE): Use new --tls-pubkey and --tls-privkey options.
  (SECURITY): Alter wording slightly to reflect new dual-key design.
  (SEE ALSO/GnuTLS): Alter description to match new design.
  (SEE ALSO): Add reference to RFC 7250, and alter description of when
              RFC 6091 is used.

Show diffs side-by-side

added added

removed removed

Lines of Context:
26
26
    specified IPv6 address.  If a link-local address is specified, an
27
27
    interface should be set, since a link-local address is only valid
28
28
    on a single interface.  By default, the server will listen to all
29
 
    available addresses.  If set, this must be an IPv6 address; an
30
 
    IPv4 address can only be specified using IPv4-mapped IPv6 address
31
 
    syntax: <quote><systemitem class="ipaddress"
32
 
    >::FFFF:192.0.2.3</systemitem ></quote>.
 
29
    available addresses.  If set, this must normally be an IPv6
 
30
    address; an IPv4 address can only be specified using IPv4-mapped
 
31
    IPv6 address syntax: <quote><systemitem class="ipaddress"
 
32
    >::FFFF:192.0.2.3</systemitem ></quote>.  (Only if IPv6 usage is
 
33
    <emphasis>disabled</emphasis> (see below) must this be an IPv4
 
34
    address.)
33
35
  </para>
34
36
  
35
37
  <para id="port">
46
48
  
47
49
  <para id="priority">
48
50
    GnuTLS priority string for the <acronym>TLS</acronym> handshake.
49
 
    The default is <quote><literal
50
 
    >SECURE256:!CTYPE-X.509:+CTYPE-OPENPGP</literal></quote>.  See
51
 
    <citerefentry><refentrytitle>gnutls_priority_init</refentrytitle>
 
51
    The default is
 
52
    <quote><literal>SECURE128&#8203;:!CTYPE-X.509&#8203;:+CTYPE-RAWPK&#8203;:!RSA&#8203;:!VERS-ALL&#8203;:+VERS-TLS1.3&#8203;:%PROFILE_ULTRA</literal></quote>
 
53
    when using raw public keys in TLS, and
 
54
    <quote><literal>SECURE256&#8203;:!CTYPE-X.509&#8203;:+CTYPE-OPENPGP&#8203;:!RSA&#8203;:+SIGN-DSA-SHA256</literal></quote>
 
55
    when using OpenPGP keys in TLS,.  See <citerefentry><refentrytitle
 
56
    >gnutls_priority_init</refentrytitle>
52
57
    <manvolnum>3</manvolnum></citerefentry> for the syntax.
53
58
    <emphasis>Warning</emphasis>: changing this may make the
54
59
    <acronym>TLS</acronym> handshake fail, making server-client
55
 
    communication impossible.
 
60
    communication impossible.  Changing this option may also make the
 
61
    network traffic decryptable by an attacker.
56
62
  </para>
57
63
  
58
64
  <para id="servicename">
59
65
    Zeroconf service name.  The default is
60
66
    <quote><literal>Mandos</literal></quote>.  This only needs to be
61
 
    changed this if it, for some reason, is necessary to run more than
62
 
    one server on the same <emphasis>host</emphasis>, which would not
 
67
    changed if for some reason is would be necessary to run more than
 
68
    one server on the same <emphasis>host</emphasis>.  This would not
63
69
    normally be useful.  If there are name collisions on the same
64
70
    <emphasis>network</emphasis>, the newer server will automatically
65
71
    rename itself to <quote><literal>Mandos #2</literal></quote>, and
66
72
    so on; therefore, this option is not needed in that case.
67
73
  </para>
68
74
  
 
75
  <para id="dbus">
 
76
    This option controls whether the server will provide a D-Bus
 
77
    system bus interface.  The default is to provide such an
 
78
    interface.
 
79
  </para>
 
80
  
 
81
  <para id="ipv6">
 
82
    This option controls whether the server will use IPv6 sockets and
 
83
    addresses.  The default is to use IPv6.  This option should
 
84
    <emphasis>never</emphasis> normally be turned off, <emphasis>even in
 
85
    IPv4-only environments</emphasis>.  This is because <citerefentry>
 
86
    <refentrytitle>mandos-client</refentrytitle>
 
87
    <manvolnum>8mandos</manvolnum></citerefentry> will normally use
 
88
    IPv6 link-local addresses, and will not be able to find or connect
 
89
    to the server if this option is turned off.  <emphasis>Only
 
90
    advanced users should consider changing this option</emphasis>.
 
91
  </para>
 
92
  
 
93
  <para id="restore">
 
94
    This option controls whether the server will restore its state
 
95
    from the last time it ran.  Default is to restore last state.
 
96
  </para>
 
97
  
 
98
  <para id="statedir">
 
99
    Directory to save (and restore) state in.  Default is
 
100
    <quote><filename
 
101
    class="directory">/var/lib/mandos</filename></quote>.
 
102
  </para>
 
103
  
 
104
  <para id="socket">
 
105
    If this option is used, the server will not create a new network
 
106
    socket, but will instead use the supplied file descriptor.  By
 
107
    default, the server will create a new network socket.
 
108
  </para>
 
109
  
 
110
  <para id="foreground">
 
111
    This option will make the server run in the foreground and not
 
112
    write a PID file.  The default is to <emphasis>not</emphasis> run
 
113
    in the foreground, except in <option>debug</option> mode, which
 
114
    implies this option.
 
115
  </para>
 
116
  
 
117
  <para id="zeroconf">
 
118
    This option controls whether the server will announce its
 
119
    existence using Zeroconf.  Default is to use Zeroconf.  If
 
120
    Zeroconf is not used, a <option>port</option> number or a
 
121
    <option>socket</option> is required.
 
122
  </para>
 
123
  
69
124
</section>