如果要做一个付费的 PHP 插件,如何避免被复制使用
比如我现在做一款 PHP 项目的第三方插件,用户需要到某平台付费后下载使用。
用户的使用环境可能是无法访问外网的
这样的情况下有什么思路是可以解决 “避免一个用户付费下载后所有用户都能复制使用” 的问题?
如果有过相关的经验,希望可以提供个思路
现在的情况就是用户毫不排斥我们会对服务器推送消息,并且乐于使用我们产品,以及使用相关插件。源码也是加密的。需要考虑的是如何保护付费插件的开发者利益
追加:
可能我没说清楚,插件使用者不是开发者,只是单纯的用户。源码加密那是肯定会做的,但是即使你源码加密也不影响这个插件在应用中正常使用不是么?就像是单机游戏一人破解万人使用,使用者不用管你源码怎样,反正我拿到能用就是了。要处理的是这种情况
回复内容:
比如我现在做一款 PHP 项目的第三方插件,用户需要到某平台付费后下载使用。
用户的使用环境可能是无法访问外网的
这样的情况下有什么思路是可以解决 “避免一个用户付费下载后所有用户都能复制使用” 的问题?
如果有过相关的经验,希望可以提供个思路
现在的情况就是用户毫不排斥我们会对服务器推送消息,并且乐于使用我们产品,以及使用相关插件。源码也是加密的。需要考虑的是如何保护付费插件的开发者利益
追加:
可能我没说清楚,插件使用者不是开发者,只是单纯的用户。源码加密那是肯定会做的,但是即使你源码加密也不影响这个插件在应用中正常使用不是么?就像是单机游戏一人破解万人使用,使用者不用管你源码怎样,反正我拿到能用就是了。要处理的是这种情况
加密方法:把php文件都编译了就可以
授权方法:内部做一个验证方式,每个付费客户会拿到一个key/sn,使用时需要输入这个key
验证方法:简单办法可以根据被访问的地址或域名检测,一个key对应一个地址
难点就在于内部的验证方式,key→(你的私有加密算法)→用户将要被访问的地址;
另外后期维护起来可能有些麻烦。可能你还要一个万能key用于用户开发阶段的使用。剩下的设计你就自己考虑吧。
真逗,就算用户使用的环境是可以访问外网的你就能防止了吗?你的代码是开源的好不好?如果你植入了识别语句会被找出来并删掉,而且,如果你的插件会主动向特定的服务器推送信息,谁敢用?核心数据被你偷了怎么办?也不用特别考虑加密,基本上插件不会100%符合要求,所以一些微调是必然的,所以加密过的插件不会有人买。
这个事儿还是完全靠自觉,实际上性价比很好的话大家是乐于付费的,几十几百块钱的东西谁会这么纠结,再说这个钱又不是程序员自己出,你会问老板“咱们话500块钱买一份还是用盗版的呢?”还是会告诉老板“咱们要用这个,500一份,给批个条”?前者老板会不会腹诽你觉得老板的面子不值500块?
最后,亲,我觉得盗版不是问题,而是免费都没人乐意用才是问题。
当然,你如果做的是PHP底层插件编译的mo或者dll的话当我什么都没说过。
针对修改后的问题
你们的产品是加密的,那插件源码也加密,付款买激活码,然后搞个在线激活,后期运行不需要联网。
phar zend or dll 混淆,
源码加密了 是不是就可以做授权什么了,获取相关信息做序列号。 被破解了 那就GG了
这个Windows都没做到,目前貌似没有完善的解决方案
楼主如果你这个付费300,我个人猜测如果销量好,会有开发个只要50的插件,所以还是建议
免费,开源 实在不行义务捐赠也行
zend guard~
核心功能用 Python,golang,c 或其他语言写,并编译成可执行文件供 php 调用.
验证机制就放到里面,这样就增加了破解难度
PHP7中可以用opcache.file_cache导出脚本opcode一定程度上保护源代码并提升运行效率.
其实有时自己稍微用php_strip_whitespace/gzcompress/base64_encode混淆下,用eval/base64_decode/gzuncompress运行,防防君子还是可以的.
mzphp :第一款支持 scss 语法、 css sprite 、以及 EnPHP 混淆加密的 php 框架,支持PHP7:
https://git.oschina.net/mz/mzphp2

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

Video Face Swap
Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics











PHP is a scripting language widely used on the server side, especially suitable for web development. 1.PHP can embed HTML, process HTTP requests and responses, and supports a variety of databases. 2.PHP is used to generate dynamic web content, process form data, access databases, etc., with strong community support and open source resources. 3. PHP is an interpreted language, and the execution process includes lexical analysis, grammatical analysis, compilation and execution. 4.PHP can be combined with MySQL for advanced applications such as user registration systems. 5. When debugging PHP, you can use functions such as error_reporting() and var_dump(). 6. Optimize PHP code to use caching mechanisms, optimize database queries and use built-in functions. 7

PHP and Python each have their own advantages, and the choice should be based on project requirements. 1.PHP is suitable for web development, with simple syntax and high execution efficiency. 2. Python is suitable for data science and machine learning, with concise syntax and rich libraries.

PHP and Python each have their own advantages, and choose according to project requirements. 1.PHP is suitable for web development, especially for rapid development and maintenance of websites. 2. Python is suitable for data science, machine learning and artificial intelligence, with concise syntax and suitable for beginners.

PHP is widely used in e-commerce, content management systems and API development. 1) E-commerce: used for shopping cart function and payment processing. 2) Content management system: used for dynamic content generation and user management. 3) API development: used for RESTful API development and API security. Through performance optimization and best practices, the efficiency and maintainability of PHP applications are improved.

PHP is still dynamic and still occupies an important position in the field of modern programming. 1) PHP's simplicity and powerful community support make it widely used in web development; 2) Its flexibility and stability make it outstanding in handling web forms, database operations and file processing; 3) PHP is constantly evolving and optimizing, suitable for beginners and experienced developers.

PHP is mainly procedural programming, but also supports object-oriented programming (OOP); Python supports a variety of paradigms, including OOP, functional and procedural programming. PHP is suitable for web development, and Python is suitable for a variety of applications such as data analysis and machine learning.

PHP is suitable for web development, especially in rapid development and processing dynamic content, but is not good at data science and enterprise-level applications. Compared with Python, PHP has more advantages in web development, but is not as good as Python in the field of data science; compared with Java, PHP performs worse in enterprise-level applications, but is more flexible in web development; compared with JavaScript, PHP is more concise in back-end development, but is not as good as JavaScript in front-end development.

PHP and Python have their own advantages and disadvantages, and the choice depends on project needs and personal preferences. 1.PHP is suitable for rapid development and maintenance of large-scale web applications. 2. Python dominates the field of data science and machine learning.
