MCPcopy Index your code
hub / github.com/tailscale/tailscale / mapLocalUser

Function mapLocalUser

ssh/tailssh/tailssh.go:1252–1261  ·  view source on GitHub ↗
(ruleSSHUsers map[string]string, reqSSHUser string)

Source from the content-addressed store, hash-verified

1250}
1251
1252func mapLocalUser(ruleSSHUsers map[string]string, reqSSHUser string) (localUser string) {
1253 v, ok := ruleSSHUsers[reqSSHUser]
1254 if !ok {
1255 v = ruleSSHUsers["*"]
1256 }
1257 if v == "=" {
1258 return reqSSHUser
1259 }
1260 return v
1261}
1262
1263func (c *conn) anyPrincipalMatches(ps []*tailcfg.SSHPrincipal) bool {
1264 for _, p := range ps {

Callers 1

matchRuleMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…