Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Problems with Twitter+OAuth+iPhone. Kids are Crying

This case is really strange, i've spent 2 whole days to get Twitter Oauth working with the iPhone and i failed over and over again. Its strange since most of the people don't seem to have the same problem as me.

First of all, the Consumer Key and Consumer Secret is okay, i tried with 2 OAuth apps (Twitter) with every possible configuration and got nothing, i even tried with a completely funcional app and the result was the same. So the Twitter app is okay, the problem doesnt lie there.

I've tried Bengottlieb's solution: http://github.com/bengottlieb/Twitter-OAuth-iPhone provided my Consumer Key and Secret and all i've got from Twitter is a "Sorry, the page doesn't exist".

I tried with "ShareKit" which is intended to be a n00b's proof drop in component, you just need to provide your Consumer key and Consumer Secret and i receive the message: "Request Error: There was a problem requesting authorization from Twitter".

I've tried including only OAuthConsumer and implementing code as tutorials say and i receive again the "Sorry, the page doesn't exist" page.

I'm using XCode 3.2.3 with the SDK 4.0 and i will download the 3.2.4 as another desperate solution.

Any help will be appreciated and maybe you achieve to make kids stop crying :'(

Thanks in advance :)

like image 404
Leopoldo Avatar asked Sep 23 '10 18:09

Leopoldo


1 Answers

Thanks Gordon, your advice took me to the solution. I was receiving from Twitter the message "Failed to validate oauth signature and token". I googled it and found that i needed to change the Time zone.

If someone has the same problem on your Mac do this:

-Click on the clock and then "Date & Time preferences" -Check "Set date and time automatically with: Apple Americas/U.S. (time.apple.com)"

That's all, the problem was with the timestamp which had been generated with an incorrect hour.

2 days wasted for such stupid thingy XD

like image 99
Leopoldo Avatar answered Sep 20 '22 11:09

Leopoldo