30 Commits

Author SHA1 Message Date
ciaranj
8be23c309c Merge remote-tracking branch 'jfromaniello/bug129' 2013-03-05 17:43:51 +00:00
ciaranj
03d713be9a Fixes Issue #129
Not ideal, but effectively reverts the default behaviour of the library to how 0.9.8 worked,
that is it passes the access_token as a query parameter to the server.

To allow the utility 'get' method to use an Authorization header *instead* then you need to
explicitly enable this behaviour by using the method :

  var oa= new Oauth(...);
  oa.useAuthorizationHeaderforGET(true)

Note this can/should be used in conjunction with the other utility method:

  oa.setAuthMethod(...)

The default value for the Authorization header is 'Bearer'

If you're building your own requests using oa._request then there is a new exported
method:

  oa.buildAuthHeader(token)
2013-03-05 17:34:20 +00:00
ciaranj
ba81ad43bd Fixes Issue #125 - Abusing externally passed in data structure
Also had to re-jig the test, as it turns out the contributor-supplied test
for this work didn't *actually* test anything :(
2013-03-05 17:00:35 +00:00
Jose F. Romaniello
798157c185 fix #129 Setting token in query params and Authorization header violates spec 2013-03-05 04:04:00 -03:00
Brian Park
efbce5bd68 Add in Authorization Header and support extra headers by default. 2012-11-21 10:29:30 -05:00
ciaranj
b103b70210 Add a test for Issue #105 2012-07-28 13:32:09 +01:00
Joe Rozner
d8d1e0bad7 fixed issue #64 w/ tests 2012-06-07 10:44:54 -07:00
ciaranj
c631a31503 Adding a test for the refresh_token grant type support 2012-04-24 21:40:24 +01:00
ciaranj
6fa0288805 Adding test for passing back the extra data to the OAuth2 getOAuthAccessToken caller 2012-04-24 20:44:58 +01:00
Raoul Millais
aca047eaeb Reimplemented configurable http method for token requests using setClientOptions 2011-08-17 08:42:58 +01:00
ciaranj
49c83f1824 Documented behaviour of getOAuthRequestToken 2011-08-16 14:04:01 +01:00
Raoul Millais
1b4624cacd Added support for GET when requesting request tokens 2011-08-16 13:26:49 +01:00
ciaranj
707b8f77b2 OAuth2 getOAuthAccessToken now POSTs rather than GET as per the spec (v20) 2011-08-15 23:30:47 +01:00
bdickason
d8b5731446 Added support and test coverage for following 301 redirects 2011-07-08 10:04:45 -04:00
ciaranj
7e2aa8cfbe Adding test for character encoding / body length issue 2011-06-25 21:37:21 +01:00
ciaranj
5a6c2594ec Add in specific test for supporting 200 responsecode and one for a 210 responsecode 2011-06-23 22:19:17 +01:00
meltingice
50a7039f52 Added signature test for OAuthEcho 2011-05-08 23:17:24 -04:00
ciaranj
9fea0b5458 Added tests for 302 redirect functionality 2011-04-19 23:09:20 +01:00
ciaranj
5041ca168a closes 24 - Now compatible with node v0.3.7 2011-02-02 21:35:04 +00:00
ciaranj
3331aefe27 Resolves Issue 18 - Handles node.js querystring a little better
in the edge case on composite parameters such as foo[bar] :)
2010-12-13 20:04:41 +00:00
ciaranj
fd2fad54da Adds support for PUT & DELETE verbs. Fixes #13 2010-12-12 23:06:24 +00:00
ciaranj
2c0b8c3b79 Fixes issue 17 - Handles rev07 and above of the OAuth spec 2010-12-12 22:38:56 +00:00
ciaranj
caebbc2ca1 Fixed the parameter ordering, and added support for repeated arguments. Fixes issue 14 2010-12-05 21:52:50 +00:00
François de Metz
c35f184420 added tests about oauth.authHeader 2010-11-23 23:23:07 +01:00
ciaranj
b6f7e03061 Extra params when passed as a POST will now properly get set as the POST body rather than be discarded as previously 2010-10-31 23:15:22 +00:00
ciaranj
bd90236624 Added some tests to cover the existing behaviours before a refactor 2010-10-31 22:28:17 +00:00
Yohei Sasaki
6c27fa9ead testcase for _buildAuthorizationHeader to check the dependency on Array.prototype.toString. 2010-10-23 11:49:25 +01:00
ciaranj
98c2e01a75 Tests all ported to Vows. No excuses now to not provide tests, I need to go back and write a lot more to cover what has already been done. 2010-10-17 12:23:45 +01:00
ciaranj
29b5abd1f8 Making the current sole test a little more textually exciting 2010-10-17 10:42:54 +01:00
ciaranj
cd23affb23 Bootstrapping up tests on Vows (DEPENDS ON NPM) 2010-10-17 10:39:19 +01:00