This patch against 2.6.5-rc3 (also applies to 2.6.5-rc3-mm4) fixes the
type of the ssec pointer in the sk_free_security function. This has no
current impact as the magic element is the top of each structure. Thanks
to Chad Hanson of TCS for discovering the bug and submitting the patch.
Index: linux-2.6/security/selinux/hooks.c
===================================================================
RCS file: /nfshome/pal/CVS/linux-2.6/security/selinux/hooks.c,v
retrieving revision 1.103
diff -u -r1.103 hooks.c
--- linux-2.6/security/selinux/hooks.c 25 Mar 2004 17:07:07 -0000 1.103
+++ linux-2.6/security/selinux/hooks.c 31 Mar 2004 19:32:05 -0000
@@ -271,7 +271,7 @@
static void sk_free_security(struct sock *sk)
{
- struct task_security_struct *ssec = sk->sk_security;
+ struct sk_security_struct *ssec = sk->sk_security;
if (sk->sk_family != PF_UNIX || ssec->magic != SELINUX_MAGIC)
return;
--
Stephen Smalley <[email protected]>
National Security Agency