This patch fixes a bug introduced by earlier code cleanups in the
SELinux convert_context code that manifests upon a policy reload that
removes previously valid security attributes. Thanks to Magosanyi Arpad
for reporting the bug.
security/selinux/ss/services.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletion(-)
Index: linux-2.6/security/selinux/ss/services.c
===================================================================
RCS file: /nfshome/pal/CVS/linux-2.6/security/selinux/ss/services.c,v
retrieving revision 1.28
diff -u -r1.28 services.c
--- linux-2.6/security/selinux/ss/services.c 17 Jul 2003 11:33:35 -0000 1.28
+++ linux-2.6/security/selinux/ss/services.c 24 Sep 2003 13:08:40 -0000
@@ -896,13 +896,15 @@
struct user_datum *usrdatum;
char *s;
u32 len;
- int rc = -EINVAL;
+ int rc;
args = p;
rc = context_cpy(&oldc, c);
if (rc)
goto out;
+
+ rc = -EINVAL;
/* Convert the user. */
usrdatum = hashtab_search(args->newp->p_users.table,
--
Stephen Smalley <[email protected]>
National Security Agency