anchor.diff:          %>
           <!-- ;jsessionid=<%=request.getSession().getId()%> -->
           <% if (maintenanceMode) { %>
  -          <div class="maintenanceModeMessage">
  -            <div class="warnMessage">
  -              <fmt:message bundle="${messages}" key="label.maintenancemode.active" /><br/>
  -              <fmt:message bundle="${messages}" key="label.maintenancemode.adminLoginOnly" />
  -            </div>
  -            <div class="infoMessage">
  -              <fmt:message bundle="${messages}" key="label.maintenancemode.message" /> : <br/>
  -            </div>
  -          </div>
  +        <div class="maintenanceModeMessage">
  +          <div class="warnMessage">
  +            <fmt:message bundle="${messages}" key="label.maintenancemode.active"/><br/>
  +            <fmt:message bundle="${messages}" key="label.maintenancemode.adminLoginOnly"/>
  +          </div>
  +          <div class="infoMessage">
  +            <fmt:message bundle="${messages}" key="label.maintenancemode.message"/> : <br/>
  +          </div>
  +        </div>
           <%} %>
           <c:if test="${param.nxtimeout}">
             <div class="feedbackMessage">
  -            <fmt:message bundle="${messages}" key="label.login.timeout" />
  +            <fmt:message bundle="${messages}" key="label.login.timeout"/>
             </div>
           </c:if>
           <c:if test="${param.connectionFailed}">
             <div class="feedbackMessage errorMessage">
  -           <fmt:message bundle="${messages}" key="label.login.connectionFailed" />
  +            <fmt:message bundle="${messages}" key="label.login.connectionFailed"/>
             </div>
           </c:if>
           <c:if test="${param.loginFailed == 'true' and param.connectionFailed != 'true'}">
  
positive.code: <!DOCTYPE html>
  <!-- Nuxeo Enterprise Platform -->
  <%@ page contentType="text/html; charset=UTF-8"%>
  <%@ page language="java"%>
  <%@ page import="java.util.List"%>
  <%@ page import="java.util.Locale"%>
  <%@ page import="org.apache.commons.lang3.StringUtils"%>
  <%@ page import="org.apache.commons.lang3.StringEscapeUtils"%>
  <%@ page import="org.joda.time.DateTime"%>
  <%@ page import="org.nuxeo.ecm.core.api.repository.RepositoryManager"%>
  <%@ page import="org.nuxeo.ecm.platform.ui.web.auth.LoginScreenHelper"%>
  <%@ page import="org.nuxeo.ecm.platform.web.common.MobileBannerHelper"%>
  <%@ page import="org.nuxeo.ecm.platform.ui.web.auth.NXAuthConstants"%>
  <%@ page import="org.nuxeo.ecm.platform.ui.web.auth.service.LoginProviderLink"%>
  <%@ page import="org.nuxeo.ecm.platform.ui.web.auth.service.LoginScreenConfig"%>
  <%@ page import="org.nuxeo.ecm.platform.web.common.admin.AdminStatusHelper"%>
  <%@ page import="org.nuxeo.common.Environment"%>
  <%@ page import="org.nuxeo.runtime.api.Framework"%>
  <%@ page import="org.nuxeo.ecm.platform.ui.web.auth.service.LoginVideo" %>
  <%@ page import="org.nuxeo.ecm.platform.web.common.locale.LocaleProvider"%>
  <%@ page import="org.nuxeo.ecm.platform.web.common.vh.VirtualHostHelper" %>
  <%@ page import="ca.firstvoices.security.lockout.LockoutUserManager" %>
  <%@ page import="org.nuxeo.ecm.platform.usermanager.UserManager" %>
  
negative.code: 
  <%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
  <%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>
  <%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn" %>
  <%
    String productName = Framework.getProperty(Environment.PRODUCT_NAME);
    String productVersion = Framework.getProperty(Environment.PRODUCT_VERSION);
    String testerName = Framework.getProperty("org.nuxeo.ecm.tester.name");
    boolean isTesting = "Nuxeo-Selenium-Tester".equals(testerName);
    String context = request.getContextPath();
    String fvContext = Framework.getProperty("fv.contextPath");
  
    String NUXEO_URL = VirtualHostHelper.getBaseURL(request);
  
    HttpSession httpSession = request.getSession(false);
    if (httpSession != null && httpSession.getAttribute(NXAuthConstants.USERIDENT_KEY) != null) {
      response.sendRedirect(NUXEO_URL + "/" + LoginScreenHelper.getStartupPagePath());
    }
  
    Locale locale = request.getLocale();
    String selectedLanguage = locale.getLanguage();
    selectedLanguage = Framework.getLocalService(LocaleProvider.class).getLocaleWithDefault(selectedLanguage).getLanguage();
  
    boolean maintenanceMode = AdminStatusHelper.isInstanceInMaintenanceMode();
    String maintenanceMessage = AdminStatusHelper.getMaintenanceMessage();
  
    LoginScreenConfig screenConfig = LoginScreenHelper.getConfig();
    List<LoginProviderLink> providers = screenConfig.getProviders();
    boolean useExternalProviders = providers != null && providers.size() > 0;
  
  // fetch Login Screen config and manage default
    boolean showNews = screenConfig.getDisplayNews();
    String iframeUrl = screenConfig.getNewsIframeUrl();
  
    String backgroundPath = LoginScreenHelper.getValueWithDefault(screenConfig.getBackgroundImage(), context + "/img/login_bg.jpg");
    String bodyBackgroundStyle = LoginScreenHelper.getValueWithDefault(screenConfig.getBodyBackgroundStyle(), "url('" + backgroundPath + "') no-repeat center center fixed #006ead");
    String loginButtonBackgroundColor = LoginScreenHelper.getValueWithDefault(screenConfig.getLoginButtonBackgroundColor(), "#0066ff");
    String loginBoxBackgroundStyle = LoginScreenHelper.getValueWithDefault(screenConfig.getLoginBoxBackgroundStyle(), "none repeat scroll 0 0");
    String footerStyle = LoginScreenHelper.getValueWithDefault(screenConfig.getFooterStyle(), "");
    boolean disableBackgroundSizeCover = Boolean.TRUE.equals(screenConfig.getDisableBackgroundSizeCover());
    String fieldAutocomplete = screenConfig.getFieldAutocomplete() ? "on" : "off";
  
    String logoWidth = LoginScreenHelper.getValueWithDefault(screenConfig.getLogoWidth(), "113");
    String logoHeight = LoginScreenHelper.getValueWithDefault(screenConfig.getLogoHeight(), "20");
    String logoAlt = LoginScreenHelper.getValueWithDefault(screenConfig.getLogoAlt(), "Nuxeo");
    String logoUrl = LoginScreenHelper.getValueWithDefault(screenConfig.getLogoUrl(), context + "/img/login_logo.png");
    String currentYear = new DateTime().toString("Y");
  
    boolean hasVideos = screenConfig.hasVideos();
    String muted = screenConfig.getVideoMuted() ? "muted " : "";
    String loop = screenConfig.getVideoLoop() ? "loop " : "";
    boolean displayMobileBanner = !"false".equals(request.getParameter("displayMobileBanner"));
  
    String urlWithContext = fvContext.equals("") ? "" : (NUXEO_URL + fvContext);
  
    UserManager userManager = Framework.getService(UserManager.class);
  
    boolean isUserLocked = false;
  
    if (userManager != null) {
      String username = request.getParameter("user_name");
  
      if (username != null) {
        try {
          Method lockedMethod = userManager.getClass().getMethod("isUserLocked", String.class);
          isUserLocked = (boolean) lockedMethod.invoke(userManager, username);
        } catch (NoSuchMethodException | InvocationTargetException | IllegalAccessException e) {
          // we don't really care
        }
      }
  
    }
    request.setAttribute("isUserLocked", isUserLocked ? "true" : "false");
  
  %>
  
  <html>
  <%
    if (selectedLanguage != null) { %>
  <fmt:setLocale value="<%= selectedLanguage %>"/>
  <%
    }%>
  <fmt:setBundle basename="messages" var="messages"/>
  
  <head>
    <title><%=productName%>
    </title>
    <link rel="icon" type="image/png" href="<%=context%>/icons/favicon.png"/>
    <link rel="shortcut icon" type="image/x-icon" href="<%=context%>/icons/favicon.ico"/>
    <script type="text/javascript" src="<%=context%>/scripts/detect_timezone.js"></script>
    <script type="text/javascript" src="<%=context%>/scripts/nxtimezone.js"></script>
    <% if (displayMobileBanner) { %>
    <script type="text/javascript" src="<%=context%>/scripts/mobile-banner.js"></script>
    <% } %>
    <script type="text/javascript">
      nxtz.resetTimeZoneCookieIfNotSet();
    </script>
  
    <meta name="viewport" content="width=device-width, initial-scale=1">
  
    <style type='text/css'>
      body {
        margin: 0;
        font-family: Arial, sans-serif;
        color: #101010;
        line-height: 24px;
      }
  
      h1 {
        font-weight: 900;
        font-size: 24px;
      }
  
      .container-box {
        border: 1px #010101 solid;
        width: 100%;
        max-width: 650px;
        margin: 15px auto;
        text-align: center;
      }
  
      form.fv-form input {
        border: 1px solid #a9a9a9;
        font-size: 18px;
        margin: 5px;
        padding: 2px;
        width: 300px;
      }
  
      .feedbackMessage {
        text-align: center;
        width: 100%;
      }
  
      .login_button {
        text-transform: uppercase;
        background: #b6020e;
        border-radius: 5px;
        padding: 5px;
        color: #fff;
      }
  
      .buttonLink {
        background-color: #4e4e4e;
        color: #fff;
        padding: 8px 15px;
        border-radius: 10px;
        margin-right: 15px;
        text-decoration: none;
      }
  
      .buttonLink:hover {
        background-color: #4c7784;
      }
    </style>
  
    <script type="text/javascript">
      function validateUserNameForCommonIssues() {
        var usernameFieldInputValue = document.getElementById("username").value;
        var hintMessageBox = document.getElementById("hintMessageJS");
  
  
        // Very simple check for missing @ sign
        if (usernameFieldInputValue != "" && usernameFieldInputValue.indexOf("@") == -1) {
          hintMessageBox.innerHTML = "Remember: In most cases your username will be your email...";
        } else {
          hintMessageBox.innerHTML = "";
        }
  
        return true;
  
      }
    </script>
  </head>
  
  <body>
  