Declaration of environment setup routines that requires root privileges. More...
#include <string>
#include <vector>
#include <functional>
#include <sys/types.h>
Go to the source code of this file.
Namespaces | |
utils | |
Functions | |
bool | utils::setSuppGroups (const std::vector< std::string > &groups) |
Set supplementary groups to the current process. More... | |
bool | utils::dropRoot (uid_t uid, gid_t gid, const std::vector< unsigned int > &caps) |
Set effective and permitted capabilities on the current process and drop root privileges. More... | |
bool | utils::launchAsRoot (const std::function< bool()> &func) |
Launch func as root user. More... | |
bool | utils::joinToNs (int nsPid, int ns) |
Join to namespace. More... | |
int | utils::passNamespacedFd (int nsPid, int ns, const std::function< int()> &fdFactory) |
Pass file descriptor from namespace of some process. More... | |
Declaration of environment setup routines that requires root privileges.