You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
tailscale/cmd/tailscaled
Brad Fitzpatrick 9bb601ebe8 ipn/ipnlocal, wgengine/netstack: use netstack for peerapi server
We're finding a bunch of host operating systems/firewalls interact poorly
with peerapi. We either get ICMP errors from the host or users need to run
commands to allow the peerapi port:

https://github.com/tailscale/tailscale/issues/3842#issuecomment-1025133727

... even though the peerapi should be an internal implementation detail.

Rather than fight the host OS & firewalls, this change handles the
server side of peerapi entirely in netstack (except on iOS), so it
never makes its way to the host OS where it might be messed with. Two
main downsides are:

1) netstack isn't as fast, but we don't really need speed for peerapi.
   And actually, with fewer trips to/from the kernel, we might
   actually make up for some of the netstack performance loss by
   staying in userspace.

2) tcpdump / Wireshark etc packet captures will no longer see the peerapi
   traffic. Oh well. Crawshaw's been wanting to add packet capture server
   support to tailscaled, so we'll probably do that sooner now.

   A future change might also then use peerapi for the client-side
   (except on iOS).

Updates #3842 (probably fixes, as well as many exit node issues I bet)

Change-Id: Ibc25edbb895dc083d1f07bd3cab614134705aa39
Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
(cherry picked from commit bd90781b34) + edits
(and cherry picked part of commit f3c0023add)
4 years ago
..
debug.go derp: use new node key type. 4 years ago
depaware.txt netcheck,portmapper,magicsock: ignore some UDP write errors on Linux 4 years ago
install_darwin.go cmd/tailscaled: remove tailscaled binary on uninstall-system-daemon 5 years ago
install_windows.go ipn/ipnlocal: add file sharing to windows shell 5 years ago
proxy.go cmd/tailscaled: add support for running an HTTP proxy 4 years ago
tailscaled.defaults cmd/tailscaled: rename relaynode reference in defaults file comment 6 years ago
tailscaled.go ipn/ipnlocal, wgengine/netstack: use netstack for peerapi server 4 years ago
tailscaled.openrc tstest/integration/vms: use an in-process logcatcher (#2360) 5 years ago
tailscaled.service cmd/tailscaled: set StateDirectoryMode=0700 in tailscaled.service 4 years ago
tailscaled_bird.go wgengine/userspace: add support to automatically enable/disable the tailscale 4 years ago
tailscaled_notwindows.go all: gofmt with Go 1.17 5 years ago
tailscaled_windows.go cmd/tailscaled: log Windows service change requests 4 years ago