@@ -16,12 +16,6 @@ import (
16
16
// tailsqlCap is the default name of the tailsql capability.
17
17
const tailsqlCap = "tailscale.com/cap/tailsql"
18
18
19
- // PeerCaps is a temporary migration alias for ACLGrants.
20
- // Deprecated: Use ACLGrants directly for new code.
21
- func PeerCaps (logf logger.Logf ) func (string , * apitype.WhoIsResponse ) error {
22
- return ACLGrants (logf )
23
- }
24
-
25
19
// ACLGrants returns an authorization function that uses ACL grants from the
26
20
// tailnet to check access for query sources.
27
21
// If logf == nil, logs are sent to log.Printf.
@@ -41,16 +35,8 @@ func ACLGrants(logf logger.Logf) func(string, *apitype.WhoIsResponse) error {
41
35
DataSrc []string `json:"src"`
42
36
}
43
37
rules , err := tailcfg .UnmarshalCapJSON [rule ](who .CapMap , tailsqlCap )
44
-
45
- // TODO(creachadair): As a temporary measure to allow us to migrate
46
- // capability names away from the https:// prefix, if we don't get a
47
- // result without the prefix, try again with it. Remove this once the
48
- // policy has been updated on the server side.
49
- if err == nil && len (rules ) == 0 {
50
- rules , err = tailcfg .UnmarshalCapJSON [rule ](who .CapMap , "https://" + tailsqlCap )
51
- }
52
38
if err != nil || len (rules ) == 0 {
53
- return errors .New ("not authorized for access tailsql" )
39
+ return errors .New ("not authorized for access to tailsql" )
54
40
}
55
41
for _ , rule := range rules {
56
42
for _ , s := range rule .DataSrc {
0 commit comments