Multiple vendor BSD platforms allows elevated privileges
| bsd-shmat-gain-privileges (15061) |
Description:
Multiple vendor BSD platforms could allow a local attacker to gain elevated privileges on the system, caused by improper incrimination of a shared memory segment's reference count by the shmat function in the System V Shared Memory interface. A local attacker could exploit this vulnerability to obtain sensitive information or gain elevated privileges on the vulnerable system.
Platforms Affected:
- FreeBSD, FreeBSD
- NetBSD, NetBSD 1.5
- NetBSD, NetBSD 1.5.1
- NetBSD, NetBSD 1.5.2
- NetBSD, NetBSD 1.5.3
- NetBSD, NetBSD 1.6
- NetBSD, NetBSD 1.6.1
- OpenBSD, OpenBSD 3.x
Remedy:
For FreeBSD:
Upgrade to the latest version of FreeBSD (RELENG_4, RELENG_5_2, 5.2-RELEASE-p2, RELENG_5_1, 5.1-RELEASE-p14, RELENG_5_0, 5.0-RELEASE-p20, RELENG_4_9, 4.9-RELEASE-p2, RELENG_4_8, 4.8-RELEASE-p15, RELENG_4_7, 4.7-RELEASE-p25), as listed in FreeBSD Security Advisory FreeBSD-SA-04:02.shmat. See References.
For OpenBSD 3.4:
Apply the 010_sysvshm.patch, available from the OpenBSD 3.4 errata Web site. See References.
For OpenBSD 3.3:
Apply the 015_sysvshm.patch, available from the OpenBSD 3.4 errata Web site. See References.
For NetBSD:
Upgrade to the appropriate fixed versions of NetBSD, as listed in NetBSD Security Advisory 2004-004. See References.
For other distributions:
Contact your vendor for upgrade or patch information.
Consequences:
Gain Privileges
References:
- BugTraq Mailing List, Thu Feb 05 2004 - 12:08:39 CST , reference count overflow in shmat() at http://archives.neohapsis.com/archives/bugtraq/2004-02/0141.html.
- FreeBSD Security Advisory FreeBSD-SA-04:02.shmat, shmat reference counting bug at ftp://ftp.freebsd.org/pub/FreeBSD/CERT/advisories/FreeBSD-SA-04:02.shmat.asc.
- NetBSD Security Advisory 2004-004, shmat reference counting bug at http://mail-index.netbsd.org/netbsd-announce/2004/02/19/0003.html.
- OpenBSD 3.3 errata Web site, 015: SECURITY FIX: February 5, 2004 at http://www.openbsd.org/errata33.html#sysvshm.
- OpenBSD 3.4 errata Web site, 010: SECURITY FIX: February 5, 2004 at http://www.openbsd.org/errata.html#sysvshm.
- BID-9586: BSD Kernel SHMAT System Call Privilege Escalation Vulnerability
- CVE-2004-0114: The shmat system call in the System V Shared Memory interface for FreeBSD 5.2 and earlier, NetBSD 1.3 and earlier, and OpenBSD 2.6 and earlier, does not properly decrement a shared memory segment's reference count when the vm_map_find function fails, which could allow local users to gain read or write access to a portion of kernel memory and gain privileges.
- OSVDB ID: 3836: Multiple BSD shmat() Privilege Escalation
Reported:
Feb 05, 2004
The information within this database may change without notice. Use of this information constitutes acceptance for use in an AS IS condition. There are NO warranties, implied or otherwise, with regard to this information or its use. Any use of this information is at the user's risk. In no event shall the author/distributor (Internet Security Systems X-Force) be held liable for any damages whatsoever arising out of or in connection with the use or spread of this information.
Copyright (c) 1994-2008 Internet Security Systems, Inc. All rights reserved worldwide.
For corrections or additions please email xforce@iss.net
