setcap cap_net_raw,cap_net_admin,cap_sys_admin,cap_dac_override,cap_dac_read_search,cap_fowner+eip
I want a process running by normal user, switch to another process's netns, another process is running by root user. What I need to do is to open /proc/pid/ns/net
and then call setns
.
I have given many capabilities to the executable as above, but it still says Permission denied
. Any ideas?