mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 12:05:37 +00:00
BUGFIX: Prevent infinite loop by visiting page/run
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@58354 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
parent
4478228ff4
commit
ab28c127d0
@ -110,7 +110,8 @@ class Controller extends ViewableData {
|
|||||||
if(!$this->action) $this->action = 'index';
|
if(!$this->action) $this->action = 'index';
|
||||||
|
|
||||||
// Check security on the controller
|
// Check security on the controller
|
||||||
if(!$this->checkAccessAction($this->action)) {
|
// run & init are manually disabled, because they create infinite loops and other dodgy situations
|
||||||
|
if(!$this->checkAccessAction($this->action) || in_array(strtolower($this->action), array('run', 'init'))) {
|
||||||
user_error("Disallowed action: '$this->action' on controller '$this->class'", E_USER_ERROR);
|
user_error("Disallowed action: '$this->action' on controller '$this->class'", E_USER_ERROR);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user