mirror of
https://github.com/juanfont/headscale.git
synced 2026-04-11 03:27:20 +02:00
Add five categories of grant validation that Tailscale enforces: 1. Capability name format: reject URL schemes (://) and restrict tailscale.com domain to an allowlist of user-grantable caps. 2. Grant-specific autogroup:self: reject wildcard (*) sources with autogroup:self destinations (stricter than ACL rules since * includes tags which cannot use autogroup:self). 3. App + autogroup:internet: reject app grants targeting autogroup:internet. 4. Raw default route CIDRs: reject 0.0.0.0/0 and ::/0 as grant destinations, requiring "*" or "autogroup:internet" instead. 5. Via field: non-tag values (e.g. autogroup:tagged) are caught at unmarshal time by Tag.UnmarshalJSON validation. This resolves 23 ERROR_VALIDATION_GAP + 1 via validation test, reducing the grant compat skip list from 28 to 5 remaining tests. Updates #2180