From ca676ea64556bf4019c9989597214a2bb7a64d72 Mon Sep 17 00:00:00 2001 From: David Anderson Date: Sat, 19 Dec 2020 18:28:27 -0800 Subject: [PATCH] tailcfg: introduce map version 8, for clients that support v6 node config. For now, the server will only send v6 configuration to mapversion 8 clients as part of an early-adopter program, while we verify that the functionality is robust. Signed-off-by: David Anderson --- control/controlclient/direct.go | 2 +- tailcfg/tailcfg.go | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/control/controlclient/direct.go b/control/controlclient/direct.go index a7df53957..5d579e1ae 100644 --- a/control/controlclient/direct.go +++ b/control/controlclient/direct.go @@ -545,7 +545,7 @@ func (c *Direct) PollNetMap(ctx context.Context, maxPolls int, cb func(*NetworkM } request := tailcfg.MapRequest{ - Version: 7, + Version: 8, KeepAlive: c.keepAlive, NodeKey: tailcfg.NodeKey(persist.PrivateNodeKey.Public()), DiscoKey: c.discoPubKey, diff --git a/tailcfg/tailcfg.go b/tailcfg/tailcfg.go index 776c79158..5eddb9e27 100644 --- a/tailcfg/tailcfg.go +++ b/tailcfg/tailcfg.go @@ -478,6 +478,7 @@ type MapRequest struct { // 5: 2020-10-19, implies IncludeIPv6, delta Peers/UserProfiles, supports MagicDNS // 6: 2020-12-07: means MapResponse.PacketFilter nil means unchanged // 7: 2020-12-15: FilterRule.SrcIPs accepts CIDRs+ranges, doesn't warn about 0.0.0.0/:: + // 8: 2020-12-19: client can receive IPv6 addresses and routes if beta enabled server-side Version int Compress string // "zstd" or "" (no compression) KeepAlive bool // whether server should send keep-alives back to us