Php function set disabled after enabling security mode _ PHP Tutorial

Source: Internet
Author: User
Function set disabled after the security mode is enabled in php. Copy the code as follows :? Phpini_set (safe_mode, true );? Table 42-2. security mode restriction function name restriction dbmopen () check whether the operated file or directory is consistent with the running script The code is as follows:


Ini_set ("safe_mode", true );
?>


Table 42-2. security mode restriction functions

Function name Restrictions
Dbmopen () Check whether the operated file or directory has the same UID (owner) as the script being executed ).
Dbase_open () Check whether the operated file or directory has the same UID (owner) as the script being executed ).
Filepro () Check whether the operated file or directory has the same UID (owner) as the script being executed ).
Filepro_rowcount () Check whether the operated file or directory has the same UID (owner) as the script being executed ).
Filepro_retrieve () Check whether the operated file or directory has the same UID (owner) as the script being executed ).
Ifx _* SQL _safe_mode limit ,(! = Safe mode)
Ingres _* SQL _safe_mode limit ,(! = Safe mode)
Mysql _* SQL _safe_mode limit ,(! = Safe mode)
Pg_loimport () Check whether the operated file or directory has the same UID (owner) as the script being executed ).
Posix_mkfifo () Check whether the operated directory has the same UID (owner) as the script being executed ).
Putenv () Follow the safe_mode_protected_env_vars and safe_mode_allowed_env_vars options set by ini. SeePutenv ()Function documentation.
Move_uploaded_file () Check whether the operated file or directory has the same UID (owner) as the script being executed ).
Chdir () Check whether the operated directory has the same UID (owner) as the script being executed ).
Dl () This function is disabled in safe mode.
Backtick operator This function is disabled in safe mode.
Shell_exec ()(The function is the same as the backticks function) This function is disabled in safe mode.
Exec () You can only perform operations in the directory set by safe_mode_exec_dir. For some reason, it cannot be used in the path of the executable object currently....Escapeshellcmd ()Will be applied to the parameters of this function.
System () You can only perform operations in the directory set by safe_mode_exec_dir. For some reason, it cannot be used in the path of the executable object currently....Escapeshellcmd ()Will be applied to the parameters of this function.
Passthru () You can only perform operations in the directory set by safe_mode_exec_dir. For some reason, it cannot be used in the path of the executable object currently....Escapeshellcmd ()Will be applied to the parameters of this function.
Popen () You can only perform operations in the directory set by safe_mode_exec_dir. For some reason, it cannot be used in the path of the executable object currently....Escapeshellcmd ()Will be applied to the parameters of this function.
Fopen () Check whether the operated directory has the same UID (owner) as the script being executed ).
Mkdir () Check whether the operated directory has the same UID (owner) as the script being executed ).
Rmdir () Check whether the operated directory has the same UID (owner) as the script being executed ).
Rename () Check whether the operated file or directory has the same UID (owner) as the script being executed ). Check whether the operated directory has the same UID (owner) as the script being executed ).
Unlink () Check whether the operated file or directory has the same UID (owner) as the script being executed ). Check whether the operated directory has the same UID (owner) as the script being executed ).
Copy () Check whether the operated file or directory has the same UID (owner) as the script being executed ). Check whether the operated directory has the same UID (owner) as the script being executed ). (OnsourceAndtarget)
Chgrp () Check whether the operated file or directory has the same UID (owner) as the script being executed ).
Chown () Check whether the operated file or directory has the same UID (owner) as the script being executed ).
Chmod () Check whether the operated file or directory has the same UID (owner) as the script being executed ). In addition, SUID, SGID, and sticky bits cannot be set.
Touch () Check whether the operated file or directory has the same UID (owner) as the script being executed ). Check whether the operated directory has the same UID (owner) as the script being executed ).
Symlink () Check whether the operated file or directory has the same UID (owner) as the script being executed ). Check whether the operated directory has the same UID (owner) as the script being executed ). (Note: Only test target)
Link () Check whether the operated file or directory has the same UID (owner) as the script being executed ). Check whether the operated directory has the same UID (owner) as the script being executed ). (Note: Only test target)
Apache_request_headers () In security mode, headers starting with "authorization" (case sensitive) are not returned.
Header () In security mode, ifWWW-Authenticate, The uid of the current script will be added toRealm.
PHP_AUTH variable In safe modePHP_AUTH_USER,PHP_AUTH_PWAndPHP_AUTH_TYPEIn$_SERVERIs unavailable. However, you can still useREMOTE_USERTo obtain the USER name ). (Note: it is valid only after PHP 4.3.0)
Highlight_file (),Show_source () Check whether the operated file or directory has the same UID (owner) as the script being executed ). Check whether the operated directory has the same UID (owner) as the script being executed ). (Note: it is only valid after version 4.2.1)
Parse_ini_file () Check whether the operated file or directory has the same UID (owner) as the script being executed ). Check whether the operated directory has the same UID (owner) as the script being executed ). (Note: it is only valid after version 4.2.1)
Set_time_limit () It does not work in security mode.
Max_execution_time It does not work in security mode.
Mail () In security mode, the fifth parameter is blocked. (Note: only affected since PHP 4.2.3)
Any usePhp4/main/fopen_wrappers.cFunctions ??

The http://www.bkjia.com/PHPjc/323776.htmlwww.bkjia.comtruehttp://www.bkjia.com/PHPjc/323776.htmlTechArticle code is as follows :? Php ini_set ("safe_mode", true );? Table 42-2. security mode restriction function name restriction dbmopen () check whether the operated file or directory is consistent with the running script...

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.