What checks are performed in the case of Location Restriction?

There are times you may want to restrict where your students can view their training.  In Schoox you can do this per course for each defined unit in your academy.  You can restrict access by IP address or physical address.

IP address Physical Address
Academy Admins can setup each Unit with multiple IP addresses (IPv4 and IPv6), either default IP addresses or Classless Inter-Domain Routing (CIDR). Provided IP addresses are stored in our DataBase. Academy Admins can setup each Unit with one Physical Address. Schoox validates the provided Physical Address using the Google Maps API. The Google formatted Physical Address, the Latitude, and the Longitude are stored in our DataBase.

Please check the following article for some details on how to set up the Location Restriction: How can I restrict access to training based on location?


But what checks are performed in order to grant access to a course?

Check #1: Once an hourly worker accesses his course, Schoox checks if the user belongs to the Units where the Course has the Limited Access function enabled. 

Check #2: If Check #1 was successful, we can proceed with the evaluation of the IP match. Schoox gets user's IP address and checks it against Units' IP addresses with the IPset of a third party library. If the user and the IP address of a Unit match, the user is granted access to the course.

Check #3: If a User fails the IPs-matching and belongs to Units where the course has Limited Access using the Physical Address option set up, then SchooX performs Location-matching.

  • SchooX gets User Coordinates (Latitude and Longitude and Accuracy) by HTML 5 Geolocation. HTML5 Geolocation is the industry standard and a robust method for obtaining Coordinates with high Accuracy.
  • User must have setup the browser to allow location sharing, otherwise, the HTML5 Geolocation fails. The user is prompt by the browser to allow location sharing with SchooX.
  • If the user selects ‘Don’t Allow’, Location-matching fails and the User is denied access to the Course.
  • If the user selects ‘Allow Location Access’, then the HTML 5 Geolocation is applied successfully.

Check #4: SchooX tries to get User Coordinates by HTML 5 Geolocation with High Accuracy enabled.

  • If this fails, then SchooX tries to get User Coordinates by HTML5 Geolocation with High Accuracy disabled.
  • If both HTML5 Geolocation attempts fail, then the User is denied access to the course.

Check #5: If SchooX successfully gets a set of Coordinates, then it calculates the distance between the user’s Coordinates and the Unit’s Coordinates. Distance is calculated via the Haversine formula.

  • If the distance is smaller than [250m + the provided Coordinates Accuracy], then the user is granted access to the course.  To ensure a valid result, [250m + provided Coordinates Accuracy] must not exceed 2000m, as accuracy is an order of magnitude greater than the distance of 250m.
  • If [250m + the provided Coordinates Accuracy] is greater than 2000m, then the maximum allowed distance is set to 2000m.
Was this article helpful?
0 out of 0 found this helpful