Announcements

Between mid-October and November, the content on AREA will be relocated to the Autodesk Community M&E Hub and the Autodesk Community Gallery. Learn more HERE.

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

I want a way to obfuscate MEL scripts.

I want a way to obfuscate MEL scripts.

I want a way to obfuscate MEL or Python scripts.
I usually develop with MEL scripts, but I'm worried that the source code can be read by anyone. Without this, we run into big problems when we sell scripts or when we temporarily provide tools to external companies.

I can hide the code using C ++, but it's difficult for beginners like me. I've heard that 3dsMax has a simple scripting method for obfuscation, but I hope Autodesk can offer some new solutions in Maya as well.

For that matter, Autodesk should create a mechanism similar to Apple's App Store. Not only will you be able to obfuscate your code, but Autodesk should also be able to profit from selling your assets.

Please consider this.

5 Comments
1006138663
Advocate

I want MEL can be encrypted

klaudio2u
Enthusiast

Not only MEL but Python/Python API too....anything scripting really.

golaem
Enthusiast

Hey there,

I encourage you to rather convert your MEL scripts to Python and use a Python ofuscator.

For developers, Python is way more popular, flexible, faster than MEL. MEL probably made sense a few years ago but I will not be surprised to see it deprecated or not updated anymore in few years. I don't see Autodesk wanting to rely on this for its ecosystem neither.

Most MEL commands can be translated easily to Python, it should not be too hard to do it.

 

Once you've got Python code, there are a tons of Python ofuscator you can find. Some pretty robust

Notice that even if you ofuscate / encrypt code, there will be always ways to deofuscate / decrypt those with some efforts 🙂

Hope that helps

YASUSHI_EMOTO
Enthusiast

Obfuscation of Python using Pyarmor splits the script file into multiple pieces.

 

The following image is an example.

Obfuscation of test.py creates a subfolder called pytransform in addition to test.py.

 

キャプチャ.JPG


I don't know how to load this python script into Maya.

Is that possible?

 

Or is it better to use a library other than Pyarmor to generate an obfuscated Python file for loading into Maya? If so, what library should I use to obfuscate?

golaem
Enthusiast

From the PyArmor doc, you just have to import your test file and the rest is done for you:

import test

Can't find what you're looking for? Ask the community or share your knowledge.

Submit Idea