0

consumer_key_rejected

I just created a new oauth application id in my projects and I'm unable to authenticate. I've been trying in python and php with no luck so I figured I'd try with wget to see what's happening. I appear to be getting the consumer_key_rejected error. Any help would be appreciated.

wget command:

wget -S -d 'https://api.login.yahoo.com/oauth/v2/get_request_token' --post-data='oauth_consumer_key=dj0yJmk9Z0txdExta3ZHRE03JmQ9WVdrOWVsWkxWVVZsTldFbWNHbzlOa
kUzTkRnNE1EWXkmcz1jb25zdW1lcnNlY3JldCZ4PTdk&oauth_nonce=aaa2349834&oauth_signature=d110bd7d3a7b9fb95e2ead59ae1fb0b3fd67b60e%26&oauth_signature_method=PLAINTEXT&oauth_timestamp=1271273941&oauth_version=1.0&oauth_callback=http://www.mysite.com/'

consumer key: dj0yJmk9Z0txdExta3ZHRE03JmQ9WVdrOWVsWkxWVVZsTldFbWNHbzlOakUzTkRnNE1EWXkmcz1jb25z
dW1lcnNlY3JldCZ4PTdk
shared key: d110bd7d3a7b9fb95e2ead59ae1fb0b3fd67b60e
application id: zVKUEe5a

result from wget command:

DEBUG output created by Wget 1.9+cvs-dev on darwin7.8.0.

--15:44:18-- https://api.login.yahoo.com/oauth/v2/get_request_token
=> `get_request_token'
Resolving api.login.yahoo.com... 68.142.197.104, 66.196.86.204
Caching api.login.yahoo.com => 68.142.197.104 66.196.86.204
Connecting to api.login.yahoo.com|68.142.197.104|:443... connected.
Created socket 3.
Releasing 0x208940 (new refcount 1).
Connected 3 to SSL 0x208a00

---request begin---
POST /oauth/v2/get_request_token HTTP/1.0
User-Agent: Wget/1.9+cvs-dev
Accept: */*
Host: api.login.yahoo.com
Connection: Keep-Alive
Content-Type: application/x-www-form-urlencoded
Content-Length: 318

---request end---
[POST data: oauth_consumer_key=dj0yJmk9Z0txdExta3ZHRE03JmQ9WVdrOWVsWkxWVVZsTldFbWNHbzlOakUzT
kRnNE1EWXkmcz1jb25zdW1lcnNlY3JldCZ4PTdk&oauth_nonce=aaa2349834&oauth_signature=d110bd7d3a7b9fb95e2ead59ae1fb0b3fd67b60e%26&oauth_signature_method=PLAINTEXT&oauth_timestamp=1271273941&oauth_version=1.0&oauth_callback=http://www.gazaro.com/]
HTTP request sent, awaiting response...
---response begin---
HTTP/1.1 401 Authorization Required
Date: Wed, 14 Apr 2010 19:43:51 GMT
P3P: policyref="http://info.yahoo.com/w3c/p3p.xml", CP="CAO DSP COR CUR ADM DEV TAI PSA PSD IVAi IVDi CONi TELo OTPi OUR DELi SAMi OTRi UNRi PUBi IND PHY ONL UNI PUR FIN COM NAV INT DEM CNT STA POL HEA PRE LOC GOV"
WWW-Authenticate: OAuth oauth_problem=consumer_key_rejected
Connection: close
Content-Type: application/x-www-form-urlencoded

---response end---

HTTP/1.1 401 Authorization Required
Date: Wed, 14 Apr 2010 19:43:51 GMT
P3P: policyref="http://info.yahoo.com/w3c/p3p.xml", CP="CAO DSP COR CUR ADM DEV TAI PSA PSD IVAi IVDi CONi TELo OTPi OUR DELi SAMi OTRi UNRi PUBi IND PHY ONL UNI PUR FIN COM NAV INT DEM CNT STA POL HEA PRE LOC GOV"
WWW-Authenticate: OAuth oauth_problem=consumer_key_rejected
Connection: close
Content-Type: application/x-www-form-urlencoded
Closed 3/SSL 0x208a00
Authorization failed.

by
1 Reply
  • Hi dominic,

    Your consumer key is registered as not requiring user authentication, so the
    get_request_token call is not applicable here. That's why it is rejected.

    If you need to access user data such as Yahoo! Updates, Status and etc,
    then please make sure your consumer key belongs to the OAuth applications
    category:
    https://developer.apps.yahoo.com/projects

    You will have to register a new consumer key.

    Thanks,
    Yu Wang
    0

Recent Posts

in OAuth General Discussion YDN SDKs