|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2017-01-10 08:00 UTC] kalle@php.net
-Status: Open
+Status: Suspended
[2017-01-10 08:00 UTC] kalle@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Wed Oct 22 07:00:01 2025 UTC |
Description: ------------ After registering a class, spidermonkey is able to access and modify any private variables within that class. This is also the case then assigning an instantiated class to spidermonkey. This problem only occurs for private variables, not for private functions. Reproduce code: --------------- class DummyClass() { private $privateVar = 'value of private var'; } $js = new JSContext(); $js->registerClass('DummyClass'); echo "Content of private variable is: ";var_export($js->evaluateScript("dc = new DummyClass;dc.privateVar;")); Expected result: ---------------- Content of private variable is: null Actual result: -------------- Content of private variable is: value of private var