[Tutorial] Install php5.6 on Kali Linux 2016.2
As you knew, php7 is set by default on Kali Linux 2016.2. For some reasons, you need to install php5.6. For example, some web app pentesting lab didn’t work with php7 like dvwa, sqli-labs, xvwa, …
How to install php5.6 on Kali Linux 2016.2:
- Add these two lines to sources.list file. Save and Close
deb http://packages.dotdeb.org wheezy-php56-zts all
deb-src http://packages.dotdeb.org wheezy-php56-zts all - Run command
apt-get update - Install php5.6 using command:apt-get -y install php5 libapache2-mod-php5 php5-mysql php5-curl php5-gd php5-intl php5-imap php5-mcrypt php5-pspell php5-recode php5-tidy php5-xmlrpc php5-xsl
- How to set php5.6 by default, use two command below:
a2dismod php7.0 ; sudo a2enmod php5.6 ; sudo service apache2 restart
ln -sfn /usr/bin/php5.6 /etc/alternatives/php - Enjoy!