views:

30

answers:

1

im getting signature_invalid error when trying to connect via oauth to delicious.com.

<cfset oUrl = "https://api.login.yahoo.com/oauth/v2/get_request_token"/&gt;
<cfset oauth_nonce  = "?oauth_nonce="&randrange(45678,99999)/>
<cfset oauth_timestamp = "&oauth_timestamp=122253373"/>
<cfset oauth_consumer_key = "&oauth_consumer_key="&URLEncodedFormat('dj0yJrvVRvrvrvRVRvvRVervNVFEyTlRFeU5qTTrverVERVERVervervRT4r34r34fgjj--')/>
<cfset oauth_signature_method = "&oauth_signature_method=plaintext"/>
<cfset oauth_signature = "&oauth_signature="&URLEncodedFormat('f28revcevERVrv4f3vVrfr1hgvcWJc112bb0f74Tu')/>
<cfset oauth_version = "&oauth_version=1.0"/>
<cfset xoauth_lang_pref = "&xoauth_lang_pref=en-us"/>
<cfset oauth_callback = "&oauth_callback=http://www.mysite.com/del/t1.cfm"/&gt;

<cfset my1 = oUrl&oauth_nonce&oauth_timestamp&oauth_consumer_key&oauth_signature_method&oauth_signature&oauth_version&xoauth_lang_pref&oauth_callback/>

what am i doing wrong??? to verify im using Consumer Key as my oauth_consumer_key and Consumer Secret as my oauth_signature

these are not my actual keys, i modified them....

thanks

A: 

Don't re-invent the wheel. There is already a good OAuth library out there for CF: http://oauth.riaforge.org/index.cfm

I can go ahead and tell you that your consumer key and secret are not the same as key and signature. They are used to create the signature, which you then use with the consumer key.

Get the OAuth package, and follow through the tutorials/demos there. If you search for OAuth tutorials online, there are several good ones. Mostly, they are for Twitter integration, but they still give a good overview.

Ben Doom