0
java.lang.NullPointerException
       at net.oauth.jsontoken.crypto.AsciiStringVerifier.verifySignature(AsciiS
ringVerifier.java:47)
       at net.oauth.jsontoken.JsonTokenParser.signatureIsValid(JsonTokenParser.
ava:177)
       at net.oauth.jsontoken.JsonTokenParser.verify(JsonTokenParser.java:130)
       at net.oauth.jsontoken.JsonTokenParser.verify(JsonTokenParser.java:103)
       at net.oauth.jsontoken.JsonTokenParser.verifyAndDeserialize(JsonTokenPar
er.java:116)
       at com.google.identitytoolkit.JsonTokenHelper.verifyAndDeserialize(JsonT
kenHelper.java:54)
       at com.google.identitytoolkit.GitkitClient.validateTokenToJson(GitkitCli
nt.java:170)
       at com.google.identitytoolkit.GitkitClient.validateToken(GitkitClient.ja
a:184)
       at com.google.identitytoolkit.GitkitClient.validateTokenInRequest(Gitkit
lient.java:218)
       at com.google.gitkit.samples.GitkitExample$LoginServlet.doGet(GitkitExam
le.java:76)

I have followed the java quick start wiki page and created the client,service account and API key. When I try to access http://localhost:4567/ it errors out with the NPE.

Any suggestions ?

thanks

  • Do you have code to share? – Michael Aaron Safyan Jan 29 '16 at 00:57
  • I am following the quick start wiki page - https://developers.google.com/identity/toolkit/web/quickstart/java – user4921940 Jan 29 '16 at 01:09
  • I have copied the gitkit-server-config.json into /identity-toolkit-java-master directory. Here are its contents - "clientId": "733620721902-loql9j5c8jjrdm03sb491bsiaib3fj03.apps.googleusercontent.com", "projectId": "swift-shore-119821", "serviceAccountEmail": "identitytoolkitserviceaccount@swift-shore-119821.iam.gserviceaccount.com", "serviceAccountPrivateKeyFile": "C:/GoogleIdentityToolkit/abc.p12", "widgetUrl": "http://localhost:4567/gitkit", "cookieName": "gtoken" } – user4921940 Jan 29 '16 at 01:15
  • I have verified that service account private key location is correct. – user4921940 Jan 29 '16 at 01:16
  • I also see this warning - com.google.identitytoolkit.GitkitVerifierManager initVer ifiers WARNING: unable to find token verifier: Connection timed out: connect java.net.ConnectException: Connection timed out: connect – user4921940 Jan 29 '16 at 17:41

0 Answers0