From c3eacf9c5f49f8983dc6bbf2030aef8478a6eab1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cau=C3=AA=20Faleiros?= Date: Tue, 3 Feb 2026 15:14:16 -0300 Subject: [PATCH] fix: csfr error on login --- app/Http/Kernel.php | 2 +- cookies.txt | 6 ++++++ routes/tenant.php | 1 - routes/web.php | 2 +- storage/test_write | 0 5 files changed, 8 insertions(+), 3 deletions(-) create mode 100644 cookies.txt mode change 100644 => 100755 storage/test_write diff --git a/app/Http/Kernel.php b/app/Http/Kernel.php index 7f9cfea..fe8013b 100644 --- a/app/Http/Kernel.php +++ b/app/Http/Kernel.php @@ -30,13 +30,13 @@ class Kernel extends HttpKernel */ protected $middlewareGroups = [ 'web' => [ + \App\Http\Middleware\UniversalTenancy::class, \App\Http\Middleware\EncryptCookies::class, \Illuminate\Cookie\Middleware\AddQueuedCookiesToResponse::class, \Illuminate\Session\Middleware\StartSession::class, // \Illuminate\Session\Middleware\AuthenticateSession::class, \Illuminate\View\Middleware\ShareErrorsFromSession::class, \App\Http\Middleware\VerifyCsrfToken::class, - \App\Http\Middleware\UniversalTenancy::class, \Illuminate\Routing\Middleware\SubstituteBindings::class, ], diff --git a/cookies.txt b/cookies.txt new file mode 100644 index 0000000..b71381a --- /dev/null +++ b/cookies.txt @@ -0,0 +1,6 @@ +# Netscape HTTP Cookie File +# https://curl.se/docs/http-cookies.html +# This file was generated by libcurl! Edit at your own risk. + +#HttpOnly_localhost FALSE / FALSE 1770147603 growup_session eyJpdiI6Ill5ZkU3Rlg4cC9HMzNxR204K0JhcUE9PSIsInZhbHVlIjoiWEIvQmhZeFEzNWpDaTNRdXBRbW45Nm44bk1UMC9JZUVhY3RneS9hWm5VSGV3RnhFR0ttVENmeWt0TVQxZGFOYURPc0JYeitKdi9DbUVEdzltcFJnYkk0T2RTektNdnJmdVJwUUdZbFNENGUwVmYyS3ZYTUJNdE9zMHZSdUk0bjYiLCJtYWMiOiI5ODAxYzU4Y2U4NmFmODkwZWQyMDMxZThmZGNjZDk4MThmOTQwNTdjMTA2ODgyZDU4N2E1MzNhNmViMmRhMWE5IiwidGFnIjoiIn0%3D +localhost FALSE / FALSE 1770147603 XSRF-TOKEN eyJpdiI6IkdiVzdmTmNNYmNNSjJCbkQ4blc0cFE9PSIsInZhbHVlIjoidVJnbGxsMVNDdmNGc0UyTzIyOTJ1TS8ydEUyS3o5NFNwRVovS0t1a0puUm5keFB1eWFsTVU5YTM0NitXMkZnc1F3cUlraTdNSitpelRHMEFPcFUxWlpWOWdSemhzZHF4ODZyVmVmaW9yYUJOd2Y0cjdFWml1cStYS1N1bVE5OEgiLCJtYWMiOiI4MjgzMjFlODViMGIyNzNjYjQ0NGNkNzU1MzgyYTMxOThkNDk0MjNhNjU4ODFkNDc5ZTI4YjcwYjdlMDQ2ZWZkIiwidGFnIjoiIn0%3D diff --git a/routes/tenant.php b/routes/tenant.php index b3982be..6c95db1 100644 --- a/routes/tenant.php +++ b/routes/tenant.php @@ -9,7 +9,6 @@ use App\Http\Middleware\UniversalTenancy; Route::middleware([ 'web', - UniversalTenancy::class, ])->group(function () { // Root route handles both Central and Tenant contexts diff --git a/routes/web.php b/routes/web.php index f69ce1f..48b84db 100644 --- a/routes/web.php +++ b/routes/web.php @@ -20,7 +20,7 @@ Route::get('/', function () { }); // Super Admin Routes -Route::group(['prefix' => 'super-admin', 'as' => 'super-admin.', 'middleware' => ['web']], function () { +Route::group(['prefix' => 'super-admin', 'as' => 'super-admin.'], function () { // Session Route::get('login', [SessionController::class, 'create'])->name('session.create'); Route::post('login', [SessionController::class, 'store'])->name('session.store'); diff --git a/storage/test_write b/storage/test_write old mode 100644 new mode 100755