Skip to content

Commit

Permalink
Template: prevents unserialization for security reasons
Browse files Browse the repository at this point in the history
  • Loading branch information
dg committed Mar 18, 2020
1 parent 8aa7888 commit 8e5fa7e
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/Bridges/ApplicationLatte/Template.php
Expand Up @@ -237,4 +237,13 @@ public function __unset($name)
{
unset($this->params[$name]);
}


/**
* Prevents unserialization.
*/
final public function __wakeup()
{
throw new Nette\NotImplementedException('Object unserialization is not supported by class ' . static::class);
}
}

0 comments on commit 8e5fa7e

Please sign in to comment.