Refactor the privilege dropping
On Linux, the libcap is now mandatory. It makes things simpler for us.
System without {set,get}res{uid,gid} now have compatibility shim using setreuid/setregid or seteuid/setegid to setup effective UID/GID, so the same code can be called all the time (including on Linux).
Closes #3583 (closed)
Edited by Ondřej Surý