From 388c69789a2a2e50965e805e3e641418082b352c Mon Sep 17 00:00:00 2001 From: James Morris Date: Sat, 16 Apr 2005 15:24:03 -0700 Subject: [PATCH] SELinux: fix bug in Netlink message type detection This patch fixes a bug in the SELinux Netlink message type detection code, where the wrong constant was being used in a case statement. The incorrect value is not valid for this class of object so it would not have been reached, and fallen through to a default handler for all Netlink messages. Signed-off-by: James Morris Signed-off-by: Stephen Smalley Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- security/selinux/nlmsgtab.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/security/selinux/nlmsgtab.c b/security/selinux/nlmsgtab.c index fa7fa030e6eb..f79408252730 100644 --- a/security/selinux/nlmsgtab.c +++ b/security/selinux/nlmsgtab.c @@ -126,7 +126,7 @@ int selinux_nlmsg_lookup(u16 sclass, u16 nlmsg_type, u32 *perm) break; case SECCLASS_NETLINK_FIREWALL_SOCKET: - case NETLINK_IP6_FW: + case SECCLASS_NETLINK_IP6FW_SOCKET: err = nlmsg_perm(nlmsg_type, perm, nlmsg_firewall_perms, sizeof(nlmsg_firewall_perms)); break; -- cgit v1.2.3