pingcrm/app/Http/Middleware/TrustProxies.php

24 lines
592 B
PHP
Raw Normal View History

2019-03-05 18:10:11 -03:00
<?php
namespace App\Http\Middleware;
use Fideloper\Proxy\TrustProxies as Middleware;
2020-07-29 11:37:19 -03:00
use Illuminate\Http\Request;
2019-03-05 18:10:11 -03:00
class TrustProxies extends Middleware
{
/**
* The trusted proxies for this application.
*
* @var array|string|null
2019-03-05 18:10:11 -03:00
*/
2019-12-18 16:43:51 -03:00
protected $proxies = '**';
2019-03-05 18:10:11 -03:00
/**
* The headers that should be used to detect proxies.
*
* @var int
*/
protected $headers = Request::HEADER_X_FORWARDED_FOR | Request::HEADER_X_FORWARDED_HOST | Request::HEADER_X_FORWARDED_PORT | Request::HEADER_X_FORWARDED_PROTO | Request::HEADER_X_FORWARDED_AWS_ELB;
2019-03-05 18:10:11 -03:00
}