mirror of
https://github.com/opnsense/src.git
synced 2026-06-09 08:43:19 -04:00
Call prison_check from vfs_suser rather than re-implementing it.
Approved by: re (kib), bz (mentor)
This commit is contained in:
parent
0162436974
commit
f0899a3460
1 changed files with 1 additions and 2 deletions
|
|
@ -461,8 +461,7 @@ vfs_suser(struct mount *mp, struct thread *td)
|
|||
* If the file system was mounted outside the jail of the calling
|
||||
* thread, deny immediately.
|
||||
*/
|
||||
if (mp->mnt_cred->cr_prison != td->td_ucred->cr_prison &&
|
||||
!prison_ischild(td->td_ucred->cr_prison, mp->mnt_cred->cr_prison))
|
||||
if (prison_check(td->td_ucred, mp->mnt_cred) != 0)
|
||||
return (EPERM);
|
||||
|
||||
/*
|
||||
|
|
|
|||
Loading…
Reference in a new issue