diff options
-rw-r--r-- | src/etc/inc/auth.inc | 2 | ||||
-rw-r--r-- | src/etc/inc/authgui.inc | 16 |
2 files changed, 16 insertions, 2 deletions
diff --git a/src/etc/inc/auth.inc b/src/etc/inc/auth.inc index ec76e1d..aa658f3 100644 --- a/src/etc/inc/auth.inc +++ b/src/etc/inc/auth.inc @@ -1815,7 +1815,7 @@ function session_auth() { exit; } else { /* give the user an error message */ - $_SESSION['Login_Error'] = "Username or Password incorrect"; + $_SESSION['Login_Error'] = gettext("Username or Password incorrect"); log_auth("webConfigurator authentication error for '{$_POST['usernamefld']}' from {$_SERVER['REMOTE_ADDR']}"); if (isAjax()) { echo "showajaxmessage('{$_SESSION['Login_Error']}');"; diff --git a/src/etc/inc/authgui.inc b/src/etc/inc/authgui.inc index 934ff41..20d4039 100644 --- a/src/etc/inc/authgui.inc +++ b/src/etc/inc/authgui.inc @@ -34,7 +34,9 @@ if (!session_auth()) { display_login_form(); exit; } + phpsession_begin(); + /* * Once here, the user has authenticated with the web server. * We give them access only to the appropriate pages based on @@ -312,6 +314,7 @@ function display_login_form() { <header> <div id="headerrow"> <div class="row"> + <!-- Header left logo box --> <div class="col-sm-4"> <div id="logodiv" style="text-align:center" class="nowarning"> <svg role="img" aria-labelledby="pfsense-logo" x="0px" y="0px" viewBox="0 0 282.8 84.2" width="240" height="100%"> @@ -333,7 +336,18 @@ function display_login_form() { </svg> </div> </div> - <div class="col-sm-8 nowarning msgbox text-center"> + + <!-- Header center message box --> + <div class="col-sm-4 nowarning msgbox text-center text-danger"> +<?php + if (!empty($_POST['usernamefld'])) { + print("<h4>" . $_SESSION['Login_Error'] . "</h4>"); + } +?> + </div> + + <!-- Header right message box (hostname or msg)--> + <div class="col-sm-4 nowarning msgbox text-center"> <span id="hostspan"> <a><h4><?=$loginbannerstr?></h4></a> </span> |