![]() |
Using the Assimilation Bridge (Python Plugin) for Rapid Prototyping - Printable Version +- hashcat Forum (https://hashcat.net/forum) +-- Forum: Developer (https://hashcat.net/forum/forum-39.html) +--- Forum: hashcat (https://hashcat.net/forum/forum-40.html) +--- Thread: Using the Assimilation Bridge (Python Plugin) for Rapid Prototyping (/thread-13346.html) Pages:
1
2
|
Using the Assimilation Bridge (Python Plugin) for Rapid Prototyping - atom - 08-11-2025 The Assimilation Bridge, in particular its Python plugin, is designed for rapid prototyping. I originally added this plugin for situations where I had reversed some algorithm from an application or library, but usually it was a one-hash scenario. In most cases, I would simply write a quick proof of concept in, crack the single hash, and move on. The Python plugin is for such cases where the hashes are more resistant, for example when they are not based on a weak password. In that case you might need both computational power and some smart password guessing. You may want to take advantage of hashcat features such as the rule engine, hybrid attack modes, restart functionality, or built-in multithreading. Instead of just writing your own standalone cracking tool, you can later move your PoC logic into the Python bridge and directly benefit from hashcat features. We recently participated in the Jabbercracky password contest (DEFCON 33) where we faced a set of completely unknown hashes with no context at all. When you do not know the hash type and there is no obvious signature or pattern in the hashes, a great tool to try is mdxfind. It is multithreaded, has many useful features, and is ideal for such situations. It supports iterations, external salt or username inputs, and more. In this contest, mdxfind could identify some of the algorithms, but some others the players had to figure out manually. That is a perfect example of when the Python bridge is useful because it gives you a programming language with access to a large pool of third-party cryptographic libraries, and using a programming language gives you maximum flexibility. Note!!! that in order to use this you need a version higher than 7.0.0, for instance the beta binary from https://hashcat.net/beta or by compiling from GitHub master sources. 0. Set up the Python bridge If hashcat -b -m 73000 runs successfully, you are ready for step 1. If you have never used it before, check out the Quickstart Guide. 1. Download the contest hash list Here is a mirror. 2. Convert it for use with the Python bridge Code: $ cat hash_list_3.txt | grep -v '^\$2a\$' | sed -e 's/$/*/g' > hashes73000.txt Mode 73000 expects the format HASH*SALT. In this contest there were no salts, only peppers, so we leave the salt field empty and handle the pepper in our Python code. We skip the bcrypts intentionally. You can also implement bcrypt in the Python bridge, but since bcrypt has a recognizable signature and is supported directly with mode 3200, it is better to handle those natively. We use mode 73000 instead of 72000 for better cross-platform compatibility. 3. Edit Python/generic_hash_mp.py Code: import sys 4. Run hashcat normally Code: $ ./hashcat -m 73000 hashes73000.txt example.dict - atom RE: Using the Assimilation Bridge (Python Plugin) for Rapid Prototyping - buka - 08-12-2025 Can one have more than one self-test pair? RE: Using the Assimilation Bridge (Python Plugin) for Rapid Prototyping - atom - 08-12-2025 Not supported, but I could make it possible. I just don't see the need right now. Do you have a good use-case? RE: Using the Assimilation Bridge (Python Plugin) for Rapid Prototyping - buka - 08-12-2025 Any kernel that computes multiple hashes at once can use that. Like Half-MD5 (5100) that does three MD5s, or your example above where there are 6 algorithms. RE: Using the Assimilation Bridge (Python Plugin) for Rapid Prototyping - tha_tux - 08-12-2025 Thanks! I'm returned ```This hash-mode plugin cannot crack multiple hashes with the same salt, please select one of the hashes.``` Need to disable this return https://github.com/hashcat/hashcat/blob/f47c14603631f545ed4e554b0490ce19afe7e3c8/src/hashes.c#L2294 Then it works ::thumb:: RE: Using the Assimilation Bridge (Python Plugin) for Rapid Prototyping - tha_tux - 08-12-2025 Furthermore the potfile stays empty, is this expected behavior? RE: Using the Assimilation Bridge (Python Plugin) for Rapid Prototyping - phurtim - 08-12-2025 (Yesterday, 03:31 PM)tha_tux Wrote: Thanks! I can confirm I am getting the same "This hash-mode plugin cannot crack multiple hashes with the same salt, please select one of the hashes." error when attempting to replicate this on windows. RE: Using the Assimilation Bridge (Python Plugin) for Rapid Prototyping - atom - 08-12-2025 Please see in the original post: Note!!! that in order to use this you need a version higher than 7.0.0, for instance the beta binary from https://hashcat.net/beta or by compiling from GitHub master sources. This will solve the error: This hash-mode plugin cannot crack multiple hashes with the same salt, please select one of the hashes RE: Using the Assimilation Bridge (Python Plugin) for Rapid Prototyping - atom - 08-12-2025 (Yesterday, 03:20 PM)buka Wrote: Any kernel that computes multiple hashes at once can use that. Like Half-MD5 (5100) that does three MD5s, or your example above where there are 6 algorithms. Just add a fixed hash mode and use a self-test hash from that fixed mode. RE: Using the Assimilation Bridge (Python Plugin) for Rapid Prototyping - atom - 08-12-2025 (Yesterday, 03:35 PM)tha_tux Wrote: Furthermore the potfile stays empty, is this expected behavior? This might be a left-over from development days. I think we can re-enable potfile support. |