headscale/hscontrol/policy/v2
Kristoffer Dalby b668c7a596 policy/v2: add policy unmarshal tests for bracketed IPv6
Add end-to-end test cases to TestUnmarshalPolicy that verify bracketed
IPv6 addresses are correctly parsed through the full policy pipeline
(JSON unmarshal -> splitDestinationAndPort -> parseAlias -> parsePortRange)
and survive JSON round-trips.

Cover single port, multiple ports, wildcard port, CIDR prefix, port
range, bracketed IPv4, and hostname rejection.

Updates #2754
2026-02-20 21:49:21 +01:00
..
filter.go all: fix golangci-lint issues (#3064) 2026-02-06 21:45:32 +01:00
filter_test.go all: upgrade to Go 1.26rc2 and modernize codebase 2026-02-08 12:35:23 +01:00
policy.go all: fix golangci-lint issues (#3064) 2026-02-06 21:45:32 +01:00
policy_test.go all: upgrade to Go 1.26rc2 and modernize codebase 2026-02-08 12:35:23 +01:00
tailscale_compat_test.go all: fix golangci-lint issues (#3064) 2026-02-06 21:45:32 +01:00
tailscale_routes_compat_test.go policy: autogroup:internet does not generate packet filters 2026-02-05 19:29:16 +01:00
types.go all: upgrade to Go 1.26rc2 and modernize codebase 2026-02-08 12:35:23 +01:00
types_test.go policy/v2: add policy unmarshal tests for bracketed IPv6 2026-02-20 21:49:21 +01:00
utils.go policy/v2: accept RFC 3986 bracketed IPv6 in ACL destinations 2026-02-20 21:49:21 +01:00
utils_test.go policy/v2: accept RFC 3986 bracketed IPv6 in ACL destinations 2026-02-20 21:49:21 +01:00