diff options
Diffstat (limited to 'net/ipv4/ipip.c')
-rw-r--r-- | net/ipv4/ipip.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/net/ipv4/ipip.c b/net/ipv4/ipip.c index c26c1717c1db..191fc24a745a 100644 --- a/net/ipv4/ipip.c +++ b/net/ipv4/ipip.c | |||
@@ -691,7 +691,7 @@ ipip_tunnel_ioctl (struct net_device *dev, struct ifreq *ifr, int cmd) | |||
691 | case SIOCADDTUNNEL: | 691 | case SIOCADDTUNNEL: |
692 | case SIOCCHGTUNNEL: | 692 | case SIOCCHGTUNNEL: |
693 | err = -EPERM; | 693 | err = -EPERM; |
694 | if (!capable(CAP_NET_ADMIN)) | 694 | if (!ns_capable(net->user_ns, CAP_NET_ADMIN)) |
695 | goto done; | 695 | goto done; |
696 | 696 | ||
697 | err = -EFAULT; | 697 | err = -EFAULT; |
@@ -735,7 +735,7 @@ ipip_tunnel_ioctl (struct net_device *dev, struct ifreq *ifr, int cmd) | |||
735 | 735 | ||
736 | case SIOCDELTUNNEL: | 736 | case SIOCDELTUNNEL: |
737 | err = -EPERM; | 737 | err = -EPERM; |
738 | if (!capable(CAP_NET_ADMIN)) | 738 | if (!ns_capable(net->user_ns, CAP_NET_ADMIN)) |
739 | goto done; | 739 | goto done; |
740 | 740 | ||
741 | if (dev == ipn->fb_tunnel_dev) { | 741 | if (dev == ipn->fb_tunnel_dev) { |