aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/tunnel/firewall/helpers.go
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--tunnel/firewall/helpers.go17
1 files changed, 0 insertions, 17 deletions
diff --git a/tunnel/firewall/helpers.go b/tunnel/firewall/helpers.go
index 91c6617e..0c9e8e3f 100644
--- a/tunnel/firewall/helpers.go
+++ b/tunnel/firewall/helpers.go
@@ -71,8 +71,6 @@ func wrapErr(err error) error {
return fmt.Errorf("Firewall error at %s:%d: %v", file, line, err)
}
-var ExemptBuiltinAdministrators = false
-
func getCurrentProcessSecurityDescriptor() (*windows.SECURITY_DESCRIPTOR, error) {
var processToken windows.Token
err := windows.OpenProcessToken(windows.CurrentProcess(), windows.TOKEN_QUERY, &processToken)
@@ -111,21 +109,6 @@ func getCurrentProcessSecurityDescriptor() (*windows.SECURITY_DESCRIPTOR, error)
TrusteeValue: windows.TrusteeValueFromSID(sid),
},
}}
- if ExemptBuiltinAdministrators {
- builtinAdmins, err := windows.CreateWellKnownSid(windows.WinBuiltinAdministratorsSid)
- if err != nil {
- return nil, err
- }
- access = append(access, windows.EXPLICIT_ACCESS{
- AccessPermissions: cFWP_ACTRL_MATCH_FILTER,
- AccessMode: windows.GRANT_ACCESS,
- Trustee: windows.TRUSTEE{
- TrusteeForm: windows.TRUSTEE_IS_SID,
- TrusteeType: windows.TRUSTEE_IS_GROUP,
- TrusteeValue: windows.TrusteeValueFromSID(builtinAdmins),
- },
- })
- }
dacl, err := windows.ACLFromEntries(access, nil)
if err != nil {
return nil, wrapErr(err)