<?php12use Illuminate\Support\Facades\Route;3use Pterodactyl\Http\Controllers\Auth;45/*6|--------------------------------------------------------------------------7| Authentication Routes8|--------------------------------------------------------------------------9|10| Endpoint: /auth11|12*/1314// These routes are defined so that we can continue to reference them programmatically.15// They all route to the same controller function which passes off to React.16Route::get('/login', [Auth\LoginController::class, 'index'])->name('auth.login');17Route::get('/password', [Auth\LoginController::class, 'index'])->name('auth.forgot-password');18Route::get('/password/reset/{token}', [Auth\LoginController::class, 'index'])->name('auth.reset');1920// Apply a throttle to authentication action endpoints, in addition to the21// recaptcha endpoints to slow down manual attack spammers even more. 🤷22//23// @see \Pterodactyl\Providers\RouteServiceProvider24Route::middleware(['throttle:authentication'])->group(function () {25// Login endpoints.26Route::post('/login', [Auth\LoginController::class, 'login'])->middleware('recaptcha');27Route::post('/login/checkpoint', Auth\LoginCheckpointController::class)->name('auth.login-checkpoint');2829// Forgot password route. A post to this endpoint will trigger an30// email to be sent containing a reset token.31Route::post('/password', [Auth\ForgotPasswordController::class, 'sendResetLinkEmail'])32->name('auth.post.forgot-password')33->middleware('recaptcha');34});3536// Password reset routes. This endpoint is hit after going through37// the forgot password routes to acquire a token (or after an account38// is created).39Route::post('/password/reset', Auth\ResetPasswordController::class)->name('auth.reset-password');4041// Remove the guest middleware and apply the authenticated middleware to this endpoint,42// so it cannot be used unless you're already logged in.43Route::post('/logout', [Auth\LoginController::class, 'logout'])44->withoutMiddleware('guest')45->middleware('auth')46->name('auth.logout');4748// Catch any other combinations of routes and pass them off to the React component.49Route::fallback([Auth\LoginController::class, 'index']);505152