PHPSandbox

SandboxWhitelistVisitor extends NodeVisitorAbstract
in package

SandboxWhitelister class for PHP Sandboxes.

This class takes parsed AST code and checks it against the passed PHPSandbox instance configuration to autmatically whitelist sandboxed code functions, classes, etc. if the appropriate settings are configured.

Tags
namespace

PHPSandbox

author

Elijah Horton [email protected]

version
3.0

Table of Contents

$sandbox  : PHPSandbox
The PHPSandbox instance to check against
__construct()  : mixed
SandboxWhitelistVisitor class constructor
leaveNode()  : void
Examine the current PhpParser\Node node against the PHPSandbox configuration for whitelisting sandboxed code

Properties

Methods

__construct()

SandboxWhitelistVisitor class constructor

public __construct(PHPSandbox $sandbox) : mixed

This constructor takes a passed PHPSandbox instance to check against for whitelisting sandboxed code.

Parameters
$sandbox : PHPSandbox

The PHPSandbox instance to check against

Return values
mixed

leaveNode()

Examine the current PhpParser\Node node against the PHPSandbox configuration for whitelisting sandboxed code

public leaveNode(Node $node) : void
Parameters
$node : Node

The sandboxed $node to examine

Return values
void

Search results