Dan Martinez
Tera Expert

Overview

"Adaptive Authentication" is a plugin that was released in Quebec but has stayed relatively hidden for the majority of developers.

Although ServiceNow Out-of-the-Box allows to whitelist/blacklist IP Addresses to ensure only users from within certain locations can log in in the instance, it does not provide an easy way to allow or block people belonging to specific groups or having specific roles from accessing the instance. For this reason, the "Adaptive Authentication" plugin becomes handy, since it allows not only to check these three aspects (IP, Roles, Groups) but also allows them to be mixed in complex conditions.

 

find_real_file.png

 

That doesn't mean an organisation has to rely on all of those three criteria, but it may become very useful to define specific criteria that couldn't be defined without the plugin.

A classic use case where this becomes quite useful is when an organisation plans their go-live. Before going live the Service Desk, Knowledge Managers, Change Manager, etc... need to access the instance to ensure the Knowledge Articles are available and up to date, the required Standard Changes are available, or even last checks can be performed, amongst other tasks. Without this plugin the easier way would be disabling all accounts coming from AD enabling only those that need to access. This is a potential solution, but it means either AD synchronisations must be stopped or a script needs to run just after them to keep disabling the accounts until the go-live happens. Specially for large organisations this may be tricky to achieve and may be risky if there are good reasons not to access before the go live.

This plugin allows to run a series of policies that check the defined filter criteria before and after a user logs in to ensure they are allowed.

Policies

The plugin comes with a series of "Policies" that are enabled plus two disabled ones that can be enabled if required. Policies are executed by the system if they are enabled and the property called "glide.authenticate.auth.policy.enabled" is set to true. This property can be found in "Adaptive Authentication > Authentication Policies > Properties". Bear in mind this property comes disabled OOB.

find_real_file.png

Once enabled, they will validate the conditions specified either prior to the user logging in (when the page is loaded) or when the user successfully logged in. Obviously, having a role or belonging to a group is something that can only be checked after logging in, but checking the IP Address a user is coming from can -and should- be done before.

find_real_file.png

Filter Criteria

These criteria allow to define the elements we will be paying attention to. However, we haven't yet defined if these are the whitelisted or blacklisted, that will be specified later. These can be based on IP, Role or Group of the user accessing.

Role Filter Criteria

For instance, some role filter criteria we could be interested in creating could be "Admin", "External", "Internal" or "Fulfiller":

find_real_file.png

This would allow us to include the criteria in the policies to -for instance- check that only "Internal" people can access, only "Fulfillers" can access or only "Admin" can access. These criteria require a condition inside where we can select the roles that are behind each of them:

find_real_file.png

The condition will be checked when the related Policy is, and it will return "true" or "false" depending on the user who logged in. We can then link the criteria against the Policy we want, but we will see that in the next section.

Group Filter Criteria

Another kind of Filter Criteria that we can define is based on Groups. For instance a criteria that defines both the "Service Desk & Customer Service Management" teams, or another criteria for the "Service Support" team separately.

find_real_file.png

Let's have a look at how the SD& CSM would look like. We are selecting two groups, but we could select as many as we need:

 find_real_file.png

Linking Policies to Filter Criteria

Now that we have defined the required Criteria and we know about the OOB Policies we can use, let's see an example of the "Deny Access Policy" where we will be defining which users must be denied access. It is paramount to select the right inputs, where we define the parameters we will be using in our criteria. In this case both the "Fulfiller" and "Admin" criteria are used.

find_real_file.png

Then, from the "Policy Conditions" tab we can create a new record. That record could look like the one below:

find_real_file.png

 

It must be remembered that the Filter Criteria will return either "true" or "false". Therefore in the Policy Condition we must define "Fulfiller IS false AND Admin IS false" if we want to deny access to anyone not having those roles.

In this case, as we are in the "Deny Access Policy" Policy we are defining a blacklist, but we could go to the "Allow Access Policy" if we wanted to define a whitelist after the user has logged in, to the "Allow access pre-auth policy" if we wanted to define a whitelist before the user has logged in or to the "Global Blocking Policy" if we wanted to block not only interactive sessions -other policies are triggered with interactive sessions only- but also any non-interactive one.

Bear in mind an interactive session is triggered by a real user and a non-interactive one by an automated event (integration, email,...)

Finally, there are two disabled (OOB) policies for Step-Up MFA and Step-Down MFA in case these cases were required, although if your organisation uses SSO they are not useful. If you want to know more about how to configure MFA within the Adaptive Authentication plugin check out this article created by @Maik Skoddow.

Results

When a user tries to log in but they have been blocked by a Policy they will receive an error message. Unfortunately, in case the user is local, they will get a message saying their username login or password are wrong. That can be misleading but it will ensure the user doesn't get through.

find_real_file.png

From a property perspective it allows to return a 403 or 404 error to external platforms where 403 is the default HTTP Status code. Additionally, it allows to return a specific error message, which OOB is "Access Denied"

find_real_file.png

If this blog article was useful to you, please click on “Helpful”.

find_real_file.png

Other blog articles created by me:

8 Comments
Maik Skoddow
Tera Patron
Tera Patron

Great article!


I have linked it in my article Bypass Multi-factor Authentication (MFA) based on IP Addresses

Dan Martinez
Tera Expert

Thanks Maik. I have linked my blog post to your article in case they want to configure the MFA

niranjansamanu
ServiceNow Employee
ServiceNow Employee

Starting San Deigo release  Servicenow support MFA along with SSO login .  San Diego Documentation link 

Nestor Paredes
Tera Contributor

Great article, Daniel.

 

I have an scenario where access to the instance should be restricted, while allowing access by using the mobile app, a Self service portal or an embedded Virtual agent chat bot; IP Address Access control is a bit too restrictive for this.

 

 

yonu1
Tera Contributor

How to bypass Integration local user created in ServiceNow from Adaptive Authentication policies which is using IP filter as the policy input.

Any help is appreciated.

Surya47
Tera Contributor

@Dan Martinez , I have multi-tenant instance which is segregated on the account level, I have implemented this adaptive authentication for only one account.  if I want to use this for multiple accounts what is the best approach to follow or is there any limitation?

ITsACrowd
Tera Contributor

Yes I would also like to know the same as @Surya47 

 

@Dan Martinez , How well does this work with Domain Separation?

 

Adam

DBasu0502
Tera Contributor

Hi ,

Where can i check the "defaulters" requests originating from "not allowed" Ip's and their daily count ?

Are there any specific events that I can monitor in sysevent ?

Are these available on the instance ?

The SOC team of my client ( a bank) would like to have that monitored and reported . 

 

Any idea?