[UNIX] sh-httpd Wildcard Character Vulnerability

From: SecuriTeam (support_at_securiteam.com)
Date: 10/28/03

  • Next message: SecuriTeam: "[TOOL] Btscanner - Bluetooth Scanner"
    To: list@securiteam.com
    Date: 28 Oct 2003 11:01:00 +0200
    
    

    The following security advisory is sent to the securiteam mailing list, and can be found at the SecuriTeam web site: http://www.securiteam.com
    - - promotion

    The SecuriTeam alerts list - Free, Accurate, Independent.

    Get your security news from a reliable source.
    http://www.securiteam.com/mailinglist.html

    - - - - - - - - -

      sh-httpd Wildcard Character Vulnerability
    ------------------------------------------------------------------------

    SUMMARY

     <http://lrp.steinkuehler.net/Packages/weblet.htm> sh-httpd is "a shell
    script-based web server that supports GET and HEAD methods and a CGI 1.1
    interface". A vulnerability in the product allows remote attackers to
    execute and read any file they desire by requesting filenames with
    wildcards.

    DETAILS

    Vulnerable systems:
     * sh-httpd version 0.4
     * sh-httpd version 0.3

    By requesting a filename from a remote host and inserting a wildcard ('*')
    with the filename, a remote attacker can read any file from the remote
    server or execute any CGI the attacker desires.

    Examples:
    GET *
    GET ../../../sh-httpd/p*
    GET /../../etc/s*
    GET ../../root/.b*

    Patch:
     === sh-httpd.patch ===

    --- sh-httpd-0.4/sh-httpd Mon Oct 9 11:28:05 2000
    +++ sh-httpd.patch Sat Jul 19 08:51:44 2003
    @@ -31,7 +31,7 @@

     bname() {
            local IFS='/'
    - set -- $1
    + set -- "$1"
            eval rc="\$$#"
            [ "$rc" = "" ] && eval rc="\$$(($# - 1))"
            echo "$rc"
    @@ -262,7 +262,7 @@

            # Split URI into base and query string at ?
            IFS='?'
    - set -- $URI
    + set -- "$URI"
            QUERY_STRING="$2"
            URL="$1"
            IFS=$OIFS
    @@ -292,7 +292,7 @@
            fi

            DIR="`dname $URL`"
    - FILE="`bname $URL`"
    + FILE="`bname "$URL"`"

            # Check for existance of directory
            if [ ! -d "$DOCROOT/$DIR" ]; then
     === eof ===

    ADDITIONAL INFORMATION

    The information has been provided by <mailto:xploit_@_hackermail.com>
    dong-h0un U.

    ========================================

    This bulletin is sent to members of the SecuriTeam mailing list.
    To unsubscribe from the list, send mail with an empty subject line and body to: list-unsubscribe@securiteam.com
    In order to subscribe to the mailing list, simply forward this email to: list-subscribe@securiteam.com

    ====================
    ====================

    DISCLAIMER:
    The information in this bulletin is provided "AS IS" without warranty of any kind.
    In no event shall we be liable for any damages whatsoever including direct, indirect, incidental, consequential, loss of business profits or special damages.


  • Next message: SecuriTeam: "[TOOL] Btscanner - Bluetooth Scanner"

    Relevant Pages

    • [UNIX] Ipswitch WhatsUp SQL Injection Vulnerability
      ... The following security advisory is sent to the securiteam mailing list, and can be found at the SecuriTeam web site: http://www.securiteam.com ... Remote exploitation of a SQL injection vulnerability in Ipswitch Inc.'s ... WhatsUp Professional allows remote attackers to gain administrative access ...
      (Securiteam)
    • [REVS] 0x00 vs ASP File Upload Scripts
      ... The following security advisory is sent to the securiteam mailing list, and can be found at the SecuriTeam web site: http://www.securiteam.com ... ASP, but as with other languages the NULL byte can cause problems when ASP ... does not store it in the filename variable. ...
      (Securiteam)
    • [NEWS] Cisco Secure ACS Denial Of Service Vulnerability
      ... The following security advisory is sent to the securiteam mailing list, and can be found at the SecuriTeam web site: http://www.securiteam.com ... packets which allows remote attackers to cause a denial of service and ... Cisco Secure ACS that support EAP ... triggered if the length field of an EAP-Response packet has a certain big ...
      (Securiteam)
    • [NEWS] Apache "mod_rewrite" LDAP URI Handling Remote Off-By-One Buffer Overflow
      ... The following security advisory is sent to the securiteam mailing list, and can be found at the SecuriTeam web site: http://www.securiteam.com ... A vulnerability has been identified in Apache, ... which could be exploited by remote attackers to execute arbitrary ... Off-by-one error in the the LDAP scheme handling in the Rewrite module ...
      (Securiteam)
    • [UNIX] Snitz Forums 2000 HTTP Response Splitting
      ... The following security advisory is sent to the securiteam mailing list, and can be found at the SecuriTeam web site: http://www.securiteam.com ... An HTTP Response Splitting vulnerability in the product has been found, ... this allows remote attackers to preform several types of attacks against ...
      (Securiteam)