Kristoffer Dalby 30dce30a9d testdata: convert .json to .hujson with header comments
Rename all 594 test data files from .json to .hujson and add
descriptive header comments to each file documenting what policy
rules are under test and what outcome is expected.

Update test loaders in all 5 _test.go files to parse HuJSON via
hujson.Parse/Standardize/Pack before json.Unmarshal.

Add cross-dependency warning to via_compat_test.go documenting
that GRANT-V29/V30/V31/V36 are shared with TestGrantsCompat.

Add .gitignore exemption for testdata HuJSON files.
2026-04-01 14:10:42 +01:00

498 lines
23 KiB
Plaintext

// GRANT-P15_4
//
// Grant: src=['autogroup:member'] dst=['8.8.8.0/24'] ip=['53']
//
// Expected: No filter rules on any node
{
"test_id": "GRANT-P15_4",
"timestamp": "2026-02-23T01:13:14Z",
"propagation_wait_seconds": 15,
"input": {
"policy_file": "/home/kradalby/acl-explore/grant_policies/grant_p15_4.json",
"full_policy": {
"groups": {
"group:admins": ["kratail2tid@passkey"],
"group:developers": ["kristoffer@dalby.cc", "kratail2tid@passkey"],
"group:monitors": ["monitorpasskeykradalby@passkey"],
"group:empty": []
},
"tagOwners": {
"tag:server": ["kratail2tid@passkey"],
"tag:prod": ["kratail2tid@passkey"],
"tag:client": ["kratail2tid@passkey"],
"tag:router": ["kratail2tid@passkey"],
"tag:exit": ["kratail2tid@passkey"]
},
"hosts": {
"webserver": "100.108.74.26",
"prodbox": "100.103.8.15",
"internal": "10.0.0.0/8"
},
"autoApprovers": {
"routes": {
"10.33.0.0/16": ["tag:router"],
"0.0.0.0/0": ["tag:exit"],
"::/0": ["tag:exit"]
}
},
"grants": [
{
"src": ["autogroup:member"],
"dst": ["8.8.8.0/24"],
"ip": ["53"]
}
]
},
"grants_section": [
{
"src": ["autogroup:member"],
"dst": ["8.8.8.0/24"],
"ip": ["53"]
}
],
"api_endpoint": "https://api.tailscale.com/api/v2/tailnet/kratail2tid%40passkey/acl",
"api_method": "POST",
"api_response_code": 200
},
"topology": {
"nodes": {
"exit-node": {
"mts_name": "exit-node",
"socket": "/home/kradalby/.config/multi-tailscale-dev/exit-node/tailscaled.sock",
"hostname": "exit-node",
"user_id": 4041918547170221,
"tags": ["tag:exit"],
"ipv4": "100.85.66.106",
"ipv6": "fd7a:115c:a1e0::7c37:426a"
},
"subnet-router": {
"mts_name": "subnet-router",
"socket": "/home/kradalby/.config/multi-tailscale-dev/subnet-router/tailscaled.sock",
"hostname": "subnet-router",
"user_id": 7489538288452506,
"tags": ["tag:router"],
"ipv4": "100.92.142.61",
"ipv6": "fd7a:115c:a1e0::3e37:8e3d",
"routable_ips": ["10.33.0.0/16"],
"approved_routes": ["10.33.0.0/16"]
},
"tagged-client": {
"mts_name": "tagged-client",
"socket": "/home/kradalby/.config/multi-tailscale-dev/tagged-client/tailscaled.sock",
"hostname": "tagged-client",
"user_id": 4031348162889210,
"tags": ["tag:client"],
"ipv4": "100.83.200.69",
"ipv6": "fd7a:115c:a1e0::c537:c845"
},
"tagged-prod": {
"mts_name": "tagged-prod",
"socket": "/home/kradalby/.config/multi-tailscale-dev/tagged-prod/tailscaled.sock",
"hostname": "tagged-prod",
"user_id": 301794218943819,
"tags": ["tag:prod"],
"ipv4": "100.103.8.15",
"ipv6": "fd7a:115c:a1e0::5b37:80f"
},
"tagged-server": {
"mts_name": "tagged-server",
"socket": "/home/kradalby/.config/multi-tailscale-dev/tagged-server/tailscaled.sock",
"hostname": "tagged-server",
"user_id": 1440249486084758,
"tags": ["tag:server"],
"ipv4": "100.108.74.26",
"ipv6": "fd7a:115c:a1e0::b901:4a87"
},
"user-kris": {
"mts_name": "user-kris",
"socket": "/home/kradalby/.config/multi-tailscale-dev/user-kris/tailscaled.sock",
"hostname": "user-kris",
"user_id": 4538565228176803,
"tags": [],
"ipv4": "100.110.121.96",
"ipv6": "fd7a:115c:a1e0::1737:7960"
},
"user-mon": {
"mts_name": "user-mon",
"socket": "/home/kradalby/.config/multi-tailscale-dev/user-mon/tailscaled.sock",
"hostname": "user-mon",
"user_id": 3982058329734709,
"tags": [],
"ipv4": "100.103.90.82",
"ipv6": "fd7a:115c:a1e0::9e37:5a52"
},
"user1": {
"mts_name": "user1",
"socket": "/home/kradalby/.config/multi-tailscale-dev/user1/tailscaled.sock",
"hostname": "user1",
"user_id": 4156223528223174,
"tags": [],
"ipv4": "100.90.199.68",
"ipv6": "fd7a:115c:a1e0::2d01:c747"
}
}
},
"captures": {
"exit-node": {
"commands": {
"packet_filter_rules": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/exit-node/tailscaled.sock debug localapi POST debug-packet-filter-rules",
"packet_filter_matches": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/exit-node/tailscaled.sock debug localapi POST debug-packet-filter-matches"
},
"packet_filter_rules": null,
"packet_filter_matches": [],
"whois": {
"100.92.142.61": {
"peer_name": "subnet-router",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/exit-node/tailscaled.sock whois --json 100.92.142.61",
"response": null
},
"100.83.200.69": {
"peer_name": "tagged-client",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/exit-node/tailscaled.sock whois --json 100.83.200.69",
"response": null
},
"100.103.8.15": {
"peer_name": "tagged-prod",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/exit-node/tailscaled.sock whois --json 100.103.8.15",
"response": null
},
"100.108.74.26": {
"peer_name": "tagged-server",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/exit-node/tailscaled.sock whois --json 100.108.74.26",
"response": null
},
"100.110.121.96": {
"peer_name": "user-kris",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/exit-node/tailscaled.sock whois --json 100.110.121.96",
"response": null
},
"100.103.90.82": {
"peer_name": "user-mon",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/exit-node/tailscaled.sock whois --json 100.103.90.82",
"response": null
},
"100.90.199.68": {
"peer_name": "user1",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/exit-node/tailscaled.sock whois --json 100.90.199.68",
"response": null
}
}
},
"subnet-router": {
"commands": {
"packet_filter_rules": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/subnet-router/tailscaled.sock debug localapi POST debug-packet-filter-rules",
"packet_filter_matches": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/subnet-router/tailscaled.sock debug localapi POST debug-packet-filter-matches"
},
"packet_filter_rules": null,
"packet_filter_matches": [],
"whois": {
"100.85.66.106": {
"peer_name": "exit-node",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/subnet-router/tailscaled.sock whois --json 100.85.66.106",
"response": null
},
"100.83.200.69": {
"peer_name": "tagged-client",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/subnet-router/tailscaled.sock whois --json 100.83.200.69",
"response": null
},
"100.103.8.15": {
"peer_name": "tagged-prod",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/subnet-router/tailscaled.sock whois --json 100.103.8.15",
"response": null
},
"100.108.74.26": {
"peer_name": "tagged-server",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/subnet-router/tailscaled.sock whois --json 100.108.74.26",
"response": null
},
"100.110.121.96": {
"peer_name": "user-kris",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/subnet-router/tailscaled.sock whois --json 100.110.121.96",
"response": null
},
"100.103.90.82": {
"peer_name": "user-mon",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/subnet-router/tailscaled.sock whois --json 100.103.90.82",
"response": null
},
"100.90.199.68": {
"peer_name": "user1",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/subnet-router/tailscaled.sock whois --json 100.90.199.68",
"response": null
}
}
},
"tagged-client": {
"commands": {
"packet_filter_rules": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/tagged-client/tailscaled.sock debug localapi POST debug-packet-filter-rules",
"packet_filter_matches": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/tagged-client/tailscaled.sock debug localapi POST debug-packet-filter-matches"
},
"packet_filter_rules": null,
"packet_filter_matches": [],
"whois": {
"100.85.66.106": {
"peer_name": "exit-node",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/tagged-client/tailscaled.sock whois --json 100.85.66.106",
"response": null
},
"100.92.142.61": {
"peer_name": "subnet-router",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/tagged-client/tailscaled.sock whois --json 100.92.142.61",
"response": null
},
"100.103.8.15": {
"peer_name": "tagged-prod",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/tagged-client/tailscaled.sock whois --json 100.103.8.15",
"response": null
},
"100.108.74.26": {
"peer_name": "tagged-server",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/tagged-client/tailscaled.sock whois --json 100.108.74.26",
"response": null
},
"100.110.121.96": {
"peer_name": "user-kris",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/tagged-client/tailscaled.sock whois --json 100.110.121.96",
"response": null
},
"100.103.90.82": {
"peer_name": "user-mon",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/tagged-client/tailscaled.sock whois --json 100.103.90.82",
"response": null
},
"100.90.199.68": {
"peer_name": "user1",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/tagged-client/tailscaled.sock whois --json 100.90.199.68",
"response": null
}
}
},
"tagged-prod": {
"commands": {
"packet_filter_rules": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/tagged-prod/tailscaled.sock debug localapi POST debug-packet-filter-rules",
"packet_filter_matches": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/tagged-prod/tailscaled.sock debug localapi POST debug-packet-filter-matches"
},
"packet_filter_rules": null,
"packet_filter_matches": [],
"whois": {
"100.85.66.106": {
"peer_name": "exit-node",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/tagged-prod/tailscaled.sock whois --json 100.85.66.106",
"response": null
},
"100.92.142.61": {
"peer_name": "subnet-router",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/tagged-prod/tailscaled.sock whois --json 100.92.142.61",
"response": null
},
"100.83.200.69": {
"peer_name": "tagged-client",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/tagged-prod/tailscaled.sock whois --json 100.83.200.69",
"response": null
},
"100.108.74.26": {
"peer_name": "tagged-server",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/tagged-prod/tailscaled.sock whois --json 100.108.74.26",
"response": null
},
"100.110.121.96": {
"peer_name": "user-kris",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/tagged-prod/tailscaled.sock whois --json 100.110.121.96",
"response": null
},
"100.103.90.82": {
"peer_name": "user-mon",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/tagged-prod/tailscaled.sock whois --json 100.103.90.82",
"response": null
},
"100.90.199.68": {
"peer_name": "user1",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/tagged-prod/tailscaled.sock whois --json 100.90.199.68",
"response": null
}
}
},
"tagged-server": {
"commands": {
"packet_filter_rules": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/tagged-server/tailscaled.sock debug localapi POST debug-packet-filter-rules",
"packet_filter_matches": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/tagged-server/tailscaled.sock debug localapi POST debug-packet-filter-matches"
},
"packet_filter_rules": null,
"packet_filter_matches": [],
"whois": {
"100.85.66.106": {
"peer_name": "exit-node",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/tagged-server/tailscaled.sock whois --json 100.85.66.106",
"response": null
},
"100.92.142.61": {
"peer_name": "subnet-router",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/tagged-server/tailscaled.sock whois --json 100.92.142.61",
"response": null
},
"100.83.200.69": {
"peer_name": "tagged-client",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/tagged-server/tailscaled.sock whois --json 100.83.200.69",
"response": null
},
"100.103.8.15": {
"peer_name": "tagged-prod",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/tagged-server/tailscaled.sock whois --json 100.103.8.15",
"response": null
},
"100.110.121.96": {
"peer_name": "user-kris",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/tagged-server/tailscaled.sock whois --json 100.110.121.96",
"response": null
},
"100.103.90.82": {
"peer_name": "user-mon",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/tagged-server/tailscaled.sock whois --json 100.103.90.82",
"response": null
},
"100.90.199.68": {
"peer_name": "user1",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/tagged-server/tailscaled.sock whois --json 100.90.199.68",
"response": null
}
}
},
"user-kris": {
"commands": {
"packet_filter_rules": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/user-kris/tailscaled.sock debug localapi POST debug-packet-filter-rules",
"packet_filter_matches": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/user-kris/tailscaled.sock debug localapi POST debug-packet-filter-matches"
},
"packet_filter_rules": null,
"packet_filter_matches": [],
"whois": {
"100.85.66.106": {
"peer_name": "exit-node",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/user-kris/tailscaled.sock whois --json 100.85.66.106",
"response": null
},
"100.92.142.61": {
"peer_name": "subnet-router",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/user-kris/tailscaled.sock whois --json 100.92.142.61",
"response": null
},
"100.83.200.69": {
"peer_name": "tagged-client",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/user-kris/tailscaled.sock whois --json 100.83.200.69",
"response": null
},
"100.103.8.15": {
"peer_name": "tagged-prod",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/user-kris/tailscaled.sock whois --json 100.103.8.15",
"response": null
},
"100.108.74.26": {
"peer_name": "tagged-server",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/user-kris/tailscaled.sock whois --json 100.108.74.26",
"response": null
},
"100.103.90.82": {
"peer_name": "user-mon",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/user-kris/tailscaled.sock whois --json 100.103.90.82",
"response": null
},
"100.90.199.68": {
"peer_name": "user1",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/user-kris/tailscaled.sock whois --json 100.90.199.68",
"response": null
}
}
},
"user-mon": {
"commands": {
"packet_filter_rules": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/user-mon/tailscaled.sock debug localapi POST debug-packet-filter-rules",
"packet_filter_matches": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/user-mon/tailscaled.sock debug localapi POST debug-packet-filter-matches"
},
"packet_filter_rules": null,
"packet_filter_matches": [],
"whois": {
"100.85.66.106": {
"peer_name": "exit-node",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/user-mon/tailscaled.sock whois --json 100.85.66.106",
"response": null
},
"100.92.142.61": {
"peer_name": "subnet-router",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/user-mon/tailscaled.sock whois --json 100.92.142.61",
"response": null
},
"100.83.200.69": {
"peer_name": "tagged-client",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/user-mon/tailscaled.sock whois --json 100.83.200.69",
"response": null
},
"100.103.8.15": {
"peer_name": "tagged-prod",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/user-mon/tailscaled.sock whois --json 100.103.8.15",
"response": null
},
"100.108.74.26": {
"peer_name": "tagged-server",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/user-mon/tailscaled.sock whois --json 100.108.74.26",
"response": null
},
"100.110.121.96": {
"peer_name": "user-kris",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/user-mon/tailscaled.sock whois --json 100.110.121.96",
"response": null
},
"100.90.199.68": {
"peer_name": "user1",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/user-mon/tailscaled.sock whois --json 100.90.199.68",
"response": null
}
}
},
"user1": {
"commands": {
"packet_filter_rules": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/user1/tailscaled.sock debug localapi POST debug-packet-filter-rules",
"packet_filter_matches": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/user1/tailscaled.sock debug localapi POST debug-packet-filter-matches"
},
"packet_filter_rules": null,
"packet_filter_matches": [],
"whois": {
"100.85.66.106": {
"peer_name": "exit-node",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/user1/tailscaled.sock whois --json 100.85.66.106",
"response": null
},
"100.92.142.61": {
"peer_name": "subnet-router",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/user1/tailscaled.sock whois --json 100.92.142.61",
"response": null
},
"100.83.200.69": {
"peer_name": "tagged-client",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/user1/tailscaled.sock whois --json 100.83.200.69",
"response": null
},
"100.103.8.15": {
"peer_name": "tagged-prod",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/user1/tailscaled.sock whois --json 100.103.8.15",
"response": null
},
"100.108.74.26": {
"peer_name": "tagged-server",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/user1/tailscaled.sock whois --json 100.108.74.26",
"response": null
},
"100.110.121.96": {
"peer_name": "user-kris",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/user1/tailscaled.sock whois --json 100.110.121.96",
"response": null
},
"100.103.90.82": {
"peer_name": "user-mon",
"command": "/home/kradalby/go/bin/tailscale --socket=/home/kradalby/.config/multi-tailscale-dev/user1/tailscaled.sock whois --json 100.103.90.82",
"response": null
}
}
}
}
}