return;
}
+ if (!saml_is_configured()) {
+ echo "Please configure the SAML add-on via the admin interface.";
+ return;
+ }
+
switch ($a->argv[1]) {
case "metadata.xml":
saml_metadata();
function saml_sso_initiate(&$a, &$b)
{
if (!saml_is_configured()) {
+ Logger::warning('SAML SSO tried to trigger, but the SAML addon is not configured yet!');
return;
}
function saml_slo_initiate(&$a, &$b)
{
+ if (!saml_is_configured()) {
+ Logger::warning('SAML SLO tried to trigger, but the SAML addon is not configured yet!');
+ return;
+ }
+
$auth = new \OneLogin\Saml2\Auth(saml_settings());
$sloBuiltUrl = $auth->logout();