Title: OpenBSD Connected Socket Ownership Vulnerability
Severity: INFO
Description:
OpenBSD contains a bug that allows users capable of executing local processes to send signals to processes running on the system belonging to other users. This could result in unpredictable behavior or denial of service against the recipient processes. The default action when SIGIO and SIGURG signals are recieved in OpenBSD is "ignore", but this issue could still affect processes designed to catch these signals.
On many UNIX systems, including OpenBSD, asynchronous I/O is implemented using the signal subsystem. Sockets can be set so that once data is available for reading, a SIGIO signal is sent to the process that owns the socket. A SIGURG signal may also be sent to the socket owner process when Out-Of-Band data is recieved. Normally the process signalled is the socket creator, but the PID to be signalled can be set using the fcntl() F_SETOWN operation or ioctl() FIOSETOWN operation.
Normally one process should not be able to set the descriptor owner to an arbitrary process ID owned by another user. Socket ownership information is stored in the socket structure "so_siguid" and "so_sigeuid" by the kernel, and when a signal is to be generated the recipient process UID is checked against these to ensure the operation does not violate the permissions of the process that created the socket. It is noteworthy that authorization is not performed when fcntl() F_SETOWN is called, only when signals are generated.
This vulnerability arises when a connection is completed and accept() is called. The routine that generates the new connected socket, sonewconn1, fails to properly copy the "so_siguid" and "so_sigeuid" fields to the new socket, setting them to zero instead. This causes the permission checking routine to fail when this socket generates signals, allowing SIGIO and SIGURG signals to be sent to unauthorized processes previously defined by F_SETOWN or FIOSETOWN.
An attacker may exploit this vulnerability to send SIGIO or SIGURG signals to arbitrary processes running on a host.
It should be noted that this vulnerability may affect other BSD-based operating systems.
Affected Products:
- OpenBSD OpenBSD 2.0.0
- OpenBSD OpenBSD 2.1.0
- OpenBSD OpenBSD 2.2.0
- OpenBSD OpenBSD 2.3.0
- OpenBSD OpenBSD 2.4.0
- OpenBSD OpenBSD 2.5.0
- OpenBSD OpenBSD 2.6.0
- OpenBSD OpenBSD 2.7.0
- OpenBSD OpenBSD 2.8.0
- OpenBSD OpenBSD 2.9.0
References:
- SecurityFocus: Bugtraq ID 402: AIX SIGIO and SIGURG Signals Vulnerability
Juniper Networks provides this content via a wide variety of sources and production methods. If notified of errors or omissions in the content of this page, Juniper Networks, at its discretion, will modify or remove the page or leave the content as is, depending on various factors including but not limited to the reputation and authority of the party providing the notification. Please use the contact information displayed elsewhere on this page to report any errors or omissions regarding the content on this page.