HomeFreeBSD

Fix NFS credential

Description

Fix NFS credential

The commit f74b821 caused a regression where creating file through NFS will
always create a file owned by root. This is because the patch enables the KSID
code in zfs_acl_ids_create, which it would use euid and egid of the current
process. However, on Linux, we should use fsuid and fsgid for file operations,
which is the original behaviour. So we revert this part of code.

The patch also enables secpolicy_vnode_*, since they are also used in file
operations, we change them to use fsuid and fsgid.

Signed-off-by: Chunwei Chen <david.chen@osnexus.com>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes #4772
Closes #4758

Details

Provenance
Chunwei Chen <david.chen@osnexus.com>Authored on Jun 18 2016, 12:36 AM
Brian Behlendorf <behlendorf1@llnl.gov>Committed on Jun 21 2016, 4:58 PM
Parents
rGab9f4b0b824a: SIMD implementation of vdev_raidz generate and reconstruct routines
Branches
Unknown
Tags
Unknown

Event Timeline

Brian Behlendorf <behlendorf1@llnl.gov> committed rG100a91aa3e97: Fix NFS credential (authored by Chunwei Chen <david.chen@osnexus.com>).Jun 21 2016, 4:58 PM