php-curl in Kali Linux 2018.4

php-curl is not installed by default in Kali Linux 2018.4 by default. There are tons of tutorials out there that instruct you to apt-get install php-curl, but this unfortunately won’t work.

You might need get an error similar to “PHP Fatal error: Uncaught Error: Call to undefined function curl_init()” when trying to run an exploit such as “Drupal 7.x Services Module Remote Code Execution” (exploits/php/webapps/41564.php).

The key is to run as follows:
  apt-get install libapache2-mod-php
  apt-get install php-curl
  apt-get install php7.3-curl

I first came across this difficulty when working with HackTheBox.eu’s Bastard box.

Leave a Reply

Your email address will not be published. Required fields are marked *