Closed GoogleCodeExporter closed 9 years ago
Attaching a screenshot of the error message appearing in Firefox.
thanks.
Original comment by celebrat...@gmail.com
on 31 Oct 2009 at 2:26
Attachments:
I tried it yesterday on another machine and got the same output as you.
But then I tried again today, and it now works.
I'm guessing it was a google 'hiccup'.
Can you try again and see if it works for you too?
Original comment by david.yu...@gmail.com
on 2 Nov 2009 at 3:24
Not a bug.
Original comment by david.yu...@gmail.com
on 3 Nov 2009 at 11:06
Hi David,
I tried it again, but again its the same message. You mentioned that you too
tried
it -- was it on a local machine ? i mean thru localhost ? Because that's when i
face
this problem. When i try your hosted app. its works great without a hitch.
Its only when i try it locally that this happens.
Btw, i saw that google requires that the RP should register itself with google
for
OAuth to work, but with localhost i haven't done any registration, would that
be an
issue ? how do you handle that .. Thnx !
Original comment by celebrat...@gmail.com
on 4 Nov 2009 at 10:29
Yes it was on a local machine (localhost).
You need to register your domain with google to be able to use OAuth.
Goto https://www.google.com/accounts/ManageDomains
Once you've done that, edit src/main/resources/openid_consumer.properties and
replace
it with your consumer key and consumer secret.
Cheers
Original comment by david.yu...@gmail.com
on 4 Nov 2009 at 1:01
Oh ok..
The issue i face during registration is - i cannot register with localhost,
google
asks me to copy a certain file in the root folder which it tried to ping back
and
fails ( since its local host ) and so the verification step fails and so i
don't get
any key / secret values..
How did you handle / test your application during development, without
deploying it
over the WWW ? Any suggestions on how this could be addressed would be of great
help..Thnks!
Original comment by celebrat...@gmail.com
on 4 Nov 2009 at 2:30
You can't register with localhost. You have to register it with a domain or
subdomain that you have access to. Say for example yourproject.appspot.com.
Once
its registered with a domain, use the consumer keys from that domain locally
for testing.
Cheers
Original comment by david.yu...@gmail.com
on 4 Nov 2009 at 4:02
Thnx David,
I found another way out - describing below just in case any of the subsequent
user
faces the same issue.
One of the google engineers suggested that i can use 'anonymous' as my
consumer_key
and 'anonymous' as my consumer_secret whenever i am testing localhost
applications.
So in your oauth_consumer.properties file, i placed the following values -
www.google.com.consumer_key = anonymous
www.google.com.consumer_secret = anonymous
all other values being left to default values.
and my oauth functionality worked fine from localhost. I was able to
authenticate
with google and then later fetch the users contacts after receiving a separate
consent from him. it worked great. IF you can add this to the readme.txt, it
might
be helpful for new users.
Point to note is that this is not supported by the new Hybrid openid-oauth
endpoints,
but only works for the non-hybrid openid, oauth endpoints as of today...
Original comment by celebrat...@gmail.com
on 7 Nov 2009 at 3:36
I've updated the demos to use the anonymous keys and updated their READMEs
Thanks!
Original comment by david.yu...@gmail.com
on 8 Nov 2009 at 11:53
Just sharing my experience running the showcase Hybrid sample on localhost:
- Register your domain, let say yourproject.appspot.com
- Edit /etc/hosts, add a new line:
127.0.0.1 yourproject.appspot.com
- unzip the showcase
- Edit oauth_consumer.properties:
www.google.com.consumer_key = your_key
www.google.com.consumer_secret = your_secret
- Build and run:
mvn install
mvn jetty:run
- Using:
Open http://yourproject.appspot.com:8080/hybrid/google/contacts in your browser
And it works as expected.
And http://yourproject.appspot.com:8080/popup_login_hybrid.html also works
* One note: ensure your system time accurate, otherwise Google response a 400
code with message: Timestamp is too far from current time: 1292937694
Original comment by gwtdevel...@gmail.com
on 21 Dec 2010 at 3:14
Thanks for sharing! I linked your post from the hybrid wiki.
Original comment by david.yu...@gmail.com
on 21 Dec 2010 at 3:25
Original issue reported on code.google.com by
celebrat...@gmail.com
on 31 Oct 2009 at 2:05