Commit Graph
8776 Commits
Author SHA1 Message Date
Fran Bull 06347d7cc7 wip 2025-02-27 13:43:56 -08:00
Fran Bull cd7d3ae4d2 add clarifying continue 2025-02-27 13:35:07 -08:00
Fran Bull 7dbcb388b8 shorten 2025-02-27 13:30:11 -08:00
Fran Bull c4110ec886 Export functions in authorization file 2025-02-27 13:23:26 -08:00
Fran Bull 24ce3279f4 close the conn, don't leave it open 2025-02-27 13:01:05 -08:00
Fran Bull ad7d1ee07a addr -> netip.AddrPortFrom().String() 2025-02-27 11:41:28 -08:00
Fran Bull 4175e2e21d don't try to http.Error after trying to encode to w 2025-02-27 10:18:30 -08:00
Fran Bull af2fd8bd7e change comment style 2025-02-27 09:38:28 -08:00
Fran Bull 559643b034 command mux robustness 2025-02-27 08:47:24 -08:00
Fran Bull b789daaf99 badrequest -> methodnotallowed 2025-02-27 08:01:23 -08:00
Fran Bull ace8630d89 splithostport -> parseaddrport 2025-02-27 07:47:07 -08:00
Fran Bull e8b2224932 401 -> 403 2025-02-27 07:39:16 -08:00
Fran Bull 69f76641ac auth getstatus max 1/s 2025-02-27 07:31:30 -08:00
Fran Bull ae30f58b46 centralize cmd http auth 2025-02-27 05:15:49 -08:00
Fran Bull 5afa742b06 unnecessary export 2025-02-26 15:03:37 -08:00
Fran Bull c35c3d1194 use a views.Slice 2025-02-26 14:45:44 -08:00
Fran Bull 66ecab9540 use a set for authorization, test it 2025-02-26 14:09:24 -08:00
Fran Bull f63ce0066d comment use of mutex 2025-02-26 09:36:20 -08:00
Fran Bull 9d65e1fc22 use status code constants, and the right ones 2025-02-26 09:34:13 -08:00
Fran Bull 2d2b954006 no need to defer 2025-02-26 09:26:39 -08:00
Fran Bull 5e15c25937 no need for a blank return at the end 2025-02-26 09:25:36 -08:00
Fran Bull f7ec770f03 use new encoder, not marshalindent 2025-02-26 09:10:10 -08:00
Fran Bull 3a35ac716d only serve debug monitor if asked for 2025-02-26 09:04:51 -08:00
Fran Bull e13b8c271b log errors don't return to http client 2025-02-26 08:38:08 -08:00
Fran Bull e0415e0221 use dnsname instead of strings split 2025-02-26 08:29:51 -08:00
Fran Bull febe30ea68 error auth refresh if server not running 2025-02-26 08:29:13 -08:00
Fran Bull 5fa145674d make tests pass under -race 2025-02-25 14:57:50 -08:00
Fran Bull 8dfb749ea5 missed a direct events access 2025-02-24 12:01:15 -08:00
Fran Bull 773894638c lint says conn can't be nil 2025-02-24 11:55:45 -08:00
Fran Bull 0b971dffd3 configure logging 2025-02-24 11:41:53 -08:00
Fran Bull f0223a9dba avoid race 2025-02-24 10:38:21 -08:00
Fran Bull 3ed0736ae9 protect nil pointer 2025-02-24 10:29:05 -08:00
Fran Bull 05277e020e move package doc to right place 2025-02-24 08:45:10 -08:00
Fran Bull e623e1d2d9 go mod tidy 2025-02-24 08:30:45 -08:00
Fran Bull aee5b38001 use httpm i guess? 2025-02-21 13:38:53 -08:00
Fran Bull 89af057be5 add copyright headers 2025-02-21 13:10:59 -08:00
Fran Bull d944cd1778 do we need to wait longer? 2025-02-21 13:07:41 -08:00
Fran Bull 0354836398 don't actually need those bits for the interface 2025-02-21 13:06:07 -08:00
Fran Bull 4040e14cb8 use the error value 2025-02-21 13:02:05 -08:00
Fran Bull 82e6b2508a fix test 2025-02-21 12:34:53 -08:00
Fran Bull a828917152 allow concurrent usage of authorization 2025-02-21 11:24:00 -08:00
Fran Bull d593a85bae comments, whitespace 2025-02-21 11:23:22 -08:00
Fran Bull 7c539e3d2f to squash: restrict communication to tagged nodes 2025-02-20 15:14:22 -08:00
Fran Bull 6ebb0c749d tsconsensus: add a tsconsensus package
tsconsensus enables tsnet.Server instances to form a consensus.

tsconsensus wraps hashicorp/raft with
 * the ability to do discovery via tailscale tags
 * inter node communication over tailscale
 * routing of commands to the leader

Updates #14667

Signed-off-by: Fran Bull <[email protected]>
2025-02-20 11:12:17 -08:00
Erisa A 074372d6c5 scripts/installer.sh: add SparkyLinux as a Debian derivative (#15076)
Fixes #15075

Signed-off-by: Erisa A <[email protected]>
2025-02-20 18:22:08 +00:00
Andrew Lytvynov 2c3338c46b client/tailscale: fix Client.BuildURL and Client.BuildTailnetURL (#15064)
This method uses `path.Join` to build the URL. Turns out with 1.24 this
started stripping consecutive "/" characters, so "http://..." in baseURL
becomes "http:/...".

Also, `c.Tailnet` is a function that returns `c.tailnet`. Using it as a
path element would encode as a pointer instead of the tailnet name.

Finally, provide a way to prevent escaping of path elements e.g. for `?`
in `acl?details=1`.

Updates #15015

Signed-off-by: Andrew Lytvynov <[email protected]>
2025-02-19 17:19:54 -08:00
836c01258d go.toolchain.branch: update to Go 1.24 (#15016)
* go.toolchain.branch: update to Go 1.24

Updates #15015

Change-Id: I29c934ec17e60c3ac3264f30fbbe68fc21422f4d
Signed-off-by: Brad Fitzpatrick <[email protected]>

* cmd/testwrapper: fix for go1.24

Updates #15015

Signed-off-by: Paul Scott <[email protected]>

* go.mod,Dockerfile: bump to Go 1.24

Also bump golangci-lint to a version that was built with 1.24

Updates #15015

Signed-off-by: Andrew Lytvynov <[email protected]>

---------

Signed-off-by: Brad Fitzpatrick <[email protected]>
Signed-off-by: Paul Scott <[email protected]>
Signed-off-by: Andrew Lytvynov <[email protected]>
Co-authored-by: Paul Scott <[email protected]>
Co-authored-by: Andrew Lytvynov <[email protected]>
2025-02-19 10:55:49 -08:00
Andrew Lytvynov cc923713f6 tempfork/acme: pull in latest changes for Go 1.24 (#15062)
https://github.com/tailscale/golang-x-crypto/commit/9a281fd8facad954dae80ef984c5d5d763f8ff91

Updates #15015

Signed-off-by: Andrew Lytvynov <[email protected]>
2025-02-19 10:42:06 -08:00
Andrew Lytvynov 323747c3e0 various: disable MPTCP when setting TCP_USER_TIMEOUT sockopt (#15063)
There's nothing about it on
https://github.com/multipath-tcp/mptcp_net-next/issues/ but empirically
MPTCP doesn't support this option on awly's kernel 6.13.2 and in GitHub
actions.

Updates #15015

Signed-off-by: Andrew Lytvynov <[email protected]>
2025-02-19 10:41:45 -08:00
Nick Khyl 09982e1918 ipn/ipnlocal: reset always-on override and apply policy settings on start
We already reset the always-on override flag when switching profiles and in a few other cases.
In this PR, we update (*LocalBackend).Start() to reset it as well. This is necessary to support
scenarios where Start() is called explicitly, such as when the GUI starts or when tailscale up is used
with additional flags and passes prefs via ipn.Options in a call to Start() rather than via EditPrefs.

Additionally, we update it to apply policy settings to the current prefs, which is necessary
for properly overriding prefs specified in ipn.Options.

Updates #14823

Signed-off-by: Nick Khyl <[email protected]>
2025-02-18 16:49:25 -06:00