Tips and Tricks PHP CON 2002
Safe Mode is an attempt to solve the shared-server security problem. It is architecturally incorrect to
try to solve this problem at the PHP level, but since the alternatives at the web server and OS levels
aren’t very realistic, many people, especially ISP’s, use safe mode for now.
The configuration directives that control safe mode are:
safe_mode = Off
open_basedir =
safe_mode_exec_dir =
safe_mode_allowed_env_vars = PHP_
safe_mode_protected_env_vars = LD_LIBRARY_PATH
disable_functions =
When safe_mode is on, PHP checks to see if the owner of the current script matches the owner of the
file to be operated on by a file function.
Source : Rasmus Lerdorf