diff --git a/bootstrap/app.php b/bootstrap/app.php index 696386de..c4fd8aff 100644 --- a/bootstrap/app.php +++ b/bootstrap/app.php @@ -4,6 +4,7 @@ use Illuminate\Foundation\Application; use Illuminate\Foundation\Configuration\Exceptions; use Illuminate\Foundation\Configuration\Middleware; +use Symfony\Component\HttpFoundation\Request; return Application::configure(basePath: dirname(__DIR__)) ->withRouting( @@ -28,6 +29,10 @@ 'solder_mods' => \App\Http\Middleware\SolderMods::class, 'solder_users' => \App\Http\Middleware\SolderUsers::class, ]); + + $middleware->trustProxies(at: [ + '10.0.0.0/8', + ], headers: Request::HEADER_X_FORWARDED_FOR | Request::HEADER_X_FORWARDED_PROTO); }) ->withExceptions(function (Exceptions $exceptions) { //