Fix and complete reverse-proxy support & Adjust front-end views

This commit is contained in:
Bubka
2022-03-24 14:58:30 +01:00
parent 911e18c9c4
commit 725c012042
37 changed files with 455 additions and 151 deletions

View File

@@ -5,6 +5,7 @@ namespace App\Http\Controllers\Auth;
use App\Http\Controllers\Controller;
use App\Providers\RouteServiceProvider;
use DarkGhostHunter\Larapass\Http\ConfirmsWebAuthn;
use App\Exceptions\UnsupportedWithReverseProxyException;
class WebAuthnConfirmController extends Controller
{
@@ -35,7 +36,10 @@ class WebAuthnConfirmController extends Controller
*/
public function __construct()
{
$this->middleware('auth');
$this->middleware('throttle:10,1')->only('options', 'confirm');
$authGuard = config('auth.defaults.guard');
if ($authGuard === 'reverse-proxy-guard') {
throw new UnsupportedWithReverseProxyException();
}
}
}