diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2014-11-13 12:46:15 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2014-11-13 12:46:15 -0500 |
commit | 2c54396e40c79876a7ddfd3231c81eedf639795b (patch) | |
tree | 575a05d0965f3ffb407ff313deb3aa5988cbe5e3 | |
parent | 911883759fed56c32b97d73154039b5f8ffcba93 (diff) | |
parent | 09c626892772e6fe03f768b3492fbb126f465fe6 (diff) |
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/linux-security
Pull SELinux fixlet from James Morris:
"WARN_ONCE() here will unnecessarily terrify users"
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/linux-security:
selinux: convert WARN_ONCE() to printk() in selinux_nlmsg_perm()
-rw-r--r-- | security/selinux/hooks.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/security/selinux/hooks.c b/security/selinux/hooks.c index e66314138b38..c603b20356ad 100644 --- a/security/selinux/hooks.c +++ b/security/selinux/hooks.c | |||
@@ -4725,9 +4725,10 @@ static int selinux_nlmsg_perm(struct sock *sk, struct sk_buff *skb) | |||
4725 | err = selinux_nlmsg_lookup(sksec->sclass, nlh->nlmsg_type, &perm); | 4725 | err = selinux_nlmsg_lookup(sksec->sclass, nlh->nlmsg_type, &perm); |
4726 | if (err) { | 4726 | if (err) { |
4727 | if (err == -EINVAL) { | 4727 | if (err == -EINVAL) { |
4728 | WARN_ONCE(1, "selinux_nlmsg_perm: unrecognized netlink message:" | 4728 | printk(KERN_WARNING |
4729 | " protocol=%hu nlmsg_type=%hu sclass=%hu\n", | 4729 | "SELinux: unrecognized netlink message:" |
4730 | sk->sk_protocol, nlh->nlmsg_type, sksec->sclass); | 4730 | " protocol=%hu nlmsg_type=%hu sclass=%hu\n", |
4731 | sk->sk_protocol, nlh->nlmsg_type, sksec->sclass); | ||
4731 | if (!selinux_enforcing || security_get_allow_unknown()) | 4732 | if (!selinux_enforcing || security_get_allow_unknown()) |
4732 | err = 0; | 4733 | err = 0; |
4733 | } | 4734 | } |