mirror of
https://github.com/BookStackApp/BookStack.git
synced 2025-07-30 04:23:11 +03:00
Complete base flow for TOTP setup
- Includes DB storage and code validation. - Extracted TOTP work to its own service file. - Still needs testing to cover this side of things.
This commit is contained in:
@ -47,6 +47,9 @@ return [
|
||||
'favourite_add_notification' => '":name" has been added to your favourites',
|
||||
'favourite_remove_notification' => '":name" has been removed from your favourites',
|
||||
|
||||
// MFA
|
||||
'mfa_setup_method_notification' => 'Multi-factor method successfully configured',
|
||||
|
||||
// Other
|
||||
'commented_on' => 'commented on',
|
||||
'permissions_update' => 'updated permissions',
|
||||
|
@ -98,6 +98,7 @@ return [
|
||||
],
|
||||
'string' => 'The :attribute must be a string.',
|
||||
'timezone' => 'The :attribute must be a valid zone.',
|
||||
'totp' => 'The provided code is not valid or has expired.',
|
||||
'unique' => 'The :attribute has already been taken.',
|
||||
'url' => 'The :attribute format is invalid.',
|
||||
'uploaded' => 'The file could not be uploaded. The server may not accept files of this size.',
|
||||
|
@ -20,7 +20,15 @@
|
||||
</p>
|
||||
</div>
|
||||
<div class="pt-m">
|
||||
<a href="{{ url('/mfa/totp-generate') }}" class="button outline">Setup</a>
|
||||
@if($userMethods->has('totp'))
|
||||
<div class="text-pos">
|
||||
@icon('check-circle')
|
||||
Already configured
|
||||
</div>
|
||||
<a href="{{ url('/mfa/totp-generate') }}" class="button outline small">Reconfigure</a>
|
||||
@else
|
||||
<a href="{{ url('/mfa/totp-generate') }}" class="button outline">Setup</a>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
Reference in New Issue
Block a user