Reputation: 41
I'm implementing a Flicker Client for the IPhone, and I am using OAuth
I managed to request the tokens successfully as well as redirecting the user to the authentication page,
My problem is when I try to ask for the access token I receive:
oauth_problem=signature_invalid Here's my header:
header OAuth realm="",
oauth_callback="oob",
oauth_consumer_key="XXXXX",
oauth_token="XXXX",
oauth_verifier="XXXX",
oauth_signature_method="HMAC-SHA1",
oauth_signature="XX",
oauth_timestamp="1309773699",
oauth_nonce="XXX",
oauth_version="1.0"
and here's my Base String:
POST&http%3A%2F%2Fwww.flickr.com%2Fservices%2Foauth%2Faccess_token&
oauth_consumer_key%3DXXXX%26
oauth_nonce%3DXXXX%26
oauth_signature_method%3DHMAC-SHA1%26
oauth_token%3DXXXX%26
oauth_timestamp%3D1309773699%26
oauth_verifier%3DXXXX%26
oauth_version%3D1.0
Thank you in advance,
Upvotes: 0
Views: 1532
Reputation: 41
The problem was solved by removing the callback attribute from the header. as the signature is regenerated from the header and then compared with the base string.. So, make sure that the header contains the same information as the base string.
I found that by comparing my header with an example from the Flicker API..
Upvotes: 2