Title: Snort RPC Preprocessor Fragment Reassembly Buffer Overflow Vulnerability
Severity: CRITICAL
Description:
Snort is an open-source network intrusion detection system.
A vulnerability in the Snort network IDS has been discovered that may allow for remote attackers to compromise hosts using the system. The vulnerability is due to a programmatic flaw in the RPC preprocessor.
The condition is in the procedure "ConvertRPC()" and occurs during the reassembly of fragmented records. This operation uses a loop that iterates once for each fragment copied to a buffer.
A check put in place to ensure that the total amount of data copied is not greater than the size of the buffer is flawed:
if(length > size)
{
DEBUG_WRAP(DebugMessage(DEBUG_FLOW, "WARNING: rpc_decode calculated bad "
"length: %d\n", length););
return;
}
else
{
total_len += length;
index += 4;
for (i=0; i < length; i++,rpc++,index++,hdrptr++)
*rpc = *index;
}
The expression, "if(length > size)", only verifies that the length of the current fragment is not greater than the total buffer size. The amount of data already written to the buffer is not checked. Consequently, it is possible to write beyond the buffer and over potentially sensitive memory:
for (i=0; i < length; i++,rpc++,index++,hdrptr++)
*rpc = *index;
Attackers can exploit this vulnerability by transmitting malicious packets across a network monitored by Snort. Successful attacks may result in the execution of instructions on the IDS system with root privileges.
Affected Products:
- Conectiva Linux 8.0.0
- Debian Linux 3.0.0
- Debian Linux 3.0.0 alpha
- Debian Linux 3.0.0 arm
- Debian Linux 3.0.0 hppa
- Debian Linux 3.0.0 ia-32
- Debian Linux 3.0.0 ia-64
- Debian Linux 3.0.0 m68k
- Debian Linux 3.0.0 mips
- Debian Linux 3.0.0 mipsel
- Debian Linux 3.0.0 ppc
- Debian Linux 3.0.0 s/390
- Debian Linux 3.0.0 sparc
- Gentoo Linux 1.4.0 _rc2
- Gentoo Linux 1.4.0 _rc3
- SmoothWall SmoothWall 1.0.0
- SmoothWall SmoothWall 2.0.0 Beta 4
- Snort Project Snort 1.8.0
- Snort Project Snort 1.8.1
- Snort Project Snort 1.8.2
- Snort Project Snort 1.8.3
- Snort Project Snort 1.8.4
- Snort Project Snort 1.8.4 beta1
- Snort Project Snort 1.8.5
- Snort Project Snort 1.8.6
- Snort Project Snort 1.8.7
- Snort Project Snort 1.9.0
References:
- ISS X-Force: Snort RPC Preprocessing Vulnerability
- SmoothWall: Fixes2 for SmoothWall GPL 1.0
- Snort: Snort Homepage
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.