Edit report at https://bugs.php.net/bug.php?id=64938&edit=1
ID: 64938
Updated by: stas@php.net
Reported by: Sjon at hortensius dot net
Summary: libxml_disable_entity_loader setting is shared
between threads
-Status: Open
+Status: Closed
Type: Bug
Package: *XML functions
Operating System: Archlinux
PHP Version: 5.4.15
Block user comment: N
Private report: N
New Comment:
Automatic comment on behalf of martin@divbyzero.net
Revision: http://git.php.net/?p=php-src.git;a=commit;h=de31324c221c1791b26350ba106cc26bad23ace9
Log: Fix bug #64938: libxml_disable_entity_loader setting is shared between threads
Previous Comments:
------------------------------------------------------------------------
[2015-01-29 16:44:50] stefan dot behninger at nasdaq dot com
Seems like this is a much bigger issue. We discovered that disabling the loader does not only affect
the current thread but obviously changes the setting globally on the entire server. Plus, it seems
to be persisted in a way that only restarting the server got us back to normal.
Planning to do some more tests tomorrow to eliminate any kind of caching that might have been
involved.
We're on PHP 5.3.3 on CentOS, strictly single-threaded.
------------------------------------------------------------------------
[2013-05-30 21:30:26] Sjon at hortensius dot net
Clarified summary
------------------------------------------------------------------------
[2013-05-29 07:21:46] sjon at hortensius dot net
Related To: Bug #62577
------------------------------------------------------------------------
[2013-05-28 13:43:33] Sjon at hortensius dot net
Description:
------------
The libxml_disable_entity_loader() setting is shared between hits in a FPM
process. Therefore; our script have the external entity-loader randomly
enabled/disabled.
Test script:
---------------
<?php
die(var_dump(libxml_disable_entity_loader(false)));
Expected result:
----------------
The default setting (which is true since 5.4.13) should always be var_dump-ed
Actual result:
--------------
since this setting is remembered in the thread; after a while all hits return
false
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=64938&edit=1