Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

authentication-adal-pkg

Package Overview
Dependencies
Maintainers
1
Versions
51
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

authentication-adal-pkg - npm Package Compare versions

Comparing version 1.0.25 to 1.0.26

62

lib/index.js

@@ -78,3 +78,4 @@ 'use strict';

var loginResource = null;
var clientId = null;
var clientIdNative = null;
var clientIdWeb = null;
var userId = null;

@@ -96,3 +97,4 @@ var authenticationResult = null;

resourceUri = config.resourceUri;
clientId = config.clientId;
clientIdWeb = config.clientIdWeb;
clientIdNative = config.clientIdNative;
userId = config.userId;

@@ -106,3 +108,3 @@ loginResource = config.loginResource;

tenant: tenant,
clientId: clientId,
clientIdNative: clientIdNativeWeb,
redirectUri: redirectUriWeb,

@@ -195,3 +197,3 @@ loginResource: loginResource

}
auth.acquireTokenPopup(clientId, null, null, acquireTokenCallback);
auth.acquireTokenPopup(clientIdWeb, null, null, acquireTokenCallback);
} else {

@@ -228,3 +230,3 @@ resolve(token);

};
auth.acquireToken(clientId, acquireTokenCallback);
auth.acquireToken(clientIdWeb, acquireTokenCallback);
} else {

@@ -298,3 +300,3 @@ resolve(token);

authContext
.acquireTokenAsync(resourceUri, clientId, platformRedirectUri)
.acquireTokenAsync(resourceUri, clientIdNative, platformRedirectUri)
.then(function(authResult) {

@@ -326,23 +328,29 @@ var token = authResult.accessToken;

// Attempt to authorize user silently
authContext.acquireTokenSilentAsync(resourceUri, clientId, userId).then(
function(authResult) {
var token = authResult.accessToken;
var exp = new Date(authResult.expiresOn).getTime();
storeToken(token, exp);
resolve(authResult);
},
function() {
// We require user credentials so triggers authentication dialog
// acquireTokenAsyncMobile(resolve, reject);
authContext
.acquireTokenAsync(resourceUri, clientId, platformRedirectUri)
.then(function(authResult) {
var token = authResult.accessToken;
var exp = new Date(authResult.expiresOn).getTime();
var token = authResult.accessToken;
storeToken(token, exp);
resolve(authResult);
}, reject);
}
);
authContext
.acquireTokenSilentAsync(resourceUri, clientIdNative, userId)
.then(
function(authResult) {
var token = authResult.accessToken;
var exp = new Date(authResult.expiresOn).getTime();
storeToken(token, exp);
resolve(authResult);
},
function() {
// We require user credentials so triggers authentication dialog
// acquireTokenAsyncMobile(resolve, reject);
authContext
.acquireTokenAsync(
resourceUri,
clientIdNative,
platformRedirectUri
)
.then(function(authResult) {
var token = authResult.accessToken;
var exp = new Date(authResult.expiresOn).getTime();
var token = authResult.accessToken;
storeToken(token, exp);
resolve(authResult);
}, reject);
}
);
}, reject);

@@ -349,0 +357,0 @@ }, reject);

{
"name": "authentication-adal-pkg",
"version": "1.0.25",
"version": "1.0.26",
"description": "An authentication SDK based on MS ADAL ",

@@ -5,0 +5,0 @@ "main": "lib/index.js",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc