Map not loading because urls are blocked

2148
5
Jump to solution
02-20-2020 03:08 PM
HarishChopra
New Contributor

I am using Esri IOS sdk version 100.6 in our iOS application with below basemaps:

openStreetMapBasemap

imageryWithLabels

terrainWithLabelsVector

Application is running fine on simulator when none of the urls are blocked. However when I am running the application on iPhone "openStreetMapBasemap" is not loading and others are very slow in moving. I know this is because our VPN is blocking urls that are called by maps Esri sdk.

So I want to know list of urls that our security team should whitelist for this application. Please advise.

Currently we have whitelisted as per below documentL

https://downloads.esri.com/resources/enterprisegis/AGOL_Domain_Requirements.pdf 

But still "openStreetMapBasemap" is not loading.

Thanks.

Tags (2)
0 Kudos
1 Solution

Accepted Solutions
WilliamCraft
MVP Regular Contributor

Try whitelisting *.arcgis.com and *.openstreetmap.org

View solution in original post

0 Kudos
5 Replies
WilliamCraft
MVP Regular Contributor

Try whitelisting *.arcgis.com and *.openstreetmap.org

0 Kudos
HarishChopra
New Contributor

@william Do you mean I should only whitelist *.arcgis.com and *.openstreetmap.org and remove the other whitelisted  from this link: https://downloads.esri.com/resources/enterprisegis/AGOL_Domain_Requirements.pdf

OR I shall whitelist all of them.

Also is there any resource for the url list that should be whitelisted because our cybersecurity team may want that before doing that.

0 Kudos
WilliamCraft
MVP Regular Contributor

Whitelisting the PDF at the URL you provided won't help anything.  However, it actually provides the very reference you're asking for.  These are the domains it suggests to whitelist in order ArcGIS Online capabilities to work properly:

https://ago-item-storage.s3.amazonaws.com

https://ago-item-storage.s3.us-east-1.amazonaws.com

https://*.arcgis.com

https://*.arcgisonline.com

http://*.esri.com

https://*.blob.core.windows.net

0 Kudos
Nicholas-Furness
Esri Regular Contributor

A couple of notes.

  1. The openstreetmap basemap that Runtime provides a shortcut for pulls tiles from openstreetmap.org, so William Craft‌'s response above is correct: add *.openstreetmap.org to the whitelist.

  2. You can find this out by turning on URL logging in the Runtime and checking the console output in Xcode. You can turn on global debugging with this code (though don't put this in production code as it affects performance):
    AGSRequestConfiguration.global().debugLogRequests = true‍‍‍
    From that I could see that you'd need to whitelist openstreetmap.org.
    2020-02-21 12:20:23.475207-0500 TestOSM[30781:5832027] **------>> sending request**  
    
     - [https://a.tile.openstreetmap.org/0/0/0.png](https://a.tile.openstreetmap.org/0/0/0.png)  
     - GET  
    
    -----
    2020-02-21 12:20:23.608706-0500 TestOSM[30781:5832024] **------>> sending request**  
    
     - [https://b.tile.openstreetmap.org/1/0/0.png](https://b.tile.openstreetmap.org/1/0/0.png)  
     - GET  
    
    -----‍‍‍‍‍‍‍‍‍‍‍‍
  3. There is a Vector Tile version of the OpenStreetMap basemap which Esri hosts now, and for which a whitelist entry of basemaps.arcgis.com or *.arcgis.com would be suitable. You can find that here. It is not currently part of the Runtime's shortcut enumerations when defining an AGSMap, but you can make use of it like this:
    let osmItem = AGSPortalItem(portal: .arcGISOnline(withLoginRequired: false),
                                itemID: "3e1a00aeae81496587988075fe529f71")
    
    let osmVectorLayer = AGSArcGISVectorTiledLayer(item: osmItem)
    
    let map = AGSMap(basemap: AGSBasemap(baseLayer: osmVectorLayer))‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍


Hope this helps!

MichaelDavis3
Occasional Contributor III

Totally off topic - but how did I never notice that OSM has little dog-prints when you zoom in on a dog park?

+1 OSM... Your move ESRI!