SSL Certificate Match Error while calling Google Places API - google-places-api

I have been using Google Places API inside my application. The client code is written in Java. It was working fine till couple of weeks ago and suddenly it started throwing following exceptions while making API call:
javax.net.ssl.SSLException: hostname in certificate didn't match: <maps.googleapis.com/209.85.175.95> != <*.googleapis.com> OR <googleapis.com> OR <*.googleapis.com>
I am using following URL for making API call : https://maps.googleapis.com/maps/api/place/search/json?
Also tried with different Google API keys generated from Google API console.
Can someone please point what I am missing here?
Many thanks

I used the latest Google API (version 1.13.2) which support better SSL options:
ApacheHttpTransport.Builder transport = new ApacheHttpTransport.Builder().doNotValidateCertificate().build();

Related

Add Trello Card results in "Error - Malformed URL:"

I'm using ruby-trello gem for creating cards in a Trello list.
For my testing credentials this works fine, for the credentials I use on a production setup I get "Trello::Error - Malformed URL:"
The "Malformed URL" is a direct response from Trello, and I can't get my head around why, and how to fix this.
There is little to no documentation on API response errors by Trello.
Maybe you should watch what you application is sending to Trello.
You should also aread the API that Trello offers and search for the specific request and its response. Also you can probe if the Keys are correct in Trello's Sandbox.
As last option write an issue on Github's gem or ask for assistance to Trello.
Hope it helps.

Xamarin Forms and TLS 1.2

When Apple started to require TLS 1.2 I had issues with it and turned it off in the info.plist. Now that they are going to require that it not be turned off for apps in the app store, I'm revisiting it. I've found some Xamarin articles on it, such ashttps://developer.xamarin.com/guides/cross-platform/transport-layer-security/ andhttps://developer.xamarin.com/guides/ios/platform_features/introduction_to_ios9/ats/#ATS-Connection-Requirements but they are not dated and the information does not appear to match my testing. What I have found it, running against a TLS 1.2 secured server, everything just works - both webviews and API calls using System.Net.Http.HttpClient (HttpClientHandler) return what is expected without error, without any special configuration. Are the articles above outdated?
I am also getting unexpected results when running against a non-secured server. The webviews do return an error as expected, but the API calls return JSON objects with the expected data, no security error. Why isn't TLS 1.2 required for these connections?
Any help / clarification would be much appreciated!

Full text search using Google Sites API gives 500 internal server error

I tried incorporating the full text search using the Google Sites API (via a service account) but to no effect. I also tried it on the Google Oauth playground, but I get 500 Internal server error in both the cases.
I am using https://sites.google.com/feeds/content/domainName/siteName?q=test as the URL.
However, I do get a 200 OK when I fire https://sites.google.com/feeds/content/domainName/siteName (without a query string) in the Google Oauth playground.
Please guide me if I am doing anything wrong.
Thanks

Google map places service is giving REQUEST

I am using google place api for places sugestions.
https://maps.googleapis.com/maps/api/place/textsearch/json?query=ari&sensor=false&key=your_api_key
I have valid api key and this URL is working fine when I am executing it from the browser.
The api return "OK" as status and places suggestion but when I am executing the same URL by cUrl or file_get_contents It returns "REQUEST_DENIED" as status and hence no place suggestions.
why this is behaving like this.
Is there any setting which I am missing.
Any suggestion would be a great help.
Thanks
Did you ever get your answer to this? As far as I am aware this is die to "cross-site-scripting" security limits. You can't go from the Places API directly to Google even though you can in a browsers address bar. You have to make the call back to your sever and have the server send the call to Google - then return those results back to your page/ web site.

Google checkout callback can't seem to reach https server

I am trying to implement Google Check out (GCO) on a new server, the process seemed to work fine on the old server.
The error from GCO integration console is the timeout error you might expect if there is load on the server and/or the response takes longer than 3 seconds to respond.
To perform a test (not integrating with my database), I have set some code to send an email to me instead. If I hit the https url manually, I get the email and I can see an output to the screen. If I then leave it as that, Google still returns the Timeout error and I don't get an email. So I have doubts as to whether google is even able to hit the https url.
I did temporarily attempt to use the unsecure url for testing and indeed I received the email, however this solution isn't the route we've developed for, so the problem is something to do with the secure url specifically.
I have looked into the certificate which is a UTN-USERFirst-Hardware which is listed as accepted on http://checkout.google.com/support/sell/bin/answer.py?answer=57856 . I have also tried to temporarily disable the firewall with no joy. Does anyone have any sugestions?
Good to hear you figured out the problem.
I'm adding the links below to add a litle more context for future readers about how Google Checkout uses HTTP Basic Authentication:
http://code.google.com/apis/checkout/developer/Google_Checkout_XML_API.html#urls_for_posting
http://code.google.com/apis/checkout/developer/Google_Checkout_XML_API.html#https_auth_scheme
http://code.google.com/apis/checkout/developer/Google_Checkout_HTML_API_Notification_API.html#Receiving_and_Processing_Notifications

Resources