{"id":12381,"date":"2019-03-26T21:55:55","date_gmt":"2019-03-26T21:55:55","guid":{"rendered":"http:\/\/www.appservgrid.com\/paw92\/?p=12381"},"modified":"2019-03-26T21:55:55","modified_gmt":"2019-03-26T21:55:55","slug":"how-to-install-ioncube-loader-in-centos-7","status":"publish","type":"post","link":"https:\/\/www.appservgrid.com\/paw92\/index.php\/2019\/03\/26\/how-to-install-ioncube-loader-in-centos-7\/","title":{"rendered":"How to Install ionCube Loader in CentOS 7"},"content":{"rendered":"<p><strong>ionCube<\/strong>\u00a0is a commercial software suite consisting of a PHP encoder, package foundry, bundler, a real time site intrusion detection and error reporting application as well as a loader.<\/p>\n<p>PHP encoder is an application for PHP software protection: used to secure, encrypt and license PHP source code.\u00a0<strong>ionCube<\/strong>\u00a0loader is an extension used to load PHP files protected and encoded using PHP encoder. It is mostly used in commercial software applications to protect their source code and prevent it from being visible.<\/p>\n<p><strong>Read Also<\/strong>:\u00a0<a href=\"https:\/\/www.tecmint.com\/install-ioncube-loader-in-ubuntu-debian\/\" target=\"_blank\" rel=\"noopener\">How to Install ionCube Loader in Debian and Ubuntu<\/a><\/p>\n<p>In this article, we will show how to install and configure\u00a0<strong>ionCube<\/strong>\u00a0Loader with\u00a0<strong>PHP<\/strong>\u00a0in\u00a0<strong>CentOS 7<\/strong>\u00a0and\u00a0<strong>RHEL 7<\/strong>distributions.<\/p>\n<h3>Prerequisites:<\/h3>\n<p>Your server must have a running web server (<a href=\"https:\/\/www.tecmint.com\/install-lamp-in-centos-7\/\" target=\"_blank\" rel=\"noopener\">Apache<\/a>\u00a0or\u00a0<a href=\"https:\/\/www.tecmint.com\/install-nginx-mariadb-php-rhel-centos-fedora\/\" target=\"_blank\" rel=\"noopener\">Nginx<\/a>) with\u00a0<strong>PHP<\/strong>\u00a0installed. If you don\u2019t have a web server and PHP on your system, you can install them using\u00a0<a href=\"https:\/\/www.tecmint.com\/20-linux-yum-yellowdog-updater-modified-commands-for-package-mangement\/\" target=\"_blank\" rel=\"noopener\">yum package manager<\/a>\u00a0as shown.<\/p>\n<h3>Step 1: Install Apache or Nginx Web Server with PHP<\/h3>\n<p><strong>1.<\/strong>\u00a0If you already have a running web server\u00a0<strong>Apache<\/strong>\u00a0or\u00a0<strong>Nginx<\/strong>\u00a0with\u00a0<strong>PHP<\/strong>\u00a0installed on your system, you can jump to the\u00a0<strong>Step 2<\/strong>, otherwise use the following\u00a0<a href=\"https:\/\/www.tecmint.com\/20-linux-yum-yellowdog-updater-modified-commands-for-package-mangement\/\" target=\"_blank\" rel=\"noopener\">yum command<\/a>\u00a0to install them.<\/p>\n<pre><strong>-------------------- Install Apache with PHP --------------------<\/strong>\r\n# yum install httpd php php-cli\tphp-mysql\r\n\r\n<strong>-------------------- Install Nginx with PHP --------------------<\/strong> \r\n# yum install nginx php php-fpm php-cli\tphp-mysql\r\n<\/pre>\n<p><strong>2.<\/strong>\u00a0After installing\u00a0<strong>Apache<\/strong>\u00a0or\u00a0<strong>Nginx<\/strong>\u00a0with\u00a0<strong>PHP<\/strong>\u00a0on your system, start the web server and make sure to enable it to auto start at system boot time using following commands.<\/p>\n<pre><strong>-------------------- Start Apache Web Server --------------------<\/strong>\r\n# systemctl start httpd\r\n# systemctl enable httpd\r\n\r\n<strong>-------------------- Start Nginx + PHP-FPM Server --------------------<\/strong>\r\n# systemctl start nginx\r\n# systemctl enable nginx\r\n# systemctl start php-fpm\r\n# systemctl enable php-fpm\r\n<\/pre>\n<h3>Step 2: Download IonCube Loader<\/h3>\n<p><strong>3.<\/strong>\u00a0Go to the\u00a0<a href=\"https:\/\/www.ioncube.com\/loaders.php\" target=\"_blank\" rel=\"nofollow noopener\">inocube\u2019s website<\/a>\u00a0and download the installation files, but before that first you need to check whether your\u00a0<a href=\"https:\/\/www.tecmint.com\/find-linux-kernel-version-distribution-name-version-number\/\" target=\"_blank\" rel=\"noopener\">system is running on 64-bit or 32-bit architecture<\/a>\u00a0using the following command.<\/p>\n<pre><strong># uname -a<\/strong>\r\n\r\nLinux tecmint.com 4.15.0-1.el7.elrepo.x86_64 #1 SMP Sun Jan 28 20:45:20 EST 2018 <strong>x86_64 x86_64 x86_64<\/strong> GNU\/Linux\r\n<\/pre>\n<div class=\"google-auto-placed ap_container\">\n<p>The above output clearly shows that the system is running on\u00a0<strong>64-bit<\/strong>\u00a0architecture.<\/p>\n<p>As per your Linux system architecture type download the ioncube loader files into\u00a0<strong>\/tmp<\/strong>\u00a0directory using following\u00a0<a href=\"https:\/\/www.tecmint.com\/10-wget-command-examples-in-linux\/\" target=\"_blank\" rel=\"noopener\">wget command<\/a>.<\/p>\n<pre><strong>-------------------- For 64-bit System --------------------<\/strong>\r\n# cd \/tmp\r\n# wget https:\/\/downloads.ioncube.com\/loader_downloads\/ioncube_loaders_lin_x86-64.tar.gz\r\n\r\n<strong>-------------------- For 32-bit System --------------------<\/strong>\r\n# cd \/tmp\r\n# wget https:\/\/downloads.ioncube.com\/loader_downloads\/ioncube_loaders_lin_x86.tar.gz\r\n<\/pre>\n<p><strong>4.<\/strong>\u00a0Then unzip the downloaded file using the\u00a0<a href=\"https:\/\/www.tecmint.com\/18-tar-command-examples-in-linux\/\" target=\"_blank\" rel=\"noopener\">tar command<\/a>\u00a0and move into the decompressed folder. Then run the\u00a0<a href=\"https:\/\/www.tecmint.com\/tag\/linux-ls-command\/\" target=\"_blank\" rel=\"noopener\">ls command<\/a>\u00a0to list the numerous ioncube loader files for different PHP versions.<\/p>\n<pre># tar -xvf ioncube_loaders_lin_x86*\r\n# cd ioncube\/\r\n$ ls -l\r\n<\/pre>\n<div id=\"attachment_29191\" class=\"wp-caption aligncenter\">\n<p><a href=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2018\/04\/Ioncube-Loader-Files.png\"><img loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-29191\" src=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2018\/04\/Ioncube-Loader-Files.png\" sizes=\"auto, (max-width: 860px) 100vw, 860px\" srcset=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2018\/04\/Ioncube-Loader-Files.png 860w, https:\/\/www.tecmint.com\/wp-content\/uploads\/2018\/04\/Ioncube-Loader-Files-768x601.png 768w\" alt=\"Ioncube Loader Files\" width=\"860\" height=\"673\" aria-describedby=\"caption-attachment-29191\" data-lazy-loaded=\"true\" \/><\/a><\/p>\n<p id=\"caption-attachment-29191\" class=\"wp-caption-text\">Ioncube Loader Files<\/p>\n<\/div>\n<h3>Step 3: Install ionCube Loader for PHP<\/h3>\n<p><strong>5.<\/strong>\u00a0There will be different ioncube loader files for various PHP versions, you need to select the right ioncube loader for your installed PHP version on your server. To know the php version installed on your server, run the command.<\/p>\n<pre># php -v\r\n<\/pre>\n<div id=\"attachment_29190\" class=\"wp-caption aligncenter\">\n<p><a href=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2018\/04\/Verify-PHP-Version.png\"><img loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-29190\" src=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2018\/04\/Verify-PHP-Version.png\" alt=\"Verify PHP Version\" width=\"691\" height=\"139\" aria-describedby=\"caption-attachment-29190\" data-lazy-loaded=\"true\" \/><\/a><\/p>\n<p id=\"caption-attachment-29190\" class=\"wp-caption-text\">Verify PHP Version<\/p>\n<\/div>\n<p>The above output clearly shows that the system is using\u00a0<strong>PHP 5.4.16<\/strong>\u00a0version, in your case it should be different version.<\/p>\n<p><strong>6.<\/strong>\u00a0Next, find the location of the extension directory for PHP version\u00a0<strong>5.4<\/strong>, it is where the ioncube loader file will be installed. From the output of this command, the directory is\u00a0<strong>\/usr\/lib64\/php\/modules<\/strong>.<\/p>\n<pre># php -i | grep extension_dir\r\n\r\nextension_dir =&gt; \/usr\/lib64\/php\/modules =&gt; <strong>\/usr\/lib64\/php\/modules<\/strong><\/pre>\n<p><strong>7.<\/strong>\u00a0Next we need to copy ioncube loader for our\u00a0<strong>PHP 5.4<\/strong>\u00a0version to the extension directory (<strong>\/usr\/lib64\/php\/modules<\/strong>).<\/p>\n<pre># cp \/tmp\/ioncube\/ioncube_loader_lin_5.4.so \/usr\/lib64\/php\/modules\r\n<\/pre>\n<p><strong>Note<\/strong>: Make sure to replace the PHP version and extension directory in the above command according to your system configuration.<\/p>\n<h3>Step 4: Configure ionCube Loader for PHP<\/h3>\n<p><strong>8.<\/strong>\u00a0Now we need to configure ioncube loader to work with PHP, in the\u00a0<code>php.ini<\/code>\u00a0file.<\/p>\n<pre># vim \/etc\/php.ini\r\n<\/pre>\n<p>Then add below line as the first line in the\u00a0<code>php.ini<\/code>\u00a0file.<\/p>\n<pre>zend_extension = <strong>\/usr\/lib64\/php\/modules\/<\/strong><strong>ioncube_loader_lin_5.4.so<\/strong>\r\n<\/pre>\n<div id=\"attachment_29196\" class=\"wp-caption aligncenter\">\n<p><a href=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2018\/04\/Enable-ionCube-Loader-in-PHP.png\"><img loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-29196\" src=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2018\/04\/Enable-ionCube-Loader-in-PHP.png\" sizes=\"auto, (max-width: 879px) 100vw, 879px\" srcset=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2018\/04\/Enable-ionCube-Loader-in-PHP.png 879w, https:\/\/www.tecmint.com\/wp-content\/uploads\/2018\/04\/Enable-ionCube-Loader-in-PHP-768x190.png 768w\" alt=\"Enable ionCube Loader in PHP\" width=\"879\" height=\"218\" aria-describedby=\"caption-attachment-29196\" data-lazy-loaded=\"true\" \/><\/a><\/p>\n<p id=\"caption-attachment-29196\" class=\"wp-caption-text\">Enable ionCube Loader in PHP<\/p>\n<\/div>\n<p><strong>Note<\/strong>: Make sure to replace the extension directory and PHP version in the above command according to your system configuration.<\/p>\n<p><strong>9.<\/strong>\u00a0Then save and exit the file. Now we need to restart the\u00a0<strong>Apache<\/strong>\u00a0or\u00a0<strong>Nginx<\/strong>\u00a0web server for the ioncube loaders to come into effect.<\/p>\n<pre><strong>-------------------- Start Apache Web Server --------------------<\/strong>\r\n# systemctl restart httpd\r\n\r\n<strong>-------------------- Start Nginx + PHP-FPM Server --------------------<\/strong>\r\n# systemctl restart nginx\r\n# systemctl restart php-fpm\r\n<\/pre>\n<h3>Step 5: Test ionCube Loader<\/h3>\n<p><strong>10.<\/strong>\u00a0To test if ionCube loader is now installed and properly configured on your server, check your PHP version once more. You should be able to see a message indicating that PHP is installed and configured with the ioncube loader extension (status should be enabled), as shown in the following screenshot.<\/p>\n<pre># php -v\r\n<\/pre>\n<div id=\"attachment_29194\" class=\"wp-caption aligncenter\">\n<p><a href=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2018\/04\/Test-ionCuber-Loader.png\"><img loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-29194\" src=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2018\/04\/Test-ionCuber-Loader.png\" sizes=\"auto, (max-width: 920px) 100vw, 920px\" srcset=\"https:\/\/www.tecmint.com\/wp-content\/uploads\/2018\/04\/Test-ionCuber-Loader.png 920w, https:\/\/www.tecmint.com\/wp-content\/uploads\/2018\/04\/Test-ionCuber-Loader-768x105.png 768w\" alt=\"Test ionCuber Loader\" width=\"920\" height=\"126\" aria-describedby=\"caption-attachment-29194\" data-lazy-loaded=\"true\" \/><\/a><\/p>\n<p id=\"caption-attachment-29194\" class=\"wp-caption-text\">Test ionCuber Loader<\/p>\n<\/div>\n<p>The above output confirms that the PHP is now loaded and enabled with ioncube loader.<\/p>\n<p><strong>ionCube<\/strong>\u00a0loader is a PHP extension for loading files secured and encoded with PHP encoder. We hope that everything worked on fine while following this guide, otherwise, use the feedback form below to send us your queries.<\/p>\n<p><a style=\"font-size: 1rem;\" href=\"https:\/\/www.tecmint.com\/install-ioncube-loader-in-centos-7\/\" target=\"_blank\" rel=\"noopener\">Source<\/a><\/p>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>ionCube\u00a0is a commercial software suite consisting of a PHP encoder, package foundry, bundler, a real time site intrusion detection and error reporting application as well as a loader. PHP encoder is an application for PHP software protection: used to secure, encrypt and license PHP source code.\u00a0ionCube\u00a0loader is an extension used to load PHP files protected &hellip; <\/p>\n<p class=\"link-more\"><a href=\"https:\/\/www.appservgrid.com\/paw92\/index.php\/2019\/03\/26\/how-to-install-ioncube-loader-in-centos-7\/\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;How to Install ionCube Loader in CentOS 7&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-12381","post","type-post","status-publish","format-standard","hentry","category-linux"],"_links":{"self":[{"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/posts\/12381","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/comments?post=12381"}],"version-history":[{"count":1,"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/posts\/12381\/revisions"}],"predecessor-version":[{"id":12382,"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/posts\/12381\/revisions\/12382"}],"wp:attachment":[{"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/media?parent=12381"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/categories?post=12381"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/tags?post=12381"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}