Bumping to 0.7.3 oauth 2 now sending a Content-Length header of 0 to
play well with github/nginx.
This commit is contained in:
parent
76cddbdf2b
commit
09d613cd46
@ -4,12 +4,13 @@ A simple oauth API for node.js . This API allows users to authenticate against
|
|||||||
|
|
||||||
Tested against both Twitter (http://twitter.com), term.ie (http://term.ie/oauth/example/) and Yahoo!
|
Tested against both Twitter (http://twitter.com), term.ie (http://term.ie/oauth/example/) and Yahoo!
|
||||||
|
|
||||||
|
Also provides rudimentary OAuth2 support, tested against facebook connect and github. For more complete usage examples please take a look
|
||||||
Also provides rudimentary OAuth2 support, tested against facebook connect.
|
at express-auth (http://github.com/ciaranj/express-auth)
|
||||||
|
|
||||||
Change History
|
Change History
|
||||||
==============
|
==============
|
||||||
0.7.2 - Fixes some broken unit tests!
|
0.7.3 - OAuth 2 now sends a Content-Length Http header to keep nginx happy :)
|
||||||
0.7.0 - Introduces support for HTTPS end points and callback URLS for OAuth 1.0A and Oauth 2 (Please be aware that this was a breaking change to the constructor arguments order)
|
0.7.2 - Fixes some broken unit tests!
|
||||||
|
0.7.0 - Introduces support for HTTPS end points and callback URLS for OAuth 1.0A and Oauth 2 (Please be aware that this was a breaking change to the constructor arguments order)
|
||||||
|
|
||||||
|
|
||||||
|
@ -38,6 +38,9 @@ exports.OAuth2.prototype._request= function(method, url, headers, access_token,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
realHeaders['Host']= parsedUrl.host;
|
realHeaders['Host']= parsedUrl.host;
|
||||||
|
|
||||||
|
//TODO: Content length should be dynamic when dealing with POST methods....
|
||||||
|
realHeaders['Content-Length']= 0;
|
||||||
if( access_token ) {
|
if( access_token ) {
|
||||||
if( ! parsedUrl.query ) parsedUrl.query= {};
|
if( ! parsedUrl.query ) parsedUrl.query= {};
|
||||||
parsedUrl.query["access_token"]= access_token;
|
parsedUrl.query["access_token"]= access_token;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user