mirror of
https://github.com/DNSCrypt/dnscrypt-proxy.git
synced 2024-11-14 12:43:34 +03:00
Revert "Install the windows service as "NT AUTHORITY\NetworkService""
This reverts commit 17db0a658f
.
On Windows, switching to user `NT AUTHORITY\NetworkService` apparently
breaks logging (reported by @Aland_123).
This commit is contained in:
parent
707098a922
commit
8076e206e0
@ -36,9 +36,6 @@ func main() {
|
||||
Description: "Encrypted/authenticated DNS proxy",
|
||||
WorkingDirectory: pwd,
|
||||
}
|
||||
if serviceUserName := serviceStartupUserName(); serviceUserName != nil {
|
||||
svcConfig.UserName = *serviceUserName
|
||||
}
|
||||
svcFlag := flag.String("service", "", fmt.Sprintf("Control the system service: %q", service.ControlAction))
|
||||
app := &App{}
|
||||
svc, err := service.New(app, svcConfig)
|
||||
|
@ -12,10 +12,6 @@ import (
|
||||
"github.com/jedisct1/dlog"
|
||||
)
|
||||
|
||||
func serviceStartupUserName() *string {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (proxy *Proxy) dropPrivilege(userStr string, fds []*os.File) {
|
||||
currentUser, err := user.Current()
|
||||
if err != nil && currentUser.Uid != "0" {
|
||||
|
@ -14,10 +14,6 @@ import (
|
||||
"github.com/jedisct1/dlog"
|
||||
)
|
||||
|
||||
func serviceStartupUserName() *string {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (proxy *Proxy) dropPrivilege(userStr string, fds []*os.File) {
|
||||
currentUser, err := user.Current()
|
||||
if err != nil && currentUser.Uid != "0" {
|
||||
|
@ -2,9 +2,4 @@ package main
|
||||
|
||||
import "os"
|
||||
|
||||
func serviceStartupUserName() *string {
|
||||
userName := "NT AUTHORITY\\NetworkService"
|
||||
return &userName
|
||||
}
|
||||
|
||||
func (proxy *Proxy) dropPrivilege(userStr string, fds []*os.File) {}
|
||||
|
Loading…
Reference in New Issue
Block a user