]> tinc-vpn.org Git - tinc/commitdiff
Make the ExperimentalProtocol option obsolete.
authorGuus Sliepen <guus@tinc-vpn.org>
Sun, 22 Aug 2021 20:44:04 +0000 (22:44 +0200)
committerGuus Sliepen <guus@tinc-vpn.org>
Sun, 29 May 2022 16:05:50 +0000 (18:05 +0200)
Remove mentions of it from the documentation, but keep supporting the
option for now, as this makes it easier to test compatibility with the
legacy protocol.

doc/tinc.conf.5.in
doc/tinc.texi
src/tincctl.c
test/integration/algorithms.py
test/integration/legacy_protocol.py
test/integration/splice.py

index a45202b6565441a6f0cc08c962f78f3b393fc7e7..c6af6d7c258108c5e3ffeebb4a1b1fd4b39fbf7e 100644 (file)
@@ -287,15 +287,6 @@ When combined with the IndirectData option,
 packets for nodes for which we do not have a meta connection with are also dropped.
 .It Va Ed25519PrivateKeyFile Li = Ar filename Po Pa @sysconfdir@/tinc/ Ns Ar NETNAME Ns Pa /ed25519_key.priv Pc
 The file in which the private Ed25519 key of this tinc daemon resides.
-This is only used if
-.Va ExperimentalProtocol
-is enabled.
-.It Va ExperimentalProtocol Li = yes | no Pq yes
-When this option is enabled, the SPTPS protocol will be used when connecting to nodes that also support it.
-Ephemeral ECDH will be used for key exchanges,
-and Ed25519 will be used instead of RSA for authentication.
-When enabled, an Ed25519 key must have been generated before with
-.Nm tinc generate-ed25519-keys .
 .It Va Forwarding Li = off | internal | kernel Po internal Pc Bq experimental
 This option selects the way indirect packets are forwarded.
 .Bl -tag -width indent
@@ -610,8 +601,7 @@ Furthermore, specifying
 .Qq none
 will turn off packet encryption.
 It is best to use only those ciphers which support CBC mode.
-This option has no effect for connections between nodes using
-.Va ExperimentalProtocol .
+This option only affects communication using the legacy protocol.
 .It Va ClampMSS Li = yes | no Pq yes
 This option specifies whether tinc should clamp the maximum segment size (MSS)
 of TCP packets to the path MTU. This helps in situations where ICMP
@@ -626,8 +616,7 @@ Any digest supported by LibreSSL or OpenSSL is recognised.
 Furthermore, specifying
 .Qq none
 will turn off packet authentication.
-This option has no effect for connections between nodes using
-.Va ExperimentalProtocol .
+This option only affects communication using the legacy protocol.
 .It Va IndirectData Li = yes | no Pq no
 When set to yes, only nodes which already have a meta connection to you
 will try to establish direct communication with you.
@@ -637,8 +626,7 @@ The length of the message authentication code used to authenticate UDP packets.
 Can be anything from
 .Qq 0
 up to the length of the digest produced by the digest algorithm.
-This option has no effect for connections between nodes using
-.Va ExperimentalProtocol .
+This option only affects communication using the legacy protocol.
 .It Va PMTU Li = Ar mtu Po 1514 Pc
 This option controls the initial path MTU to this node.
 .It Va PMTUDiscovery Li = yes | no Po yes Pc
index ab3dca233c0c2858bdb79166d5c761973d46f38b..c1e62a521d4680608340768e03e1e638c3006667 100644 (file)
@@ -1025,15 +1025,6 @@ packets for nodes for which we do not have a meta connection with are also dropp
 @cindex Ed25519PrivateKeyFile
 @item Ed25519PrivateKeyFile = <@var{path}> (@file{@value{sysconfdir}/tinc/@var{netname}/ed25519_key.priv})
 The file in which the private Ed25519 key of this tinc daemon resides.
-This is only used if ExperimentalProtocol is enabled.
-
-@cindex ExperimentalProtocol
-@item ExperimentalProtocol = <yes|no> (yes)
-When this option is enabled, the SPTPS protocol will be used when connecting to nodes that also support it.
-Ephemeral ECDH will be used for key exchanges,
-and Ed25519 will be used instead of RSA for authentication.
-When enabled, an Ed25519 key must have been generated before with
-@command{tinc generate-ed25519-keys}.
 
 @cindex Forwarding
 @item Forwarding = <off|internal|kernel> (internal) [experimental]
@@ -1333,7 +1324,7 @@ The symmetric cipher algorithm used to encrypt UDP packets using the legacy prot
 Any cipher supported by LibreSSL or OpenSSL is recognized.
 Furthermore, specifying @samp{none} will turn off packet encryption.
 It is best to use only those ciphers which support CBC mode.
-This option has no effect for connections using the SPTPS protocol, which always use AES-256-CTR.
+This option only affects communication using the legacy protocol.
 
 @cindex ClampMSS
 @item ClampMSS = <yes|no> (yes)
@@ -1352,7 +1343,7 @@ Possible values are 0 (off), 1 (fast zlib) and any integer up to 9 (best zlib),
 The digest algorithm used to authenticate UDP packets using the legacy protocol.
 Any digest supported by LibreSSL or OpenSSL is recognized.
 Furthermore, specifying @samp{none} will turn off packet authentication.
-This option has no effect for connections using the SPTPS protocol, which always use HMAC-SHA-256.
+This option only affects communication using the legacy protocol.
 
 @cindex IndirectData
 @item IndirectData = <yes|no> (no)
@@ -1365,7 +1356,7 @@ It is best to leave this option out or set it to no.
 The length of the message authentication code used to authenticate UDP packets using the legacy protocol.
 Can be anything from 0
 up to the length of the digest produced by the digest algorithm.
-This option has no effect for connections using the SPTPS protocol, which never truncate MACs.
+This option only affects communication using the legacy protocol.
 
 @cindex PMTU
 @item PMTU = <@var{mtu}> (1514)
@@ -3030,9 +3021,9 @@ Therefore, tinc also authenticates the data.
 Finally, tinc uses sequence numbers (which themselves are also authenticated) to prevent an attacker from replaying valid packets.
 
 Since version 1.1pre3, tinc has two protocols used to protect your data; the legacy protocol, and the new Simple Peer-to-Peer Security (SPTPS) protocol.
-The SPTPS protocol is designed to address some weaknesses in the legacy protocol.
-The new authentication protocol is used when two nodes connect to each other that both have the ExperimentalProtocol option set to yes,
-otherwise the legacy protocol will be used.
+The SPTPS protocol is designed to address some weaknesses in the legacy protocol,
+and is used automatically if both sides support it.
+Once two nodes have connected with the new protocol, rollback to the legacy protocol is not allowed.
 
 @menu
 * Legacy authentication protocol::
index 2ed286a62d95881ede05da7ddd97e0c7dd7433f7..676ecec6976cded284496ad3214e3c100dee5438 100644 (file)
@@ -1677,7 +1677,7 @@ const var_t variables[] = {
        {"DeviceType", VAR_SERVER},
        {"DirectOnly", VAR_SERVER | VAR_SAFE},
        {"Ed25519PrivateKeyFile", VAR_SERVER},
-       {"ExperimentalProtocol", VAR_SERVER},
+       {"ExperimentalProtocol", VAR_SERVER | VAR_OBSOLETE},
        {"Forwarding", VAR_SERVER},
        {"FWMark", VAR_SERVER},
        {"GraphDumpFile", VAR_SERVER | VAR_OBSOLETE},
index b056c7d54974617997fd9ab41a343965806685c5..52e0f8209339633d962bfdd961ba210d3e5bb19a 100755 (executable)
@@ -23,7 +23,7 @@ def init(ctx: Test, digest: str, cipher: str) -> T.Tuple[Tinc, Tinc]:
         set Digest {digest}
         set Cipher {cipher}
     """
-    foo.cmd(stdin=stdin)
+    foo.cmd("--force", stdin=stdin)
     foo.start()
 
     stdin = f"""
@@ -35,7 +35,7 @@ def init(ctx: Test, digest: str, cipher: str) -> T.Tuple[Tinc, Tinc]:
         set Digest {digest}
         set Cipher {cipher}
     """
-    bar.cmd(stdin=stdin)
+    bar.cmd("--force", stdin=stdin)
 
     foo.add_script(bar.script_up)
     bar.add_script(foo.script_up)
index 845ac3458288bef15624dc422062b0427691879e..f7ab1bd2139c68afd8fd631a7d464bd43f8a9fd0 100755 (executable)
@@ -73,14 +73,14 @@ with Test("foo 1.1, bar 1.1") as context:
 
 with Test("foo 1.1, bar 1.0") as context:
     foo_node, bar_node = init(context)
-    bar_node.cmd("set", "ExperimentalProtocol", "no")
+    bar_node.cmd("--force", "set", "ExperimentalProtocol", "no")
     foo_node.cmd("del", f"{bar_node}.Ed25519PublicKey")
     bar_node.cmd("del", f"{foo_node}.Ed25519PublicKey")
     run_keys_test(foo_node, bar_node, empty=True)
 
 with Test("bar 1.0 must not be allowed to connect") as context:
     foo_node, bar_node = init(context)
-    bar_node.cmd("set", "ExperimentalProtocol", "no")
+    bar_node.cmd("--force", "set", "ExperimentalProtocol", "no")
 
     bar_up = bar_node.add_script(Script.SUBNET_UP)
     bar_node.cmd("start")
index ce8136aa5efe1ac91789151c360bf054f1973cc3..2166a400351ac817c5cd739ee4edf292e9732e6b 100755 (executable)
@@ -30,7 +30,7 @@ def init(ctx: Test, *options: str) -> T.Tuple[Tinc, Tinc]:
         set Sandbox {SANDBOX_LEVEL}
         {custom}
     """
-    foo.cmd(stdin=stdin)
+    foo.cmd("--force", stdin=stdin)
 
     stdin = f"""
         init {bar}
@@ -42,7 +42,7 @@ def init(ctx: Test, *options: str) -> T.Tuple[Tinc, Tinc]:
         set Sandbox {SANDBOX_LEVEL}
         {custom}
     """
-    bar.cmd(stdin=stdin)
+    bar.cmd("--force", stdin=stdin)
 
     foo.add_script(Script.SUBNET_UP)
     bar.add_script(Script.SUBNET_UP)