Adaptive Authentication Login Error message

Russell Park
Mega Guru

I am working on implementing Adaptive Authentication and have it working the way we want based on IP and Role based access.  I would like to change the message users receive if they do not match the allowed criteria.  Currently the message show "User Name and Password invalid".  How or where can i create a custom message to replace the current one.

Thank you!

8 REPLIES 8

Filipe Cruz
Kilo Sage
Kilo Sage

Hi Russell,

Can you check the UI message with key "login_invalid"?

https:your_instance.service-now.com/nav_to.do?uri=sys_ui_message.do?sys_id=caead3ffc0a80164010696930...


Hope this helps!

Please, don't forget to mark my answer as correct if it solves your issue or mark it as helpful if it is relevant for you!

Best Regards,

Filipe Cruz

I checked that and that message displays also when the username/pw is incorrect.  I was trying to have a different message to state something like "User Unauthorized" when they dont match one of the criterias.  I still would like the invalid username/pw when they have access and just type pw incorrect.

 

Hi Russell,

try to check the installation exist "Login":

https://your_instance.service-now.com/nav_to.do?uri=sys_installation_exit.do?sys_id=7cfa46450a0a0aa9...

 

There you can check the code and see if there is a specific place to place that custom message you need.

Please, don't forget to mark my answer as correct if it solves your issue or mark it as helpful if it is relevant for you!

Best Regards,

Filipe Cruz

I see the "Login" script as shown below but I'm not sure where to even begin with adding an else if to capture failed logins due to not meeting the Advanced Authentication policies.  I assume I would need another sys_ui_message specifically for that type of failed login attempt but how do i differentiate that in the script?

 

  loginFailed: function() {
        if (GlideController.exists("glide.ldap.error.connection")) {
            var ldapConnError = GlideController.getGlobal("glide.ldap.error.connection");
            if (GlideStringUtil.notNil(ldapConnError))
                GlideSession.get().addErrorMessage(ldapConnError);
        } else if (request.getSession().getAttribute("glide.authenticate.local.login.method") == "certificate") {
            var message = GlideSysMessage.format("cert_login_invalid");
            GlideSession.get().addErrorMessage(message);
        } else {
            var message = GlideSysMessage.format("login_invalid");
            GlideSession.get().addErrorMessage(message);
        }

    }

 

Thanks for helping out with this.

 

Russell