2019-05-20 07:37:41 +02:00
|
|
|
<?php
|
|
|
|
|
2022-03-15 14:47:07 +01:00
|
|
|
// use Illuminate\Support\Facades\Route;
|
|
|
|
use App\Http\Controllers\Auth\WebAuthnManageController;
|
|
|
|
use App\Http\Controllers\Auth\WebAuthnRegisterController;
|
|
|
|
use App\Http\Controllers\Auth\WebAuthnLoginController;
|
|
|
|
use App\Http\Controllers\Auth\WebAuthnDeviceLostController;
|
|
|
|
use App\Http\Controllers\Auth\WebAuthnRecoveryController;
|
|
|
|
|
2019-05-20 07:37:41 +02:00
|
|
|
/*
|
|
|
|
|--------------------------------------------------------------------------
|
|
|
|
| Web Routes
|
|
|
|
|--------------------------------------------------------------------------
|
|
|
|
|
|
|
|
|
| Here is where you can register web routes for your application. These
|
|
|
|
| routes are loaded by the RouteServiceProvider within a group which
|
|
|
|
| contains the "web" middleware group. Now create something great!
|
|
|
|
|
|
|
|
|
*/
|
|
|
|
|
2019-05-28 17:29:15 +02:00
|
|
|
// Route::get('/', function () {
|
|
|
|
// return view('welcome');
|
|
|
|
// });
|
2019-05-20 07:37:41 +02:00
|
|
|
|
2019-12-21 23:23:44 +01:00
|
|
|
// Route::get('twofaccount/{TwoFAccount}', 'TwoFAccountController@show');
|
2021-10-22 14:18:13 +02:00
|
|
|
|
|
|
|
Route::group(['middleware' => 'guest:web'], function () {
|
2022-03-15 14:47:07 +01:00
|
|
|
Route::post('user', 'Auth\RegisterController@register')->name('user.register');
|
|
|
|
Route::post('user/password/lost', 'Auth\ForgotPasswordController@sendResetLinkEmail')->middleware('AvoidResetPassword')->name('user.password.lost');;
|
|
|
|
Route::post('user/password/reset', 'Auth\ResetPasswordController@reset')->name('user.password.reset');
|
|
|
|
Route::post('webauthn/lost', [WebAuthnDeviceLostController::class, 'sendRecoveryEmail'])->name('webauthn.lost');
|
|
|
|
Route::post('webauthn/recover/options', [WebAuthnRecoveryController::class, 'options'])->name('webauthn.recover.options');
|
|
|
|
Route::post('webauthn/recover', [WebAuthnRecoveryController::class, 'recover'])->name('webauthn.recover');
|
2021-10-22 14:18:13 +02:00
|
|
|
});
|
|
|
|
|
|
|
|
Route::group(['middleware' => 'auth:web'], function () {
|
2022-03-15 14:47:07 +01:00
|
|
|
Route::put('user', 'Auth\UserController@update')->name('user.update');
|
|
|
|
Route::patch('user/password', 'Auth\PasswordController@update')->name('user.password.update');
|
2021-10-22 14:18:13 +02:00
|
|
|
Route::get('user/logout', 'Auth\LoginController@logout')->name('user.logout');
|
2022-03-15 14:47:07 +01:00
|
|
|
Route::post('webauthn/register/options', [WebAuthnRegisterController::class, 'options'])->name('webauthn.register.options');
|
|
|
|
Route::post('webauthn/register', [WebAuthnRegisterController::class, 'register'])->name('webauthn.register');
|
|
|
|
Route::get('webauthn/credentials', [WebAuthnManageController::class, 'index'])->name('webauthn.credentials.index');
|
|
|
|
Route::patch('webauthn/credentials/{credential}/name', [WebAuthnManageController::class, 'rename'])->name('webauthn.credentials.rename');
|
|
|
|
Route::delete('webauthn/credentials/{credential}', [WebAuthnManageController::class, 'delete'])->name('webauthn.credentials.delete');
|
|
|
|
});
|
|
|
|
|
|
|
|
Route::group(['middleware' => ['guest:web', 'throttle:10,1']], function () {
|
|
|
|
Route::post('user/login', 'Auth\LoginController@login')->name('user.login');
|
|
|
|
Route::post('webauthn/login/options', [WebAuthnLoginController::class, 'options'])->name('webauthn.login.options');
|
|
|
|
Route::post('webauthn/login', [WebAuthnLoginController::class, 'login'])->name('webauthn.login');
|
2021-10-22 14:18:13 +02:00
|
|
|
});
|
|
|
|
|
2020-03-05 12:56:35 +01:00
|
|
|
Route::get('/{any}', 'SinglePageController@index')->where('any', '.*')->name('landing');
|