ashapangare / oauthconsumer

Automatically exported from code.google.com/p/oauthconsumer
0 stars 0 forks source link

Fix for incorrect POST behavior in NSMutableURLRequest+Parameters.m (issues 5 and 16) #17

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?

POSTing anything with a POST body and no encoded POST parameters

What is the expected output? What do you see instead?

Expect correct signature and successful POST.
Instead depending on input, either invalid signatures are created, or an 
out-of-bounds exception occurs.

What version of the product are you using? On what operating system?

Obj-C 2.0 version. File marked 10/19/07

Please provide any additional information below.

Attached is a patch that looks for the specific "Content-Type" header 
"application/x-www-form-urlencoded"  as per 
http://tools.ietf.org/html/rfc5849#section-3.4.1

I beleive this patch should resolve issues 5 and 16.

Original issue reported on code.google.com by j.ignaci...@gmail.com on 19 Mar 2013 at 2:58

Attachments:

GoogleCodeExporter commented 8 years ago
Of course, this puts the onus on the caller to correctly set the Content-Type 
header for proper behavior.

Original comment by j.ignaci...@gmail.com on 19 Mar 2013 at 3:07