net: Export ip fragment sysctl to unprivileged users
authorNikolay Borisov <kernel@kyup.com>
Mon, 15 Feb 2016 10:11:32 +0000 (12:11 +0200)
committerDavid S. Miller <davem@davemloft.net>
Wed, 17 Feb 2016 01:42:54 +0000 (20:42 -0500)
Now that all the ip fragmentation related sysctls are namespaceified
there is no reason to hide them anymore from "root" users inside
containers.

Signed-off-by: Nikolay Borisov <kernel@kyup.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv4/ip_fragment.c

index 957161413335f147d6b204ecdedb4879999bf6e7..efbd47d1a53155496e236eb7d4d0c893ef533d1c 100644 (file)
@@ -789,10 +789,6 @@ static int __net_init ip4_frags_ns_ctl_register(struct net *net)
                table[1].extra2 = &net->ipv4.frags.high_thresh;
                table[2].data = &net->ipv4.frags.timeout;
                table[3].data = &net->ipv4.frags.max_dist;
-
-               /* Don't export sysctls to unprivileged users */
-               if (net->user_ns != &init_user_ns)
-                       table[0].procname = NULL;
        }
 
        hdr = register_net_sysctl(net, "net/ipv4", table);