mirror of
https://github.com/Icinga/icingaweb2.git
synced 2025-07-21 21:04:25 +02:00
Avoid to set an empty redirect url parameter when accessing icinga web 2
This commit is contained in:
parent
d02c078e4a
commit
d882ea11b4
@ -315,13 +315,18 @@ class ActionController extends Zend_Controller_Action
|
||||
if ($redirect !== null) {
|
||||
$login->setParam('redirect', '__SELF__');
|
||||
}
|
||||
|
||||
$this->_response->setHttpResponseCode(403);
|
||||
} elseif ($redirect !== null) {
|
||||
if (! $redirect instanceof Url) {
|
||||
$redirect = Url::fromPath($redirect);
|
||||
}
|
||||
$login->setParam('redirect', $redirect->getRelativeUrl());
|
||||
|
||||
if (($relativeUrl = $redirect->getRelativeUrl())) {
|
||||
$login->setParam('redirect', $relativeUrl);
|
||||
}
|
||||
}
|
||||
|
||||
$this->rerenderLayout()->redirectNow($login);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user