encrypt an Matlab application standalone ?
14 次查看(过去 30 天)
显示 更早的评论
Hi,
We are aiming at sharing an application to partners without allowing them to get access to the source code
Therefor, Is it possible to protect (encrypt) an executable file from Matlab (.exe) ?
In particular, can we trust in p-code or standalone executable ?
Or do we need more advanced coding tools or crypting workflow ?
Thanks
0 个评论
回答(3 个)
Steven Lord
2020-7-22
From the documentation for MATLAB Compiler: "All MATLAB files in the deployable archive are encrypted using the Advanced Encryption Standard (AES) cryptosystem."
2 个评论
David Leffingwell
2023-6-12
编辑:David Leffingwell
2023-6-12
In R2021b or later you can use the -s option of the MATLAB Compiler to obfuscate the file and folder structure in the Standalone application. Also, in R2022b or later, you can use the -j option of the MATLAB Compiler to automatically P-Code all your M files with a newer version of P-Code.
Walter Roberson
2020-7-23
In particular, can we trust in p-code or standalone executable ?
You should definitely not trust in p-code. It obscures, but there are debugging techniques that can examine parts of it. It is expected that someone might have largely decoded it by now.
Last year, someone made the claim that they had the AES key needed to decrypt .exe files. I do not know if the claim was accurate, but I would not rule out the possibility that someone dug through the executable enough to figure it out.
The role of good encryption and obfuscation is to make it more expensive to decode the files than the value gained. You should never ever count on software encryption to make it impossible for code to be examined.
The military works with hardened hardware with sealed chips designed to make it near impossible to get at the components (and bus lines) without breaking the device beyond use. Even then, for the class of devices that needs that kind of protection, they use carefully designed software and hardware to avoid "back channels" (e.g., giving away whether an operation succeded or not by monitoring timing differences.)
0 个评论
David Leffingwell
2023-6-12
The MATLAB Compiler can be used to create an encrypted Standalone application.
In R2021b or later you can use the -s option of the MATLAB Compiler to obfuscate the file and folder structure in the Standalone application. Also, in R2022b or later, you can use the -j option of the MATLAB Compiler to automatically P-Code all your M files with a newer version of P-Code.
0 个评论
另请参阅
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!