Commit Graph
47 Commits
Author SHA1 Message Date
Brad Fitzpatrick 51491012ec lanscaping: omit h2c
-rwxr-xr-x@ 1 bradfitz  staff  13759346 Jan 10 21:26 /Users/bradfitz/bin/tailscaled.min
-rwxr-xr-x@ 1 bradfitz  staff  15007896 Jan 10 21:26 /Users/bradfitz/bin/tailscaled.minlinux

Change-Id: I523522c71deaeb4f7c2f6e81630109337682931c
Signed-off-by: Brad Fitzpatrick <[email protected]>
2025-01-10 21:26:39 -08:00
Brad Fitzpatrick 55587d3156 lanscaping: remove serve, webclient
-rwxr-xr-x@ 1 bradfitz  staff  14338354 Jan 10 21:12 /Users/bradfitz/bin/tailscaled.min
-rwxr-xr-x@ 1 bradfitz  staff  15532184 Jan 10 21:12 /Users/bradfitz/bin/tailscaled.minlinux

Change-Id: I075670f96610e55b7adaacb105fe4d749ed6cfd8
Signed-off-by: Brad Fitzpatrick <[email protected]>
2025-01-10 21:12:16 -08:00
Brad Fitzpatrick 5b4d3207b0 lanscaping: remove TKA
-rwxr-xr-x@ 1 bradfitz  staff  15297778 Jan 10 21:03 /Users/bradfitz/bin/tailscaled.min
-rwxr-xr-x@ 1 bradfitz  staff  16515224 Jan 10 21:03 /Users/bradfitz/bin/tailscaled.minlinux

Change-Id: I297e3d82d5763019ab6fb1f2a1bc3f3369d10d9c
Signed-off-by: Brad Fitzpatrick <[email protected]>
2025-01-10 21:03:14 -08:00
Brad Fitzpatrick aa0ec3e4a5 lanscaping: add missing ts_omit_ssh
-rwxr-xr-x@ 1 bradfitz  staff  16935810 Jan 10 20:21 /Users/bradfitz/bin/tailscaled.min
-rwxr-xr-x@ 1 bradfitz  staff  18153624 Jan 10 20:21 /Users/bradfitz/bin/tailscaled.minlinux

Change-Id: I1f94b576a0fe03b1a853f4261d85288934f29b39
Signed-off-by: Brad Fitzpatrick <[email protected]>
2025-01-10 20:21:47 -08:00
Brad Fitzpatrick cdcf8d51cf lanscaping: omit nftables
Change-Id: I5ce60ade4ec0c818ce83a08950847f7a4baaeabf
Signed-off-by: Brad Fitzpatrick <[email protected]>
2025-01-10 20:20:57 -08:00
Brad Fitzpatrick 30d682899b lanscaping: butcher out gvisor; 16MB
Change-Id: I8185f5bdfe080e33910a8224de66c97f10e2ed40
Signed-off-by: Brad Fitzpatrick <[email protected]>
2025-01-10 20:04:36 -08:00
Brad Fitzpatrick 515d9689d5 lanscaping: start adding ts_omit_netstack
Change-Id: Iefa404306db4eaaaedbaaf7aaad85a241aff2ae1
Signed-off-by: Brad Fitzpatrick <[email protected]>
2025-01-10 19:39:32 -08:00
Brad Fitzpatrick 45a2d139a1 lanscaping: baseline
Change-Id: I551c241a499602929c7bba437c11a65c913e2d5e
2025-01-10 19:14:08 -08:00
Brad FitzpatrickandPercy Wegmann 73128e2523 ssh/tailssh: remove unused public key support
When we first made Tailscale SSH, we assumed people would want public
key support soon after. Turns out that hasn't been the case; people
love the Tailscale identity authentication and check mode.

In light of CVE-2024-45337, just remove all our public key code to not
distract people, and to make the code smaller. We can always get it
back from git if needed.

Updates tailscale/corp#25131
Updates golang/go#70779

Co-authored-by: Percy Wegmann <[email protected]>
Change-Id: I87a6e79c2215158766a81942227a18b247333c22
Signed-off-by: Brad Fitzpatrick <[email protected]>
2024-12-12 11:16:55 -08:00
Irbe Krumina 44c8892c18 Makefile,./build_docker.sh: update kube operator image build target name (#14251)
Updates tailscale/corp#24540
Updates tailscale/tailscale#12914

Signed-off-by: Irbe Krumina <[email protected]>
2024-11-29 15:32:18 +00:00
Percy Wegmann 7d83056a1b ssh/tailssh: fix SSH on busybox systems
This involved the following:

1. Pass the su command path as first of args in call to unix.Exec to make sure that busybox sees the correct program name.
   Busybox is a single executable userspace that implements various core userspace commands in a single binary. You'll
   see it used via symlinking, so that for example /bin/su symlinks to /bin/busybox. Busybox knows that you're trying
   to execute /bin/su because argv[0] is '/bin/su'. When we called unix.Exec, we weren't including the program name for
   argv[0], which caused busybox to fail with 'applet not found', meaning that it didn't know which command it was
   supposed to run.
2. Tell su to whitelist the SSH_AUTH_SOCK environment variable in order to support ssh agent forwarding.
3. Run integration tests on alpine, which uses busybox.
4. Increment CurrentCapabilityVersion to allow turning on SSH V2 behavior from control.

Fixes #12849

Signed-off-by: Percy Wegmann <[email protected]>
2024-08-21 11:44:41 -05:00
Maisem Ali 2b638f550d cmd/k8s-operator: add depaware.txt
Updates #12742

Signed-off-by: Maisem Ali <[email protected]>
2024-07-08 12:43:10 -07:00
Percy Wegmann 730f0368d0 ssh/tailssh: replace incubator process with su instead of running su as child
This allows the SSH_AUTH_SOCK environment variable to work inside of
su and agent forwarding to succeed.

Fixes #12467

Signed-off-by: Percy Wegmann <[email protected]>
2024-06-20 10:11:03 -05:00
Percy Wegmann 08a9551a73 ssh/tailssh: fall back to using su when no TTY available on Linux
This allows pam authentication to run for ssh sessions, triggering
automation like pam_mkhomedir.

Updates #11854

Signed-off-by: Percy Wegmann <[email protected]>
2024-05-29 13:15:17 -05:00
Percy Wegmann 843afe7c53 ssh/tailssh: add integration test
Updates tailscale/corp#11854

Signed-off-by: Percy Wegmann <[email protected]>
2024-05-01 11:19:36 -05:00
Irbe Krumina 44aa809cb0 cmd/{k8s-nameserver,k8s-operator},k8s-operator: add a kube nameserver, make operator deploy it (#11919)
* cmd/k8s-nameserver,k8s-operator: add a nameserver that can resolve ts.net DNS names in cluster.

Adds a simple nameserver that can respond to A record queries for ts.net DNS names.
It can respond to queries from in-memory records, populated from a ConfigMap
mounted at /config. It dynamically updates its records as the ConfigMap
contents changes.
It will respond with NXDOMAIN to queries for any other record types
(AAAA to be implemented in the future).
It can respond to queries over UDP or TCP. It runs a miekg/dns
DNS server with a single registered handler for ts.net domain names.
Queries for other domain names will be refused.

The intended use of this is:
1) to allow non-tailnet cluster workloads to talk to HTTPS tailnet
services exposed via Tailscale operator egress over HTTPS
2) to allow non-tailnet cluster workloads to talk to workloads in
the same cluster that have been exposed to tailnet over their
MagicDNS names but on their cluster IPs.

DNSConfig CRD can be used to configure
the operator to deploy kube nameserver (./cmd/k8s-nameserver) to cluster.

Updates tailscale/tailscale#10499

Signed-off-by: Irbe Krumina <[email protected]>
2024-04-30 20:18:23 +01:00
Brad Fitzpatrick 9258bcc360 Makefile: fix default SYNO_ARCH in Makefile
It was broken with the move to dist in 32e0ba5e68 which doesn't accept
amd64 anymore.

Updates #cleanup

Change-Id: Iaaaba2d73c6a09a226934fe8e5c18b16731ee7a6
Signed-off-by: Brad Fitzpatrick <[email protected]>
2024-04-15 08:59:48 -07:00
Irbe Krumina 231e44e742 Revert "cmd/{k8s-nameserver,k8s-operator},k8s-operator: add a kube nameserver, make operator deploy it (#11017)" (#11669)
Temporarily reverting this PR to avoid releasing
half finished featue.

This reverts commit 9e2f58f846.

Signed-off-by: Irbe Krumina <[email protected]>
2024-04-08 21:31:52 +01:00
Irbe Krumina 9e2f58f846 cmd/{k8s-nameserver,k8s-operator},k8s-operator: add a kube nameserver, make operator deploy it (#11017)
* cmd/k8s-nameserver,k8s-operator: add a nameserver that can resolve ts.net DNS names in cluster.

Adds a simple nameserver that can respond to A record queries for ts.net DNS names.
It can respond to queries from in-memory records, populated from a ConfigMap
mounted at /config. It dynamically updates its records as the ConfigMap
contents changes.
It will respond with NXDOMAIN to queries for any other record types
(AAAA to be implemented in the future).
It can respond to queries over UDP or TCP. It runs a miekg/dns
DNS server with a single registered handler for ts.net domain names.
Queries for other domain names will be refused.

The intended use of this is:
1) to allow non-tailnet cluster workloads to talk to HTTPS tailnet
services exposed via Tailscale operator egress over HTTPS
2) to allow non-tailnet cluster workloads to talk to workloads in
the same cluster that have been exposed to tailnet over their
MagicDNS names but on their cluster IPs.

Updates tailscale/tailscale#10499

Signed-off-by: Irbe Krumina <[email protected]>

* cmd/k8s-operator/deploy/crds,k8s-operator: add DNSConfig CustomResource Definition

DNSConfig CRD can be used to configure
the operator to deploy kube nameserver (./cmd/k8s-nameserver) to cluster.

Signed-off-by: Irbe Krumina <[email protected]>

* cmd/k8s-operator,k8s-operator: optionally reconcile nameserver resources

Adds a new reconciler that reconciles DNSConfig resources.
If a DNSConfig is deployed to cluster,
the reconciler creates kube nameserver resources.
This reconciler is only responsible for creating
nameserver resources and not for populating nameserver's records.

Signed-off-by: Irbe Krumina <[email protected]>

* cmd/{k8s-operator,k8s-nameserver}: generate DNSConfig CRD for charts, append to static manifests

Signed-off-by: Irbe Krumina <[email protected]>

---------

Signed-off-by: Irbe Krumina <[email protected]>
2024-03-27 20:18:17 +00:00
Irbe Krumina ca48db0d60 Makefile,build_docker.sh: allow to configure target platform. (#10806)
Build dev tailscale and k8s-operator images for linux/amd64 only by default,
make it possible to configure target build platform via PLATFORM var.

Updates#cleanup

Signed-off-by: Irbe Krumina <[email protected]>
2024-01-10 19:19:20 +00:00
James Tucker 953fa80c6f cmd/{derper,stund},net/stunserver: add standalone stun server
Add a standalone server for STUN that can be hosted independently of the
derper, and factor that back into the derper.

Fixes #8434
Closes #8435
Closes #10745

Signed-off-by: James Tucker <[email protected]>
2024-01-08 16:22:33 -08:00
Irbe Krumina 1a08ea5990 cmd/k8s-operator: operator can create subnetrouter (#9505)
* k8s-operator,cmd/k8s-operator,Makefile,scripts,.github/workflows: add Connector kube CRD.

Connector CRD allows users to configure the Tailscale Kubernetes operator
to deploy a subnet router to expose cluster CIDRs or
other CIDRs available from within the cluster
to their tailnet.

Also adds various CRD related machinery to
generate CRD YAML, deep copy implementations etc.

Engineers will now have to run
'make kube-generate-all` after changing kube files
to ensure that all generated files are up to date.

* cmd/k8s-operator,k8s-operator: reconcile Connector resources

Reconcile Connector resources, create/delete subnetrouter resources in response to changes to Connector(s).

Connector reconciler will not be started unless
ENABLE_CONNECTOR env var is set to true.
This means that users who don't want to use the alpha
Connector custom resource don't have to install the Connector
CRD to their cluster.
For users who do want to use it the flow is:
- install the CRD
- install the operator (via Helm chart or using static manifests).
For Helm users set .values.enableConnector to true, for static
manifest users, set ENABLE_CONNECTOR to true in the static manifest.

Updates tailscale/tailscale#502


Signed-off-by: Irbe Krumina <[email protected]>
2023-12-14 13:51:59 +00:00
Andrew Dunham 3f576fc4ca ci: run 'go vet' in golangci-lint; fix errors in tests
Updates #cleanup

Signed-off-by: Andrew Dunham <[email protected]>
Change-Id: Ice78fc907bad24c1de749a1595e212ef2db4b8bb
2023-12-07 15:08:28 -05:00
Irbe Krumina 35ad2aafe3 Makefile: make it possibe to pass a custom tag when building dev images (#9461)
Updates #cleanup

Signed-off-by: Irbe Krumina <[email protected]>
2023-09-19 17:51:22 +01:00
Brad Fitzpatrick 98a5116434 all: adjust some build tags for plan9
I'm not saying it works, but it compiles.

Updates #5794

Change-Id: I2f3c99732e67fe57a05edb25b758d083417f083e
Signed-off-by: Brad Fitzpatrick <[email protected]>
2023-08-24 15:42:35 -07:00
David Anderson 32e0ba5e68 release/dist/synology: build synology packages with cmd/dist
Updates #8217

Signed-off-by: David Anderson <[email protected]>
2023-05-29 14:18:37 -07:00
Will Norris 8b9ee7a558 Makefile: add help text to Makefile
https://rosszurowski.com/log/2022/makefiles#self-documenting-makefiles
Signed-off-by: Will Norris <[email protected]>
2023-02-16 22:39:09 +00:00
Brad Fitzpatrick b1248442c3 all: update to Go 1.20, use strings.CutPrefix/Suffix instead of our fork
Updates #7123
Updates #5309

Change-Id: I90bcd87a2fb85a91834a0dd4be6e03db08438672
Signed-off-by: Brad Fitzpatrick <[email protected]>
2023-02-01 15:23:54 -08:00
David Anderson d81a2b2ce2 Makefile: add a target for doing dev builds of the k8s operator.
Updates #502.

Signed-off-by: David Anderson <[email protected]>
2022-12-13 09:50:57 -08:00
缘生 9c67395334 feat(build): add support on Loongnix-Server (loong64) (#6233)
Makefile, .github/workflow: add tests, targets for GOARCH=loong64 (Loongnix)

Signed-off-by: ysicing <[email protected]>
2022-12-11 20:16:40 -08:00
Maisem Ali 42d9e7171c Makefile: add publishdevimage target
This builds and publishes the tailscale container image for dev testing.

Signed-off-by: Maisem Ali <[email protected]>
2022-10-21 10:19:06 -07:00
Maisem Ali c3270af52b Makefile: add target for wasm and make it part of check
Signed-off-by: Maisem Ali <[email protected]>
2022-08-15 09:43:35 -07:00
David Crawshaw 93324cc7b3 cmd/derper: add depaware.txt
Signed-off-by: David Crawshaw <[email protected]>
2022-08-05 11:38:10 -07:00
Brad Fitzpatrick e1309e1323 all: require Go 1.19
Updates #5210

Change-Id: I2e950b4776636b4ea89b6566b60e4a87596a3a43
Signed-off-by: Brad Fitzpatrick <[email protected]>
2022-08-02 11:49:01 -07:00
Brad Fitzpatrick f6642e0ece Makefile: add tidy target
Change-Id: I6cd3a6837f9ddfd283f57378465dcefa4d0ada47
Signed-off-by: Brad Fitzpatrick <[email protected]>
2022-03-21 11:06:13 -07:00
Maisem Ali 7f3d0992aa Makefile: use ./tool/go everywhere
Signed-off-by: Maisem Ali <[email protected]>
2022-03-18 10:13:18 -07:00
Maisem Ali 0ada42684b Makefile: update make spk target to use the new go spk builder
Signed-off-by: Maisem Ali <[email protected]>
2022-01-21 12:27:00 -08:00
Brad Fitzpatrick c0984f88dc Makefile: add spk and pushspk targets for iterative Synology development
Change-Id: I97319d14917aa2b00ff72a7b73b3db79ea8392b7
Signed-off-by: Brad Fitzpatrick <[email protected]>
2021-12-06 09:52:06 -08:00
Maisem Ali 9feb483ad3 build_docker.sh: use github.com/tailscale/mkctr instead of docker
Signed-off-by: Maisem Ali <[email protected]>
2021-11-22 11:39:30 -08:00
Mangirdas f771327f0c Add multiarch image make target
Updates #3112

Signed-off-by: Mangirdas <[email protected]>
2021-11-03 13:13:20 -07:00
Brad Fitzpatrick af30897f0d Makefile: add a linux/arm check
Signed-off-by: Brad Fitzpatrick <[email protected]>
2021-08-18 15:36:09 -07:00
Brad Fitzpatrick a038e8690c wgengine/netstack: fix 32-bit build broken from prior commit
Signed-off-by: Brad Fitzpatrick <[email protected]>
2021-03-01 11:19:31 -08:00
Brad Fitzpatrick ee6475a44d wgengine: unify NewUserspaceEngine, NewUserspaceEngineAdvanced
Also rename EngineConfig to Config to avoid wgengine.EngineConfig
stutter.

Signed-off-by: Brad Fitzpatrick <[email protected]>
2021-02-27 21:52:24 -08:00
Brad Fitzpatrick 5a94317628 Makefile: remove tsshd from depaware
I'd removed it from the GitHub actions checks before submitted earlier
but forgot to update it here.
2020-09-11 11:09:32 -07:00
Brad Fitzpatrick 158202dbb1 go mod tidy 2020-09-09 12:17:44 -07:00
Brad Fitzpatrick 5e0375808b cmd/tailscale/cli: fix vet warning
And add vet to the "make check" target, like the CI has.
2020-08-24 21:35:27 -07:00
Brad Fitzpatrick 6757c990a8 Fix staticcheck warning, add Makefile with staticcheck targets, lock in staticcheck version in go.mod 2020-06-15 11:05:46 -07:00