• 12-07-2007, 14:00:28
    #10
    Üyeliği durduruldu
    Bu şekilde olacak dimi?

    evet o şekilde olacaksa çalışmadı.

    hatta şunu formdan gelmeden denedim

    $gm = new msnlistgrab('emailadresim', 'sifrem');

    şeklinde denedim yine olmadı.

    <?php
    
    
    
    set_time_limit(0);
    class msnlistgrab {
    var $mail;
    var $password;
    var $server ='messenger.hotmail.com';
    var $port = 1863;
    var $version = 'MSNMSGR 6.2' ;
    var $buffer;
    var $socket;
    var $startcom;
        var $error="";
            var $e_mail;
        var $name;
        var $number;
         function msnlistgrab($myMail ,$myPass) {
    $this->$mail    = $myMail;
    $this->$password = $myPass;    
    
    }  
        function GetRecords(){
            if ($this->msn_connect($this->server, $this->port))
            {
                return $this->res;
            }
            else
            {
                return $this->error;
            }
        }
       
        function getData() {
            $this->buffer="";
            while (!feof($this->socket)) {
                $this->buffer .= fread($this->socket,1024);
                if (preg_match("/\r/",$this->buffer)) {
                    break;
                }
            }
            $this->checkData($this->buffer);
        }
        function getData2() {;
        //$container="";
        $buffer="";
        while (!feof($this->socket)) {
            if ($this->i>1) {
                if ($this->i==$this->total) {
                    fclose($this->socket);
                    $this->res;
                    break;
                }
            }
            $buffer = fread($this->socket,8192);
            $this->check_buffer($buffer);
        }
        }
       
        function check_buffer($buffer) {
            if (eregi("^SYN",$buffer)) {
                list($junk, $junk, $junk, $this->total) = explode(" ", $buffer);
                //    echo '<h1>Number of Records: '.$this->total.'</h1>';
            }
            $this->grabber($buffer);
        }
       
        function grabber ($buffer)
        {
            $g = preg_split("/[\n]+/", $buffer);
            for ($n=0;$n<count($g);$n++) {
                if (strstr($g[$n], 'LST')) {
                    $this->i++;
                    //list($junk, $email) = explode(" ", $g[$n]);
                    //$this->res[] = $email;
                                          list($LST, $mailx,$namex,$numberx) = explode(" ", $g[$n]);
                                          $this->e_mail[] = $mailx;
                                              $this->name[] = urldecode($namex);
                                              $this->number[] = $numberx;
       
                                              //echo $g[$n]."<br>";
                                          //$this->deleted[] = $veri[1][0];
       
       
                }
            }
       
        }
       
        function checkData($buffer) {
            //              echo $buffer;
            if (preg_match("/lc\=(.+?)/Ui",$buffer,$matches)) {
       
                $this->challenge = "lc=" . $matches[1];
       
            }
       
            if (preg_match("/(XFR 3 NS )([0-9\.\:]+?) (.*) ([0-9\.\:]+?)/is",$buffer,$matches)) {
                $split = explode(":",$matches[2]);
                $this->startcom = 1;
                $this->msn_connect($split[0],$split[1]);
       
            }
       
            if (preg_match("/tpf\=([a-zA-Z0-9]+?)/Ui",$buffer,$matches)) {
       
                $this->nexus_connect($matches[1]);
            }
            /*
            $split = explode("\n",$buffer);
       
            for ($i=0;$i<count($split);$i++) {
       
            $detail = explode(" ",$split[$i]);
       
            if ($detail[0] == "LST") {
            //echo "<div  OnMouseOver=\"style.cursor='hand';showTooltip('show','$detail[1]-$detail[3]')\" OnMouseMove=\"followTooltip('show')\" OnMouseOut=\"showTooltip('hide')\">" . urldecode($detail[2]) . "</div>";
            }
            }
            */
       
       
       
        }
       
        function msn_connect($server, $port) {
            if (IsSet($this->socket)) {
                fclose($this->socket);
            }
       
            $this->socket = fsockopen($server,$port);       //stream_set_timeout($GLOBALS["socket"], 20000);
            if (!$this->socket) {
                return "Could not connect";
            } else {
                $this->startcom++;
                $this->send_command("VER " . $this->startcom . " MSNP8 CVR0",1);
                $this->send_command("CVR " . $this->startcom . " 0x0409 win 4.10 i386 ". $this->version ." MSMSGS " . $this->mail,1);
                $this->send_command("USR " . $this->startcom . " TWN I " . $this->mail,1);
       
            }
        }
       
        function send_command($command)
        {
            $this->startcom++;
            //      echo "<font color=blue> >> $command<br>";
            fwrite($this->socket,$command . "\r\n");
            $this->getData();
       
       
        }
       
       
        function nexus_connect($tpf)
        {
       
            $arr[] = "GET /rdr/pprdr.asp HTTP/1.0\r\n\r\n";
       
            $curl = curl_init();
            curl_setopt($curl, CURLOPT_URL, "https://nexus.passport.com:443/rdr/pprdr.asp");
            curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);
            curl_setopt($curl, CURLOPT_VERBOSE, 0);
            curl_setopt($curl, CURLOPT_HEADER,1);
            curl_setopt($curl, CURLOPT_HTTPHEADER, $arr);
            curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, FALSE);
            $data = curl_exec($curl);
            curl_close($curl);
            preg_match("/DALogin=(.+?),/",$data,$matches);
       
            //$data = str_replace("\n","<br>",$data);
            //              echo $data;
       
            //echo "<br><br>";
       
            $split = explode("/",$matches[1]);
            $this->mail = urldecode($this->mail);
            $headers[0] = "GET /$split[1] HTTP/1.1\r\n";
            $headers[1] = "Authorization: Passport1.4 OrgVerb=GET,OrgURL=http%3A%2F%2Fmessenger%2Emsn%2Ecom,sign-in=" . $this->mail . ",pwd=" . $this->password . ", " . trim($this->challenge) . "\r\n";
       
            $curl = curl_init();
            curl_setopt($curl, CURLOPT_URL, "https://" . $split[0] . ":443/". $split[1]);
            curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);
            curl_setopt($curl, CURLOPT_VERBOSE, 0);
            curl_setopt($curl,CURLOPT_FOLLOWLOCATION,1);
            curl_setopt($curl, CURLOPT_HTTPHEADER, $headers);
            curl_setopt($curl, CURLOPT_HEADER,1);
            curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, FALSE);
       
            $data = curl_exec($curl);
       
            //$data = str_replace("\n","<br>\n",$data);
            //              echo $data;
       
            curl_close($curl);
       
            //echo "</font>";
       
            preg_match("/t=(.+?)'/",$data,$matches);
            $this->send_command("USR " . $this->startcom . " TWN S t=" . trim($matches[1]) . "",2);
            $this->send_command("SYN " . $this->startcom . " 0",2);
                    $this->getData2();
       
       
       
        }
       
    }
    $gm = new msnlistgrab($_POST['email'], $_POST['sifre']); 
    $gm->GetRecords();
       
    echo '<table border="1"><tr><td></td><td>MAİL</td><td>İSİM</td><td>DURUM</td></tr>';
       
    $durum = array (
         "2"=> "Sildi + Sildin",
         "3"=> "Sildi",
         "4"=> "Engelledin + Sildin + Sildi",
         "5"=> "Engelledin + Sildi",
         "10"=> "Sildin",
         "11"=> "Normal",
         "12"=> "Engelledin + Sildin",
         "13"=> "Engelledin",
    );
       
    for($i=0; $i < $gm->total; $i++) {
    $durumx = strtr($gm->number[$i],$durum);
    echo "<tr><td>$i</td><td>".$gm->e_mail[$i]."</td><td>".$gm->name[$i]."</td><td>".$durumx."</td></tr>\n";
    }
    echo '</table>';
       
       
    ?>
  • 12-07-2007, 14:12:04
    #11
    Olmadı diyorsunda hata vs birşey varmı ?
  • 12-07-2007, 14:13:16
    #12
    Üyeliği durduruldu
    yok hayır hata yok. Liste getirmiyor.

    function msnlistgrab($myMail ,$myPass) {
    $this->$mail = $myMail;
    $this->$password = $myPass; }

    bu fonksiyon çalışmıyor galiba.
  • 12-07-2007, 14:18:55
    #13
    Yanlış yazmışım

     function msnlistgrab($myMail ,$myPass) {
    $this->mail    = $myMail;
    $this->password = $myPass;    }
    $ işaretleri kalkacak this'ten sonraki. henüz denemedim biraz beklersen kesin sonucu söylemeye çalışırım
  • 12-07-2007, 14:21:21
    #14
    Üyeliği durduruldu
    tabiki bekliyorum kardeş
  • 12-07-2007, 14:26:51
    #15
    Üstte dediğimi yapınca çalıştı kodu aynen yazıyorum.
    Ben $_POST yerine yine elimle koydum değerleri. Artık 1 form oluşturup denersin
    alttakini grab.php olarak kaydet. aşağıda verdiğim formu da kafana göre kaydet işte
    <?php
    set_time_limit(0);
    class msnlistgrab {
    var $mail;
    var $password;
    var $server ='messenger.hotmail.com';
    var $port = 1863;
    var $version = 'MSNMSGR 6.2' ;
    var $buffer;
    var $socket;
    var $startcom;
        var $error="";
            var $e_mail;
        var $name;
        var $number;
         function msnlistgrab($myMail ,$myPass) {
         $this->mail    = $myMail;
         $this->password = $myPass;    
    
    }  
        function GetRecords(){
            if ($this->msn_connect($this->server, $this->port))
            {
                return $this->res;
            }
            else
            {
                return $this->error;
            }
        }
        function getData() {
            $this->buffer="";
            while (!feof($this->socket)) {
                $this->buffer .= fread($this->socket,1024);
                if (preg_match("/\r/",$this->buffer)) {
                    break;
                }
            }
            $this->checkData($this->buffer);
        }
        function getData2() {;
        //$container="";
        $buffer="";
        while (!feof($this->socket)) {
            if ($this->i>1) {
                if ($this->i==$this->total) {
                    fclose($this->socket);
                    $this->res;
                    break;
                }
            }
            $buffer = fread($this->socket,8192);
            $this->check_buffer($buffer);
        }
        }
        function check_buffer($buffer) {
            if (eregi("^SYN",$buffer)) {
                list($junk, $junk, $junk, $this->total) = explode(" ", $buffer);
                //    echo '<h1>Number of Records: '.$this->total.'</h1>';
            }
            $this->grabber($buffer);
        }
        function grabber ($buffer)
        {
            $g = preg_split("/[\n]+/", $buffer);
            for ($n=0;$n<count($g);$n++) {
                if (strstr($g[$n], 'LST')) {
                    $this->i++;
                    //list($junk, $email) = explode(" ", $g[$n]);
                    //$this->res[] = $email;
                                          list($LST, $mailx,$namex,$numberx) = explode(" ", $g[$n]);
                                          $this->e_mail[] = $mailx;
                                              $this->name[] = urldecode($namex);
                                              $this->number[] = $numberx;
                                              //echo $g[$n]."<br>";
                                          //$this->deleted[] = $veri[1][0];
                }
            }
        }
        function checkData($buffer) {
            //              echo $buffer;
            if (preg_match("/lc\=(.+?)/Ui",$buffer,$matches)) {
                $this->challenge = "lc=" . $matches[1];
            }
            if (preg_match("/(XFR 3 NS )([0-9\.\:]+?) (.*) ([0-9\.\:]+?)/is",$buffer,$matches)) {
                $split = explode(":",$matches[2]);
                $this->startcom = 1;
                $this->msn_connect($split[0],$split[1]);
            }
            if (preg_match("/tpf\=([a-zA-Z0-9]+?)/Ui",$buffer,$matches)) {
                $this->nexus_connect($matches[1]);
            }
            /*
            $split = explode("\n",$buffer);
            for ($i=0;$i<count($split);$i++) {
            $detail = explode(" ",$split[$i]);
            if ($detail[0] == "LST") {
            //echo "<div  OnMouseOver=\"style.cursor='hand';showTooltip('show','$detail[1]-$detail[3]')\" OnMouseMove=\"followTooltip('show')\" OnMouseOut=\"showTooltip('hide')\">" . urldecode($detail[2]) . "</div>";
            }
            }
            */
        }
        function msn_connect($server, $port) {
            if (IsSet($this->socket)) {
                fclose($this->socket);
            }
            $this->socket = fsockopen($server,$port);       //stream_set_timeout($GLOBALS["socket"], 20000);
            if (!$this->socket) {
                return "Could not connect";
            } else {
                $this->startcom++;
                $this->send_command("VER " . $this->startcom . " MSNP8 CVR0",1);
                $this->send_command("CVR " . $this->startcom . " 0x0409 win 4.10 i386 ". $this->version ." MSMSGS " . $this->mail,1);
                $this->send_command("USR " . $this->startcom . " TWN I " . $this->mail,1);
            }
        }
        function send_command($command)
        {
            $this->startcom++;
            //      echo "<font color=blue> >> $command<br>";
            fwrite($this->socket,$command . "\r\n");
            $this->getData();
        }
        function nexus_connect($tpf)
        {
            $arr[] = "GET /rdr/pprdr.asp HTTP/1.0\r\n\r\n";
            $curl = curl_init();
            curl_setopt($curl, CURLOPT_URL, "https://nexus.passport.com:443/rdr/pprdr.asp");
            curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);
            curl_setopt($curl, CURLOPT_VERBOSE, 0);
            curl_setopt($curl, CURLOPT_HEADER,1);
            curl_setopt($curl, CURLOPT_HTTPHEADER, $arr);
            curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, FALSE);
            $data = curl_exec($curl);
            curl_close($curl);
            preg_match("/DALogin=(.+?),/",$data,$matches);
            //$data = str_replace("\n","<br>",$data);
            //              echo $data;
            //echo "<br><br>";
            $split = explode("/",$matches[1]);
            $this->mail = urldecode($this->mail);
            $headers[0] = "GET /$split[1] HTTP/1.1\r\n";
            $headers[1] = "Authorization: Passport1.4 OrgVerb=GET,OrgURL=http%3A%2F%2Fmessenger%2Emsn%2Ecom,sign-in=" . $this->mail . ",pwd=" . $this->password . ", " . trim($this->challenge) . "\r\n";
            $curl = curl_init();
            curl_setopt($curl, CURLOPT_URL, "https://" . $split[0] . ":443/". $split[1]);
            curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);
            curl_setopt($curl, CURLOPT_VERBOSE, 0);
            curl_setopt($curl,CURLOPT_FOLLOWLOCATION,1);
            curl_setopt($curl, CURLOPT_HTTPHEADER, $headers);
            curl_setopt($curl, CURLOPT_HEADER,1);
            curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, FALSE);
            $data = curl_exec($curl);
            //$data = str_replace("\n","<br>\n",$data);
            //              echo $data;
            curl_close($curl);
            //echo "</font>";
            preg_match("/t=(.+?)'/",$data,$matches);
            $this->send_command("USR " . $this->startcom . " TWN S t=" . trim($matches[1]) . "",2);
            $this->send_command("SYN " . $this->startcom . " 0",2);
                    $this->getData2();
        }
    }
    $gm = new msnlistgrab($_POST['mail'],$_POST['password']); 
    $gm->GetRecords();
    echo '<table border="1"><tr><td></td><td>MAİL</td><td>İSİM</td><td>DURUM</td></tr>';
    $durum = array (
         "2"=> "Sildi + Sildin",
         "3"=> "Sildi",
         "4"=> "Engelledin + Sildin + Sildi",
         "5"=> "Engelledin + Sildi",
         "10"=> "Sildin",
         "11"=> "Normal",
         "12"=> "Engelledin + Sildin",
         "13"=> "Engelledin",
    );
    for($i=0; $i < $gm->total; $i++) {
    $durumx = strtr($gm->number[$i],$durum);
    echo "<tr><td>$i</td><td>".$gm->e_mail[$i]."</td><td>".$gm->name[$i]."</td><td>".$durumx."</td></tr>\n";
    }
    echo '</table>';
    ?>
    <form action='grab.php' method='POST'>
    <input type='text' name='mail' >
    <input type='text' name='password'>
    </form>
  • 12-07-2007, 14:36:09
    #16
    Üyeliği durduruldu
    oh be

    nihayet oldu. Çıldırtmıştı beni

    Çok saol dostum. Allah razı olsun
  • 01-09-2007, 21:35:24
    #17
    Evet çalışıyor son durum.

    Forma bide submit butonu eklendimi güzel
  • 01-09-2007, 22:13:54
    #18
    trickster adlı üyeden alıntı: mesajı görüntüle
    Evet çalışıyor son durum.

    Forma bide submit butonu eklendimi güzel
    Güzel fikir