1
0
mirror of https://github.com/juanfont/headscale.git synced 2026-02-07 20:04:00 +01:00
juanfont.headscale/hscontrol
Kristoffer Dalby ea53078dde integration: add test for tagged→user-owned conversion panic
Add TestTagsAuthKeyConvertToUserViaCLIRegister that reproduces the
exact panic from #3038: register a node with a tags-only PreAuthKey
(no user), force reauth with empty tags, then register via CLI with
a user. The mapper panics on node.Owner().Model().ID when User is nil.

The critical detail is using a tags-only PreAuthKey (User: nil). When
the key is created under a user, the node inherits the User pointer
from createAndSaveNewNode and the bug is masked.

Also add Owner() validity assertions to the existing unit test
TestTaggedNodeWithoutUserToDifferentUser to catch the nil pointer
at the unit test level.

Updates #3038
2026-02-02 14:53:27 +00:00
..
assets
capver capver: generate 2025-12-18 10:02:23 +01:00
db db: use PolicyManager for RequestTags migration 2026-01-21 15:10:29 +01:00
derp derp: migrate to derpserver package API 2026-01-21 19:17:10 +00:00
dns
mapper state: set User pointer during tagged→user-owned conversion 2026-02-02 14:52:47 +00:00
policy policy: update tests for SSH validation rules 2026-01-21 17:01:30 +00:00
routes
state state: set User pointer during tagged→user-owned conversion 2026-02-02 14:52:47 +00:00
templates Link to headscale.net for docs 2026-01-16 14:54:04 +01:00
types gen: regenerate protobuf and type views 2026-01-21 19:17:10 +00:00
util util/dns: fix variable redeclaration in ValidateDNSName 2026-01-17 10:13:24 +01:00
app.go app: only wire up debug server if set 2025-12-17 12:32:04 +01:00
auth_tags_test.go state: fix expiry handling during node tag conversion 2026-01-28 15:34:18 +00:00
auth_test.go integration: add test for tagged→user-owned conversion panic 2026-02-02 14:53:27 +00:00
auth.go cli: ensure tagged-devices is included in profile list (#2991) 2026-01-09 16:31:23 +01:00
debug.go
grpcv1_test.go grpc: support expire/delete API keys by ID 2026-01-20 17:13:38 +01:00
grpcv1.go grpc: support expire/delete API keys by ID 2026-01-20 17:13:38 +01:00
handlers.go
metrics.go
noise.go
oidc_template_test.go
oidc_test.go oidc: make email verification configurable 2025-12-18 11:42:32 +00:00
oidc.go oidc: make email verification configurable 2025-12-18 11:42:32 +00:00
platform_config.go
poll.go
tailsql.go
templates_consistency_test.go Link to headscale.net for docs 2026-01-16 14:54:04 +01:00