passwordspassword-hashhashcat

Output progress over time in hashcat


I am analysing the amount of hashes cracked over a set period of time. I am looking to save the current status of the crack every 10 seconds.

'''

Recovered........: 132659/296112 (44.80%) Digests, 0/1 (0.00%) Salts Recovered/Time...: CUR:3636,N/A,N/A AVG:141703,8502198,204052756 (Min,Hour,Day) Progress.........: 15287255040/768199139595 (1.99%)

'''

I want these 3 lines of the status saved every 10 seconds or so. Is it possible to do this within hashcat or will I need to make a separate script in python?


Solution

  • Getting the status every 10 seconds

    You can enable printing the status with --status and you can set the status to prints every X seconds with --status-timer X. You can see these command line arguments on the hashcat options wiki page, or hashcat --help.

    Example: hashcat -a 0 -m 0 example.hash example.dict --status --status-timer 10


    Saving all the statuses

    I'm assuming that you just want to save everything that gets printed by hashcat while it's running. An easy way to do this is just copy everything from stdout into a file. This is a popular s/o question, so we'll just use this answer.

    To be safe, let's use -a which appends to the file, so we don't accidentally overwrite previous runs. All we need to do is put | tee -a file.txt after our hashcat call.


    Solution

    Give this a shot, it should save all the statuses (and everything else from stdout) to output.txt:

    hashcat -a A -m M hashes.txt dictionary.txt --status --status-timer 10 | tee -a output.txt
    

    Just swap out A, M, hashes.txt, and dictionary.txt with the arguments you're using.

    If you need help getting just the "Recovered" lines from this output file, or if this doesn't work on your computer (I'm on OSX), let me know in a comment.