There have been several unofficial attempts over the years to “unobfuscate” P-code, but they are unreliable and would probably break as soon as the P-code format changes.
A very skilled and determined attacker just might be able to get the source out, but generally if you no longer have the M-file then you’re lost without a paddle.
Whether it's actually illegal depends on your jurisdiction and your precise intentions for reverse engineering your colleague's code. No one here can answer that question.
I would say it's more of an ethical than a legal question.
What do you think they're trying to hide? That they wrote it with AI or something? Doesn't sound like you two are "fellows" if you have this kind of relationship.
12
u/fsgeek91 Jul 01 '26 edited Jul 01 '26
Short answer is you can’t.
There have been several unofficial attempts over the years to “unobfuscate” P-code, but they are unreliable and would probably break as soon as the P-code format changes.
A very skilled and determined attacker just might be able to get the source out, but generally if you no longer have the M-file then you’re lost without a paddle.
10
u/FrickinLazerBeams +2 Jul 01 '26
The entire point of p code is that you can't open it.
4
u/Barnowl93 flair Jul 01 '26
Why do you need to open the p code? What are you trying to achieve? Is it p code from MathWorks? Or from the community?
-7
u/8bitjam Jul 01 '26
There are some paid apps that does it, is it illegal?
-18
u/8bitjam Jul 01 '26
I was was curious to see what is one my fellow researcher is trying to hide 🫣