ILIAS
release_10 Revision v10.1-43-ga1241a92c2f
◀ ilDoc Overview
shib_login.php
Go to the documentation of this file.
1
<?php
2
20
use
ILIAS\AuthShibboleth\LoginPerformer
;
21
22
require_once(
"../vendor/composer/vendor/autoload.php"
);
23
ilContext::init
(
ilContext::CONTEXT_SHIBBOLETH
);
24
ilInitialisation::initILIAS
();
25
global
$DIC
;
26
27
$server
=
$DIC
->http()->request()->getServerParams();
28
29
if
(
30
!isset(
$server
[
'HTTP_SHIB_APPLICATION_ID'
])
31
&& !isset(
$server
[
'Shib-Application-ID'
])
32
&& !isset(
$server
[
'REDIRECT_Shib_Application_ID'
])
33
) {
34
$factory =
$DIC
->ui()->factory();
35
$message_box = $factory->messageBox()->failure(
"The file shib_login.php must be protected by Shibboleth, otherwise you cannot use Shibboleth authentication."
)->withButtons([
36
$factory->button()->standard(
'Open Documentation'
,
'./Services/AuthShibboleth/README.md'
)
37
]);
38
39
$DIC
->ui()->mainTemplate()->setContent(
$DIC
->ui()->renderer()->render($message_box));
40
$DIC
->ui()->mainTemplate()->printToStdout();
41
}
else
{
42
// authentication is done here
43
$login =
new
LoginPerformer
(
44
ilLoggerFactory::getLogger
(
'init'
),
45
$DIC
->ctrl(),
46
$DIC
->ui()->mainTemplate(),
47
$DIC
->language(),
48
$DIC
[
'ilAuthSession'
]
49
);
50
51
$login->
doShibbolethAuthentication
();
52
}
ilLoggerFactory\getLogger
static getLogger(string $a_component_id)
Get component logger.
Definition:
class.ilLoggerFactory.php:90
LoginPerformer
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
ilContext\CONTEXT_SHIBBOLETH
const CONTEXT_SHIBBOLETH
Definition:
class.ilContext.php:45
ILIAS\AuthShibboleth\LoginPerformer
Definition:
LoginPerformer.php:38
ilInitialisation\initILIAS
static initILIAS()
ilias initialisation
Definition:
class.ilInitialisation.php:1153
$DIC
global $DIC
Definition:
shib_login.php:25
ilContext\init
static init(string $a_type)
Init context by type.
Definition:
class.ilContext.php:52
ILIAS\AuthShibboleth\LoginPerformer\doShibbolethAuthentication
doShibbolethAuthentication()
Definition:
LoginPerformer.php:49
$server
$server
Definition:
shib_login.php:27
components
ILIAS
AuthShibboleth
resources
shib_login.php
Generated on Wed Sep 10 2025 15:14:53 for ILIAS by
1.8.13 (using
Doxyfile
)