shadowbrokers-exploits/windows/Resources/Dsz/Scripts/Include/unix/_ProcessesUnix.dsi
2017-04-14 11:45:07 +02:00

20 lines
498 B
Text

@include "_Users.dsi";
#-------------------------------------------------------------------------------
# _IsProcessRunningAsRoot
# Determines whether the current process is running as root
#-------------------------------------------------------------------------------
Sub _IsProcessRunningAsRoot()
{
string $user;
if (_GetCurrentUser($user) &&
defined($user) &&
($user == "root")) {
return true;
} else {
return false;
}
} /* END _IsProcessRunningAsRoot */