Can i encryt python script?

helloo

Can i encrypt or lock python scripts?

just suddenly wonder about it.

When you finish your script, add 1 line - convertToByteCode(), compile, close, open it again, it should work

2 Likes

let me try this

thank you~

How to decrypt after encryption?

You can’t, that is the point.
Also please understand that while this bytecode conversion can hide your code, it is not actually secure like proper encryption would be and is probably reversible by a determined user.

really … hmmm

then if client want to get vcmx file of production line , company have to open their own codes.

hmmm…

of course i can make video of them , but if client want to get that VC file , they can get information logic of line.

well sometimes i can understand automotive industry , but what about semiconductor or other high tech industries?

they need security of every logic on process line or equptments.

example , If TSMC or Samsung want ASML’s equptment of simulation file without encryption.

that will be fun.

there are 3D cad files , PLC signal Logics , scripts , and others too. they dont want to open it.

i think VC need this feature. lock scripts.

The simulation models are usually not that detailed in their behavior that they would contain some high trade secrets. The basic operation can be reverse-engineered anyway just by looking at how the model behaves when testing with different inputs.

It is also reasonable to expect that there is a certain level of trust between companies that share simulation models. The models can contain malicious scripts, for example, because there is no Python script sandboxing in VC. If the scripts are obfuscated then there is no way to verify what they do on the user’s computer.

If you want to hide your code deeper, you could write code in C++, either Python API or C# API can call the file, however, nothing is 100% secure, even for C++.

thanks for answer.

im not that professional of programming , so that can be hard.

today i got kind of issue on this, so it makes me tired now hahaha :melting_face: