How to install or uninstall suPHP
Module status in default profiles
The following EasyApache profiles include the mod_suphp
Apache module by default:
- Basic
- Mod Ruid2
Note:
The Mod Ruid2 profile is only available if you do not use CloudLinux.
Installation steps
If your most recent EasyApache build does not include suPHP, perform the following steps to install suPHP:
Navigate to WHM's EasyApache 3interface (Home >> Software >> EasyApache 3).
Note:
To access EasyApache from the command line interface, run the
/scripts/easyapache
script asroot
.Select the profile that you wish to modify.
Click the gear icon (
) that corresponds to your selection.- Click Next Step in the Apache Version stage.
- Click Next Step in the PHP Version stage.
Perform one of the following actions in the Short Options List stage:
- To install the suPHP PHP handler, select Mod SuPHP.
- To uninstall the suPHP PHP handler, deselect Mod SuPHP.
- Click Save and Build at the bottom of the Short Options List interface.
- After the EasyApache build completes, use the Configure PHP and suEXEC interface to set the PHP 5 Handler option to suphp.
If your most recent EasyApache build includes suPHP, perform the following steps to select suPHP as your PHP handler:
- In WHM's Configure PHP and suEXEC interface (Home >> Service Configuration >> Configure suPHP and suEXEC), set the PHP 5 Handler option to suphp.
- Click Save New Configuration.
How to enable or disable the module in a custom EasyApache profile file
The following table contains the module information that EasyApache stores in the profile file for the module:
EasyApache module name | mod_suphp |
---|---|
EasyApache Profile Entry | Apache : optmods : PHPAsUser |
To enable or disable the suPHP PHP handler in a custom EasyApache profile file, set the Apache : optmods : PHPAsUser
profile entry to one of the following values:
1
– This value enables the suPHP PHP handler in the profile.0
– This value disables the suPHP PHP handler in the profile.
Requirements
PHP
suPHP requires PHP. If you do not install PHP, suPHP will not function.
Compatibility
This module has no known compatibility issues.
History
Date | EasyApache version | Action | Details |
---|---|---|---|
7/16/2014 | 3.26.0 | EA update | Case 68701: Update suPHP to version 0.7.2 |
2/11/2014 | 3.24.11 | Doc update | Removed Apache 1.3 and 2.0 |
5/1/2012 | 3.12.3 | EA update | Case 57958: switching mod_ruid2+DSO to suPHP results in PHP sites no longer functioning |
12/28/2011 | 3.8.1 | EA update | Case 53894: Patch mod_suphp for mod_ruid2 compatibility |
Related documentation
- EasyApache – The EasyApache home page.
- Apache PHP Request Handling – Detailed information on the available PHP handlers.
Vendor documentation
The following text is an excerpt from the suPHP project homepage:
suPHP is a tool for executing PHP scripts with the permissions
of their owners. It consists of an Apache module (mod_suphp) and a
setuid root binary (suphp) that is called by the Apache module to
change the uid of the process executing the PHP interpreter.
For more information on the suPHP PHP handler, click the following link:
Apache version | Documentation |
---|---|
2.2 and 2.4 | suPHP Homepage |