svn commit: r246412 - head/sys/kern
Sergey Kandaurov
pluknet at FreeBSD.org
Wed Feb 6 15:18:47 UTC 2013
Author: pluknet
Date: Wed Feb 6 15:18:46 2013
New Revision: 246412
URL: http://svnweb.freebsd.org/changeset/base/246412
Log:
Prezero the acl structure which is to be copied to usermode, to avoid
leakage of the previous content of padding and unitialized fields.
Reported by: Ilia Noskov <noskov at nic.ru>
Reviewed by: kib
MFC after: 1 week
Modified:
head/sys/kern/vfs_acl.c
Modified: head/sys/kern/vfs_acl.c
==============================================================================
--- head/sys/kern/vfs_acl.c Wed Feb 6 15:08:41 2013 (r246411)
+++ head/sys/kern/vfs_acl.c Wed Feb 6 15:18:46 2013 (r246412)
@@ -247,7 +247,7 @@ vacl_get_acl(struct thread *td, struct v
struct acl *inkernelacl;
int error;
- inkernelacl = acl_alloc(M_WAITOK);
+ inkernelacl = acl_alloc(M_WAITOK | M_ZERO);
vn_lock(vp, LK_EXCLUSIVE | LK_RETRY);
#ifdef MAC
error = mac_vnode_check_getacl(td->td_ucred, vp, type);
More information about the svn-src-head
mailing list