diff options
author | nectar <nectar@FreeBSD.org> | 2003-08-10 23:04:55 +0000 |
---|---|---|
committer | nectar <nectar@FreeBSD.org> | 2003-08-10 23:04:55 +0000 |
commit | f5b9f87e772a6fcee8bcad474c3fd99d063c15d4 (patch) | |
tree | 12f0209fc6a10880cdeb076f627efa787cd2a715 /sys/pci/meteor.c | |
parent | 09416455b19e2f92a8958f72868349089319992a (diff) | |
download | FreeBSD-src-f5b9f87e772a6fcee8bcad474c3fd99d063c15d4.zip FreeBSD-src-f5b9f87e772a6fcee8bcad474c3fd99d063c15d4.tar.gz |
Add or correct range checking of signal numbers in system calls and
ioctls.
In the particular case of ptrace(), this commit more-or-less reverts
revision 1.53 of sys_process.c, which appears to have been erroneous.
Reviewed by: iedowse, jhb
Diffstat (limited to 'sys/pci/meteor.c')
-rw-r--r-- | sys/pci/meteor.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/sys/pci/meteor.c b/sys/pci/meteor.c index 670945a..62666cc 100644 --- a/sys/pci/meteor.c +++ b/sys/pci/meteor.c @@ -1392,6 +1392,8 @@ meteor_ioctl(dev_t dev, u_long cmd, caddr_t arg, int flag, struct thread *td) *(u_short *)arg = mtr->fps; break; case METEORSSIGNAL: + if (*(int *)arg < 0 || *(int *)arg > _SIG_MAXSIG) + return EINVAL; mtr->signal = *(int *) arg; if (mtr->signal) { mtr->proc = td->td_proc; |