Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision Both sides next revision
php [2007/02/13 01:16]
a
php [2007/03/08 00:53]
greebo
Line 1: Line 1:
 ====== PHP tips ====== ====== PHP tips ======
 ===== Instalation tips ===== ===== Instalation tips =====
 +
 +
  
  
Line 19: Line 21:
         php_admin_flag safe_mode On         php_admin_flag safe_mode On
         php_admin_value open_basedir "/var/www/domain_dir/:/home/"         php_admin_value open_basedir "/var/www/domain_dir/:/home/"
 +        php_admin_value sendmail_from webmaster@example.com
 + 
 + 
 +        php_admin_flag display_errors On
 +        php_admin_value safe_mode_include_dir "/usr/share/php/"
 +#       php_admin_value default_charset "UTF-8"
 +        php_admin_value default_charset "windows-1250"
 +
 +
  
 FIXME - styling needed FIXME - styling needed
Line 24: Line 35:
 '' ''
 PHP to secure a setup, a good start is a secure php.ini, for example: PHP to secure a setup, a good start is a secure php.ini, for example:
-- disable the Fopen Wrapper, allow_url_fopen = Off +  - disable the Fopen Wrapper, allow_url_fopen = Off 
-- use disable_classes and disable_functions like ini_alter, ini_get_all, ini_get, ini_restore, ini_set, php_get_tmpdir, php_ini_scanned_files, php_logo_guid, php_uname, phpcredits, phpinfo, phpversion, putenv, restore_include_path, set_include_path, set_time_limit, version_compare, zend_logo_guid, zend_version, show_source, system, shell_exec, passthru, exec, proc_open, time_limit, version_compare, zend_logo_guid, zend_version, show_source, system, shell_exec, passthru, exec, proc_open etc. etc. +  - use disable_classes and disable_functions like  
-- set register_globals = off +  ini_alter, ini_get_all, ini_get, ini_restore, ini_set, php_get_tmpdir, php_ini_scanned_files, php_logo_guid, php_uname, phpcredits, phpinfo, phpversion, putenv, restore_include_path, set_include_path, set_time_limit, version_compare, zend_logo_guid, zend_version, show_source, system, shell_exec, passthru, exec, proc_open, time_limit, version_compare, zend_logo_guid, zend_version, show_source, system, shell_exec, passthru, exec, proc_open etc. etc. 
-- set log_errors = on, error_reporting and error_log + 
-- use open_basedir and include_path +  - set register_globals = off 
-- use safe_mode if possible''+  - set log_errors = on, error_reporting and error_log 
 +  - use open_basedir and include_path 
 +  - use safe_mode if possible''
  
 === see also: === === see also: ===
php.txt · Last modified: 2010/02/20 14:43 by greebo
CC Attribution-Share Alike 4.0 International
Driven by DokuWiki Recent changes RSS feed Valid CSS Valid XHTML 1.0 ipv6 ready