summaryrefslogtreecommitdiffhomepage
path: root/control/controlclient/map.go
AgeCommit message (Collapse)AuthorFilesLines
2022-09-21control/controlclient,ipn/ipnlocal: wire tka enable/disableTom DNetto1-0/+12
Signed-off-by: Tom DNetto <tom@tailscale.com>
2022-09-15envknob: support changing envknobs post-initBrad Fitzpatrick1-3/+3
Updates #5114 Change-Id: Ia423fc7486e1b3f3180a26308278be0086fae49b Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
2022-08-22control/controlclient,tailcfg: [capver 40] create KeySignature field in ↵Tom DNetto1-0/+3
tailcfg.Node We calve out a space to put the node-key signature (used on tailnets where network lock is enabled). Signed-off-by: Tom DNetto <tom@tailscale.com>
2022-08-09tailcfg, control/controlclient: make Debug settings sticky in a map session ↵Brad Fitzpatrick1-2/+41
[capver 37] Fixes #4843 Change-Id: I3accfd91be474ac745cb47f5d6e866c37d5c5d2d Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
2022-08-02control/controlclient, tailcfg: add 6 more patchable Node fields [capver 36]Brad Fitzpatrick1-0/+28
Change-Id: Iae997a9a98a5dd841bc41fa91227d5a7dd476a25 Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
2022-07-25all: convert more code to use net/netip directlyBrad Fitzpatrick1-2/+2
perl -i -npe 's,netaddr.IPPrefixFrom,netip.PrefixFrom,' $(git grep -l -F netaddr.) perl -i -npe 's,netaddr.IPPortFrom,netip.AddrPortFrom,' $(git grep -l -F netaddr. ) perl -i -npe 's,netaddr.IPPrefix,netip.Prefix,g' $(git grep -l -F netaddr. ) perl -i -npe 's,netaddr.IPPort,netip.AddrPort,g' $(git grep -l -F netaddr. ) perl -i -npe 's,netaddr.IP\b,netip.Addr,g' $(git grep -l -F netaddr. ) perl -i -npe 's,netaddr.IPv6Raw\b,netip.AddrFrom16,g' $(git grep -l -F netaddr. ) goimports -w . Then delete some stuff from the net/netaddr shim package which is no longer neeed. Updates #5162 Change-Id: Ia7a86893fe21c7e3ee1ec823e8aba288d4566cd8 Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
2022-07-25net/netaddr: start migrating to net/netip via new netaddr adapter packageBrad Fitzpatrick1-2/+2
Updates #5162 Change-Id: Id7bdec303b25471f69d542f8ce43805328d56c12 Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
2022-07-20tailcfg, control/controlclient: add tailcfg.PeersChangedPatch [capver 33]Brad Fitzpatrick1-1/+12
This adds a lighter mechanism for endpoint updates from control. Change-Id: If169c26becb76d683e9877dc48cfb35f90cc5f24 Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
2022-07-19tailcfg: remove old DNS fieldsBrad Fitzpatrick1-6/+0
The control plane server doesn't send these to modern clients so we don't need them in the tree. The server has its own serialization code to generate legacy MapResponses when needed. Change-Id: Idd1e5d96ddf9d4306f2da550d20b77f0c252817a Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
2022-03-22control/controlclient, ipn/ipnlocal, tailcfg: add MapResponse.PopBrowserURLBrad Fitzpatrick1-0/+1
Updates #3802 Change-Id: I89481fc5782a0cc8084354706f8f28d94f197325 Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
2022-02-16tailcfg: make Node.Hostinfo a HostinfoViewMaisem Ali1-1/+3
Signed-off-by: Maisem Ali <maisem@tailscale.com>
2022-02-15tailcfg: add start of SSH policy to be sent from control plane to nodesBrad Fitzpatrick1-0/+5
Updates #3802 Change-Id: Iec58f35d445aaa267d0f7e7e2f30c049c1df4c0e Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
2022-01-24envknob: add new package for all the strconv.ParseBool(os.Getenv(..))Brad Fitzpatrick1-3/+2
A new package can also later record/report which knobs are checked and set. It also makes the code cleaner & easier to grep for env knobs. Change-Id: Id8a123ab7539f1fadbd27e0cbeac79c2e4f09751 Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
2021-11-01types/netmap: use key.NodePublic instead of tailcfg.NodeKey.David Anderson1-1/+1
Update #3206 Signed-off-by: David Anderson <danderson@tailscale.com>
2021-10-29various: use NodePublic.AsNodeKey() instead of tailcfg.NodeKeyFromNodePublic()David Anderson1-1/+1
Updates #3206 Signed-off-by: David Anderson <danderson@tailscale.com>
2021-10-28control/controlclient: stop using wgkey.David Anderson1-6/+4
Updates #3206 Signed-off-by: David Anderson <danderson@tailscale.com>
2021-10-28types/netmap: use new node key type.David Anderson1-1/+2
Signed-off-by: David Anderson <danderson@tailscale.com>
2021-09-19tailcfg, health: add way for control plane to add problems to health checkBrad Fitzpatrick1-0/+5
So if the control plane knows that something's broken about the node, it can include problem(s) in MapResponse and "tailscale status" will show it. (and GUIs in the future, as it's in ipnstate.Status/JSON) This also bumps the MapRequest.Version, though it's not strictly required. Doesn't hurt. Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
2021-09-03types/key: add a special key with custom serialization for control private ↵Dave Anderson1-1/+2
keys (#2792) * Revert "Revert "types/key: add MachinePrivate and MachinePublic."" This reverts commit 61c3b98a24317dcfd5cbe3db29e7d6b64b8c27a7. Signed-off-by: David Anderson <danderson@tailscale.com> * types/key: add ControlPrivate, with custom serialization. ControlPrivate is just a MachinePrivate that serializes differently in JSON, to be compatible with how the Tailscale control plane historically serialized its private key. Signed-off-by: David Anderson <danderson@tailscale.com>
2021-09-03Revert "types/key: add MachinePrivate and MachinePublic."David Anderson1-2/+1
Broke the tailscale control plane due to surprise different serialization. This reverts commit 4fdb88efe1d9b4f8af0aad99bbacc814323ef92a.
2021-09-03types/key: add MachinePrivate and MachinePublic.David Anderson1-1/+2
Plumb throughout the codebase as a replacement for the mixed use of tailcfg.MachineKey and wgkey.Private/Public. Signed-off-by: David Anderson <danderson@tailscale.com>
2021-06-28control/controlclient: add debug knob to force node to only IPv6 self addrBrad Fitzpatrick1-1/+20
Updates #2268 Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
2021-04-19tailcfg, control/controlclient: accept nil MapResponse.Node (mapver 18)Brad Fitzpatrick1-12/+21
All MapResponse fields can not be omitted and are tagged "omitempty". Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
2021-04-19tailcfg, control/controlclient: allow empty MapResponse.Domain (mapver17)Brad Fitzpatrick1-1/+5
Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
2021-04-18control/controlclient: add start of some MapResponse->NetworkMap testsBrad Fitzpatrick1-5/+6
Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
2021-04-18control/controlclient: break direct.go into map.go (+tests), add mapSessionBrad Fitzpatrick1-0/+268
So the NetworkMap-from-incremental-MapResponses can be tested easily. And because direct.go was getting too big. No change in behavior at this point. Just movement. Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>