diff options
Diffstat (limited to 'security')
-rw-r--r-- | security/selinux/netif.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/security/selinux/netif.c b/security/selinux/netif.c index b10c34e..e87ab94 100644 --- a/security/selinux/netif.c +++ b/security/selinux/netif.c @@ -20,6 +20,7 @@ #include <linux/notifier.h> #include <linux/netdevice.h> #include <linux/rcupdate.h> +#include <net/net_namespace.h> #include "security.h" #include "objsec.h" @@ -234,6 +235,9 @@ static int sel_netif_netdev_notifier_handler(struct notifier_block *this, { struct net_device *dev = ptr; + if (dev->nd_net != &init_net) + return NOTIFY_DONE; + if (event == NETDEV_DOWN) sel_netif_kill(dev); |