OIDC test - test jumbojett oidc round two change root paths

This commit is contained in:
matt committed 2026-10-28 21:56:05 -07:00
1 parent 4b7abac7ca
commit 07d3895eb5
6 files changed
+6 -6

No files matched your search

+23
View File
@@ -0,0 +1,23 @@
<?php
session_start();
$config = require __DIR__ . '/../config.php';
if (!isset($_SESSION['authenticated'])) {
// User not logged in – show a login button
echo '<h1>Welcome to the demo</h1>';
echo '<p><a href="auth.php">Login with Authelia SSO</a></p>';
exit;
}
// The user is logged in – display the attributes
$name = $_SESSION['name'] ?? 'unknown';
$email = $_SESSION['email'] ?? 'unknown';
$groups = $_SESSION['groups'] ?? [];
echo '<h1>Logged in as ' . htmlspecialchars($name) . '</h1>';
echo '<ul>';
echo '<li><strong>Email:</strong> ' . htmlspecialchars($email) . '</li>';
echo '<li><strong>Groups:</strong> ' . htmlspecialchars(implode(', ', $groups)) . '</li>';
echo '</ul>';
echo '<p><a href="logout.php">Logout</a></p>';