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

pico33.txt

pico33.txt
Posted Jun 21, 2005
Authored by Raphael Rigo

Pico Server (pServ) versions 3.3 and below suffer from directory traversal, remote command execution, and heap overflow vulnerabilities.

tags | exploit, remote, overflow, vulnerability
SHA-256 | 1f225e2a45a655bfcf6ac51525c62d4428411528be7b9522b0bdf479cf38f65d

pico33.txt

Change Mirror Download
                 Multiple vulnerabilities in Pico Server (pServ) v3.3

discovered by Raphaƫl Rigo

Product: Pico Server (pServ)
Affected Version: 3.3 (verified), <=3.3 probably too
Not affected Version: 3.4
OS affected: all
Risk: critical
Remote Exploit: yes
URL: http://pserv.sourceforge.net/

Overview
========

Pico Server is a small web server. It is meant to be portable and configurable.
* small, portable
* fast
* CGI-BIN support
* auto-indexing of directories
* access and error logging (see p-reporter for an analyser)
* forking or single-connection at choice

Pico Server (pServ) is written in portable C (K&R style so it can compile on
older compilers too) and sports several options that by means of #define
statements can customize the behaviour, the performance and the feature set so
to be able to fit better the the requisites.

Vulnerabilities
===============

1) Directory traversal

A bug in the directory parsing code allows the attacker to access any
directory the server has the right to access.

Details :
pServ computes the depth of the directory the user tries to access in the
variable named depthCount. This counts is decreased when a /../ is
encountered, unfortunately, it is also increased when /./ is
encountered, allowing the attacker to use a /./ for each /../ to make
sure depthCount is not negative.

Risk : HIGH
The attacker may gain important information about the system that could
lead to other attacks.

Proof of concept :
access : http://www.example.com/./../

Workaround :
There is no workaround for this vulnerability.

Solution :
Update to v3.4

-----------------------------------------------------------------------

2) Remote command execution

The directory traversal vulnerability described above also enables
remote command execution. This may help an attacker to compromise the
server.

Details :
pServ considers every request beginning with /cgi-bin/ as a script
execution.

Risk : CRITICAL
The attacker may use this vulnerability to destroy data or for other
attacks (i.e. use wget to download root exploits).

Proof of concept :
access : http://www.example.com/cgi-bin/./.././../usr/bin/ls

Workaround :
Disable cgi-bin support at compile time.

Solution :
Update to v3.4

-----------------------------------------------------------------------

3) Multiple heap overflows in cgi execution

The lack of bounds checking for cgi arguments allows an attacker to
overflow the allocated memory, possibly allowing for remote code
execution.

Details :
Each argument is allocated a buffer of size MAX_PATH_LEN (128 on Linux)
but the attacker is only limited by the maximum request length (2048).
The malloc'ed buffer can therefore be overflowed.

Risk : HIGH
Successful exploitation can lead to arbitrary code execution.

Workaround :
Disable cgi-bin support at compile time.

Solution :
Update to v3.4

-----------------------------------------------------------------------


Timeline
========
2005-05-18 Discovery
2005-05-19 First attempt to contact developer
2005-05-21 Second attempt
2005-05-22 Developer reply
2005-06-11 Fixed version 3.4 released and advisory published
Login or Register to add favorites

File Archive:

March 2024

  • Su
  • Mo
  • Tu
  • We
  • Th
  • Fr
  • Sa
  • 1
    Mar 1st
    16 Files
  • 2
    Mar 2nd
    0 Files
  • 3
    Mar 3rd
    0 Files
  • 4
    Mar 4th
    32 Files
  • 5
    Mar 5th
    28 Files
  • 6
    Mar 6th
    42 Files
  • 7
    Mar 7th
    17 Files
  • 8
    Mar 8th
    13 Files
  • 9
    Mar 9th
    0 Files
  • 10
    Mar 10th
    0 Files
  • 11
    Mar 11th
    15 Files
  • 12
    Mar 12th
    19 Files
  • 13
    Mar 13th
    21 Files
  • 14
    Mar 14th
    38 Files
  • 15
    Mar 15th
    15 Files
  • 16
    Mar 16th
    0 Files
  • 17
    Mar 17th
    0 Files
  • 18
    Mar 18th
    10 Files
  • 19
    Mar 19th
    32 Files
  • 20
    Mar 20th
    46 Files
  • 21
    Mar 21st
    16 Files
  • 22
    Mar 22nd
    13 Files
  • 23
    Mar 23rd
    0 Files
  • 24
    Mar 24th
    0 Files
  • 25
    Mar 25th
    12 Files
  • 26
    Mar 26th
    31 Files
  • 27
    Mar 27th
    19 Files
  • 28
    Mar 28th
    42 Files
  • 29
    Mar 29th
    0 Files
  • 30
    Mar 30th
    0 Files
  • 31
    Mar 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