36 $obj =
new self($httpState, $cookieFactory);
37 $obj->handleRequest();
47 $this->
http = $httpState;
55 $queries = $this->
http->request()->getQueryParams();
70 if ($this->wac->check()) {
76 switch (
$e->getCode()) {
89 $this->handleErrors(
$e);
99 protected function deny(): void
101 if (!$this->wac->isChecked()) {
110 $ilFileDelivery =
new Delivery(
'./Services/WebAccessChecker/templates/images/access_denied.png', $this->
http);
111 $ilFileDelivery->setDisposition($this->wac->getDisposition());
112 $ilFileDelivery->deliver();
118 $ilFileDelivery =
new Delivery(
'./Services/WebAccessChecker/templates/images/access_denied.mp4', $this->
http);
119 $ilFileDelivery->setDisposition($this->wac->getDisposition());
120 $ilFileDelivery->stream();
142 if ($this->wac->getPathObject()->isImage()) {
145 if ($this->wac->getPathObject()->isVideo()) {
149 $this->wac->initILIAS();
165 $stream->write(
$e->getMessage());
176 if (!$this->wac->isChecked()) {
180 $ilFileDelivery =
new Delivery($this->wac->getPathObject()->getCleanURLdecodedPath(), $this->http);
181 $ilFileDelivery->setCache(
true);
182 $ilFileDelivery->setDisposition($this->wac->getDisposition());
183 if ($this->wac->getPathObject()->isStreamable()) {
184 $ilFileDelivery->stream();
186 $ilFileDelivery->deliver();
static handleErrorReporting()
Set error reporting level.
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
const NO_CHECKING_INSTANCE
const INITIALISATION_FAILED
const ACCESS_DENIED_NO_LOGIN
const ACCESS_WITHOUT_CHECK
const ACCESS_DENIED_NO_PUB
Class ilWebAccessCheckerDelivery.
handleNotFoundError(ilWACException $e)
static run(Services $httpState, CookieFactory $cookieFactory)
handleAccessErrors(ilWACException $e)
__construct(Services $httpState, CookieFactory $cookieFactory)
ilWebAccessCheckerDelivery constructor.
Class ilWebAccessChecker.
static http()
Fetches the global http state from ILIAS.