Skip to content
Commit 8292d7f6 authored by Yang Yang's avatar Yang Yang Committed by David S. Miller
Browse files

net: ipv4: add capability check for net administration



Root in init user namespace can modify /proc/sys/net/ipv4/ip_forward
without CAP_NET_ADMIN, this doesn't follow the principle of
capabilities. For example, let's take a look at netdev_store(),
root can't modify netdev attribute without CAP_NET_ADMIN.
So let's keep the consistency of permission check logic.

Reported-by: default avatarZeal Robot <zealci@zte.com.cn>
Signed-off-by: default avatarYang Yang <yang.yang29@zte.com.cn>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent b79c6fba
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment