Initial commit after restructure
This commit is contained in:
16
process/process_windows.go
Normal file
16
process/process_windows.go
Normal file
@@ -0,0 +1,16 @@
|
||||
package process
|
||||
|
||||
import "strings"
|
||||
|
||||
func (m *Process) IsUser() bool {
|
||||
return m.Pid != 4 && // Kernel
|
||||
!strings.HasPrefix(m.UserName, "NT-") // NT-Authority (localized!)
|
||||
}
|
||||
|
||||
func (m *Process) IsAdmin() bool {
|
||||
return strings.HasPrefix(m.UserName, "NT-") // NT-Authority (localized!)
|
||||
}
|
||||
|
||||
func (m *Process) IsSystem() bool {
|
||||
return m.Pid == 4
|
||||
}
|
||||
Reference in New Issue
Block a user