使用eAccelerator加密PHP程序

yipeiwu_com6年前PHP代码库
使用 eAccelerator 加密PHP程序
复制代码 代码如下:

# /usr/local/bin/encoder

执行后会看到简单的使用说明:
复制代码 代码如下:

Usage: encoder [options] source_file_name
encoder [options] source_file_name...
encoder [options] source_directory_name...
Options:
-s suffix
encode files only with following suffix (default is "php")
-a
encode all files (no by default)
-l
follow symbolic links (no by default)
-r
encode directories recursively (no by default)
-c
copy files those shouldn't be encoded (no by default)
-f
overwrite existing files (no by default)
-w
exclude check for eaccelerator_load() and subsequent warning
-o target
If you encode only one script then 'target' specifyes an output
file name. If you encode directory or several files at once
then 'target' specifyes an output directory name.
Examples:
encoder some_file.php
encoder some_file.php -o some_encoded_file.php
encoder *.php -o some_dir
encoder ~/public_html/x -rcf -sphp -sinc -o ~/public_html/y

稍微玩一下应该就知道怎 用了...
使用 encoder 去对 PHP 程式加密编码,会产生另外一个档案,你也可以对整个目录作转换,例如:
复制代码 代码如下:

# encoder code -rcf -sphp -sinc -o code_encoded

这个命令会把 code/ 目录下所有的 php / inc 结尾的档案作编码,并存放到 code_encoded 下面,
同时,由于指定了 -c 这个选项,其他格式、不需编码的档案,如 jpg/gif/html/js 等,
也会原封不动复制一份到 code_encoded 下面,这样方便你直接以这个目录来提供服务。
选项 -r 含底下所有子目录

相关文章

PHP使用PHPExcel实现批量上传到数据库的方法

PHP使用PHPExcel实现批量上传到数据库的方法

此例子只使用execel2003的.xls文档,若使用的是其他版本,可以保存格式为“Execel 97-2003 工作簿(*.xls)”即.xls文件类型即可! 功能说明:只能上传Exc...

PHP利用APC模块实现大文件上传进度条的方法

php 大文件带进度的上传,一直是一个令php程序员很苦恼的问题。查询baidu 、Google ,大体做带进度的上传方式为:flash+php,socket,apc+php等,下面我介...

php程序之die调试法 快速解决错误

这是稍微有经验的phper 都会采用如下方式来解决问题 1. 看错误输出, 从输出项 反查源码,在源码处上下文加入调试代码,代码可以是最简单的 $debuglineno = __LINE...

thinkphp在低版本Nginx 下支持PATHINFO的方法分享

最近在用thinkphp做一个项目,基本完成后部署到nginx服务器上才发觉nginx是不支持pathinfo的那么我们如何来处理呢。 Nginx环境 在Nginx低版本中,是不支持PA...

phpstorm配置Xdebug进行调试PHP教程

phpstorm配置Xdebug进行调试PHP教程

运行环境: PHPSTORM版本 : 8.0.1 PHP版本 : 5.6.2 xdebug版本:php_xdebug-2.2.5-5.6-vc11-x86_64.dll ps : php...