translated

This commit is contained in:
geekpi 2015-09-24 09:56:47 +08:00
parent 1b7b9c857b
commit 33e2644eb8
2 changed files with 91 additions and 91 deletions

View File

@ -1,91 +0,0 @@
translating----geekpi
How to Setup IonCube Loaders on Ubuntu 14.04 / 15.04
================================================================================
IonCube Loaders is an encryption/decryption utility for PHP applications which assists in speeding up the pages that are served. It also protects your website's PHP code from being viewed and ran on unlicensed computers. Using ionCube encoded and secured PHP files requires a file called ionCube Loader to be installed on the web server and made available to PHP which is often required for a lot of PHP based applications. It handles the reading and execution of encoded files at run time. PHP can use the loader with one line added to a PHP configuration file that php.ini.
### Prerequisites ###
In this article we will setup the installation of Ioncube Loader on Ubuntu 14.04/15.04, so that it can be used in all PHP Modes. The only requirement for this tutorial is to have "php.ini" file exists in your system with LEMP stack installed on the server.
### Download IonCube Loader ###
Login to your ubuntu server to download the latest IonCube loader package according to your operating system architecture whether your are using a 32 Bit or 64 Bit OS. You can get its package by issuing the following command with super user privileges or root user.
# wget http://downloads3.ioncube.com/loader_downloads/ioncube_loaders_lin_x86-64.tar.gz
![download ioncube](http://blog.linoxide.com/wp-content/uploads/2015/09/download1.png)
After Downloading unpack the archive into the "/usr/local/src/" folder by issuing the following command.
# tar -zxvf ioncube_loaders_lin_x86-64.tar.gz -C /usr/local/src/
![extracting archive](http://blog.linoxide.com/wp-content/uploads/2015/09/2-extract.png)
After extracting the archive, we can see the list of all modules present in it. But we needs only the relevant with the version of PHP installed on our system.
To check your PHP version, you can run the below command to find the relevant modules.
# php -v
![ioncube modules](http://blog.linoxide.com/wp-content/uploads/2015/09/modules.png)
With reference to the output of above command we came to know that the PHP version installed on the system is 5.6.4, so we need to copy the appropriate module to the PHP modules folder.
To do so we will create a new folder with name "ioncube" within the "/usr/local/" directory and copy the required ioncube loader modules into it.
root@ubuntu-15:/usr/local/src/ioncube# mkdir /usr/local/ioncube
root@ubuntu-15:/usr/local/src/ioncube# cp ioncube_loader_lin_5.6.so ioncube_loader_lin_5.6_ts.so /usr/local/ioncube/
### PHP Configuration ###
Now we need to put the following line into the configuration file of PHP file "php.ini" which is located in "/etc/php5/cli/" folder then restart your web servers services and php module.
# vim /etc/php5/cli/php.ini
![ioncube zend extension](http://blog.linoxide.com/wp-content/uploads/2015/09/zend-extension.png)
In our scenario we have Nginx web server installed, so we will run the following commands to start its services.
# service php5-fpm restart
# service nginx restart
![web services](http://blog.linoxide.com/wp-content/uploads/2015/09/web-services.png)
### Testing IonCube Loader ###
To test the ioncube loader in the PHP configuration for your website, create a test file called "info.php" with the following content and place it into the web directory of your web server.
# vim /usr/share/nginx/html/info.php
Then save the changes after placing phpinfo script and access "info.php" in your browser with your domain name or servers IP address after reloading the web server services.
You will be able to see the below section at the bottom of your php modules information.
![php info](http://blog.linoxide.com/wp-content/uploads/2015/09/php-info.png)
From the terminal issue the following command to verify the php version that shows the ionCube PHP Loader is Enabled.
# php -v
![php ioncube loader](http://blog.linoxide.com/wp-content/uploads/2015/09/php-ioncube.png)
The output shown in the PHP version's command clearly indicated that IonCube loader has been successfully integrated with PHP.
### Conclusion ###
At the end of this tutorial you learnt about the installation and configuration of ionCube Loader on Ubuntu with Nginx web server there will be no such difference if you are using any other web server. So, installing Loaders is simple when its done correctly, and on most servers its installation will work without a problem. However there is no such thing as a "standard PHP installation", and servers can be setup in many different ways, and with different features enabled or disabled.
If you are on a shared server, then make sure that you have run the ioncube-loader-helper.php script, and click the link to test run time installation. If you still face as such issue while doing your setup, feel free to contact us and leave us a comment.
--------------------------------------------------------------------------------
via: http://linoxide.com/ubuntu-how-to/setup-ioncube-loaders-ubuntu-14-04-15-04/
作者:[Kashif Siddique][a]
译者:[译者ID](https://github.com/译者ID)
校对:[校对者ID](https://github.com/校对者ID)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]:http://linoxide.com/author/kashifs/

View File

@ -0,0 +1,91 @@
如何在Ubuntu 14.04 / 15.04中设置IonCube Loaders
================================================================================
IonCube Loaders是PHP中用于辅助加速页面的加解密工具。它保护你的PHP代码不会被在未授权的计算机上查看。使用ionCube编码并加密PHP需要一个叫ionCube Loader的文件安装在web服务器上并提供给需要大量访问的PHP用。它在运行时处理并执行编码。PHP只需在php.ini中添加一行就可以使用这个loader。
### 前提条件 ###
在这篇文章中我们将在Ubuntu14.04/15.04安装Ioncube Loader 以便它可以在所有PHP模式中使用。本教程的唯一要求就是你系统安装了LEMP并有“的php.ini”文件。
### 下载 IonCube Loader ###
根据你系统的架构是32位或者64位来下载最新的IonCube loader包。你可以用超级用户权限或者root用户运行下面的命令。
# wget http://downloads3.ioncube.com/loader_downloads/ioncube_loaders_lin_x86-64.tar.gz
![download ioncube](http://blog.linoxide.com/wp-content/uploads/2015/09/download1.png)
下载完成后用下面的命令解压到"/usr/local/src/"。
# tar -zxvf ioncube_loaders_lin_x86-64.tar.gz -C /usr/local/src/
![extracting archive](http://blog.linoxide.com/wp-content/uploads/2015/09/2-extract.png)
解压完成后我们就可以看到所有的存在的模块。但是我们只需要我们安装的PHP版本的相关模块。
要检查PHP版本你可以运行下面的命令来找出相关的模块。
# php -v
![ioncube modules](http://blog.linoxide.com/wp-content/uploads/2015/09/modules.png)
根据上面的命令我们知道我们安装的是PHP 5.6.4因此我们需要拷贝合适的模块到PHP模块目录下。
首先我们在“/usr/local/”创建一个叫“ioncube”的目录并复制需要的ioncube loader到这里。
root@ubuntu-15:/usr/local/src/ioncube# mkdir /usr/local/ioncube
root@ubuntu-15:/usr/local/src/ioncube# cp ioncube_loader_lin_5.6.so ioncube_loader_lin_5.6_ts.so /usr/local/ioncube/
### PHP 配置 ###
我们要在位于"/etc/php5/cli/"文件夹下的"php.ini"中加入下面的配置行并重启web服务和php模块。
# vim /etc/php5/cli/php.ini
![ioncube zend extension](http://blog.linoxide.com/wp-content/uploads/2015/09/zend-extension.png)
此时我们安装的是nginx因此我们用下面的命令来重启服务。
# service php5-fpm restart
# service nginx restart
![web services](http://blog.linoxide.com/wp-content/uploads/2015/09/web-services.png)
### 测试 IonCube Loader ###
要为我们的网站测试ioncube loader。用下面的内容创建一个"info.php"文件并放在网站的web目录下。
# vim /usr/share/nginx/html/info.php
加入phpinfo的脚本后重启web服务后用域名或者ip地址访问“info.php”。
你会在最下面的php模块信息里看到下面这段。
![php info](http://blog.linoxide.com/wp-content/uploads/2015/09/php-info.png)
From the terminal issue the following command to verify the php version that shows the ionCube PHP Loader is Enabled.
在终端中运行下面的命令来验证php版本并显示PHP Loader已经启用了。
# php -v
![php ioncube loader](http://blog.linoxide.com/wp-content/uploads/2015/09/php-ioncube.png)
上面的php版本输出明显地显示了IonCube loader已经成功与PHP集成了。
### 总结 ###
教程的最后你已经了解了在安装有nginx的Ubuntu中安装和配置ionCube Loader如果你正在使用其他的web服务这与其他服务没有明显的差别。因此做完这些安装Loader是很简单的并且在大多数服务器上的安装都不会有问题。然而并没有一个所谓的“标准PHP安装”服务可以通过许多方式安装并启用或者禁用功能。
如果你是在共享服务器上那么确保运行了ioncube-loader-helper.php脚本并点击链接来测试运行时安装。如果安装时你仍然遇到了问题欢迎联系我们及给我们留下评论。
--------------------------------------------------------------------------------
via: http://linoxide.com/ubuntu-how-to/setup-ioncube-loaders-ubuntu-14-04-15-04/
作者:[Kashif Siddique][a]
译者:[geekpi](https://github.com/geekpi)
校对:[校对者ID](https://github.com/校对者ID)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]:http://linoxide.com/author/kashifs/