atlassian-oauth2
Advanced tools
Comparing version 0.4.1 to 0.4.2
@@ -6,3 +6,3 @@ var request = require('request'), | ||
var EXPIRE_IN_SECONDS = 60, | ||
AUTHORIZATION_SERVER_URL = "https://auth.atlassian.io", | ||
AUTHORIZATION_SERVER_URL = "https://oauth-2-authorization-server.services.atlassian.com", | ||
JWT_CLAIM_PREFIX = "urn:atlassian:connect", | ||
@@ -9,0 +9,0 @@ GRANT_TYPE = "urn:ietf:params:oauth:grant-type:jwt-bearer", |
{ | ||
"name": "atlassian-oauth2", | ||
"description": "Atlassian Connect OAuth2 library", | ||
"version": "0.4.1", | ||
"version": "0.4.2", | ||
"author": "Seb Ruiz <sruiz@atlassian.com>", | ||
@@ -6,0 +6,0 @@ "repository": { |
@@ -38,3 +38,3 @@ var should = require('should'), | ||
var token = oauth2._createAssertionPayload(hostBaseUrl, oauthClientId, "admin"); | ||
token.aud.should.be.eql("https://auth.atlassian.io"); | ||
token.aud.should.be.eql("https://oauth-2-authorization-server.services.atlassian.com"); | ||
done(); | ||
@@ -90,3 +90,3 @@ }); | ||
opts = opts || {}; | ||
var interceptor = nock(opts.authorizationServerBaseUrl || 'https://auth.atlassian.io') | ||
var interceptor = nock(opts.authorizationServerBaseUrl || 'https://oauth-2-authorization-server.services.atlassian.com') | ||
.post(opts.authorizationPath || '/oauth2/token') | ||
@@ -104,3 +104,3 @@ .reply(replyCallback); | ||
function interceptFailedRequest(testCallback, replyCallback, failureMessage, opts) { | ||
var interceptor = nock('https://auth.atlassian.io') | ||
var interceptor = nock('https://oauth-2-authorization-server.services.atlassian.com') | ||
.post('/oauth2/token') | ||
@@ -124,3 +124,3 @@ .reply(replyCallback); | ||
interceptRequest(done, 200, { | ||
authorizationServerBaseUrl: 'https://auth2.atlassian.io', | ||
authorizationServerBaseUrl: 'https://auth.example.com', | ||
authorizationPath: '/some/other/path' | ||
@@ -127,0 +127,0 @@ }); |
16906