mirror of
https://github.com/yarrick/iodine.git
synced 2025-01-12 02:49:30 +00:00
ebf4e7ee9e
Under Linux, a process may not be run under root, yet it may have a permission to do what a superuser may do given specific capabilities are granted. This commit makes iodine not depend on EUID being 0 in order to run properly. Instead, in presence of libcap-ng, the following capabilities are being checked: * `CAP_NET_BIND_SERVICES` for server to bind to a port, lower than `/proc/sys/net/ipv4/ip_unprivileged_port_start` * `CAP_NET_ADMIN` to operate on a TUN device * `CAP_SETUID` and `CAP_SETGID` in case server is configured to change the user it runs on behalf of This change is handy if iodine is being run under a non-root user, provided `AmbientCapabilities=` and `CapabilityBoundingSet=` of systemd are employed in the first place. Fixes: https://github.com/yarrick/iodine/issues/80 Signed-off-by: Oleksandr Natalenko <oleksandr@redhat.com> |
||
---|---|---|
.. | ||
Android.16.mk | ||
Android.mk | ||
android_dns.h | ||
base32.c | ||
base64.c | ||
base128.c | ||
client.c | ||
client.h | ||
common.c | ||
common.h | ||
dns.c | ||
dns.h | ||
encoding.c | ||
encoding.h | ||
fw_query.c | ||
fw_query.h | ||
iodine.c | ||
iodined.c | ||
login.c | ||
login.h | ||
Makefile | ||
md5.c | ||
md5.h | ||
osflags | ||
read.c | ||
read.h | ||
tun.c | ||
tun.h | ||
user.c | ||
user.h | ||
util.c | ||
util.h | ||
version.h | ||
windows.h |