Python-我如何编码我的Python脚本 [英] Python - how do i encode my python script

查看:80
本文介绍了Python-我如何编码我的Python脚本的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想对脚本进行编码,使其看不到代码
不可编辑

I want to encode my script to be unable to see codes and Uneditable.

并且无法解码。

因为它具有许可证...

Because it has license...

谢谢。

推荐答案


我想对脚本进行编码以使其看不到代码

I want to encode my script to be unable to see codes

无法完成。显然,该脚本必须是可读的,用户计算机才能运行它。

Can't be done. The script obviously has to be readable for the user's computer to run it.


不可编辑

再次,不可能。如果脚本位于其他人的计算机上,则他们有权执行他们想做的任何事情。

Again, impossible. If the script lives on someone else's computer, they have permission to do anything they want.

您可以做的最接近的事情是将脚本作为<$ c $分发。 c> .pyc 而不是 .py 文件。

The closest thing you can do is to distribute your script as a .pyc instead of a .py file. But even then, a knowledgeable user will be able to decode it.

听起来似乎您可能根本不想分发脚本,但要维护后端API代替。这样一来,用户永远不会访问您的代码。

It sounds like you might not want to distribute a script at all, but maintain a back-end API instead. This way the user never has access to your code in the first place.

这篇关于Python-我如何编码我的Python脚本的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆