diff options
Diffstat (limited to 'ext/standard/php_fopen_wrapper.c')
| -rw-r--r-- | ext/standard/php_fopen_wrapper.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/ext/standard/php_fopen_wrapper.c b/ext/standard/php_fopen_wrapper.c index 1462f4a2e3..ea1861b28f 100644 --- a/ext/standard/php_fopen_wrapper.c +++ b/ext/standard/php_fopen_wrapper.c @@ -187,7 +187,8 @@ php_stream * php_stream_url_wrap_php(php_stream_wrapper *wrapper, char *path, ch } if (!strcasecmp(path, "input")) { - if ((options & STREAM_OPEN_FOR_INCLUDE) && !PG(allow_url_include) ) { + /* Override default behavior for php://input when used as an include and allow_url_include is being used in BC (off) mode */ + if ((options & STREAM_OPEN_FOR_INCLUDE) && !PG(allow_url_include_list) ) { if (options & REPORT_ERRORS) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "URL file-access is disabled in the server configuration"); } @@ -197,7 +198,8 @@ php_stream * php_stream_url_wrap_php(php_stream_wrapper *wrapper, char *path, ch } if (!strcasecmp(path, "stdin")) { - if ((options & STREAM_OPEN_FOR_INCLUDE) && !PG(allow_url_include) ) { + /* Override default behavior for php://stdin when used as an include and allow_url_include is being used in BC (off) mode */ + if ((options & STREAM_OPEN_FOR_INCLUDE) && !PG(allow_url_include_list) ) { if (options & REPORT_ERRORS) { php_error_docref(NULL TSRMLS_CC, E_WARNING, "URL file-access is disabled in the server configuration"); } |
