aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJacques Vidrine <nectar@FreeBSD.org>2003-08-10 23:35:21 +0000
committerJacques Vidrine <nectar@FreeBSD.org>2003-08-10 23:35:21 +0000
commit999f613f03c8594a1c510773ca5ba07d9a780162 (patch)
treedbfc91e5790db3baf34e7f21d8ffdb355e2cd376
parent9be7140460e54f1b494b87ae64e5dbde9c0099db (diff)
downloadsrc-999f613f03c8594a1c510773ca5ba07d9a780162.tar.gz
src-999f613f03c8594a1c510773ca5ba07d9a780162.zip
MFC 1.24: Validate the iBCS2 statfs(2) length parameter.
Notes
Notes: svn path=/releng/4.4/; revision=118755
-rw-r--r--UPDATING3
-rw-r--r--sys/conf/newvers.sh2
-rw-r--r--sys/i386/ibcs2/ibcs2_stat.c4
3 files changed, 8 insertions, 1 deletions
diff --git a/UPDATING b/UPDATING
index 9e7c173d06a3..d0c06b46bfa4 100644
--- a/UPDATING
+++ b/UPDATING
@@ -17,6 +17,9 @@ minimal number of processes, if possible, for that patch. For those
updates that don't have an advisory, or to be safe, you can do a full
build and install as described in the COMMON ITEMS section.
+20030810: p39 FreeBSD-SA-03:10.iBCS2
+ iBCS2 system call translator for statfs leaked information.
+
20030810: p38 FreeBSD-SA-03:09.signal
Repair range-checking errors in signal handling.
diff --git a/sys/conf/newvers.sh b/sys/conf/newvers.sh
index ae81c832809e..ca15e7ce1c46 100644
--- a/sys/conf/newvers.sh
+++ b/sys/conf/newvers.sh
@@ -36,7 +36,7 @@
TYPE="FreeBSD"
REVISION="4.4"
-BRANCH="RELEASE-p38"
+BRANCH="RELEASE-p39"
RELEASE="${REVISION}-${BRANCH}"
VERSION="${TYPE} ${RELEASE}"
diff --git a/sys/i386/ibcs2/ibcs2_stat.c b/sys/i386/ibcs2/ibcs2_stat.c
index 863e6e0b7d99..eb3bcb188a09 100644
--- a/sys/i386/ibcs2/ibcs2_stat.c
+++ b/sys/i386/ibcs2/ibcs2_stat.c
@@ -82,6 +82,10 @@ cvt_statfs(sp, buf, len)
{
struct ibcs2_statfs ssfs;
+ if (len < 0)
+ return (EINVAL);
+ else if (len > sizeof(ssfs))
+ len = sizeof(ssfs);
bzero(&ssfs, sizeof ssfs);
ssfs.f_fstyp = 0;
ssfs.f_bsize = sp->f_bsize;