Skip to content

Commit

Permalink
changed the redirect to httpUtils->redirectTrustedURL as requested by @…
Browse files Browse the repository at this point in the history
  • Loading branch information
doedje committed Mar 19, 2024
1 parent 249c27e commit 47a0a80
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/Controller/SFO.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
use SimpleSAML\Metadata\MetaDataStorageHandler;
use SimpleSAML\Module;
use SimpleSAML\Module\saml\Message;
use SimpleSAML\Utils;
use SimpleSAML\XHTML\Template;

use function sprintf;
Expand Down Expand Up @@ -117,8 +118,8 @@ public function acs(): Template
$e->getSubStatus() == 'urn:oasis:names:tc:SAML:2.0:status:NoAuthnContext') {
Logger::debug('SFO - token of demanded LOA is not available, redirecting to selfserviceUrl.');

header('Location: '. $selfserviceUrl);
exit();
$httpUtils = new Utils\HTTP();
return $httpUtils->redirectTrustedURL($selfserviceUrl);

} else {
Logger::debug('SFO - status response received, showing error page.');
Expand Down

0 comments on commit 47a0a80

Please sign in to comment.