hashcat Forum
bulk extracting hashes - Printable Version

+- hashcat Forum (https://hashcat.net/forum)
+-- Forum: Misc (https://hashcat.net/forum/forum-15.html)
+--- Forum: User Contributions (https://hashcat.net/forum/forum-25.html)
+--- Thread: bulk extracting hashes (/thread-6983.html)



bulk extracting hashes - mb1shop - 10-31-2017

I was wondering if there scripts that could be run recursively against a directory of files (doc, ppt, xls, docx, pdf, zip, 7z, rar, etc..) that would call the appropriate office2john.py (for example) to extract hashes for a large number of files.  They then could be passed to hashid or similar to make sorted lists to be passed into hashcat.


RE: bulk extracting hashes - MrMeeseeks - 10-31-2017

You could easily write a bash script. Do something along the lines of:
Code:
find ~/officedocs -name '*.pdf' -or -name '*.doc' -or -name '*.7z' | xargs office2john.py ARG ARG

Just add each kind of office document that you want to search in the find options, then pipe it all over to xargs office2john.py
Or pass it to a case statement so you can execute the proper application e.g. 7z2john rar2john zip2john etc.

Hope this helps get you in the right direction.