Skip to content

Commit

Permalink
LEAF_3975_FY23_part2_update
Browse files Browse the repository at this point in the history
  • Loading branch information
jrodcode committed Nov 8, 2023
1 parent d00e22e commit a9c0604
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions LEAF_Nexus/auth_cookie/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@
{
$redirect = '';

$redirect = $protocol . HTTP_HOST . dirname($_SERVER['PHP_SELF']) . '/../';

if (isset($_GET['r'])) {
$encodedRedirect = $_GET['r'];
$decodedRedirect = base64_decode($encodedRedirect);
Expand All @@ -28,12 +30,12 @@
$parsedRedirect = parse_url($decodedRedirect);

if ($parsedRedirect !== false) {
$redirect = $protocol . HTTP_HOST . $parsedRedirect['path'];
$query = isset($parsedRedirect['query']) ? '?' . $parsedRedirect['query'] : '';
$fragment = isset($parsedRedirect['fragment']) ? '#' . $parsedRedirect['fragment'] : '';
$redirect = $protocol . HTTP_HOST . $parsedRedirect['path'] . $query . $fragment;
}
}
} else {
$redirect = $protocol . HTTP_HOST . dirname($_SERVER['PHP_SELF']) . '/../';
}
}

$user = decryptUser($_COOKIE['REMOTE_USER']);

Expand Down

0 comments on commit a9c0604

Please sign in to comment.