]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Slightly change the semantics of vnode labels for MAC: rather than
authorRobert Watson <rwatson@FreeBSD.org>
Sat, 26 Oct 2002 14:38:24 +0000 (14:38 +0000)
committerRobert Watson <rwatson@FreeBSD.org>
Sat, 26 Oct 2002 14:38:24 +0000 (14:38 +0000)
commit763bbd2f4f7e9cd2be35b41d00439acfe3493a2d
treec8fd3cabfa2bfa5d30b618f0bd199b68acdff307
parent49d7a091acb496c1a2ea818fafe12922060278d4
Slightly change the semantics of vnode labels for MAC: rather than
"refreshing" the label on the vnode before use, just get the label
right from inception.  For single-label file systems, set the label
in the generic VFS getnewvnode() code; for multi-label file systems,
leave the labeling up to the file system.  With UFS1/2, this means
reading the extended attribute during vfs_vget() as the inode is
pulled off disk, rather than hitting the extended attributes
frequently during operations later, improving performance.  This
also corrects sematics for shared vnode locks, which were not
previously present in the system.  This chances the cache
coherrency properties WRT out-of-band access to label data, but in
an acceptable form.  With UFS1, there is a small race condition
during automatic extended attribute start -- this is not present
with UFS2, and occurs because EAs aren't available at vnode
inception.  We'll introduce a work around for this shortly.

Approved by: re
Obtained from: TrustedBSD Project
Sponsored by: DARPA, Network Associates Laboratories
29 files changed:
sys/conf/files
sys/fs/devfs/devfs_vnops.c
sys/fs/procfs/procfs.c
sys/fs/procfs/procfs.h
sys/fs/procfs/procfs_mac.c [deleted file]
sys/fs/pseudofs/pseudofs.h
sys/fs/pseudofs/pseudofs_vnops.c
sys/kern/kern_mac.c
sys/kern/vfs_subr.c
sys/modules/procfs/Makefile
sys/security/mac/mac_framework.c
sys/security/mac/mac_framework.h
sys/security/mac/mac_internal.h
sys/security/mac/mac_net.c
sys/security/mac/mac_pipe.c
sys/security/mac/mac_policy.h
sys/security/mac/mac_process.c
sys/security/mac/mac_syscalls.c
sys/security/mac/mac_system.c
sys/security/mac/mac_vfs.c
sys/security/mac_biba/mac_biba.c
sys/security/mac_mls/mac_mls.c
sys/security/mac_none/mac_none.c
sys/security/mac_stub/mac_stub.c
sys/security/mac_test/mac_test.c
sys/sys/mac.h
sys/sys/mac_policy.h
sys/ufs/ffs/ffs_vfsops.c
sys/ufs/ufs/ufs_vnops.c