exploit the possibilities
Home Files News &[SERVICES_TAB]About Contact Add New

iDEFENSE Security Advisory 2004-09-30.t

iDEFENSE Security Advisory 2004-09-30.t
Posted Oct 7, 2004
Authored by iDefense Labs | Site idefense.com

iDEFENSE Security Advisory 09.30.04 - Remote exploitation of an input validation vulnerability in Samba allows attackers to access files and directories outside of the specified share path.

tags | advisory, remote
advisories | CVE-2004-0815
SHA-256 | 093d77ea6f8671a498b2960e60a63166e361922696586d3e51dd8af521ab506e

iDEFENSE Security Advisory 2004-09-30.t

Change Mirror Download
Samba Arbitrary File Access Vulnerability 

iDEFENSE Security Advisory 09.30.04
www.idefense.com/application/poi/display?id=146&type=vulnerabilities
September 30, 2004

I. BACKGROUND

Samba is an Open Source/Free Software suite that provides seamless file
and print services to SMB/CIFS clients.

II. DESCRIPTION

Remote exploitation of an input validation vulnerability in Samba allows
attackers to access files and directories outside of the specified share
path.

Each file and directory name passed into Samba is converted and checked
with the functions unix_convert() and check_name(). The main purpose of
the unix_convert() routine is to convert names from the DOS namespace to
Unix namespace. It calls unix_clean_name(), which in turn removes double
slashes, leading './' characters and '..' directory-traversal
characters. check_name() does any final checks necessary to confirm the
validity of the converted filename and calls reduce_name(), which in
turn calls unix_clean_name() for a second time. The end result allows
for an attacker to specify the realpath of any file on the computer.

Example:
/./////etc is passed to unix_clean_name(). It becomes /.///etc. The
leading slash is then trimmed off to make .///etc. It is then passed to
unix_clean_name() again. The resulting string is /etc, which is an
absolute path on the system.

III. ANALYSIS

Successful exploitation allows remote attackers to bypass the specified
share restrictions to gain read, write and list access to files and
directories under the privileges of the user. In situations where a
public share is available, the attack can be performed by
unauthenticated attackers.

An attacker does not need exploit code to exploit this vulnerability.
The smbclient program can be used to request/write/list files using the
"get", "put" and "dir" commands, respectively.

IV. DETECTION

iDEFENSE has confirmed that Samba versions 3.0.2 and 2.2.9 are
vulnerable. It is suspected that all versions of Samba are vulnerable.

V. WORKAROUND

Only allow trusted users/hosts to connect to samba shares.

VI. VENDOR RESPONSE

Samba 2.2.12 upgrade for Samba 2.2.x:
http://us4.samba.org/samba/ftp/samba-2.2.12.tar.gz

Samba 3.0.5 patch:
http://us4.samba.org/samba/ftp/patches/security/samba-3.0.5-reduce_name.
patch

Samba 3.0.7 is not vulnerable.

VII. CVE INFORMATION

The Common Vulnerabilities and Exposures (CVE) project has assigned the
names CAN-2004-0815 to these issues. This is a candidate for inclusion
in the CVE list (http://cve.mitre.org), which standardizes names for
security problems.

VIII. DISCLOSURE TIMELINE

09/22/2004 Initial vendor notification
09/22/2004 iDEFENSE clients notified
09/22/2004 Initial vendor response
09/30/2004 Coordinated public disclosure

IX. CREDIT

Karol Wiesek is credited with this discovery.

Get paid for vulnerability research
http://www.idefense.com/poi/teams/vcp.jsp

X. LEGAL NOTICES

Copyright (c) 2004 iDEFENSE, Inc.

Permission is granted for the redistribution of this alert
electronically. It may not be edited in any way without the express
written consent of iDEFENSE. If you wish to reprint the whole or any
part of this alert in any other medium other than electronically, please
email customerservice@idefense.com for permission.

Disclaimer: The information in the advisory is believed to be accurate
at the time of publishing based on currently available information. Use
of the information constitutes acceptance for use in an AS IS condition.
There are no warranties with regard to this information. Neither the
author nor the publisher accepts any liability for any direct, indirect,
or consequential loss or damage arising from use of, or reliance on,
this information.
Login or Register to add favorites

File Archive:

July 2024

  • Su
  • Mo
  • Tu
  • We
  • Th
  • Fr
  • Sa
  • 1
    Jul 1st
    27 Files
  • 2
    Jul 2nd
    10 Files
  • 3
    Jul 3rd
    35 Files
  • 4
    Jul 4th
    27 Files
  • 5
    Jul 5th
    18 Files
  • 6
    Jul 6th
    0 Files
  • 7
    Jul 7th
    0 Files
  • 8
    Jul 8th
    28 Files
  • 9
    Jul 9th
    44 Files
  • 10
    Jul 10th
    24 Files
  • 11
    Jul 11th
    25 Files
  • 12
    Jul 12th
    11 Files
  • 13
    Jul 13th
    0 Files
  • 14
    Jul 14th
    0 Files
  • 15
    Jul 15th
    0 Files
  • 16
    Jul 16th
    0 Files
  • 17
    Jul 17th
    0 Files
  • 18
    Jul 18th
    0 Files
  • 19
    Jul 19th
    0 Files
  • 20
    Jul 20th
    0 Files
  • 21
    Jul 21st
    0 Files
  • 22
    Jul 22nd
    0 Files
  • 23
    Jul 23rd
    0 Files
  • 24
    Jul 24th
    0 Files
  • 25
    Jul 25th
    0 Files
  • 26
    Jul 26th
    0 Files
  • 27
    Jul 27th
    0 Files
  • 28
    Jul 28th
    0 Files
  • 29
    Jul 29th
    0 Files
  • 30
    Jul 30th
    0 Files
  • 31
    Jul 31st
    0 Files

Top Authors In Last 30 Days

File Tags

Systems

packet storm

© 2022 Packet Storm. All rights reserved.

Services
Security Services
Hosting By
Rokasec
close