net/tsdial: partially fix "tailscale nc" (UserDial) on macOS
At least in the case of dialing a Tailscale IP. Updates #4529 Change-Id: I9fd667d088a14aec4a56e23aabc2b1ffddafa3fe Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
This commit is contained in:

committed by
Brad Fitzpatrick

parent
a5e1f7d703
commit
b0fbd85592
@ -40,6 +40,15 @@ func OS() string {
|
||||
return runtime.GOOS
|
||||
}
|
||||
|
||||
// IsMacGUIVariant reports whether runtime.GOOS=="darwin" and this one of the
|
||||
// two GUI variants (that is, not tailscaled-on-macOS).
|
||||
// This predicate should not be used to determine sandboxing properties. It's
|
||||
// meant for callers to determine whether the NetworkExtension-like auto-netns
|
||||
// is in effect.
|
||||
func IsMacGUIVariant() bool {
|
||||
return IsMacAppStore() || IsMacSysExt()
|
||||
}
|
||||
|
||||
// IsSandboxedMacOS reports whether this process is a sandboxed macOS
|
||||
// process (either the app or the extension). It is true for the Mac App Store
|
||||
// and macsys (System Extension) version on macOS, and false for
|
||||
|
Reference in New Issue
Block a user