In this article, we will have explained the necessary steps to installing and configure IonCube Loader on CentOS 8. Before continuing with this tutorial, make sure you are logged in as a user with
sudo privileges. All the commands in this tutorial should be run as a non-root user.
IonCube loader is used to secure typically the software that’s written in the PHP programming language. Ioncube makes it uncomplicated to protect your PHP source codes from easy observation, theft, and shift by compiling to bytecode. Encoding the application sources offers many benefits
Install IonCube Loader on CentOS 8
Step 1. The first command will update the package lists to ensure you get the latest version and dependencies.
sudo dnf install epel-release sudo dnf update
Step 2. Install Apache and PHP.
You need to install PHP and Apache on your system:
sudoa dnf install httpd php php-common php-cli
Check the version of the PHP command:
$ php -v PHP 7.4.10 (cli) (built: Jan 19 2021 10:09:36) ( NTS ) Copyright (c) 1997-2018 The PHP Group Zend Engine v3.2.0, Copyright (c) 1998-2018 Zend Technologies
Step 2. Download and Install Ioncube on the CentOS system.
Now download Ioncube loaders from the official website:
Once the download is completed, extract the downloaded file with the following command:
tar xzf ioncube_loaders_lin_x86-64.tar.gz -C /usr/local
Step 3. Enable ionCube Loader in PHP.
Use the below command to find out the PHP configuration file and enable the IonCube loader:
$ php -i | grep extension_dir extension_dir => /usr/lib64/php/modules => /usr/lib64/php/modules
Next, copy the ionCube loader module from the IonCube directory that matches your PHP version to the PHP extension directory:
cp ioncube/ioncube_loader_lin_7.4.so /usr/lib64/php/modules/
After that, you will need to enable it by editing
Add the following line at the end of the file:
zend_extension = /usr/lib64/php/modules/ioncube_loader_lin_7.4.so
Our server HTTPd reload command
systemctl restart httpd
Once done, you have added ionCube settings to your PHP configuration. To verify the configuration, type:
$ php -v PHP 7.4.10 (cli) (built: Jan 16 2021 12:46:36) ( NTS ) Copyright (c) The PHP Group Zend Engine v3.4.0, Copyright (c) Zend Technologies with the ionCube PHP Loader + ionCube24 v10.4.1, Copyright (c) 2002-2020, by ionCube Ltd. with Zend OPcache v7.4.8, Copyright (c), by Zend Technologies
That’s all you need to do to install IonCube on CentOS 8. I hope you find this quick tip helpful. For further reading on IonCube Loader, please refer to their official knowledge base. If you have questions or suggestions, feel free to leave a comment below.