Home Upgrade Search Memberlist Extras Hacker Tools Award Goals Help Wiki Contact

PHP 

Web-Based Hash Cracker (Based off Hashcat)

Hey guys. I coded this earlier today. It's nothing special, but it's useful nonetheless. Obviously, this requires hashcat and a little modification. You'll have to specify the paths to your hash and your wordlist.

Code
<!DOCTYPE HTML>
<html>
<body>
<center>

    <form action="" method="post">
    Hash:<br><input type="text" name="hash"><br><br>
    <input type="submit">
    </form>

    <br>
    <br>

<?php

if(isset($_POST["hash"])) {

    $hash = $_POST["hash"];

    $filename = rand(1, 100);
    $handle = fopen($filename, "w");
    fwrite($handle, $hash);
    fclose($handle);

    $crackhash = shell_exec("hashcat -a 0 -m 0 /opt/lampp/htdocs/$filename /home/jared/Documents/passwords/output.txt"); // SPECIFY HASH LOCATION AND WORDLIST LOCATION
    preg_match_all("#$hash:(.*)\s#", $crackhash, $output);
    if($output[1][0] != NULL)
        echo "Password is: <font color='green'><b>" . @$output[1][0] . "</b></font>";

    else
        echo "<font color='red'><b>Password was not found.</b></font>";

    exec("rm $filename");

}

?>

</center>
</body>
</html>
You know that you can change the time limit..So change the timeout limit in PHP script and your server and you will be fine
If hashcat takes days to crack... you're running '98 or you have one HELL of a wordlist.
(Apr 22, 2013 04:25 PM)Pillows Wrote:  I think this would better be used for a php command line script. Or if you could use ajax so there's no timeouts.

If it were command line it would be 100% useless. You could just ./hashcat instead.


Possibly Related Threads...
Thread / Author Replies Views Last Post
[PHP] by тнe randoм dυтcн gυySep 10, 2016 02:52 AM 11 527 Sep 10, 2016 02:52 AM
Last Post: Sakuto
[PHP] by amr2006Feb 13, 2013 02:02 AM 10 1,688 Feb 13, 2013 02:02 AM
Last Post: skyle17