Is there a way to obfuscate the code generated from the model?

9 views (last 30 days)

Accepted Answer

MathWorks Support Team
MathWorks Support Team on 17 Jun 2025
Protected Model makes it possible to obfuscate the generated code.
Details of the Protected Model can be found in the following documentation:
When creating a Protected Model, you can select one of the following three Content types for the generated code.
(1) Binaries
(2) Obfuscated source code
(3) Readable source code
 
(1) is .lib and can be selected if you do not want your distribution partners to decipher the generated code.
(2) and (3) are C code, although there is a difference in readability.
The obfuscated source code in (2) is the generated code with all of the variable and function names converted to meaningless character strings, except for the names of interfaces to other sets of code, which cannot be changed. 
Please refer to the following documentation for details on settings:

More Answers (0)

Categories

Find more on Simulink Coder in Help Center and File Exchange

Tags

No tags entered yet.

Products


Release

R2016b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!