diff options
Diffstat (limited to 'net/core/dev.c')
-rw-r--r-- | net/core/dev.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/net/core/dev.c b/net/core/dev.c index e0489ca731c..8e1dc305122 100644 --- a/net/core/dev.c +++ b/net/core/dev.c @@ -114,6 +114,7 @@ #include <linux/wireless.h> #include <net/iw_handler.h> #include <asm/current.h> +#include <linux/audit.h> /* * The list of packet types we will receive (as opposed to discard) @@ -2147,6 +2148,12 @@ void dev_set_promiscuity(struct net_device *dev, int inc) printk(KERN_INFO "device %s %s promiscuous mode\n", dev->name, (dev->flags & IFF_PROMISC) ? "entered" : "left"); + audit_log(current->audit_context, GFP_ATOMIC, + AUDIT_ANOM_PROMISCUOUS, + "dev=%s prom=%d old_prom=%d auid=%u", + dev->name, (dev->flags & IFF_PROMISC), + (old_flags & IFF_PROMISC), + audit_get_loginuid(current->audit_context)); } } |