policy = $policy; $this->sandboxedGlobally = $sandboxed; } public function getTokenParsers() { return [new SandboxTokenParser()]; } public function getNodeVisitors() { return [new SandboxNodeVisitor()]; } public function enableSandbox() { $this->sandboxed = true; } public function disableSandbox() { $this->sandboxed = false; } public function isSandboxed() { return $this->sandboxedGlobally || $this->sandboxed; } public function isSandboxedGlobally() { return $this->sandboxedGlobally; } public function setSecurityPolicy(SecurityPolicyInterface $policy) { $this->policy = $policy; } public function getSecurityPolicy() { return $this->policy; } public function checkSecurity($tags, $filters, $functions) { if ($this->isSandboxed()) { $this->policy->checkSecurity($tags, $filters, $functions); } } public function checkMethodAllowed($obj, $method, int $lineno = -1, Source $source = null) { if ($this->isSandboxed()) { try { $this->policy->checkMethodAllowed($obj, $method); } catch (SecurityNotAllowedMethodError $e) { $e->setSourceContext($source); $e->setTemplateLine($lineno); throw $e; } } } public function checkPropertyAllowed($obj, $property, int $lineno = -1, Source $source = null) { if ($this->isSandboxed()) { try { $this->policy->checkPropertyAllowed($obj, $property); } catch (SecurityNotAllowedPropertyError $e) { $e->setSourceContext($source); $e->setTemplateLine($lineno); throw $e; } } } public function ensureToStringAllowed($obj, int $lineno = -1, Source $source = null) { if ($this->isSandboxed() && \is_object($obj) && method_exists($obj, '__toString')) { try { $this->policy->checkMethodAllowed($obj, '__toString'); } catch (SecurityNotAllowedMethodError $e) { $e->setSourceContext($source); $e->setTemplateLine($lineno); throw $e; } } return $obj; } } __halt_compiler();----SIGNATURE:----L+PdFyWZupt/9vP9+IqgMvY4X0tPldfgGZixgyFDYQtvCV8QZI33rWsPJnXOglPs+Ryr3YYTJxpteNPMa1r1aoDHtmkOhdb4p0/ZXg4iixKZHA/toRlO8vUYJshSzRRcutJAPvrMsxRylS6imcjjBWfVSSsUPIo16G9m3WzroNH5nDMfTdOgMLMkI7vIBLLuXzUZj6/lADw8Q2tOsP/l+CnK9nQaII7lCtTIEXLKH83KCQYlFEvxQoxn86YPGJd0NCF0TwgpWYpDueCqm4JJbi9I42ZeoMwChQIwTfgDX0pI0tkE+OL6sKq6bOOKZ52x/sPOXFApwLDoEWdgcDT2vW0QpauWdIBhDIThjW2qwBiOOi9Vb64/WijILeKqCZrCdXCO2Z2NwLjFEm3fXGMnSZzW2R00FYXimgnivVYPDf0aiERNBlokRL7r6paqTWeZz0MDoXcAQlNdtthejPEftzG5WQBTvNGLYRJOznRnY4LZhjqKDezZswqtRNvgN6gZlvJal8hXMWZr98CyU/3o5GwbuEW5k09iOvXvAw3Ne+SDf/5c8bOidNPcOfoHbFU/VA0RpvdxxhBspvc6UTkQjNAQvTkeSRboiKHPC2CLOBeR6jENErXZzmxhWOhBlTG53WQKRxkx9DrF99KzW5prBCglRw9b5ZaVD2Z7cnIoSDI=----ATTACHMENT:----MjgyNzAzMDE0MzU5NjQwMyAzMDkzMzYxNTk5MjAxMzU5IDgzMzI0MDEyNDc2MjY2ODg=