{"id":2807,"date":"2018-01-30T20:07:15","date_gmt":"2018-01-30T17:07:15","guid":{"rendered":"https:\/\/www.howtoforge.com\/tutorial\/install-ioncube-loader-on-debian-9\/"},"modified":"2018-01-30T20:07:15","modified_gmt":"2018-01-30T17:07:15","slug":"how-to-install-ioncube-loader-on-debian-9","status":"publish","type":"post","link":"https:\/\/afaghhosting.net\/blog\/how-to-install-ioncube-loader-on-debian-9\/","title":{"rendered":"How to Install ionCube Loader on Debian 9"},"content":{"rendered":"<div dir=\"ltr\" style=\"text-align: left;\"><img decoding=\"async\" class=\"ff-og-image-inserted\" src=\"https:\/\/afaghhosting.net\/blog\/wp-content\/uploads\/2018\/01\/how-to-install-ioncube-loader-on-debian-9.gif\" alt=\"\" title=\"\"><\/div>\n<p dir=\"ltr\" style=\"text-align: left;\">IonCube is a\u00a0PHP extension that can be used for decoding secured encrypted PHP files at runtime. The IonCube encoder is used by commercial PHP program vendors to protect applications and the loader, which we install in this tutorial, is required to run\u00a0IonCube encoded files on your server. The IoncubeLoader is available free of charge. Ioncube loader increases your website loading speed and preventing others from stealing the source code by converting your PHP into byte-code.<\/p>\n<p dir=\"ltr\" style=\"text-align: left;\">In this tutorial, we will explain\u00a0the installation of IonCube Loader on Debian 9 server.<\/p>\n<h2 id=\"requirements\" dir=\"ltr\" style=\"text-align: left;\">Requirements<\/h2>\n<ul dir=\"ltr\" style=\"text-align: left;\">\n<li>A server running Debian 9 with LAMP installed.<\/li>\n<li>A non-root user with sudo privileges.<\/li>\n<\/ul>\n<h2 id=\"getting-started\" dir=\"ltr\" style=\"text-align: left;\">Getting Started<\/h2>\n<p dir=\"ltr\" style=\"text-align: left;\">Before starting, update all packages that are installed on your server using the following command:<\/p>\n<p class=\"command\" dir=\"ltr\" style=\"text-align: left;\">sudo apt-get update -y<br \/>\nsudo apt-get upgrade -y<\/p>\n<p dir=\"ltr\" style=\"text-align: left;\">Once all the packages are updated, restart the system to apply all the changes:<\/p>\n<p class=\"command\" dir=\"ltr\" style=\"text-align: left;\">sudo reboot<\/p>\n<h2 id=\"installing-ioncube-loader\" dir=\"ltr\" style=\"text-align: left;\">Installing IonCube Loader<\/h2>\n<p dir=\"ltr\" style=\"text-align: left;\">First, you will need to download the latest version of the IonCube Loader from their official website. Otherwise, you can download it using the following command:<\/p>\n<p class=\"command\" dir=\"ltr\" style=\"text-align: left;\">wget https:\/\/downloads.ioncube.com\/loader_downloads\/ioncube_loaders_lin_x86-64.tar.gz<\/p>\n<p dir=\"ltr\" style=\"text-align: left;\">Once the download is completed, extract the downloaded file using the following command:<\/p>\n<p class=\"command\" dir=\"ltr\" style=\"text-align: left;\">tar -xvzf ioncube_loaders_lin_x86-64.tar.gz<\/p>\n<p dir=\"ltr\" style=\"text-align: left;\">By default the files will be unzipped to a folder ioncube.<\/p>\n<p dir=\"ltr\" style=\"text-align: left;\">Now, change the directory to ioncube folder and run ls command to see all the extension:<\/p>\n<p class=\"command\" dir=\"ltr\" style=\"text-align: left;\">cd ioncube<br \/>\nls<\/p>\n<p dir=\"ltr\" style=\"text-align: left;\">You should see the various ioncube loader files corresponding to various php versions as below:<\/p>\n<pre dir=\"ltr\">ioncube_loader_lin_4.1.so ioncube_loader_lin_5.0_ts.so ioncube_loader_lin_5.4.so ioncube_loader_lin_7.0_ts.so README.txt\nioncube_loader_lin_4.2.so ioncube_loader_lin_5.1.so ioncube_loader_lin_5.4_ts.so ioncube_loader_lin_7.1.so USER-GUIDE.pdf\nioncube_loader_lin_4.3.so ioncube_loader_lin_5.1_ts.so ioncube_loader_lin_5.5.so ioncube_loader_lin_7.1_ts.so USER-GUIDE.txt\nioncube_loader_lin_4.3_ts.so ioncube_loader_lin_5.2.so ioncube_loader_lin_5.5_ts.so ioncube_loader_lin_7.2.so\nioncube_loader_lin_4.4.so ioncube_loader_lin_5.2_ts.so ioncube_loader_lin_5.6.so ioncube_loader_lin_7.2_ts.so\nioncube_loader_lin_4.4_ts.so ioncube_loader_lin_5.3.so ioncube_loader_lin_5.6_ts.so LICENSE.txt\nioncube_loader_lin_5.0.so ioncube_loader_lin_5.3_ts.so ioncube_loader_lin_7.0.so loader-wizard.php\n<\/pre>\n<p dir=\"ltr\" style=\"text-align: left;\">Now, you will need to select the correct ioncube loader file as per the PHP version installed on your server. Run the following command to see the version of PHP installed on your server:<\/p>\n<p class=\"command\" dir=\"ltr\" style=\"text-align: left;\">php -v<\/p>\n<p dir=\"ltr\" style=\"text-align: left;\">Output:<\/p>\n<pre dir=\"ltr\">PHP 7.0.22-0ubuntu0.16.04.1 (cli) ( NTS )\nCopyright (c) 1997-2017 The PHP Group\nZend Engine v3.0.0, Copyright (c) 1998-2017 Zend Technologies\n with Zend OPcache v7.0.22-0ubuntu0.16.04.1, Copyright (c) 1999-2017, by Zend Technologies\n<\/pre>\n<p dir=\"ltr\" style=\"text-align: left;\">In the above output, you should see that the PHP version installed is PHP 7.0.22. So you will need to copy ioncube_loader_lin_7.0.so file from ioncube directory to the PHP extension directory.<\/p>\n<p dir=\"ltr\" style=\"text-align: left;\">First, find the location of the PHP extension directory using the following command:<\/p>\n<p class=\"command\" dir=\"ltr\" style=\"text-align: left;\">php -i | grep extension_dir<\/p>\n<p dir=\"ltr\" style=\"text-align: left;\">You should see the following output:<\/p>\n<pre dir=\"ltr\">extension_dir =&gt; \/usr\/lib\/php\/20151012 =&gt; \/usr\/lib\/php\/20151012\n<\/pre>\n<p dir=\"ltr\" style=\"text-align: left;\">Now, copy ioncube loader file to the PHP extension directory (\/usr\/lib\/php\/20151012) using the following command:<\/p>\n<p class=\"command\" dir=\"ltr\" style=\"text-align: left;\">cd ioncube<br \/>\ncp ioncube_loader_lin_7.0.so \/usr\/lib\/php\/20151012\/<\/p>\n<p dir=\"ltr\" style=\"text-align: left;\">Next, you will need to edit php.ini file and add path of the ioncube extension. You can do this with the following command:<\/p>\n<p class=\"command\" dir=\"ltr\" style=\"text-align: left;\">sudo nano \/etc\/php\/7.0\/apache2\/php.ini<\/p>\n<p dir=\"ltr\" style=\"text-align: left;\">Add the following line:<\/p>\n<pre dir=\"ltr\">zend_extension=\/usr\/lib\/php\/20151012\/ioncube_loader_lin_7.0.so\n<\/pre>\n<p dir=\"ltr\" style=\"text-align: left;\">Save the file, then open other php.ini file:<\/p>\n<p class=\"command\" dir=\"ltr\" style=\"text-align: left;\">sudo nano \/etc\/php\/7.0\/cli\/php.ini<\/p>\n<p dir=\"ltr\" style=\"text-align: left;\">Add the following line:<\/p>\n<pre dir=\"ltr\">zend_extension=\/usr\/lib\/php\/20151012\/ioncube_loader_lin_7.0.so\n<\/pre>\n<p dir=\"ltr\" style=\"text-align: left;\">Save and close the file, then restart Apache service to apply the changes:<\/p>\n<p class=\"command\" dir=\"ltr\" style=\"text-align: left;\">sudo systemctl restart apache2<\/p>\n<h2 id=\"testing-ioncube-loader\" dir=\"ltr\" style=\"text-align: left;\">Testing IonCube Loader<\/h2>\n<p dir=\"ltr\" style=\"text-align: left;\">Now, everything is configured properly, it&#8217;s time to test whether Ioncube loader is installed or not. You can test it using the following command:<\/p>\n<p class=\"command\" dir=\"ltr\" style=\"text-align: left;\">php -v<\/p>\n<p dir=\"ltr\" style=\"text-align: left;\">If everythig is fine, you should see the following output:<\/p>\n<pre dir=\"ltr\">PHP 7.0.22-0ubuntu0.16.04.1 (cli) ( NTS )\nCopyright (c) 1997-2017 The PHP Group\nZend Engine v3.0.0, Copyright (c) 1998-2017 Zend Technologies\n with the ionCube PHP Loader (enabled) + Intrusion Protection from ioncube24.com (unconfigured) v10.1.0, Copyright (c) 2002-2017, by ionCube Ltd.\n with Zend OPcache v7.0.22-0ubuntu0.16.04.1, Copyright (c) 1999-2017, by Zend Technologies\n<\/pre>\n<div dir=\"ltr\" style=\"text-align: left;\">\n<p><b>Share this page:<\/b><\/p>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>IonCube is a\u00a0PHP extension that can be used for decoding secured encrypted PHP files at runtime. The IonCube encoder is used by commercial PHP program vendors to protect applications and the loader, which we install in this tutorial, is required to run\u00a0IonCube encoded files on your server. The IoncubeLoader is available free of charge. Ioncube &hellip;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[36],"tags":[],"class_list":["post-2807","post","type-post","status-publish","format-standard","hentry","category-36"],"_links":{"self":[{"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/posts\/2807","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/comments?post=2807"}],"version-history":[{"count":0,"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/posts\/2807\/revisions"}],"wp:attachment":[{"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/media?parent=2807"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/categories?post=2807"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/tags?post=2807"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}