[samba] [CVE-2007-6015] remote buffer overflow vulnerability
Bug #175502 reported by
disabled.user
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
samba (Gentoo Linux) |
Fix Released
|
Critical
|
|||
samba (Ubuntu) |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
Binary package hint: samba
References:
[1] DSA-1427-1 (http://
[2] CVE-2007-6015 (http://
Quoting [1]:
"Alin Rad Pop discovered that Samba, a LanManager-like file and printer server for Unix, is vulnerable to a buffer overflow in the nmbd code which handles GETDC mailslot requests, which might lead to the execution of arbitrary code."
Changed in samba: | |
status: | Unknown → Fix Released |
Changed in samba (Gentoo Linux): | |
importance: | Unknown → Critical |
To post a comment you must log in.
Secunia Research has discovered a vulnerability in Samba, which can be
exploited by malicious people to compromise a vulnerable system.
The vulnerability is caused due to a boundary error within the
"send_mailslot()" function. This can be exploited to cause a stack-based
buffer overflow with zero bytes via a specially crafted "SAMLOGON"
domain logon packet containing a username string placed at an odd offset
followed by an overly long GETDC string.
Successful exploitation allows execution of arbitrary code, but requires
that the "domain logon" option is enabled.
The vulnerability is confirmed in version 3.0.27a. Other versions may
also be affected.
Vulnerability Details: ------- ------- -
-------
The buffer overflow is triggered by the call to "set_message()" in
nmbd/nmbd_packets.c at line 1895. The "set_message()" function will call
a "memset()" to zero on "dgram->data" + 35 with a length bigger than the
available 576-35 bytes for an overly long total length for the SAMLOGON
GETDC, username, workgroup, and local hostname.
The vulnerability would at first glance be only triggerable in certain pstring( )" processlogon. c will convert the
unusual configurations with an overly long local workgroup or hostname
due to the limitations in size of the NetBIOS Datagram packet (576
bytes). However if an empty (two zero bytes) Unicode username is placed
at an odd offset within the SAMLOGON request, the "pull_ucs2_
function called at line 365 in nmbd/nmbd_
whole GETDC string following the username into ascuser, allowing the
buffer overflow to take place in standard configurations.
Exploitation:
-------------
Secunia Research has created a PoC for the vulnerability, which is
available upon request.
The vulnerability can also be reproduced by sending a SAMLOGON request
with an empty username placed at an odd offset and an overly long GETDC
string (around 250 bytes).
Closing comments:
-----------------
We have assigned this vulnerability Secunia advisory SA27760 and CVE
identifier CVE-2007-6015.
A preliminary disclosure date of 2007-12-05 10am CET has been set, where
the details will be publicly disclosed. However, we are naturally
prepared to push the disclosure date if you need more time to address
the vulnerability.