Using google maps api behind firewall - google-maps

I have an application embedding google maps. Works fine. Some users are behind a firewall with very restricted access to the rest of the world.
Does anyone know of a valid list of dns-names/ip-addresses used by the google maps api? I can see what dns-names it loads from in firebug's net panel. But it feels a bit unsafe to use just them. Is there a such list that I can add to the firewalls whitelist?
..fredrik
EDIT
I spoke to someone who was working at the maps-team at google. And he said that it's not possible since the ip addresses changes since the maps service is split over a whole range over servers.

As I see in Chrome's console there are 3 servers that Google Maps are using right now:
mt0.google.com (ew-in-f100.1e100.net)
mt1.google.com (ew-in-f102.1e100.net)
maps.gstatic.com (ew-in-f104.1e100.net)
As you can see all of them are in 1e100.net domain.
1e100 equals1 googol ;)

This is possible now. The primary source of information is found here: https://developers.google.com/maps/documentation/business/articles/prelaunch_checklist#firewall
Configure Firewall to Allow Access to the Google Maps API Services
Why it's important: The Maps API services use a variety of domains, some which do not belong to the *google.com domain. If you are behind a restrictive firewall, it is important you understand which Maps API services use which domains.
Failure to allow access to the correct domains will cause API requests to fail, which can break your applications. For a complete listing of domains used by the Maps APIs, please consult our portal resource (login required):
Log in to the Google Enterprise Support Portal
The support portal is only available to Google Maps API for Work users.
Navigate to the "Resources" tab
Select the Resource called "List of domains used by the Google Maps API Family."
You should allow your applications to access these domains.
Please note that we do not recommend managing firewall restrictions by IP address, as the IPs associated with these domains are not static.

Here is the content of the article about domains used in Google Maps APIs. This article is available in Google Cloud support portal:
This document lists all the domains that are used by the Google Maps Platform when Maps components are loaded. This list of domain is provided to help you set up your firewall configuration, in case your Internet access is filtered by a per-domain policy.
Important notes:
This list is subject to change as new features are rolled out, and may not be up-to-date as new domains are noticed. It is recommended to check this page every 2 months.
The entries below containing google.com can be replaced with the other domains where Google Maps has launched: maps.google.co.uk, ditu.google.com, bendi.google.com, ditu.google.cn, bendi.google.cn, mapy.google.pl, etc.
Users accessing the API from China will send requests to domains under google.cn and gstatic.cn in addition to google.com and gstatic.com respectively.
Javascript Maps API (V2 and V3) over HTTP
The Maps Javascript API V3 (and V2) bootstrap and services (geocoding, driving directions, elevation, kml) use:
maps.google.com
maps.googleapis.com
Static dependencies:
maps.gstatic.com
Map tiles and traffic tiles:
maps.googleapis.com
Aerial tiles:
khmdb0.google.com
khmdb0.googleapis.com
khmdb1.google.com
khmdb1.googleapis.com
Satellite tiles:
khm.google.com
khm.googleapis.com
khm0.google.com
khm0.googleapis.com
khm1.google.com
khm1.googleapis.com
khms0.google.com
khms0.googleapis.com
khms1.google.com
khms1.googleapis.com
Streetview imagery:
geo0.ggpht.com
geo1.ggpht.com
geo2.ggpht.com
geo3.ggpht.com
lh3.ggpht.com
lh4.ggpht.com
lh5.ggpht.com
lh6.ggpht.com
cbk0.google.com
cbk0.googleapis.com
cbk1.google.com
cbk1.googleapis.com
cbk2.google.com
cbk2.googleapis.com
cbk3.google.com
cbk3.googleapis.com
lh3.googleusercontent.com
lh4.googleusercontent.com
lh5.googleusercontent.com
lh6.googleusercontent.com
Reporting requests:
gg.google.com
Identification requests:
id.google.com
Javascript Maps API (V2 and V3) over HTTPS
The Maps Javascript API V3 (and V2) bootstrap and services (geocoding, driving directions, elevation, kml) use:
maps-api-ssl.google.com
maps.googleapis.com
Static dependencies:
maps-api-ssl.google.com
maps.gstatic.com
Map tiles and traffic tiles:
maps.googleapis.com
Aerial tiles:
khmdb0.google.com
khmdb0.googleapis.com
khmdb1.google.com
khmdb1.googleapis.com
Satellite tiles:
khm.google.com
khm.googleapis.com
khm0.google.com
khm0.googleapis.com
khm1.google.com
khm1.googleapis.com
khms0.google.com
khms0.googleapis.com
khms1.google.com
khms1.googleapis.com
khms2.google.com
khms2.googleapis.com
khms3.google.com
khms3.googleapis.com
Streetview imagery:
geo0.ggpht.com
geo1.ggpht.com
geo2.ggpht.com
geo3.ggpht.com
lh3.ggpht.com
lh4.ggpht.com
lh5.ggpht.com
lh6.ggpht.com
cbks0.google.com
cbks0.googleapis.com
cbks1.google.com
cbks1.googleapis.com
cbks2.google.com
cbks2.googleapis.com
cbks3.google.com
cbks3.googleapis.com
lh3.googleusercontent.com
lh4.googleusercontent.com
lh5.googleusercontent.com
lh6.googleusercontent.com
Reporting requests:
gg.google.com
Identification requests are not sent.
Additional domains
You may also see the javascript v3 API access the following domains:
googleapis.l.google.com
clients.l.google.com
maps.l.google.com
mt.l.google.com
khm.l.google.com
csi.gstatic.com
Maps API Web Services
The Geocoding API V3 (and V2), the Directions API, the Elevation API, the Distance Matrix API, and the Static Maps API V2 (and V1) use:
Over HTTP:
maps.google.com (legacy)
maps.googleapis.com (recommended)
Over HTTPS:
maps-api-ssl.google.com (legacy)
maps.googleapis.com (recommended)
Maps Android SDK
The Maps Android SDK uses these domains over HTTPS:
clients4.google.com
www.google.com
csi.gstatic.com

Related

Licence - Google Maps Url opens Defaultbrowser from Software

If I build a extension in my Software which opens Google Maps in the default browser with the Address of a Contact, do I need a Licence and start a plan at Google?
Like: https://www.google.de/maps/search/Kongo+Kinshasa
On some Pages I found, was mentioned that the use of Google Maps Urls are free, but I'm not sure.
There's no need to start a plan or acquire a licence from Google to be able to use the Maps URLs.
You just have to observe Google Maps Platform's Terms of Service in implementing this service in your use case as Google Maps URLs are also bound by these terms.
And lastly, you are correct to say that Maps URLs are free of charge. You won't even need an API key to use it.

Can I generate URLs to point to Google Maps on all platforms and perform some actions

Regardless of the platform I would like to launch Google Maps and optionally perform some actions like showing location, route etc
Google provides Google Maps URLs which allows you to do just that. You can build a universal, cross-platform URL to launch Google Maps and perform searches, get directions and navigation, and display map views and panoramic images. The URL syntax is the same regardless of the platform in use.
You don't need a Google API key to use Google Maps URLs.
Google Map URLs
Recently, in May 2017, Google launched the new Google Maps URLs API. You can read about this API in the official documentation
https://developers.google.com/maps/documentation/urls/guide
This API is intended to provide universal, cross-platform Google Maps URLs. So you can use it with websites, mobile apps, etc.
Search, directions, display map and display street view panorama modes are available in this API.
I hope this helps!

Using a business API key for reverse geocoding with Google

I'm working on a project that uses Google Maps APIs to reverse geocoding locations.
The customer is supposed to buy a licensed API key when rolling out to production.
Now I'm developing the application and I also need to test its functionality when using a valid, whether free or business, API key.
Let's pick a sample reverse geolocation request
https://maps.googleapis.com/maps/api/geocode/json?latlng=40.714224,-73.961452&sensor=true
I have registered a developer account into https://code.google.com/apis/console/ and generated a server API key. Then I enabled Google Geolocation APIs and Google Maps API v3 (I think I need only the second).
When adding &key=XXX parameter to my previous request I get an error that the key is not valid.
Reading documentation with more attention, I discovered that the geolocation service I'm using is actually part of Maps Web Service APIs (Maps V3 APIs run on browser as Javascript). I tried to find those APIs into the Services list of my console but couldn't find anything more.
How do I use Google's reverse geocoding API with a business key for a project that will handle thousands of daily requests?
with no api key, the Google Geocoding API has the following limits in place: 2,500 requests per day.
Google Maps API for Business customers have higher limits: 100,000 requests per day.
to use to API for Business you have to use URL signing, see https://developers.google.com/maps/documentation/business/webservices/auth
NB: If you're switching from the free API services to a Maps API for Business implementation, you must remove the key parameter from your requests. Google Maps API web services will deny requests made with both a client ID and a key.

Google Maps API v3 over HTTPS?

Is there a https version of the google maps api v3? I have a site that uses https and am getting annoying mixed secure and non-secure content errors in IE. I read that in v2 you had to pay to get this, but haven't seen anything for v3.
Yesterday Google announced that sites may use the v3 API for free over https:
http://googlegeodevelopers.blogspot.com/2011/03/maps-apis-over-ssl-now-available-to-all.html
Try replacing
http://maps.google.com/maps
with
https://maps-api-ssl.google.com/maps
Update
As of March 2011
The Maps API v3, Static Maps API, and Maps API Web Services are now
available to all developers over https:
This is one of my big problems with Google Maps. If you want to access Google Maps javascript via https you have to sign up as a Google Maps Premier customer.
There is a Google Maps API issue on the topic with lots of mutinous comments, but the final word from Google is that they will not be supporting this functionality in the free API.
This particular problem is close to my heart as I have spent the last few days porting one of our projects over to Bing Maps (it does support https).
Google does allows https access for Maps API v3, Static Maps API, and Maps API Web Services.
But with one condition:
If your site uses SSL because you charge for access to your
application, or because your application is not publicly accessible to
all users, you must still purchase a Maps API Premier license.

Google static maps API page mentions that static maps to be used only in browser

In the Google static maps API description (http://code.google.com/apis/maps/documentation/staticmaps/), I found the following statement : (present in the "Overview" section)
"Note that static maps may only be displayed within browser content; use of static maps outside of the browser is not allowed."
I need some help in deciphering the above statement.
Does this mean that the Google static maps has to be used inside a browser and cannot be used in context of a application doing http requests?
Thanks in advance for the help.
Interesting question.
This section from the "Google Maps API Family" FAQ says:
Can I use Google Maps in my non-Web application?
Yes, the Google Maps APIs can now be used in Desktop applications, provided that they adhere to the other restrictions of the Terms of Service. Note that in order for a desktop application to be deemed "publicly accessible", there must be a publicly accessible webpage from which it can be downloaded. See Section 7.1c of the Terms of Service for more information.
The FAQ also explicitly includes the Static Maps API as part of the set of "Google Maps APIs" mentioned above:
What are the Google Maps APIs?
The Google Maps APIs give developers several ways of embedding Google Maps into web pages, and allows for either simple use or extensive customization. There are now several API offerings: Google Maps Javascript API, Google Maps API for Flash, Google Static Maps API. In addition, we also offer the Mapplets API to enable the creation of mini-applications that run inside Google Maps. Depending on your needs, you may find yourself using one or a combination of these APIs.
The problem is that Section 10.8 of the Terms of Use is still saying:
10 - Except as explicitly permitted in Section 7 or the Maps APIs Documentation, you must not (nor may you permit anyone else to):
...
10.8 - use the Static Maps API other than in an implementation in a web browser;
It seems that using the Static Maps in a non-Web application is explicitly permitted in the Maps APIs Documentation, but I wonder if Section 10.8 takes precedence.
I will try to seek further information about this issue, and will update this answer accordingly.
Related links:
Google Maps API Group: J2SE Desktop App Options
Google Maps API Group: Static Maps and Mobile Applications