Geofencing
About geofencing
Our geofencing feature enables you to strengthen security for transactions by evaluating the current location of a device against a list of allowed regions. By limiting the use of Encap SCA activations (registrations/enrolments) and authentications to certain regions, you can reduce the chance of fraud.
How does geofencing work?
When geofencing is enabled, the client will send the country code of the location of the device to the server. The server will verify the location and limit the use of the device based on the configuration in your application configuration and what you have set as your allowed regions.
Supported operations
Geofencing is supported in activation (registration/enrolment) and authentication operations.
The geofencing result is returned from the Encap server to you using the REST API.
Functionality
Geofencing is configured in your application configuration, through the following mode parameters:
GEOFENCING_ACTIVATION_MODEGEOFENCING_AUTHENTICATION_MODE
The mode that geofencing is set to determines the functionality when the app calls the methods illustrated in the table above.
For start methods
The Encap server informs the client about the current geofencing mode.
If geofencing is enabled (OPTIONAL or REQUIRED), then the external geocoder platform is called with location as a parameter.
For finish methods
If geofencing is enabled (OPTIONAL or REQUIRED), then the client will send a request to the server that includes the country code from the geocoder external service, or without a country code if the lookup was not successful.
If there is no location on the device, then the client will wait until the timeout measured from the start method to complete.
The timeout is configured on the server for location and geofencing.
How to configure geofencing
To use our geofencing feature, you need to:
Configure the mobile SDK
To configure the mobile SDK for geofencing:
- In order for the device to get a valid location for the reverse geocode lookup, you need to add a value for
NSLocationWhenInUseUsageDescriptionin the app'sInfo.plist.
This is the message that will be presented to the end-user the first time the Encap API starts looking for a location.Change the location accuracyYou can also change the location accuracy if desired. To do this, see accuracy in our location feature documentation.
- The end-user must grant location permissions on their mobile device.
Configure the application configuration
The process for configuring the application configuration varies depending on whether you are a MobileID customer or an Encap SCA customer.
You can use the buttons below to learn how to configure the application configuration for the different products.
Error codes
The table below illustrates error codes related to geofencing if the geofencing mode is set to REQUIRED. If the geofencing mode is set to OFF or OPTIONAL, then no new error codes are introduced.
You can find the corresponding error descriptions in our SDK error codes documentation.