Re: [oauth] HTTP PUT request format

2010-04-18 Thread Lukas Rosenstock
Hi!
The correct way would be to use the HTTP "Authorization" header.
Both methods which you have mentioned are basically fallbacks for that
semantically correct "Authorization" header.

If you can't use that, however, I would say 1) is better than 2) because as
per the specification the signature in the body implies a
application/x-www-form-urlencoded content type which usually is not the case
if you use PUT.

OAuth libraries should handle that as well.

Regards,
 Lukas Rosenstock

2010/4/16 AriB 

>
> Hi,
>
> when sending HTTP POST or PUT requests with Oauth, which is the right
> request format, 1) or 2)?
>
> Thanks in advance,
>
> AB
>
> 1)
>
> PUT
>
> http://www.mycompany.com:8080/blahblah?oauth_signature_method=HMAC-SHA1&oauth_token=blahblah&oauth_consumer_key=blahblah&oauth_timestamp=1271415739&oauth_nonce=14979237328487&oauth_version=1.0&oauth_signature=BZ5yz0cPta7Qs2PPzVD%2F6aDG6Gk%3D
>
> POST data:
> myrequestbodyhere
>
> [no cookies]
>
> Request Headers:
> Connection: keep-alive
> Content-Type: application/x-www-form-urlencoded; charset=UTF-8
> Content-Length: 10
>
> 2)
>
> PUT http://www.mycompany.com:8080/blahblah
>
> POST data:
> oauth_signature_method=HMAC-
>
> SHA1&oauth_token=blahblah&oauth_consumer_key=blahblah&oauth_timestamp=1271415739&oauth_nonce=14979237328487&oauth_version=1.0&oauth_signature=BZ5yz0cPta7Qs2PPzVD
> %2F6aDG6Gk%3D
>
> myrequestbodyhere
>
> [no cookies]
>
> Request Headers:
> Connection: keep-alive
> Content-Type: application/x-www-form-urlencoded; charset=UTF-8
> Content-Length: 10
>
> --
> You received this message because you are subscribed to the Google Groups
> "OAuth" group.
> To post to this group, send email to oa...@googlegroups.com.
> To unsubscribe from this group, send email to
> oauth+unsubscr...@googlegroups.com .
> For more options, visit this group at
> http://groups.google.com/group/oauth?hl=en.
>
>


-- 
http://lukasrosenstock.net/

-- 
You received this message because you are subscribed to the Google Groups 
"OAuth" group.
To post to this group, send email to oa...@googlegroups.com.
To unsubscribe from this group, send email to 
oauth+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/oauth?hl=en.



[oauth] Re: Any .NET dev's using oAuthBase? Sample code would be *lovely*

2010-04-18 Thread David King
That's excellent Alex, cheers!

Sorry it took so long to write back, GMail was automatically archiving
my groups messages - d'oh!

On Apr 7, 8:41 am, Alex Henderson  wrote:
> Just my 2ø worth - but I would suggest having a look over previous posts on
> this list for similar questions - the OAuthBase code is out of date, and
> buggy in my opinion.
>
> My suggestion would be to take a look at this page:
>
> http://oauth.net/code/
>
> And grab one of the more mature libraries... it
> should also make implementation easier for your developer.
>
> There are also some libraries not linked on that page that might be worth
> checking out, such as Hammock (which I believe was originally part of the
> tweetsharp project).
>
> http://hammock.codeplex.com/documentation
>
> Some suggested started points for your developers might be:
>
> http://oauth.net/documentation/getting-started/http://www.dotnetopenauth.net/about/about-oauth/http://code.google.com/p/devdefined-tools/wiki/OAuthConsumerhttp://lab.madgex.com/oauth-net/gettingatarted01.aspx/http://blog.bittercoder.com/PermaLink,guid,83488336-290d-4c4b-a314-14...
>
> It really just comes down to personal taste and finding a library that suits
> your needs.. but I would definitely steer clear of OAuthBase and go for
> something a little more mature / feature rich.
>
> Cheers,
>
>  - Alex
>
>
>
> On Wed, Apr 7, 2010 at 2:26 PM, David King  wrote:
> > Just as the title says, I have a developer that is looking to use
> > oAuthBase with .NET and has asked me if there's any examples he could
> > take a look at / reverse engineer...
>
> > Thanks all!
>
> > --
> > You received this message because you are subscribed to the Google Groups
> > "OAuth" group.
> > To post to this group, send email to oa...@googlegroups.com.
> > To unsubscribe from this group, send email to
> > oauth+unsubscr...@googlegroups.com .
> > For more options, visit this group at
> >http://groups.google.com/group/oauth?hl=en.

-- 
You received this message because you are subscribed to the Google Groups 
"OAuth" group.
To post to this group, send email to oa...@googlegroups.com.
To unsubscribe from this group, send email to 
oauth+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/oauth?hl=en.