mirror of
https://github.com/freebsd/freebsd-src
synced 2024-07-22 02:37:15 +00:00
Allow any user to read the NFS stats, for example with nfsstat(1).
This was originally allowed by3cea29603d
(2011). But it got broken by693957f886
(2016) and apparently nobody noticed. MFC after: 1 week Sponsored by: Axcient Reviewed by: rmacklem, ken Differential Revision: https://reviews.freebsd.org/D37589
This commit is contained in:
parent
97c802923e
commit
d2ce00e9a6
|
@ -85,7 +85,7 @@ sys_nfssvc(struct thread *td, struct nfssvc_args *uap)
|
|||
AUDIT_ARG_CMD(uap->flag);
|
||||
|
||||
/* Allow anyone to get the stats. */
|
||||
if ((uap->flag & ~NFSSVC_GETSTATS) != 0) {
|
||||
if ((uap->flag & ~(NFSSVC_GETSTATS | NFSSVC_NEWSTRUCT)) != 0) {
|
||||
error = priv_check(td, PRIV_NFS_DAEMON);
|
||||
if (error != 0)
|
||||
return (error);
|
||||
|
|
Loading…
Reference in a new issue