shlink/module/Rest/config/auth.config.php

37 lines
843 B
PHP
Raw Normal View History

<?php
2019-10-05 18:26:10 +03:00
declare(strict_types=1);
namespace Shlinkio\Shlink\Rest;
2020-01-01 23:11:53 +03:00
use Laminas\ServiceManager\AbstractFactory\ConfigAbstractFactory;
return [
'auth' => [
'routes_whitelist' => [
2018-12-23 12:18:38 +03:00
Action\HealthAction::class,
ConfigProvider::UNVERSIONED_HEALTH_ENDPOINT_NAME,
],
2021-01-21 21:26:19 +03:00
'routes_with_query_api_key' => [
Action\ShortUrl\SingleStepCreateShortUrlAction::class,
],
],
'dependencies' => [
'factories' => [
Middleware\AuthenticationMiddleware::class => ConfigAbstractFactory::class,
],
],
ConfigAbstractFactory::class => [
2021-01-21 21:26:19 +03:00
Middleware\AuthenticationMiddleware::class => [
Service\ApiKeyService::class,
'config.auth.routes_whitelist',
'config.auth.routes_with_query_api_key',
],
],
];