How to Install the PHP Suhosin Extension

Installing Suhosin on PHP 7.2

This extension does not yet support PHP 7.2.

Installing Suhosin on PHP 7.0 or 7.1

Suhosin for PHP 7 is currently in development. As of August 2016, Suhosin for PHP 7 is not compiling correctly due to a known bug.

Once the bug in Suhosin for PHP 7 is fixed, to install on PHP 7.X, SSH in to your server as root and install the packages required to build the Suhosin extension.

sudo apt-get -y install gcc make autoconf libc-dev pkg-config

Next, run the following commands on your server:

git clone https://github.com/sektioneins/suhosin7
cd suhosin7
/opt/sp/php7.X/bin/phpize
PATH=/opt/sp/php7.X/bin:$PATH ./configure
make
sudo make install
sudo bash -c "echo extension=suhosin.so > /etc/php7.X-sp/conf.d/suhosin.ini"
sudo service php7.X-fpm-sp restart

Installing Suhosin on PHP 5.4, 5.5, or 5.6

To install this extension on PHP 5.X, SSH in to your server as root and install the packages required to build the Suhosin extension.

sudo apt-get -y install gcc make autoconf libc-dev pkg-config

Next, download Suhosin, extract it, and change to the Suhosin directory. You can find the latest version on the Suhosin downloads page.

wget https://download.suhosin.org/suhosin-0.9.38.tar.gz
tar xzf suhosin-0.9.38.tar.gz
cd suhosin-0.9.38

Now, compile, install, and restart PHP. To install for multiple PHP versions, repeat the steps below for each PHP version.

/opt/sp/php5.X/bin/phpize
PATH=/opt/sp/php5.X/bin:$PATH ./configure
make
sudo make install
sudo bash -c "echo extension=suhosin.so > /etc/php5.X-sp/conf.d/suhosin.ini"
sudo service php5.X-fpm-sp restart

Note : Search suhosin7.so and include php.ini extensions="/path/suhosin7.so"

Verifying the Installation

You can verify Suhosin is installed correctly by running the command:

phpX.Y-sp -i | grep suhosin

You should see the following output:

/etc/phpX.Y-sp/conf.d/suhosin.ini,
suhosin
suhosin.apc_bug_workaround => Off => Off
suhosin.cookie.checkraddr => 0 => 0
suhosin.cookie.cryptdocroot => On => On
suhosin.cookie.cryptkey => [ protected ] => [ protected ]
suhosin.cookie.cryptlist => no value => no value
suhosin.cookie.cryptraddr => 0 => 0
suhosin.cookie.cryptua => On => On
suhosin.cookie.disallow_nul => 1 => 1
suhosin.cookie.disallow_ws => 1 => 1
suhosin.cookie.encrypt => Off => Off
...

Source : https://serverpilot.io/community/articles/how-to-install-the-php-suhosin-extension.html
Posted on: November 6, 2017, by :  | 106 views

Leave a Reply

https://serang.ut.ac.id/css/css/slot88/ https://tinjut.bagkeu.dikdasmen.kemdikbud.go.id/slot-maxwin/ https://dpm.polinema.ac.id/slot-gacor/ https://akademik.ft.unm.ac.id/slot-dana/ https://ppdb.probolinggokab.go.id/slot-5000/ https://bkad.sulselprov.go.id/assets/ https://ojs.balidwipa.ac.id/docs/slot-gacor/ http://korpri.pekalongankab.go.id/api/slot-gacor/ https://elang.umpp.ac.id/foto/farmasi/-/asset/ http://rsud-kelet.jatengprov.go.id/wp-content/-/asset/ https://kusdhianto-fe.staff.ugm.ac.id/slot88/ http://ppdb.probolinggokab.go.id/judi-bola/ https://bapenda.labuhanbatukab.go.id/racikan-sbobet/ http://rsud-kelet.jatengprov.go.id/wp-content/-/data/ https://agenda.riau.go.id/-/judi-bola/ https://balapan.padang.go.id/sbobet88/ http://jdih.wakatobikab.go.id/sbobet88/ http://kph.menlhk.go.id/sbobet88/ https://bkad.sulselprov.go.id/data/ https://dpm.polinema.ac.id/slot-gacor/ https://dinkes.jemberkab.go.id/storage/attachments/