2015-07-08 03:34:58 -04:00
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace App\Http;
|
|
|
|
|
|
|
|
use Illuminate\Foundation\Http\Kernel as HttpKernel;
|
|
|
|
|
|
|
|
class Kernel extends HttpKernel
|
|
|
|
{
|
|
|
|
/**
|
|
|
|
* The application's global HTTP middleware stack.
|
|
|
|
*
|
2016-01-03 23:55:13 -05:00
|
|
|
* These middleware are run during every request to your application.
|
|
|
|
*
|
2022-05-23 21:01:33 -04:00
|
|
|
* @var array<int, class-string|string>
|
2015-07-08 03:34:58 -04:00
|
|
|
*/
|
|
|
|
protected $middleware = [
|
2021-04-20 17:11:13 -04:00
|
|
|
// \App\Http\Middleware\TrustHosts::class,
|
2019-09-06 01:32:11 -04:00
|
|
|
\App\Http\Middleware\TrustProxies::class,
|
2022-05-23 21:01:33 -04:00
|
|
|
\Illuminate\Http\Middleware\HandleCors::class,
|
2020-12-09 16:00:01 -05:00
|
|
|
\App\Http\Middleware\PreventRequestsDuringMaintenance::class,
|
2017-01-26 19:17:37 -05:00
|
|
|
\Illuminate\Foundation\Http\Middleware\ValidatePostSize::class,
|
|
|
|
\App\Http\Middleware\TrimStrings::class,
|
|
|
|
\Illuminate\Foundation\Http\Middleware\ConvertEmptyStringsToNull::class,
|
2016-01-03 23:55:13 -05:00
|
|
|
];
|
|
|
|
|
|
|
|
/**
|
|
|
|
* The application's route middleware groups.
|
|
|
|
*
|
2022-05-23 21:01:33 -04:00
|
|
|
* @var array<string, array<int, class-string|string>>
|
2016-01-03 23:55:13 -05:00
|
|
|
*/
|
|
|
|
protected $middlewareGroups = [
|
|
|
|
'web' => [
|
|
|
|
\App\Http\Middleware\EncryptCookies::class,
|
|
|
|
\Illuminate\Cookie\Middleware\AddQueuedCookiesToResponse::class,
|
|
|
|
\Illuminate\Session\Middleware\StartSession::class,
|
|
|
|
\Illuminate\View\Middleware\ShareErrorsFromSession::class,
|
|
|
|
\App\Http\Middleware\VerifyCsrfToken::class,
|
2016-08-19 16:38:49 -04:00
|
|
|
\Illuminate\Routing\Middleware\SubstituteBindings::class,
|
2016-01-03 23:55:13 -05:00
|
|
|
],
|
|
|
|
|
|
|
|
'api' => [
|
2022-05-23 21:01:33 -04:00
|
|
|
// \Laravel\Sanctum\Http\Middleware\EnsureFrontendRequestsAreStateful::class,
|
2023-03-13 17:33:19 -04:00
|
|
|
\Illuminate\Routing\Middleware\ThrottleRequests::class.':api',
|
2020-02-25 16:05:35 -05:00
|
|
|
\Illuminate\Routing\Middleware\SubstituteBindings::class,
|
2016-01-03 23:55:13 -05:00
|
|
|
],
|
2015-07-08 03:34:58 -04:00
|
|
|
];
|
|
|
|
|
|
|
|
/**
|
2023-03-13 17:33:19 -04:00
|
|
|
* The application's middleware aliases.
|
2015-07-08 03:34:58 -04:00
|
|
|
*
|
2023-05-05 15:31:58 -04:00
|
|
|
* Aliases may be used instead of class names to conveniently assign middleware to routes and groups.
|
2016-01-03 23:55:13 -05:00
|
|
|
*
|
2022-05-23 21:01:33 -04:00
|
|
|
* @var array<string, class-string|string>
|
2015-07-08 03:34:58 -04:00
|
|
|
*/
|
2023-03-13 17:33:19 -04:00
|
|
|
protected $middlewareAliases = [
|
2018-11-02 18:11:14 -04:00
|
|
|
'auth' => \App\Http\Middleware\Authenticate::class,
|
2015-07-08 03:34:58 -04:00
|
|
|
'auth.basic' => \Illuminate\Auth\Middleware\AuthenticateWithBasicAuth::class,
|
2022-05-23 21:01:33 -04:00
|
|
|
'auth.session' => \Illuminate\Session\Middleware\AuthenticateSession::class,
|
2018-03-05 18:45:02 -05:00
|
|
|
'cache.headers' => \Illuminate\Http\Middleware\SetCacheHeaders::class,
|
2016-08-19 16:38:49 -04:00
|
|
|
'can' => \Illuminate\Auth\Middleware\Authorize::class,
|
|
|
|
'guest' => \App\Http\Middleware\RedirectIfAuthenticated::class,
|
2019-10-31 17:24:53 -04:00
|
|
|
'password.confirm' => \Illuminate\Auth\Middleware\RequirePassword::class,
|
2022-10-11 18:14:02 -04:00
|
|
|
'signed' => \App\Http\Middleware\ValidateSignature::class,
|
2016-08-19 16:38:49 -04:00
|
|
|
'throttle' => \Illuminate\Routing\Middleware\ThrottleRequests::class,
|
2018-11-02 18:11:14 -04:00
|
|
|
'verified' => \Illuminate\Auth\Middleware\EnsureEmailIsVerified::class,
|
|
|
|
];
|
2015-07-08 03:34:58 -04:00
|
|
|
}
|