offlinemark / poet

[unmaintained] Post-exploitation tool
MIT License
183 stars 55 forks source link

server crashes if run directly as root (not sudo) #57

Closed offlinemark closed 9 years ago

offlinemark commented 9 years ago

when the server drops privileges, it looks for uid/gid to drop to via the SUDO_UID and SUDO_GID environment variables, which are automatically set whenever a process is run via sudo. the server doesn't check if these env variables don't exist, and crashes. need to detect this and decide how to proceed. either abort priv dropping and continue running server as root, or add flags to specify who to drop to? i'll probably go with the former, to keep things simple

offlinemark commented 9 years ago

oh this was a dup of #54