mirror of
https://github.com/opnsense/src.git
synced 2026-05-28 04:12:45 -04:00
o Modify syscons ioctl securelevel checks to use securelevel_gt() (oh look,
yet another API to do direct hardware I/O access.) Obtained from: TrustedBSD Project
This commit is contained in:
parent
19f1565901
commit
8c7cc7234e
1 changed files with 3 additions and 2 deletions
|
|
@ -980,8 +980,9 @@ scioctl(dev_t dev, u_long cmd, caddr_t data, int flag, struct thread *td)
|
|||
error = suser_td(td);
|
||||
if (error != 0)
|
||||
return error;
|
||||
if (securelevel > 0)
|
||||
return EPERM;
|
||||
error = securelevel_gt(td->td_proc->p_ucred, 0);
|
||||
if (error != 0)
|
||||
return error;
|
||||
#ifdef __i386__
|
||||
td->td_frame->tf_eflags |= PSL_IOPL;
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Reference in a new issue