Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit a02fe132 authored by Josef Bacik's avatar Josef Bacik Committed by James Morris
Browse files

selinux: prevent rentry into the FS

BUG fix.  Keep us from re-entering the fs when we aren't supposed to.

See discussion at
http://marc.info/?t=120716967100004&r=1&w=2



Signed-off-by: default avatarJosef Bacik <jbacik@redhat.com>
Acked-by: default avatarStephen Smalley <sds@tycho.nsa.gov>
Signed-off-by: default avatarJames Morris <jmorris@namei.org>
parent 9597362d
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -180,7 +180,7 @@ static int inode_alloc_security(struct inode *inode)
	struct task_security_struct *tsec = current->security;
	struct inode_security_struct *isec;

	isec = kmem_cache_zalloc(sel_inode_cache, GFP_KERNEL);
	isec = kmem_cache_zalloc(sel_inode_cache, GFP_NOFS);
	if (!isec)
		return -ENOMEM;

@@ -2429,7 +2429,7 @@ static int selinux_inode_init_security(struct inode *inode, struct inode *dir,
		return -EOPNOTSUPP;

	if (name) {
		namep = kstrdup(XATTR_SELINUX_SUFFIX, GFP_KERNEL);
		namep = kstrdup(XATTR_SELINUX_SUFFIX, GFP_NOFS);
		if (!namep)
			return -ENOMEM;
		*name = namep;