I'm asking this after reading a SO question where the OP asked for help decoding obfuscated code, which looks like it belongs to a closed-source company.
The OP's client is saying "I don't know the full legal particulars of the contract (if there was one) for the code development. They claim it was fully paid for and released to them. If the code development was completely outside the scope and use of Ioncube, then it's debatable if it is unethical. "
To me the whole thing stinks of: the client bought the product and hired the OP to decode it, but either doesn't understand he didn't buy a licence to modify, distribute, reverse engineer, or reproduce the software. But it's easy to just accept a job and say "whatever" to these sorts of things, but there is room for this to be legit.
What considerations should we take to ensure we're doing the right thing, and furthermore protect ourselves?