Bob knowingly pays Rob for doing something illegal (handing over an item that Rob has stolen, murdering Alice etc. — you name it).
Both are caught and sent to jail.
Now, will Rob legally own the money Bob paid him? Does the Clean Hands doctrine prevent Bob from obtaining a court order that Rob gives him the money back?
The doctrine says that Bob won't have it as an equitable remedy. But does the remedy necessarily need to be equitable?
(Any common law jurisdiction.)