Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ISPConfig
ISPConfig 3
Commits
29ef4521
Verified
Commit
29ef4521
authored
Mar 27, 2022
by
Helmo
Browse files
Print that we sent an email
parent
62e64493
Changes
3
Hide whitespace changes
Inline
Side-by-side
interface/web/login/lib/lang/en.lng
View file @
29ef4521
...
...
@@ -35,5 +35,6 @@ $wb['lost_password_function_denied_txt'] = 'This activation link is not valid.';
$wb
[
'otp_code_txt'
]
=
'Two Factor Authentication'
;
$wb
[
'otp_code_desc_txt'
]
=
'Enter the code you got from your authenticator app or via email.'
;
$wb
[
'otp_code_placeholder_txt'
]
=
'OTP code'
;
$wb
[
'otp_code_email_sent_txt'
]
=
'An email was sent to'
;
$wb
[
'otp_code_resend_txt'
]
=
'Request new code'
;
?>
interface/web/login/otp.php
View file @
29ef4521
...
...
@@ -55,6 +55,7 @@ if(count($_POST) >= 1) {
$app
->
auth
->
csrf_token_check
();
}
require
ISPC_ROOT_PATH
.
'/web/login/lib/lang/'
.
$app
->
functions
->
check_language
(
$conf
[
'language'
])
.
'.lng'
;
function
finish_2fa_success
(
$msg
=
''
)
{
global
$app
;
...
...
@@ -162,6 +163,7 @@ if($_SESSION['otp']['type'] == 'email') {
}
else
{
$_SESSION
[
'otp'
][
'sent'
]
++
;
}
$token_sent_message
=
$wb
[
'otp_code_email_sent_txt'
]
.
' '
.
$email_to
;
}
...
...
@@ -183,7 +185,9 @@ if($logo['custom_logo'] != ''){
$app
->
tpl
->
setVar
(
'base64_logo_txt'
,
$base64_logo_txt
);
$app
->
tpl
->
setVar
(
'current_theme'
,
isset
(
$_SESSION
[
's'
][
'theme'
])
?
$_SESSION
[
's'
][
'theme'
]
:
'default'
,
true
);
if
(
!
empty
(
$token_sent_message
))
{
$app
->
tpl
->
setVar
(
'token_sent_message'
,
$token_sent_message
);
}
//* Load templating system and lang file
$app
->
uses
(
'tpl'
);
...
...
@@ -197,7 +201,6 @@ $app->tpl->setVar('_csrf_id',$csrf_token['csrf_id']);
$app
->
tpl
->
setVar
(
'_csrf_key'
,
$csrf_token
[
'csrf_key'
]);
//$app->tpl->setVar('msg', print_r($_SESSION['otp'], 1)); // For DEBUG only.
require
ISPC_ROOT_PATH
.
'/web/login/lib/lang/'
.
$app
->
functions
->
check_language
(
$conf
[
'language'
])
.
'.lng'
;
$app
->
tpl
->
setVar
(
$wb
);
$app
->
tpl_defaults
();
...
...
interface/web/login/templates/otp.htm
View file @
29ef4521
...
...
@@ -14,6 +14,7 @@
<div
class=
"right"
>
<input
class=
"btn btn-default formbutton-default"
type=
"submit"
value=
"{tmpl_var name='login_button_txt'}"
>
</div>
<tmpl_if
name=
"token_sent_message"
>
{tmpl_var name='token_sent_message'}
<br
/></tmpl_if>
<a
href=
"otp.php?action=resend"
>
{tmpl_var name='otp_code_resend_txt'}
</a>
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment