tobitaz

scan

Jun 1st, 2021 (edited)
710
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 3.19 KB | None | 0 0
  1. <?php
  2. ini_set('max_execution_time', '0');
  3. set_time_limit(0);
  4.  
  5. echo '
  6. <html>
  7. <head>
  8. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  9. </head>
  10. <style>
  11. body
  12. {
  13. background-color:black;
  14. }
  15. .fon
  16. {
  17. color:green;
  18. }
  19. .tes
  20. {
  21. border-size:3px;
  22. border-color:green;
  23. color:green;
  24. background-color:black;
  25. width:100%;
  26. }
  27. .tj
  28. {
  29. color:white;
  30. font-size:20px;
  31. }
  32. .topright{
  33.  position: absolute;
  34.  right: 0;
  35.  width: 50%;
  36.  height: 120px;
  37.  
  38. }
  39. .topleft{
  40.  position: absolute;
  41.  left: 0px;  
  42.  width: 40%;
  43.  height: 120px;
  44.  
  45. }
  46. .bo{
  47.  position: relative;
  48.  width: 100%;
  49.  height :120px;
  50.  border: 3px solid green;
  51. }
  52. .to{
  53.  position: relative;
  54.  width: 100%;
  55.  height :500%;
  56.  border: 3px solid green;
  57. }
  58.  
  59. .btn
  60. {
  61. background-color:green;
  62. color:black;
  63. border-width:2px;
  64. border-color:green;
  65. width:100%;
  66. }
  67. .re
  68. {
  69. color:red;
  70. font-size:20px;
  71. font-style:italic;
  72. }
  73. </style>
  74. <body>
  75.  
  76. <font class="tj">
  77. Hejes Directory Scanner </font>
  78. <br /><br /><br />
  79. <div class="bo">
  80. <form action="" method="post">
  81. <div class="full">
  82. <div class="topleft">
  83. <font class="fon">wordlist source:
  84. <br />
  85. custom error word:
  86. <br />
  87. Target Url:
  88. <br />
  89. file scan
  90. (.php, .asp, .html):
  91. <br />
  92. <button class="btn" type="submit">SCAN</button>
  93. </font>
  94. </div>
  95.  
  96.  
  97.  
  98.  
  99. <div class="topright">
  100. <input class="tes" name="wl" value="wordlist.txt" />
  101. <br />
  102. <input class="tes" name="myer" value="404" />
  103. <br />
  104. <input class="tes" name="urljom" value="http://">
  105. <br />
  106. <input class="tes" name="ext" value="">
  107. </div>
  108. </form>
  109. </div>
  110. </div>
  111. ';
  112.  
  113.  
  114. $wlist = $_POST["wl"];
  115. $urljom = $_POST["urljom"];
  116. $myerr = $_POST["myer"];
  117. $ext = $_POST["ext"];
  118.  
  119. function cekeror($taz, $tuz, $word)
  120. {
  121.  
  122. $ti = strripos($taz, "not be found");
  123. $ta = strripos($taz, "not exist");
  124. $te = strripos($taz, "not found");
  125. $tazz = strripos($taz, "404");
  126. $tazz1 = strripos($taz, "error");
  127. $tazz2 = strripos($taz, $tuz);
  128.  
  129.  
  130. if($ti === false && $ta === false && $te === false && $tazz === false && $tazz1 === false && $tazz2 === false)
  131. {
  132. return "<font class='fon'>found:<font class='re'>/".$word.$ext."</font></font><br />";
  133.  
  134. }
  135. }
  136.  
  137.  
  138.  
  139. if($urljom != null)
  140. {
  141. $comx = file_get_contents($wlist);
  142.  
  143.   $arrayjom = preg_split('/(\r?\n)+/', $comx);
  144.  
  145. echo "<div class='to'>";
  146. echo "<font class='fon'>import dictionary: ".$wlist."</font><br />";
  147.  
  148. if($ext != null)
  149. {
  150. echo "<font class='fon'>file scan : ".$ext."</font><br />";
  151.  
  152. }
  153. else
  154. {
  155. echo "<font class='fon'>directory scan :</font><br />";
  156. }
  157.  
  158. echo "<font class='fon'>scanning..</font><font class='re'>".$urljom."</font><br />";
  159.  
  160.  
  161.  
  162. $x = 0;
  163. foreach($arrayjom as $allcom)
  164. {
  165.  
  166.  $tazjom = curl_init($urljom."/".$allcom.$ext);
  167.  
  168. curl_setopt($tazjom, CURLOPT_RETURNTRANSFER, true);
  169. curl_setopt ($tazjom, CURLOPT_CONNECTTIMEOUT, 6);
  170. curl_setopt($tazjom, CURLOPT_TIMEOUT, 6);
  171.  
  172. curl_setopt($tazjom, CURLOPT_FOLLOWLOCATION, true);
  173. $tobjom = curl_exec($tazjom);
  174. curl_close($tazjom);
  175.  
  176.  
  177.  
  178. if($tobjom === false)
  179. {
  180. echo "<font class='fon'>Error...</font><br />";
  181. }
  182. else
  183. {
  184. $x = $x + 1;
  185.  
  186. echo cekeror($tobjom, $myerr, $allcom);
  187.  
  188. if($x > 100)
  189. {
  190. echo "<font class='fon'>scanning.....100+ word</font><br />";
  191. $x = 0;
  192. }
  193.  
  194. }
  195. }
  196.  
  197. }
  198.  
  199. echo "</div>";
  200.  
  201.  
  202. ?>
Add Comment
Please, Sign In to add comment