mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
62 lines
1.4 KiB
PHP
62 lines
1.4 KiB
PHP
![]() |
<?php
|
||
|
|
||
|
return [
|
||
|
|
||
|
/*
|
||
|
* A cors profile determines which origins, methods, headers are allowed for
|
||
|
* a given requests. The `DefaultProfile` reads its configuration from this
|
||
|
* config file.
|
||
|
*
|
||
|
* You can easily create your own cors profile.
|
||
|
* More info: https://github.com/spatie/laravel-cors/#creating-your-own-cors-profile
|
||
|
*/
|
||
|
'cors_profile' => App\Http\Profile\CorsApiProfile::class,
|
||
|
|
||
|
/*
|
||
|
* This configuration is used by `DefaultProfile`.
|
||
|
*/
|
||
|
'default_profile' => [
|
||
|
|
||
|
'allow_credentials' => false,
|
||
|
|
||
|
'allow_origins' => [
|
||
|
'*',
|
||
|
],
|
||
|
|
||
|
'allow_methods' => [
|
||
|
'POST',
|
||
|
'GET',
|
||
|
'OPTIONS',
|
||
|
'PUT',
|
||
|
'PATCH',
|
||
|
'DELETE',
|
||
|
],
|
||
|
|
||
|
'allow_headers' => [
|
||
|
'Content-Type',
|
||
|
'X-Auth-Token',
|
||
|
'Origin',
|
||
|
'Authorization',
|
||
|
],
|
||
|
|
||
|
'expose_headers' => [
|
||
|
'Cache-Control',
|
||
|
'Content-Language',
|
||
|
'Content-Type',
|
||
|
'Expires',
|
||
|
'Last-Modified',
|
||
|
'Pragma',
|
||
|
],
|
||
|
|
||
|
'forbidden_response' => [
|
||
|
'message' => 'Forbidden (cors).',
|
||
|
'status' => 403,
|
||
|
],
|
||
|
|
||
|
/*
|
||
|
* Preflight request will respond with value for the max age header.
|
||
|
*/
|
||
|
'max_age' => 60 * 60 * 24,
|
||
|
],
|
||
|
];
|