Expand description
Detect if you are running as root, restart self with sudo
if needed or setup uid zero when running with the SUID flag set.
Requirements
- The
sudo
program is required to be installed and setup correctly on the target system. - Linux or Mac OS X tested
- It should work on *BSD. However, it is not tested.
Enums
Cross platform representation of the state the current program running
Functions
This checks whether the current process is running as sudo or not. Returns the RunningAs enum as result