Sin descripción
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. <?php
  2. namespace App\Http;
  3. use Illuminate\Foundation\Http\Kernel as HttpKernel;
  4. class Kernel extends HttpKernel
  5. {
  6. /**
  7. * The application's global HTTP middleware stack.
  8. *
  9. * These middleware are run during every request to your application.
  10. *
  11. * @var array
  12. */
  13. protected $middleware = [
  14. \App\Http\Middleware\TrustProxies::class,
  15. \Fruitcake\Cors\HandleCors::class,
  16. \App\Http\Middleware\CheckForMaintenanceMode::class,
  17. \Illuminate\Foundation\Http\Middleware\ValidatePostSize::class,
  18. \App\Http\Middleware\TrimStrings::class,
  19. \Illuminate\Foundation\Http\Middleware\ConvertEmptyStringsToNull::class,
  20. ];
  21. /**
  22. * The application's route middleware groups.
  23. *
  24. * @var array
  25. */
  26. protected $middlewareGroups = [
  27. 'web' => [
  28. \App\Http\Middleware\EncryptCookies::class,
  29. \Illuminate\Cookie\Middleware\AddQueuedCookiesToResponse::class,
  30. \Illuminate\Session\Middleware\StartSession::class,
  31. // \Illuminate\Session\Middleware\AuthenticateSession::class,
  32. \Illuminate\View\Middleware\ShareErrorsFromSession::class,
  33. \App\Http\Middleware\VerifyCsrfToken::class,
  34. \Illuminate\Routing\Middleware\SubstituteBindings::class,
  35. \RealRashid\SweetAlert\ToSweetAlert::class,
  36. ],
  37. 'api' => [
  38. 'throttle:60,1',
  39. \Illuminate\Routing\Middleware\SubstituteBindings::class,
  40. ],
  41. ];
  42. /**
  43. * The application's route middleware.
  44. *
  45. * These middleware may be assigned to groups or used individually.
  46. *
  47. * @var array
  48. */
  49. protected $routeMiddleware = [
  50. 'auth' => \App\Http\Middleware\Authenticate::class,
  51. 'auth.basic' => \Illuminate\Auth\Middleware\AuthenticateWithBasicAuth::class,
  52. 'bindings' => \Illuminate\Routing\Middleware\SubstituteBindings::class,
  53. 'cache.headers' => \Illuminate\Http\Middleware\SetCacheHeaders::class,
  54. 'can' => \Illuminate\Auth\Middleware\Authorize::class,
  55. 'guest' => \App\Http\Middleware\RedirectIfAuthenticated::class,
  56. 'password.confirm' => \Illuminate\Auth\Middleware\RequirePassword::class,
  57. 'signed' => \Illuminate\Routing\Middleware\ValidateSignature::class,
  58. 'throttle' => \Illuminate\Routing\Middleware\ThrottleRequests::class,
  59. 'verified' => \Illuminate\Auth\Middleware\EnsureEmailIsVerified::class,
  60. /**auth cek */
  61. 'auth_cek' => \App\Http\Middleware\AuthCheckLogin::class,
  62. /**spatie */
  63. 'role' => \Spatie\Permission\Middlewares\RoleMiddleware::class,
  64. 'permission' => \Spatie\Permission\Middlewares\PermissionMiddleware::class,
  65. 'api_version' => \App\Http\Middleware\APIVersion::class,
  66. ];
  67. }