php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #76094 Access violation when using opcache
Submitted: 2018-03-14 10:13 UTC Modified: -
Votes:1
Avg. Score:5.0 ± 0.0
Reproduced:1 of 1 (100.0%)
Same Version:1 (100.0%)
Same OS:0 (0.0%)
From: mlocati at gmail dot com Assigned:
Status: Closed Package: opcache
PHP Version: 7.2.3 OS: Windows 10
Private report: No CVE-ID: None
 [2018-03-14 10:13 UTC] mlocati at gmail dot com
Description:
------------
We have an access violation issue when using opcache.

I can't replicate it with a simple script, but here's a list of steps to reproduce the crash:

1. Install and configure MySQL, and create an empty database

2. Download https://github.com/concrete5/concrete5-legacy/archive/master.zip

3. Extract it (eg to C:\bug)

4. Create a file named C:\bug\bug.ini file with this contents:
date.timezone=UTC
extension_dir=ext
extension=mysqli
extension=gd2
zend_extension=opcache
opcache.enable=1

5. Launch this command:
php -c C:\bug\bug.ini -S 127.0.0.1:2888 -t C:\bug\web

6. Browse to http://127.0.0.1:2888 and install concrete5 (hint: for a faster setup, choose "Empty Site" in the "Sample Content" section)

7. Browse to http://127.0.0.1:2888/index.php/dashboard/files/search/

8. Hit the the "Browse..." button

9. Specify the location of a PNG or JPG file (for instance you can download and use https://documentation.concrete5.org/packages/concrete5_theme/themes/concrete5/images/logo.png )

10. Hit "Upload File"

11. CRASH!


I have a full Windows dump of the crash (created following the instructions at https://msdn.microsoft.com/it-it/library/windows/desktop/bb787181%28v=vs.85%29.aspx?f=255&MSPPError=-2147217396 ) if anyone needs it.

Windows version: 10.0.16299.248 (Fall Creators Update with latest patches)

PHP version: PHP 7.2.3 - ZTS MSVC15 (Visual C++ 2017) x86

Actual result:
--------------
Unhandled exception in 0x14F7EFB2 (php7ts.dll) in php.exe: 0xC0000005: access violation while reading 0xF4C3C01A.

> php7ts.dll!add_next_index_stringl(_zval_struct * arg, const char * str, unsigned int length) Row 1584

  php7ts.dll!php_pcre_match_impl(pcre_cache_entry * pce, char * subject, int subject_len, _zval_struct * return_value, _zval_struct * subpats, int global, int use_flags, int flags, int start_offset) Row 1061
  
  php7ts.dll!php_do_pcre_match(_zend_execute_data * execute_data, _zval_struct * return_value, int global) Row 734
 
  php7ts.dll!zif_preg_match(_zend_execute_data * execute_data, _zval_struct * return_value) Row 1147
 
  php7ts.dll!ZEND_DO_ICALL_SPEC_RETVAL_USED_HANDLER(_zend_execute_data * execute_data) Row 627
 
  php7ts.dll!execute_ex(_zend_execute_data * ex) Row 59723
 
  php7ts.dll!zend_execute(_zend_op_array * op_array, _zval_struct * return_value) Row 63761
 
  php7ts.dll!zend_execute_scripts(int type, _zval_struct * retval, int file_count, ...) Row 1496
 
  php7ts.dll!php_execute_script(_zend_file_handle * primary_file) Row 2590
 
  php.exe!php_cli_server_dispatch_script(php_cli_server * server, php_cli_server_client * client) Row 1987
 
  php.exe!php_cli_server_dispatch(php_cli_server * server, php_cli_server_client * client) Row 2162
 
  php.exe!php_cli_server_recv_event_read_request(php_cli_server * server, php_cli_server_client * client) Row 2382
 
  php.exe!php_cli_server_do_event_for_each_fd_callback(void * _params, unsigned int fd, int event) Row 2460
 
  [Frame inline] php.exe!php_cli_server_poller_iter_on_active(php_cli_server_poller *)
 
  [Frame inline] php.exe!php_cli_server_do_event_for_each_fd(php_cli_server *)
 
  php.exe!php_cli_server_do_event_loop(php_cli_server *) Row 2488
 
  php.exe!do_cli_server(int argc, char * * argv) Row 2611
 
  php.exe!main(int argc, char * * argv) Row 1407


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2018-03-15 03:17 UTC] laruence@php.net
Automatic comment on behalf of laruence@gmail.com
Revision: http://git.php.net/?p=php-src.git;a=commit;h=4758164ac5fd61be70d9366175b30df758ac8262
Log: Fixed bug #76094 (Access violation when using opcache)
 [2018-03-15 03:17 UTC] laruence@php.net
-Status: Open +Status: Closed
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sat Dec 21 16:01:28 2024 UTC