@azure/msal-angular
Advanced tools
Comparing version 2.0.0-beta.5 to 2.0.0-beta.6
@@ -5,1 +5,2 @@ /** | ||
export * from './public-api'; | ||
//# sourceMappingURL=azure-msal-angular.d.ts.map |
@@ -1,1 +0,1 @@ | ||
{"__symbolic":"module","version":4,"metadata":{"MsalService":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Injectable","line":24,"character":1}}],"members":{"__ctor__":[{"__symbolic":"constructor","parameterDecorators":[[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Inject","line":30,"character":9},"arguments":[{"__symbolic":"reference","name":"MSAL_INSTANCE"}]}],null],"parameters":[{"__symbolic":"reference","module":"@azure/msal-browser","name":"IPublicClientApplication","line":30,"character":48},{"__symbolic":"reference","module":"@angular/common","name":"Location","line":31,"character":26}]}],"acquireTokenPopup":[{"__symbolic":"method"}],"acquireTokenRedirect":[{"__symbolic":"method"}],"acquireTokenSilent":[{"__symbolic":"method"}],"handleRedirectObservable":[{"__symbolic":"method"}],"loginPopup":[{"__symbolic":"method"}],"loginRedirect":[{"__symbolic":"method"}],"logout":[{"__symbolic":"method"}],"logoutRedirect":[{"__symbolic":"method"}],"logoutPopup":[{"__symbolic":"method"}],"ssoSilent":[{"__symbolic":"method"}],"getLogger":[{"__symbolic":"method"}],"setLogger":[{"__symbolic":"method"}]}},"IMsalService":{"__symbolic":"interface"},"MsalGuard":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Injectable","line":16,"character":1}}],"members":{"__ctor__":[{"__symbolic":"constructor","parameterDecorators":[[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Inject","line":21,"character":9},"arguments":[{"__symbolic":"reference","name":"MSAL_GUARD_CONFIG"}]}],null,null,null,null],"parameters":[{"__symbolic":"reference","name":"MsalGuardConfiguration"},{"__symbolic":"reference","name":"MsalBroadcastService"},{"__symbolic":"reference","name":"MsalService"},{"__symbolic":"reference","module":"@angular/common","name":"Location","line":24,"character":26},{"__symbolic":"reference","module":"@angular/router","name":"Router","line":25,"character":24}]}],"parseUrl":[{"__symbolic":"method"}],"getDestinationUrl":[{"__symbolic":"method"}],"loginInteractively":[{"__symbolic":"method"}],"activateHelper":[{"__symbolic":"method"}],"canActivate":[{"__symbolic":"method"}],"canActivateChild":[{"__symbolic":"method"}],"canLoad":[{"__symbolic":"method"}]}},"MsalGuardConfiguration":{"__symbolic":"interface"},"MsalGuardAuthRequest":{"__symbolic":"interface"},"MsalInterceptor":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Injectable","line":20,"character":1}}],"members":{"__ctor__":[{"__symbolic":"constructor","parameterDecorators":[[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Inject","line":23,"character":9},"arguments":[{"__symbolic":"reference","name":"MSAL_INTERCEPTOR_CONFIG"}]}],null,null],"parameters":[{"__symbolic":"reference","name":"MsalInterceptorConfiguration"},{"__symbolic":"reference","name":"MsalService"},{"__symbolic":"reference","module":"@angular/common","name":"Location","line":25,"character":26}]}],"intercept":[{"__symbolic":"method"}],"acquireTokenInteractively":[{"__symbolic":"method"}],"getScopesForEndpoint":[{"__symbolic":"method"}]}},"MsalInterceptorConfiguration":{"__symbolic":"interface"},"MsalInterceptorAuthRequest":{"__symbolic":"interface"},"MSAL_INSTANCE":{"__symbolic":"new","expression":{"__symbolic":"reference","module":"@angular/core","name":"InjectionToken","line":7,"character":33},"arguments":["MSAL_INSTANCE"]},"MSAL_GUARD_CONFIG":{"__symbolic":"new","expression":{"__symbolic":"reference","module":"@angular/core","name":"InjectionToken","line":9,"character":37},"arguments":["MSAL_GUARD_CONFIG"]},"MSAL_INTERCEPTOR_CONFIG":{"__symbolic":"new","expression":{"__symbolic":"reference","module":"@angular/core","name":"InjectionToken","line":11,"character":43},"arguments":["MSAL_INTERCEPTOR_CONFIG"]},"MsalBroadcastService":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Injectable","line":11,"character":1}}],"members":{"__ctor__":[{"__symbolic":"constructor","parameterDecorators":[[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Inject","line":19,"character":9},"arguments":[{"__symbolic":"reference","name":"MSAL_INSTANCE"}]}],null],"parameters":[{"__symbolic":"reference","module":"@azure/msal-browser","name":"IPublicClientApplication","line":19,"character":53},{"__symbolic":"reference","name":"MsalService"}]}]}},"MsalModule":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"NgModule","line":16,"character":1},"arguments":[{"declarations":[{"__symbolic":"reference","name":"MsalRedirectComponent"}],"imports":[{"__symbolic":"reference","module":"@angular/common","name":"CommonModule","line":19,"character":8}],"providers":[{"__symbolic":"reference","name":"MsalGuard"},{"__symbolic":"reference","name":"MsalBroadcastService"}]}]}],"members":{},"statics":{"forRoot":{"__symbolic":"function","parameters":["msalInstance","guardConfig","interceptorConfig"],"value":{"ngModule":{"__symbolic":"reference","name":"MsalModule"},"providers":[{"provide":{"__symbolic":"reference","name":"MSAL_INSTANCE"},"useValue":{"__symbolic":"reference","name":"msalInstance"}},{"provide":{"__symbolic":"reference","name":"MSAL_GUARD_CONFIG"},"useValue":{"__symbolic":"reference","name":"guardConfig"}},{"provide":{"__symbolic":"reference","name":"MSAL_INTERCEPTOR_CONFIG"},"useValue":{"__symbolic":"reference","name":"interceptorConfig"}},{"__symbolic":"reference","name":"MsalService"}]}}}},"MsalRedirectComponent":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Component","line":14,"character":1},"arguments":[{"selector":"app-redirect","template":""}]}],"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"MsalService"}]}],"ngOnInit":[{"__symbolic":"method"}]}},"MsalCustomNavigationClient":{"__symbolic":"class","extends":{"__symbolic":"reference","module":"@azure/msal-browser","name":"NavigationClient","line":17,"character":48},"decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Injectable","line":16,"character":1}}],"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"MsalService"},{"__symbolic":"reference","module":"@angular/router","name":"Router","line":21,"character":24},{"__symbolic":"reference","module":"@angular/common","name":"Location","line":22,"character":26}]}],"navigateInternal":[{"__symbolic":"method"}]}}},"origins":{"MsalService":"./msal.service","IMsalService":"./IMsalService","MsalGuard":"./msal.guard","MsalGuardConfiguration":"./msal.guard.config","MsalGuardAuthRequest":"./msal.guard.config","MsalInterceptor":"./msal.interceptor","MsalInterceptorConfiguration":"./msal.interceptor.config","MsalInterceptorAuthRequest":"./msal.interceptor.config","MSAL_INSTANCE":"./constants","MSAL_GUARD_CONFIG":"./constants","MSAL_INTERCEPTOR_CONFIG":"./constants","MsalBroadcastService":"./msal.broadcast.service","MsalModule":"./msal.module","MsalRedirectComponent":"./msal.redirect.component","MsalCustomNavigationClient":"./msal.navigation.client"},"importAs":"@azure/msal-angular"} | ||
{"__symbolic":"module","version":4,"metadata":{"MsalService":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Injectable","line":24,"character":1}}],"members":{"__ctor__":[{"__symbolic":"constructor","parameterDecorators":[[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Inject","line":30,"character":9},"arguments":[{"__symbolic":"reference","name":"MSAL_INSTANCE"}]}],null],"parameters":[{"__symbolic":"reference","module":"@azure/msal-browser","name":"IPublicClientApplication","line":30,"character":48},{"__symbolic":"reference","module":"@angular/common","name":"Location","line":31,"character":26}]}],"acquireTokenPopup":[{"__symbolic":"method"}],"acquireTokenRedirect":[{"__symbolic":"method"}],"acquireTokenSilent":[{"__symbolic":"method"}],"handleRedirectObservable":[{"__symbolic":"method"}],"loginPopup":[{"__symbolic":"method"}],"loginRedirect":[{"__symbolic":"method"}],"logout":[{"__symbolic":"method"}],"logoutRedirect":[{"__symbolic":"method"}],"logoutPopup":[{"__symbolic":"method"}],"ssoSilent":[{"__symbolic":"method"}],"getLogger":[{"__symbolic":"method"}],"setLogger":[{"__symbolic":"method"}]}},"IMsalService":{"__symbolic":"interface"},"MsalGuard":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Injectable","line":16,"character":1}}],"members":{"__ctor__":[{"__symbolic":"constructor","parameterDecorators":[[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Inject","line":21,"character":9},"arguments":[{"__symbolic":"reference","name":"MSAL_GUARD_CONFIG"}]}],null,null,null,null],"parameters":[{"__symbolic":"reference","name":"MsalGuardConfiguration"},{"__symbolic":"reference","name":"MsalBroadcastService"},{"__symbolic":"reference","name":"MsalService"},{"__symbolic":"reference","module":"@angular/common","name":"Location","line":24,"character":26},{"__symbolic":"reference","module":"@angular/router","name":"Router","line":25,"character":24}]}],"parseUrl":[{"__symbolic":"method"}],"getDestinationUrl":[{"__symbolic":"method"}],"loginInteractively":[{"__symbolic":"method"}],"activateHelper":[{"__symbolic":"method"}],"canActivate":[{"__symbolic":"method"}],"canActivateChild":[{"__symbolic":"method"}],"canLoad":[{"__symbolic":"method"}]}},"MsalGuardConfiguration":{"__symbolic":"interface"},"MsalGuardAuthRequest":{"__symbolic":"interface"},"MsalInterceptor":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Injectable","line":20,"character":1}}],"members":{"__ctor__":[{"__symbolic":"constructor","parameterDecorators":[[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Inject","line":23,"character":9},"arguments":[{"__symbolic":"reference","name":"MSAL_INTERCEPTOR_CONFIG"}]}],null,null],"parameters":[{"__symbolic":"reference","name":"MsalInterceptorConfiguration"},{"__symbolic":"reference","name":"MsalService"},{"__symbolic":"reference","module":"@angular/common","name":"Location","line":25,"character":26}]}],"intercept":[{"__symbolic":"method"}],"acquireTokenInteractively":[{"__symbolic":"method"}],"getScopesForEndpoint":[{"__symbolic":"method"}],"matchResourcesToEndpoint":[{"__symbolic":"method"}],"matchScopesToEndpoint":[{"__symbolic":"method"}]}},"MsalInterceptorConfiguration":{"__symbolic":"interface"},"MsalInterceptorAuthRequest":{"__symbolic":"interface"},"ProtectedResourceScopes":{"__symbolic":"interface"},"MSAL_INSTANCE":{"__symbolic":"new","expression":{"__symbolic":"reference","module":"@angular/core","name":"InjectionToken","line":7,"character":33},"arguments":["MSAL_INSTANCE"]},"MSAL_GUARD_CONFIG":{"__symbolic":"new","expression":{"__symbolic":"reference","module":"@angular/core","name":"InjectionToken","line":9,"character":37},"arguments":["MSAL_GUARD_CONFIG"]},"MSAL_INTERCEPTOR_CONFIG":{"__symbolic":"new","expression":{"__symbolic":"reference","module":"@angular/core","name":"InjectionToken","line":11,"character":43},"arguments":["MSAL_INTERCEPTOR_CONFIG"]},"MsalBroadcastService":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Injectable","line":11,"character":1}}],"members":{"__ctor__":[{"__symbolic":"constructor","parameterDecorators":[[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Inject","line":19,"character":9},"arguments":[{"__symbolic":"reference","name":"MSAL_INSTANCE"}]}],null],"parameters":[{"__symbolic":"reference","module":"@azure/msal-browser","name":"IPublicClientApplication","line":19,"character":53},{"__symbolic":"reference","name":"MsalService"}]}]}},"MsalModule":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"NgModule","line":16,"character":1},"arguments":[{"declarations":[{"__symbolic":"reference","name":"MsalRedirectComponent"}],"imports":[{"__symbolic":"reference","module":"@angular/common","name":"CommonModule","line":19,"character":8}],"providers":[{"__symbolic":"reference","name":"MsalGuard"},{"__symbolic":"reference","name":"MsalBroadcastService"}]}]}],"members":{},"statics":{"forRoot":{"__symbolic":"function","parameters":["msalInstance","guardConfig","interceptorConfig"],"value":{"ngModule":{"__symbolic":"reference","name":"MsalModule"},"providers":[{"provide":{"__symbolic":"reference","name":"MSAL_INSTANCE"},"useValue":{"__symbolic":"reference","name":"msalInstance"}},{"provide":{"__symbolic":"reference","name":"MSAL_GUARD_CONFIG"},"useValue":{"__symbolic":"reference","name":"guardConfig"}},{"provide":{"__symbolic":"reference","name":"MSAL_INTERCEPTOR_CONFIG"},"useValue":{"__symbolic":"reference","name":"interceptorConfig"}},{"__symbolic":"reference","name":"MsalService"}]}}}},"MsalRedirectComponent":{"__symbolic":"class","decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Component","line":14,"character":1},"arguments":[{"selector":"app-redirect","template":""}]}],"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"MsalService"}]}],"ngOnInit":[{"__symbolic":"method"}]}},"MsalCustomNavigationClient":{"__symbolic":"class","extends":{"__symbolic":"reference","module":"@azure/msal-browser","name":"NavigationClient","line":17,"character":48},"decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Injectable","line":16,"character":1}}],"members":{"__ctor__":[{"__symbolic":"constructor","parameters":[{"__symbolic":"reference","name":"MsalService"},{"__symbolic":"reference","module":"@angular/router","name":"Router","line":21,"character":24},{"__symbolic":"reference","module":"@angular/common","name":"Location","line":22,"character":26}]}],"navigateInternal":[{"__symbolic":"method"}]}}},"origins":{"MsalService":"./msal.service","IMsalService":"./IMsalService","MsalGuard":"./msal.guard","MsalGuardConfiguration":"./msal.guard.config","MsalGuardAuthRequest":"./msal.guard.config","MsalInterceptor":"./msal.interceptor","MsalInterceptorConfiguration":"./msal.interceptor.config","MsalInterceptorAuthRequest":"./msal.interceptor.config","ProtectedResourceScopes":"./msal.interceptor.config","MSAL_INSTANCE":"./constants","MSAL_GUARD_CONFIG":"./constants","MSAL_INTERCEPTOR_CONFIG":"./constants","MsalBroadcastService":"./msal.broadcast.service","MsalModule":"./msal.module","MsalRedirectComponent":"./msal.redirect.component","MsalCustomNavigationClient":"./msal.navigation.client"},"importAs":"@azure/msal-angular"} |
(function (global, factory) { | ||
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/core'), require('@angular/common'), require('@azure/msal-browser'), require('rxjs'), require('@angular/router'), require('rxjs/operators')) : | ||
typeof define === 'function' && define.amd ? define('@azure/msal-angular', ['exports', '@angular/core', '@angular/common', '@azure/msal-browser', 'rxjs', '@angular/router', 'rxjs/operators'], factory) : | ||
(global = global || self, factory((global.azure = global.azure || {}, global.azure['msal-angular'] = {}), global.ng.core, global.ng.common, global['@azure/msal-browser'], global.rxjs, global.ng.router, global.rxjs.operators)); | ||
(global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory((global.azure = global.azure || {}, global.azure['msal-angular'] = {}), global.ng.core, global.ng.common, global['@azure/msal-browser'], global.rxjs, global.ng.router, global.rxjs.operators)); | ||
}(this, (function (exports, core, common, msalBrowser, rxjs, router, operators) { 'use strict'; | ||
@@ -17,3 +17,3 @@ | ||
var name = "@azure/msal-angular"; | ||
var version = "2.0.0-beta.5"; | ||
var version = "2.0.0-beta.6"; | ||
@@ -214,2 +214,4 @@ /* | ||
} | ||
// Capture current path before it gets changed by handleRedirectObservable | ||
var currentPath = this.location.path(true); | ||
return this.authService.handleRedirectObservable() | ||
@@ -226,10 +228,16 @@ .pipe(operators.concatMap(function () { | ||
_this.authService.getLogger().verbose("Guard - at least 1 account exists, can activate or load"); | ||
// Prevent navigating the app to /#code= | ||
if (state && state.url.indexOf("#") > -1 && state.url.indexOf("code=") > -1) { | ||
// Prevent navigating the app to /#code= or /code= | ||
if (state && currentPath.indexOf("code=") > -1) { | ||
_this.authService.getLogger().info("Guard - Hash contains known code response, stopping navigation."); | ||
return rxjs.of(false); | ||
// Path routing (navigate to current path without hash) | ||
if (currentPath.indexOf("#") > -1) { | ||
return rxjs.of(_this.parseUrl(_this.location.path())); | ||
} | ||
// Hash routing (navigate to root path) | ||
return rxjs.of(_this.parseUrl("")); | ||
} | ||
return rxjs.of(true); | ||
}), operators.catchError(function () { | ||
_this.authService.getLogger().verbose("Guard - error while logging in, unable to activate"); | ||
}), operators.catchError(function (error) { | ||
_this.authService.getLogger().error("Guard - error while logging in, unable to activate"); | ||
_this.authService.getLogger().errorPii("Guard - error: " + error.message); | ||
/** | ||
@@ -289,3 +297,3 @@ * If a loginFailedRoute is set, checks to see if Angular 10+ is used and state is passed in before returning route | ||
this.authService.getLogger().verbose("MSAL Interceptor activated"); | ||
var scopes = this.getScopesForEndpoint(req.url); | ||
var scopes = this.getScopesForEndpoint(req.url, req.method); | ||
// If no scopes for endpoint, does not acquire token | ||
@@ -348,7 +356,7 @@ if (!scopes || scopes.length === 0) { | ||
* @param endpoint Url of the request | ||
* @param endpoint Http method of the request | ||
* @returns Array of scopes, or null if not found | ||
* | ||
*/ | ||
MsalInterceptor.prototype.getScopesForEndpoint = function (endpoint) { | ||
var _this = this; | ||
MsalInterceptor.prototype.getScopesForEndpoint = function (endpoint, httpMethod) { | ||
this.authService.getLogger().verbose("Interceptor - getting scopes for endpoint"); | ||
@@ -358,3 +366,18 @@ // Ensures endpoints and protected resources compared are normalized | ||
var protectedResourcesArray = Array.from(this.msalInterceptorConfig.protectedResourceMap.keys()); | ||
var keyMatchesEndpointArray = protectedResourcesArray.filter(function (key) { | ||
var matchingProtectedResources = this.matchResourcesToEndpoint(protectedResourcesArray, normalizedEndpoint); | ||
if (matchingProtectedResources.length > 0) { | ||
return this.matchScopesToEndpoint(this.msalInterceptorConfig.protectedResourceMap, matchingProtectedResources, httpMethod); | ||
} | ||
return null; | ||
}; | ||
/** | ||
* Finds resource endpoints that match request endpoint | ||
* @param protectedResourcesArray | ||
* @param endpoint | ||
* @param location | ||
* @returns | ||
*/ | ||
MsalInterceptor.prototype.matchResourcesToEndpoint = function (protectedResourcesEndpoints, endpoint) { | ||
var _this = this; | ||
return protectedResourcesEndpoints.filter(function (key) { | ||
var normalizedKey = _this.location.normalize(key); | ||
@@ -366,15 +389,56 @@ // Normalized key should include query strings if applicable | ||
if (relativeNormalizedKey === "" || relativeNormalizedKey === "/*") { | ||
return msalBrowser.StringUtils.matchPattern(normalizedKey, normalizedEndpoint); | ||
return msalBrowser.StringUtils.matchPattern(normalizedKey, endpoint); | ||
} | ||
else { | ||
// Matching endpoint with both protected resource and relative url of protected resource | ||
return msalBrowser.StringUtils.matchPattern(normalizedKey, normalizedEndpoint) || msalBrowser.StringUtils.matchPattern(relativeNormalizedKey, normalizedEndpoint); | ||
return msalBrowser.StringUtils.matchPattern(normalizedKey, endpoint) || msalBrowser.StringUtils.matchPattern(relativeNormalizedKey, endpoint); | ||
} | ||
}); | ||
// Process all protected resources and send the first matched resource | ||
if (keyMatchesEndpointArray.length > 0) { | ||
var keyForEndpoint = keyMatchesEndpointArray[0]; | ||
if (keyForEndpoint) { | ||
return this.msalInterceptorConfig.protectedResourceMap.get(keyForEndpoint); | ||
}; | ||
/** | ||
* Finds scopes from first matching endpoint with HTTP method that matches request | ||
* @param protectedResourceMap Protected resource map | ||
* @param endpointArray Array of resources that match request endpoint | ||
* @param httpMethod Http method of the request | ||
* @returns | ||
*/ | ||
MsalInterceptor.prototype.matchScopesToEndpoint = function (protectedResourceMap, endpointArray, httpMethod) { | ||
var allMatchedScopes = []; | ||
// Check each matched endpoint for matching HttpMethod and scopes | ||
endpointArray.forEach(function (matchedEndpoint) { | ||
var scopesForEndpoint = []; | ||
var methodAndScopesArray = protectedResourceMap.get(matchedEndpoint); | ||
// Return if resource is unprotected | ||
if (methodAndScopesArray === null) { | ||
allMatchedScopes.push(null); | ||
return; | ||
} | ||
methodAndScopesArray.forEach(function (entry) { | ||
// Entry is either array of scopes or ProtectedResourceScopes object | ||
if (typeof entry === "string") { | ||
scopesForEndpoint.push(entry); | ||
} | ||
else { | ||
// Ensure methods being compared are normalized | ||
var normalizedRequestMethod = httpMethod.toLowerCase(); | ||
var normalizedResourceMethod = entry.httpMethod.toLowerCase(); | ||
// Method in protectedResourceMap matches request http method | ||
if (normalizedResourceMethod === normalizedRequestMethod) { | ||
entry.scopes.forEach(function (scope) { | ||
scopesForEndpoint.push(scope); | ||
}); | ||
} | ||
} | ||
}); | ||
// Only add to all scopes if scopes for endpoint and method is found | ||
if (scopesForEndpoint.length > 0) { | ||
allMatchedScopes.push(scopesForEndpoint); | ||
} | ||
}); | ||
if (allMatchedScopes.length > 0) { | ||
if (allMatchedScopes.length > 1) { | ||
this.authService.getLogger().warning("Interceptor - More than 1 matching scopes for endpoint found."); | ||
} | ||
// Returns scopes for first matching endpoint | ||
return allMatchedScopes[0]; | ||
} | ||
@@ -484,2 +548,4 @@ return null; | ||
function __extends(d, b) { | ||
if (typeof b !== "function" && b !== null) | ||
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null"); | ||
extendStatics(d, b); | ||
@@ -670,2 +736,3 @@ function __() { this.constructor = d; } | ||
} | ||
/** @deprecated */ | ||
function __spread() { | ||
@@ -676,2 +743,3 @@ for (var ar = [], i = 0; i < arguments.length; i++) | ||
} | ||
/** @deprecated */ | ||
function __spreadArrays() { | ||
@@ -685,3 +753,7 @@ for (var s = 0, i = 0, il = arguments.length; i < il; i++) | ||
} | ||
; | ||
function __spreadArray(to, from) { | ||
for (var i = 0, il = from.length, j = to.length; i < il; i++, j++) | ||
to[j] = from[i]; | ||
return to; | ||
} | ||
function __await(v) { | ||
@@ -751,14 +823,17 @@ return this instanceof __await ? (this.v = v, this) : new __await(v); | ||
} | ||
function __classPrivateFieldGet(receiver, privateMap) { | ||
if (!privateMap.has(receiver)) { | ||
throw new TypeError("attempted to get private field on non-instance"); | ||
} | ||
return privateMap.get(receiver); | ||
function __classPrivateFieldGet(receiver, state, kind, f) { | ||
if (kind === "a" && !f) | ||
throw new TypeError("Private accessor was defined without a getter"); | ||
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) | ||
throw new TypeError("Cannot read private member from an object whose class did not declare it"); | ||
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver); | ||
} | ||
function __classPrivateFieldSet(receiver, privateMap, value) { | ||
if (!privateMap.has(receiver)) { | ||
throw new TypeError("attempted to set private field on non-instance"); | ||
} | ||
privateMap.set(receiver, value); | ||
return value; | ||
function __classPrivateFieldSet(receiver, state, value, kind, f) { | ||
if (kind === "m") | ||
throw new TypeError("Private method is not writable"); | ||
if (kind === "a" && !f) | ||
throw new TypeError("Private accessor was defined without a setter"); | ||
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) | ||
throw new TypeError("Cannot write private member to an object whose class did not declare it"); | ||
return (kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value; | ||
} | ||
@@ -789,4 +864,10 @@ | ||
this.authService.getLogger().verbosePii("MsalCustomNavigationClient - navigating to newUrl: " + newUrl); | ||
this.router.navigateByUrl(newUrl, { replaceUrl: options.noHistory }); | ||
return [2 /*return*/, Promise.resolve(false)]; | ||
// Prevent hash clearing from causing an issue with Client-side navigation after redirect is handled | ||
if (options.noHistory) { | ||
window.location.replace(newUrl); | ||
} | ||
else { | ||
this.router.navigateByUrl(newUrl, { replaceUrl: options.noHistory }); | ||
} | ||
return [2 /*return*/, Promise.resolve(options.noHistory)]; | ||
}); | ||
@@ -793,0 +874,0 @@ }); |
@@ -1,2 +0,2 @@ | ||
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("@angular/core"),require("@angular/common"),require("@azure/msal-browser"),require("rxjs"),require("@angular/router"),require("rxjs/operators")):"function"==typeof define&&define.amd?define("@azure/msal-angular",["exports","@angular/core","@angular/common","@azure/msal-browser","rxjs","@angular/router","rxjs/operators"],t):t(((e=e||self).azure=e.azure||{},e.azure["msal-angular"]={}),e.ng.core,e.ng.common,e["@azure/msal-browser"],e.rxjs,e.ng.router,e.rxjs.operators)}(this,(function(e,t,r,n,o,i,a){"use strict";var c=new t.InjectionToken("MSAL_INSTANCE"),s=new t.InjectionToken("MSAL_GUARD_CONFIG"),u=new t.InjectionToken("MSAL_INTERCEPTOR_CONFIG"),l="@azure/msal-angular",p="2.0.0-beta.5",g=function(){function e(e,t){this.instance=e,this.location=t;var r=this.location.path(!0).split("#").pop();r&&(this.redirectHash="#"+r),this.instance.initializeWrapperLibrary(n.WrapperSKU.Angular,p)}return e.prototype.acquireTokenPopup=function(e){return o.from(this.instance.acquireTokenPopup(e))},e.prototype.acquireTokenRedirect=function(e){return o.from(this.instance.acquireTokenRedirect(e))},e.prototype.acquireTokenSilent=function(e){return o.from(this.instance.acquireTokenSilent(e))},e.prototype.handleRedirectObservable=function(e){return o.from(this.instance.handleRedirectPromise(e||this.redirectHash))},e.prototype.loginPopup=function(e){return o.from(this.instance.loginPopup(e))},e.prototype.loginRedirect=function(e){return o.from(this.instance.loginRedirect(e))},e.prototype.logout=function(e){return o.from(this.instance.logout(e))},e.prototype.logoutRedirect=function(e){return o.from(this.instance.logoutRedirect(e))},e.prototype.logoutPopup=function(e){return o.from(this.instance.logoutPopup(e))},e.prototype.ssoSilent=function(e){return o.from(this.instance.ssoSilent(e))},e.prototype.getLogger=function(){return this.logger||(this.logger=this.instance.getLogger().clone(l,p)),this.logger},e.prototype.setLogger=function(e){this.logger=e.clone(l,p),this.instance.setLogger(e)},e}();g.decorators=[{type:t.Injectable}],g.ctorParameters=function(){return[{type:void 0,decorators:[{type:t.Inject,args:[c]}]},{type:r.Location}]};var h=function(e,t){var r=this;this.msalInstance=e,this.authService=t,this._msalSubject=new o.Subject,this.msalSubject$=this._msalSubject.asObservable(),this._inProgress=new o.BehaviorSubject(n.InteractionStatus.Startup),this.inProgress$=this._inProgress.asObservable(),this.msalInstance.addEventCallback((function(e){r._msalSubject.next(e);var t=n.EventMessageUtils.getInteractionStatusFromEvent(e);null!==t&&(r.authService.getLogger().verbose("BroadcastService - "+e.eventType+" results in setting inProgress to "+t),r._inProgress.next(t))}))};h.decorators=[{type:t.Injectable}],h.ctorParameters=function(){return[{type:void 0,decorators:[{type:t.Inject,args:[c]}]},{type:g}]};var v=function(){function e(e,t,r,n,o){this.msalGuardConfig=e,this.msalBroadcastService=t,this.authService=r,this.location=n,this.router=o,this.msalBroadcastService.inProgress$.subscribe()}return e.prototype.parseUrl=function(e){return this.router.parseUrl(e)},e.prototype.getDestinationUrl=function(e){this.authService.getLogger().verbose("Guard - getting destination url");var t=document.getElementsByTagName("base"),r=this.location.normalize(t.length?t[0].href:window.location.origin),n=this.location.prepareExternalUrl(e);return n.startsWith("#")?(this.authService.getLogger().verbose("Guard - destination by hash routing"),r+"/"+n):""+r+e},e.prototype.loginInteractively=function(e){var t=this,r="function"==typeof this.msalGuardConfig.authRequest?this.msalGuardConfig.authRequest(this.authService,e):Object.assign({},this.msalGuardConfig.authRequest);if(this.msalGuardConfig.interactionType===n.InteractionType.Popup)return this.authService.getLogger().verbose("Guard - logging in by popup"),this.authService.loginPopup(r).pipe(a.map((function(e){return t.authService.getLogger().verbose("Guard - login by popup successful, can activate, setting active account"),t.authService.instance.setActiveAccount(e.account),!0})));this.authService.getLogger().verbose("Guard - logging in by redirect");var o=this.getDestinationUrl(e.url);return this.authService.loginRedirect(Object.assign({redirectStartPage:o},r)).pipe(a.map((function(){return!1})))},e.prototype.activateHelper=function(e){var r=this;if(this.msalGuardConfig.interactionType!==n.InteractionType.Popup&&this.msalGuardConfig.interactionType!==n.InteractionType.Redirect)throw new n.BrowserConfigurationAuthError("invalid_interaction_type","Invalid interaction type provided to MSAL Guard. InteractionType.Popup or InteractionType.Redirect must be provided in the MsalGuardConfiguration");return this.authService.getLogger().verbose("MSAL Guard activated"),n.UrlString.hashContainsKnownProperties(window.location.hash)&&n.BrowserUtils.isInIframe()?(this.authService.getLogger().warning("Guard - redirectUri set to page with MSAL Guard. It is recommended to not set redirectUri to a page that requires authentication."),o.of(!1)):(this.msalGuardConfig.loginFailedRoute&&(this.loginFailedRoute=this.parseUrl(this.msalGuardConfig.loginFailedRoute)),this.authService.handleRedirectObservable().pipe(a.concatMap((function(){return r.authService.instance.getAllAccounts().length?(r.authService.getLogger().verbose("Guard - at least 1 account exists, can activate or load"),e&&e.url.indexOf("#")>-1&&e.url.indexOf("code=")>-1?(r.authService.getLogger().info("Guard - Hash contains known code response, stopping navigation."),o.of(!1)):o.of(!0)):e?(r.authService.getLogger().verbose("Guard - no accounts retrieved, log in required to activate"),r.loginInteractively(e)):(r.authService.getLogger().verbose("Guard - no accounts retrieved, no state, cannot load"),o.of(!1))})),a.catchError((function(){return r.authService.getLogger().verbose("Guard - error while logging in, unable to activate"),r.loginFailedRoute&&parseInt(t.VERSION.major,10)>9&&e?(r.authService.getLogger().verbose("Guard - loginFailedRoute set, redirecting"),o.of(r.loginFailedRoute)):o.of(!1)}))))},e.prototype.canActivate=function(e,t){return this.authService.getLogger().verbose("Guard - canActivate"),this.activateHelper(t)},e.prototype.canActivateChild=function(e,t){return this.authService.getLogger().verbose("Guard - canActivateChild"),this.activateHelper(t)},e.prototype.canLoad=function(){return this.authService.getLogger().verbose("Guard - canLoad"),this.activateHelper()},e}();v.decorators=[{type:t.Injectable}],v.ctorParameters=function(){return[{type:void 0,decorators:[{type:t.Inject,args:[s]}]},{type:h},{type:g},{type:r.Location},{type:i.Router}]};var f=function(){function e(e,t,r){this.msalInterceptorConfig=e,this.authService=t,this.location=r}return e.prototype.intercept=function(e,t){var r=this;if(this.msalInterceptorConfig.interactionType!==n.InteractionType.Popup&&this.msalInterceptorConfig.interactionType!==n.InteractionType.Redirect)throw new n.BrowserConfigurationAuthError("invalid_interaction_type","Invalid interaction type provided to MSAL Interceptor. InteractionType.Popup, InteractionType.Redirect must be provided in the msalInterceptorConfiguration");this.authService.getLogger().verbose("MSAL Interceptor activated");var i,c=this.getScopesForEndpoint(e.url);if(!c||0===c.length)return this.authService.getLogger().verbose("Interceptor - no scopes for endpoint"),t.handle(e);this.authService.instance.getActiveAccount()?(this.authService.getLogger().verbose("Interceptor - active account selected"),i=this.authService.instance.getActiveAccount()):(this.authService.getLogger().verbose("Interceptor - no active account, fallback to first account"),i=this.authService.instance.getAllAccounts()[0]);var s="function"==typeof this.msalInterceptorConfig.authRequest?this.msalInterceptorConfig.authRequest(this.authService,e,{account:i}):Object.assign(Object.assign({},this.msalInterceptorConfig.authRequest),{account:i});return this.authService.getLogger().info("Interceptor - "+c.length+" scopes found for endpoint"),this.authService.getLogger().infoPii("Interceptor - ["+c+"] scopes found for "+e.url),this.authService.acquireTokenSilent(Object.assign(Object.assign({},s),{scopes:c,account:i})).pipe(a.catchError((function(){return r.authService.getLogger().error("Interceptor - acquireTokenSilent rejected with error. Invoking interaction to resolve."),r.acquireTokenInteractively(s,c)})),a.switchMap((function(e){return e.accessToken?o.of(e):(r.authService.getLogger().error("Interceptor - acquireTokenSilent resolved with null access token. Known issue with B2C tenants, invoking interaction to resolve."),r.acquireTokenInteractively(s,c))})),a.switchMap((function(n){r.authService.getLogger().verbose("Interceptor - setting authorization headers");var o=e.headers.set("Authorization","Bearer "+n.accessToken),i=e.clone({headers:o});return t.handle(i)})))},e.prototype.acquireTokenInteractively=function(e,t){if(this.msalInterceptorConfig.interactionType===n.InteractionType.Popup)return this.authService.getLogger().verbose("Interceptor - error acquiring token silently, acquiring by popup"),this.authService.acquireTokenPopup(Object.assign(Object.assign({},e),{scopes:t}));this.authService.getLogger().verbose("Interceptor - error acquiring token silently, acquiring by redirect");var r=window.location.href;return this.authService.acquireTokenRedirect(Object.assign(Object.assign({},e),{scopes:t,redirectStartPage:r})),o.EMPTY},e.prototype.getScopesForEndpoint=function(e){var t=this;this.authService.getLogger().verbose("Interceptor - getting scopes for endpoint");var r=this.location.normalize(e),o=Array.from(this.msalInterceptorConfig.protectedResourceMap.keys()).filter((function(e){var o=t.location.normalize(e),i=new n.UrlString(e).getUrlComponents(),a=i.QueryString?i.AbsolutePath+"?"+i.QueryString:t.location.normalize(i.AbsolutePath);return""===a||"/*"===a?n.StringUtils.matchPattern(o,r):n.StringUtils.matchPattern(o,r)||n.StringUtils.matchPattern(a,r)}));if(o.length>0){var i=o[0];if(i)return this.msalInterceptorConfig.protectedResourceMap.get(i)}return null},e}();f.decorators=[{type:t.Injectable}],f.ctorParameters=function(){return[{type:void 0,decorators:[{type:t.Inject,args:[u]}]},{type:g},{type:r.Location}]};var d=function(){function e(e){this.authService=e}return e.prototype.ngOnInit=function(){this.authService.getLogger().verbose("MsalRedirectComponent activated"),this.authService.handleRedirectObservable().subscribe()},e}();d.decorators=[{type:t.Component,args:[{selector:"app-redirect",template:""}]}],d.ctorParameters=function(){return[{type:g}]};var y=function(){function e(){}return e.forRoot=function(t,r,n){return{ngModule:e,providers:[{provide:c,useValue:t},{provide:s,useValue:r},{provide:u,useValue:n},g]}},e}();y.decorators=[{type:t.NgModule,args:[{declarations:[d],imports:[r.CommonModule],providers:[v,h]}]}]; | ||
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("@angular/core"),require("@angular/common"),require("@azure/msal-browser"),require("rxjs"),require("@angular/router"),require("rxjs/operators")):"function"==typeof define&&define.amd?define("@azure/msal-angular",["exports","@angular/core","@angular/common","@azure/msal-browser","rxjs","@angular/router","rxjs/operators"],t):t(((e="undefined"!=typeof globalThis?globalThis:e||self).azure=e.azure||{},e.azure["msal-angular"]={}),e.ng.core,e.ng.common,e["@azure/msal-browser"],e.rxjs,e.ng.router,e.rxjs.operators)}(this,(function(e,t,r,o,n,i,a){"use strict";var c=new t.InjectionToken("MSAL_INSTANCE"),s=new t.InjectionToken("MSAL_GUARD_CONFIG"),u=new t.InjectionToken("MSAL_INTERCEPTOR_CONFIG"),l="@azure/msal-angular",p="2.0.0-beta.6",g=function(){function e(e,t){this.instance=e,this.location=t;var r=this.location.path(!0).split("#").pop();r&&(this.redirectHash="#"+r),this.instance.initializeWrapperLibrary(o.WrapperSKU.Angular,p)}return e.prototype.acquireTokenPopup=function(e){return n.from(this.instance.acquireTokenPopup(e))},e.prototype.acquireTokenRedirect=function(e){return n.from(this.instance.acquireTokenRedirect(e))},e.prototype.acquireTokenSilent=function(e){return n.from(this.instance.acquireTokenSilent(e))},e.prototype.handleRedirectObservable=function(e){return n.from(this.instance.handleRedirectPromise(e||this.redirectHash))},e.prototype.loginPopup=function(e){return n.from(this.instance.loginPopup(e))},e.prototype.loginRedirect=function(e){return n.from(this.instance.loginRedirect(e))},e.prototype.logout=function(e){return n.from(this.instance.logout(e))},e.prototype.logoutRedirect=function(e){return n.from(this.instance.logoutRedirect(e))},e.prototype.logoutPopup=function(e){return n.from(this.instance.logoutPopup(e))},e.prototype.ssoSilent=function(e){return n.from(this.instance.ssoSilent(e))},e.prototype.getLogger=function(){return this.logger||(this.logger=this.instance.getLogger().clone(l,p)),this.logger},e.prototype.setLogger=function(e){this.logger=e.clone(l,p),this.instance.setLogger(e)},e}();g.decorators=[{type:t.Injectable}],g.ctorParameters=function(){return[{type:void 0,decorators:[{type:t.Inject,args:[c]}]},{type:r.Location}]};var h=function(e,t){var r=this;this.msalInstance=e,this.authService=t,this._msalSubject=new n.Subject,this.msalSubject$=this._msalSubject.asObservable(),this._inProgress=new n.BehaviorSubject(o.InteractionStatus.Startup),this.inProgress$=this._inProgress.asObservable(),this.msalInstance.addEventCallback((function(e){r._msalSubject.next(e);var t=o.EventMessageUtils.getInteractionStatusFromEvent(e);null!==t&&(r.authService.getLogger().verbose("BroadcastService - "+e.eventType+" results in setting inProgress to "+t),r._inProgress.next(t))}))};h.decorators=[{type:t.Injectable}],h.ctorParameters=function(){return[{type:void 0,decorators:[{type:t.Inject,args:[c]}]},{type:g}]};var v=function(){function e(e,t,r,o,n){this.msalGuardConfig=e,this.msalBroadcastService=t,this.authService=r,this.location=o,this.router=n,this.msalBroadcastService.inProgress$.subscribe()}return e.prototype.parseUrl=function(e){return this.router.parseUrl(e)},e.prototype.getDestinationUrl=function(e){this.authService.getLogger().verbose("Guard - getting destination url");var t=document.getElementsByTagName("base"),r=this.location.normalize(t.length?t[0].href:window.location.origin),o=this.location.prepareExternalUrl(e);return o.startsWith("#")?(this.authService.getLogger().verbose("Guard - destination by hash routing"),r+"/"+o):""+r+e},e.prototype.loginInteractively=function(e){var t=this,r="function"==typeof this.msalGuardConfig.authRequest?this.msalGuardConfig.authRequest(this.authService,e):Object.assign({},this.msalGuardConfig.authRequest);if(this.msalGuardConfig.interactionType===o.InteractionType.Popup)return this.authService.getLogger().verbose("Guard - logging in by popup"),this.authService.loginPopup(r).pipe(a.map((function(e){return t.authService.getLogger().verbose("Guard - login by popup successful, can activate, setting active account"),t.authService.instance.setActiveAccount(e.account),!0})));this.authService.getLogger().verbose("Guard - logging in by redirect");var n=this.getDestinationUrl(e.url);return this.authService.loginRedirect(Object.assign({redirectStartPage:n},r)).pipe(a.map((function(){return!1})))},e.prototype.activateHelper=function(e){var r=this;if(this.msalGuardConfig.interactionType!==o.InteractionType.Popup&&this.msalGuardConfig.interactionType!==o.InteractionType.Redirect)throw new o.BrowserConfigurationAuthError("invalid_interaction_type","Invalid interaction type provided to MSAL Guard. InteractionType.Popup or InteractionType.Redirect must be provided in the MsalGuardConfiguration");if(this.authService.getLogger().verbose("MSAL Guard activated"),o.UrlString.hashContainsKnownProperties(window.location.hash)&&o.BrowserUtils.isInIframe())return this.authService.getLogger().warning("Guard - redirectUri set to page with MSAL Guard. It is recommended to not set redirectUri to a page that requires authentication."),n.of(!1);this.msalGuardConfig.loginFailedRoute&&(this.loginFailedRoute=this.parseUrl(this.msalGuardConfig.loginFailedRoute));var i=this.location.path(!0);return this.authService.handleRedirectObservable().pipe(a.concatMap((function(){return r.authService.instance.getAllAccounts().length?(r.authService.getLogger().verbose("Guard - at least 1 account exists, can activate or load"),e&&i.indexOf("code=")>-1?(r.authService.getLogger().info("Guard - Hash contains known code response, stopping navigation."),i.indexOf("#")>-1?n.of(r.parseUrl(r.location.path())):n.of(r.parseUrl(""))):n.of(!0)):e?(r.authService.getLogger().verbose("Guard - no accounts retrieved, log in required to activate"),r.loginInteractively(e)):(r.authService.getLogger().verbose("Guard - no accounts retrieved, no state, cannot load"),n.of(!1))})),a.catchError((function(o){return r.authService.getLogger().error("Guard - error while logging in, unable to activate"),r.authService.getLogger().errorPii("Guard - error: "+o.message),r.loginFailedRoute&&parseInt(t.VERSION.major,10)>9&&e?(r.authService.getLogger().verbose("Guard - loginFailedRoute set, redirecting"),n.of(r.loginFailedRoute)):n.of(!1)})))},e.prototype.canActivate=function(e,t){return this.authService.getLogger().verbose("Guard - canActivate"),this.activateHelper(t)},e.prototype.canActivateChild=function(e,t){return this.authService.getLogger().verbose("Guard - canActivateChild"),this.activateHelper(t)},e.prototype.canLoad=function(){return this.authService.getLogger().verbose("Guard - canLoad"),this.activateHelper()},e}();v.decorators=[{type:t.Injectable}],v.ctorParameters=function(){return[{type:void 0,decorators:[{type:t.Inject,args:[s]}]},{type:h},{type:g},{type:r.Location},{type:i.Router}]};var f=function(){function e(e,t,r){this.msalInterceptorConfig=e,this.authService=t,this.location=r}return e.prototype.intercept=function(e,t){var r=this;if(this.msalInterceptorConfig.interactionType!==o.InteractionType.Popup&&this.msalInterceptorConfig.interactionType!==o.InteractionType.Redirect)throw new o.BrowserConfigurationAuthError("invalid_interaction_type","Invalid interaction type provided to MSAL Interceptor. InteractionType.Popup, InteractionType.Redirect must be provided in the msalInterceptorConfiguration");this.authService.getLogger().verbose("MSAL Interceptor activated");var i,c=this.getScopesForEndpoint(e.url,e.method);if(!c||0===c.length)return this.authService.getLogger().verbose("Interceptor - no scopes for endpoint"),t.handle(e);this.authService.instance.getActiveAccount()?(this.authService.getLogger().verbose("Interceptor - active account selected"),i=this.authService.instance.getActiveAccount()):(this.authService.getLogger().verbose("Interceptor - no active account, fallback to first account"),i=this.authService.instance.getAllAccounts()[0]);var s="function"==typeof this.msalInterceptorConfig.authRequest?this.msalInterceptorConfig.authRequest(this.authService,e,{account:i}):Object.assign(Object.assign({},this.msalInterceptorConfig.authRequest),{account:i});return this.authService.getLogger().info("Interceptor - "+c.length+" scopes found for endpoint"),this.authService.getLogger().infoPii("Interceptor - ["+c+"] scopes found for "+e.url),this.authService.acquireTokenSilent(Object.assign(Object.assign({},s),{scopes:c,account:i})).pipe(a.catchError((function(){return r.authService.getLogger().error("Interceptor - acquireTokenSilent rejected with error. Invoking interaction to resolve."),r.acquireTokenInteractively(s,c)})),a.switchMap((function(e){return e.accessToken?n.of(e):(r.authService.getLogger().error("Interceptor - acquireTokenSilent resolved with null access token. Known issue with B2C tenants, invoking interaction to resolve."),r.acquireTokenInteractively(s,c))})),a.switchMap((function(o){r.authService.getLogger().verbose("Interceptor - setting authorization headers");var n=e.headers.set("Authorization","Bearer "+o.accessToken),i=e.clone({headers:n});return t.handle(i)})))},e.prototype.acquireTokenInteractively=function(e,t){if(this.msalInterceptorConfig.interactionType===o.InteractionType.Popup)return this.authService.getLogger().verbose("Interceptor - error acquiring token silently, acquiring by popup"),this.authService.acquireTokenPopup(Object.assign(Object.assign({},e),{scopes:t}));this.authService.getLogger().verbose("Interceptor - error acquiring token silently, acquiring by redirect");var r=window.location.href;return this.authService.acquireTokenRedirect(Object.assign(Object.assign({},e),{scopes:t,redirectStartPage:r})),n.EMPTY},e.prototype.getScopesForEndpoint=function(e,t){this.authService.getLogger().verbose("Interceptor - getting scopes for endpoint");var r=this.location.normalize(e),o=Array.from(this.msalInterceptorConfig.protectedResourceMap.keys()),n=this.matchResourcesToEndpoint(o,r);return n.length>0?this.matchScopesToEndpoint(this.msalInterceptorConfig.protectedResourceMap,n,t):null},e.prototype.matchResourcesToEndpoint=function(e,t){var r=this;return e.filter((function(e){var n=r.location.normalize(e),i=new o.UrlString(e).getUrlComponents(),a=i.QueryString?i.AbsolutePath+"?"+i.QueryString:r.location.normalize(i.AbsolutePath);return""===a||"/*"===a?o.StringUtils.matchPattern(n,t):o.StringUtils.matchPattern(n,t)||o.StringUtils.matchPattern(a,t)}))},e.prototype.matchScopesToEndpoint=function(e,t,r){var o=[];return t.forEach((function(t){var n=[],i=e.get(t);null!==i?(i.forEach((function(e){if("string"==typeof e)n.push(e);else{var t=r.toLowerCase();e.httpMethod.toLowerCase()===t&&e.scopes.forEach((function(e){n.push(e)}))}})),n.length>0&&o.push(n)):o.push(null)})),o.length>0?(o.length>1&&this.authService.getLogger().warning("Interceptor - More than 1 matching scopes for endpoint found."),o[0]):null},e}();f.decorators=[{type:t.Injectable}],f.ctorParameters=function(){return[{type:void 0,decorators:[{type:t.Inject,args:[u]}]},{type:g},{type:r.Location}]};var d=function(){function e(e){this.authService=e}return e.prototype.ngOnInit=function(){this.authService.getLogger().verbose("MsalRedirectComponent activated"),this.authService.handleRedirectObservable().subscribe()},e}();d.decorators=[{type:t.Component,args:[{selector:"app-redirect",template:""}]}],d.ctorParameters=function(){return[{type:g}]};var y=function(){function e(){}return e.forRoot=function(t,r,o){return{ngModule:e,providers:[{provide:c,useValue:t},{provide:s,useValue:r},{provide:u,useValue:o},g]}},e}();y.decorators=[{type:t.NgModule,args:[{declarations:[d],imports:[r.CommonModule],providers:[v,h]}]}]; | ||
/*! ***************************************************************************** | ||
@@ -16,3 +16,3 @@ Copyright (c) Microsoft Corporation. | ||
***************************************************************************** */ | ||
var b=function(e,t){return(b=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])})(e,t)};function S(e,t,r,n){return new(r||(r=Promise))((function(o,i){function a(e){try{s(n.next(e))}catch(e){i(e)}}function c(e){try{s(n.throw(e))}catch(e){i(e)}}function s(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,c)}s((n=n.apply(e,t||[])).next())}))}function m(e,t){var r,n,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:c(0),throw:c(1),return:c(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function c(i){return function(c){return function(i){if(r)throw new TypeError("Generator is already executing.");for(;a;)try{if(r=1,n&&(o=2&i[0]?n.return:i[0]?n.throw||((o=n.return)&&o.call(n),0):n.next)&&!(o=o.call(n,i[1])).done)return o;switch(n=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,n=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(o=a.trys,(o=o.length>0&&o[o.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]<o[3])){a.label=i[1];break}if(6===i[0]&&a.label<o[1]){a.label=o[1],o=i;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(i);break}o[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(e){i=[6,e],n=0}finally{r=o=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,c])}}}Object.create;Object.create;var I=function(e){function t(t,r,n){var o=e.call(this)||this;return o.authService=t,o.router=r,o.location=n,o}return function(e,t){function r(){this.constructor=e}b(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}(t,e),t.prototype.navigateInternal=function(e,t){return S(this,void 0,void 0,(function(){var r,o;return m(this,(function(i){return this.authService.getLogger().verbose("MsalCustomNavigationClient called"),r=new n.UrlString(e).getUrlComponents(),o=r.QueryString?r.AbsolutePath+"?"+r.QueryString:this.location.normalize(r.AbsolutePath),this.authService.getLogger().verbosePii("MsalCustomNavigationClient - navigating to newUrl: "+o),this.router.navigateByUrl(o,{replaceUrl:t.noHistory}),[2,Promise.resolve(!1)]}))}))},t}(n.NavigationClient);I.decorators=[{type:t.Injectable}],I.ctorParameters=function(){return[{type:g},{type:i.Router},{type:r.Location}]},e.MSAL_GUARD_CONFIG=s,e.MSAL_INSTANCE=c,e.MSAL_INTERCEPTOR_CONFIG=u,e.MsalBroadcastService=h,e.MsalCustomNavigationClient=I,e.MsalGuard=v,e.MsalInterceptor=f,e.MsalModule=y,e.MsalRedirectComponent=d,e.MsalService=g,Object.defineProperty(e,"__esModule",{value:!0})})); | ||
var S=function(e,t){return(S=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])})(e,t)};function b(e,t,r,o){return new(r||(r=Promise))((function(n,i){function a(e){try{s(o.next(e))}catch(e){i(e)}}function c(e){try{s(o.throw(e))}catch(e){i(e)}}function s(e){var t;e.done?n(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,c)}s((o=o.apply(e,t||[])).next())}))}function m(e,t){var r,o,n,i,a={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return i={next:c(0),throw:c(1),return:c(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function c(i){return function(c){return function(i){if(r)throw new TypeError("Generator is already executing.");for(;a;)try{if(r=1,o&&(n=2&i[0]?o.return:i[0]?o.throw||((n=o.return)&&n.call(o),0):o.next)&&!(n=n.call(o,i[1])).done)return n;switch(o=0,n&&(i=[2&i[0],n.value]),i[0]){case 0:case 1:n=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,o=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(!(n=a.trys,(n=n.length>0&&n[n.length-1])||6!==i[0]&&2!==i[0])){a=0;continue}if(3===i[0]&&(!n||i[1]>n[0]&&i[1]<n[3])){a.label=i[1];break}if(6===i[0]&&a.label<n[1]){a.label=n[1],n=i;break}if(n&&a.label<n[2]){a.label=n[2],a.ops.push(i);break}n[2]&&a.ops.pop(),a.trys.pop();continue}i=t.call(e,a)}catch(e){i=[6,e],o=0}finally{r=n=0}if(5&i[0])throw i[1];return{value:i[0]?i[1]:void 0,done:!0}}([i,c])}}}Object.create;Object.create;var I=function(e){function t(t,r,o){var n=e.call(this)||this;return n.authService=t,n.router=r,n.location=o,n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function r(){this.constructor=e}S(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}(t,e),t.prototype.navigateInternal=function(e,t){return b(this,void 0,void 0,(function(){var r,n;return m(this,(function(i){return this.authService.getLogger().verbose("MsalCustomNavigationClient called"),r=new o.UrlString(e).getUrlComponents(),n=r.QueryString?r.AbsolutePath+"?"+r.QueryString:this.location.normalize(r.AbsolutePath),this.authService.getLogger().verbosePii("MsalCustomNavigationClient - navigating to newUrl: "+n),t.noHistory?window.location.replace(n):this.router.navigateByUrl(n,{replaceUrl:t.noHistory}),[2,Promise.resolve(t.noHistory)]}))}))},t}(o.NavigationClient);I.decorators=[{type:t.Injectable}],I.ctorParameters=function(){return[{type:g},{type:i.Router},{type:r.Location}]},e.MSAL_GUARD_CONFIG=s,e.MSAL_INSTANCE=c,e.MSAL_INTERCEPTOR_CONFIG=u,e.MsalBroadcastService=h,e.MsalCustomNavigationClient=I,e.MsalGuard=v,e.MsalInterceptor=f,e.MsalModule=y,e.MsalRedirectComponent=d,e.MsalService=g,Object.defineProperty(e,"__esModule",{value:!0})})); | ||
//# sourceMappingURL=azure-msal-angular.umd.min.js.map |
@@ -5,1 +5,2 @@ import { InjectionToken } from "@angular/core"; | ||
export declare const MSAL_INTERCEPTOR_CONFIG: InjectionToken<string>; | ||
//# sourceMappingURL=constants.d.ts.map |
@@ -5,2 +5,2 @@ /** | ||
export * from './public-api'; | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYXp1cmUtbXNhbC1hbmd1bGFyLmpzIiwic291cmNlUm9vdCI6IkM6L1VzZXJzL2phbnV0dGVyL0NvZGUvbWljcm9zb2Z0LWF1dGhlbnRpY2F0aW9uLWxpYnJhcnktZm9yLWpzL2xpYi9tc2FsLWFuZ3VsYXIvc3JjLyIsInNvdXJjZXMiOlsiYXp1cmUtbXNhbC1hbmd1bGFyLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBOztHQUVHO0FBRUgsY0FBYyxjQUFjLENBQUMiLCJzb3VyY2VzQ29udGVudCI6WyIvKipcbiAqIEdlbmVyYXRlZCBidW5kbGUgaW5kZXguIERvIG5vdCBlZGl0LlxuICovXG5cbmV4cG9ydCAqIGZyb20gJy4vcHVibGljLWFwaSc7XG4iXX0= | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYXp1cmUtbXNhbC1hbmd1bGFyLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vc3JjL2F6dXJlLW1zYWwtYW5ndWxhci50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQTs7R0FFRztBQUVILGNBQWMsY0FBYyxDQUFDIiwic291cmNlc0NvbnRlbnQiOlsiLyoqXG4gKiBHZW5lcmF0ZWQgYnVuZGxlIGluZGV4LiBEbyBub3QgZWRpdC5cbiAqL1xuXG5leHBvcnQgKiBmcm9tICcuL3B1YmxpYy1hcGknO1xuIl19 |
@@ -9,2 +9,2 @@ /* | ||
export const MSAL_INTERCEPTOR_CONFIG = new InjectionToken("MSAL_INTERCEPTOR_CONFIG"); | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29uc3RhbnRzLmpzIiwic291cmNlUm9vdCI6IkM6L1VzZXJzL2phbnV0dGVyL0NvZGUvbWljcm9zb2Z0LWF1dGhlbnRpY2F0aW9uLWxpYnJhcnktZm9yLWpzL2xpYi9tc2FsLWFuZ3VsYXIvc3JjLyIsInNvdXJjZXMiOlsiY29uc3RhbnRzLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBOzs7R0FHRztBQUVILE9BQU8sRUFBRSxjQUFjLEVBQUUsTUFBTSxlQUFlLENBQUM7QUFFL0MsTUFBTSxDQUFDLE1BQU0sYUFBYSxHQUFHLElBQUksY0FBYyxDQUFTLGVBQWUsQ0FBQyxDQUFDO0FBR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gICAgIHRoaXMuX2luUHJvZ3Jlc3MgPSBuZXcgQmVoYXZpb3JTdWJqZWN0PEludGVyYWN0aW9uU3RhdHVzPihJbnRlcmFjdGlvblN0YXR1cy5TdGFydHVwKTtcclxuICAgICAgICB0aGlzLmluUHJvZ3Jlc3MkID0gdGhpcy5faW5Qcm9ncmVzcy5hc09ic2VydmFibGUoKTtcclxuXHJcbiAgICAgICAgdGhpcy5tc2FsSW5zdGFuY2UuYWRkRXZlbnRDYWxsYmFjaygobWVzc2FnZTogRXZlbnRNZXNzYWdlKSA9PiB7XHJcbiAgICAgICAgICAgIHRoaXMuX21zYWxTdWJqZWN0Lm5leHQobWVzc2FnZSk7XHJcbiAgICAgICAgICAgIGNvbnN0IHN0YXR1cyA9IEV2ZW50TWVzc2FnZVV0aWxzLmdldEludGVyYWN0aW9uU3RhdHVzRnJvbUV2ZW50KG1lc3NhZ2UpO1xyXG4gICAgICAgICAgICBpZiAoc3RhdHVzICE9PSBudWxsKSB7XHJcbiAgICAgICAgICAgICAgICB0aGlzLmF1dGhTZXJ2aWNlLmdldExvZ2dlcigpLnZlcmJvc2UoYEJyb2FkY2FzdFNlcnZpY2UgLSAke21lc3NhZ2UuZXZlbnRUeXBlfSByZXN1bHRzIGluIHNldHRpbmcgaW5Qcm9ncmVzcyB0byAke3N0YXR1c31gKTtcclxuICAgICAgICAgICAgICAgIHRoaXMuX2luUHJvZ3Jlc3MubmV4dChzdGF0dXMpO1xyXG4gICAgICAgICAgICB9XHJcbiAgICAgICAgfSk7XHJcbiAgICB9XHJcbn1cclxuIl19 |
@@ -5,2 +5,3 @@ /* | ||
*/ | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibXNhbC5ndWFyZC5jb25maWcuanMiLCJzb3VyY2VSb290IjoiQzovVXNlcnMvamFudXR0ZXIvQ29kZS9taWNyb3NvZnQtYXV0aGVudGljYXRpb24tbGlicmFyeS1mb3ItanMvbGliL21zYWwtYW5ndWxh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lcXVlc3Q/OiBNc2FsR3VhcmRBdXRoUmVxdWVzdCB8ICgoYXV0aFNlcnZpY2U6IE1zYWxTZXJ2aWNlLCBzdGF0ZTogUm91dGVyU3RhdGVTbmFwc2hvdCkgPT4gTXNhbEd1YXJkQXV0aFJlcXVlc3QpO1xyXG4gICAgbG9naW5GYWlsZWRSb3V0ZT86IHN0cmluZztcclxufTtcclxuIl19 |
@@ -100,2 +100,4 @@ /* | ||
} | ||
// Capture current path before it gets changed by handleRedirectObservable | ||
const currentPath = this.location.path(true); | ||
return this.authService.handleRedirectObservable() | ||
@@ -112,10 +114,16 @@ .pipe(concatMap(() => { | ||
this.authService.getLogger().verbose("Guard - at least 1 account exists, can activate or load"); | ||
// Prevent navigating the app to /#code= | ||
if (state && state.url.indexOf("#") > -1 && state.url.indexOf("code=") > -1) { | ||
// Prevent navigating the app to /#code= or /code= | ||
if (state && currentPath.indexOf("code=") > -1) { | ||
this.authService.getLogger().info("Guard - Hash contains known code response, stopping navigation."); | ||
return of(false); | ||
// Path routing (navigate to current path without hash) | ||
if (currentPath.indexOf("#") > -1) { | ||
return of(this.parseUrl(this.location.path())); | ||
} | ||
// Hash routing (navigate to root path) | ||
return of(this.parseUrl("")); | ||
} | ||
return of(true); | ||
}), catchError(() => { | ||
this.authService.getLogger().verbose("Guard - error while logging in, unable to activate"); | ||
}), catchError((error) => { | ||
this.authService.getLogger().error("Guard - error while logging in, unable to activate"); | ||
this.authService.getLogger().errorPii(`Guard - error: ${error.message}`); | ||
/** | ||
@@ -156,2 +164,2 @@ * If a loginFailedRoute is set, checks to see if Angular 10+ is used and state is passed in before returning route | ||
]; | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibXNhbC5ndWFyZC5qcyIsInNvdXJjZVJvb3QiOiJDOi9Vc2Vycy9qYW51dHRlci9Db2RlL21pY3Jvc29mdC1hdXRoZW50aWNhdGlvbi1saWJyYXJ5LWZvci1qcy9saWIvbXNhbC1hbm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BhY3RpdmUgYWNjb3VudFwiKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgdGhpcy5hdXRoU2VydmljZS5pbnN0YW5jZS5zZXRBY3RpdmVBY2NvdW50KHJlc3BvbnNlLmFjY291bnQpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gdHJ1ZTtcclxuICAgICAgICAgICAgICAgICAgICB9KVxyXG4gICAgICAgICAgICAgICAgKTtcclxuICAgICAgICB9XHJcblxyXG4gICAgICAgIHRoaXMuYXV0aFNlcnZpY2UuZ2V0TG9nZ2VyKCkudmVyYm9zZShcIkd1YXJkIC0gbG9nZ2luZyBpbiBieSByZWRpcmVjdFwiKTtcclxuICAgICAgICBjb25zdCByZWRpcmVjdFN0YXJ0UGFnZSA9IHRoaXMuZ2V0RGVzdGluYXRpb25Vcmwoc3RhdGUudXJsKTtcclxuICAgICAgICByZXR1cm4gdGhpcy5hdXRoU2VydmljZS5sb2dpblJlZGlyZWN0KHtcclxuICAgICAgICAgICAgcmVkaXJlY3RTdGFydFBhZ2UsXHJcbiAgICAgICAgICAgIC4uLmF1dGhSZXF1ZXN0XHJcbiAgICAgICAgfSBhcyBSZWRpcmVjdFJlcXVlc3QpXHJcbiAgICAgICAgICAgIC5waXBlKFxyXG4gICAgICAgICAgICAgICAgbWFwKCgpID0+IGZhbHNlKVxyXG4gICAgICAgICAgICApO1xyXG4gICAgfVxyXG5cclxuICAgIC8qKlxyXG4gICAgICogSGVscGVyIHdoaWNoIGNoZWNrcyBmb3IgdGhlIGNvcnJlY3QgaW50ZXJhY3Rpb24gdHlwZSwgcHJldmVudHMgcGFnZSB3aXRoIEd1YXJkIHRvIGJlIHNldCBhcyByZWlkcmVjdCwgYW5kIGNhbGxzIGhhbmRsZVJlZGlyZWN0T2JzZXJ2YWJsZVxyXG4gICAgICogQHBhcmFtIHN0YXRlIFxyXG4gICAgICovXHJcbiAgICBwcml2YXRlIGFjdGl2YXRlSGVscGVyKHN0YXRlPzogUm91dGVyU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IGlmIChzdGF0ZSkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgdGhpcy5hdXRoU2VydmljZS5nZXRMb2dnZXIoKS52ZXJib3NlKFwiR3VhcmQgLSBubyBhY2NvdW50cyByZXRyaWV2ZWQsIGxvZyBpbiByZXF1aXJlZCB0byBhY3RpdmF0ZVwiKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiB0aGlzLmxvZ2luSW50ZXJhY3RpdmVseShzdGF0ZSk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIH0gXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHRoaXMuYXV0aFNlcnZpY2UuZ2V0TG9nZ2VyKCkudmVyYm9zZShcIkd1YXJkIC0gbm8gYWNjb3VudHMgcmV0cmlldmVkLCBubyBzdGF0ZSwgY2Fubm90IGxvYWRcIik7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBvZihmYWxzZSk7XHJcbiAgICAgICAgICAgICAgICAgICAgfVxyXG5cclxuICAgICAgICAgICAgICAgICAgICB0aGlzLmF1dGhTZXJ2aWNlLmdldExvZ2dlcigpLnZlcmJvc2UoXCJHdWFyZCAtIGF0IGxlYXN0IDEgYWNjb3VudCBleGlzdHMsIGNhbiBhY3RpdmF0ZSBvciBsb2FkXCIpO1xyXG5cclxuICAgICAgICAgICAgICAgICAgICAvLyBQcmV2ZW50IG5hdmlnYXRpbmcgdGhlIGFwcCB0byAvI2NvZGU9XHJcbiAgICAgICAgICAgICAgICAgICAgaWYgKHN0YXRlICYmIHN0YXRlLnVybC5pbmRleE9mKFwiI1wiKSA+IC0xICYmIHN0YXRlLnVybC5pbmRleE9mKFwiY29kZT1cIikgPiAtMSkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB0aGlzLmF1dGhTZXJ2aWNlLmdldExvZ2dlcigpLmluZm8oXCJHdWFyZCAtIEhhc2ggY29udGFpbnMga25vd24gY29kZSByZXNwb25zZSwgc3RvcHBpbmcgbmF2aWdhdGlvbi5cIik7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBvZihmYWxzZSk7XHJcbiAgICAgICAgICAgICAgICAgICAgfVxyXG5cclxuICAgICAgICAgICAgICAgICAgICByZXR1cm4gb2YodHJ1ZSk7XHJcblxyXG4gICAgICAgICAgICAgICAgfSksXHJcbiAgICAgICAgICAgICAgICBjYXRjaEVycm9yKCgpID0+IHtcclxuICAgICAgICAgICAgICAgICAgICB0aGlzLmF1dGhTZXJ2aWNlLmdldExvZ2dlcigpLnZlcmJvc2UoXCJHdWFyZCAtIGVycm9yIHdoaWxlIGxvZ2dpbmcgaW4sIHVuYWJsZSB0byBhY3RpdmF0ZVwiKTtcclxuICAgICAgICAgICAgICAgICAgICAvKipcclxuICAgICAgICAgICAgICAgICAgICAgKiBJZiBhIGxvZ2luRmFpbGVkUm91dGUgaXMgc2V0LCBjaGVja3MgdG8gc2VlIGlmIEFuZ3VsYXIgMTArIGlzIHVzZWQgYW5kIHN0YXRlIGlzIHBhc3NlZCBpbiBiZWZvcmUgcmV0dXJuaW5nIHJvdXRlXHJcbiAgICAgICAgICAgICAgICAgICAgICogQXBwcyB1c2luZyBBbmd1bGFyIDkgd2lsbCByZWNlaXZlIG9mKGZhbHNlKSBpbiBjYW5Mb2FkIGludGVyZmFjZSwgYXMgaXQgZG9lcyBub3Qgc3VwcG9ydCBVcmxUcmVlIHJldHVybiB0eXBlc1xyXG4gICAgICAgICAgICAgICAgICAgICAqL1xyXG4gICAgICAgICAgICAgICAgICAgIGlmICh0aGlzLmxvZ2luRmFpbGVkUm91dGUgJiYgcGFyc2VJbnQoVkVSU0lPTi5tYWpvciwgMTApID4gOSAmJiBzdGF0ZSkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB0aGlzLmF1dGhTZXJ2aWNlLmdldExvZ2dlcigpLnZlcmJvc2UoXCJHdWFyZCAtIGxvZ2luRmFpbGVkUm91dGUgc2V0LCByZWRpcmVjdGluZ1wiKTtccl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ICAgICAgdGhpcy5hdXRoU2VydmljZS5nZXRMb2dnZXIoKS52ZXJib3NlKFwiR3VhcmQgLSBubyBhY2NvdW50cyByZXRyaWV2ZWQsIG5vIHN0YXRlLCBjYW5ub3QgbG9hZFwiKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIG9mKGZhbHNlKTtcclxuICAgICAgICAgICAgICAgICAgICB9XHJcblxyXG4gICAgICAgICAgICAgICAgICAgIHRoaXMuYXV0aFNlcnZpY2UuZ2V0TG9nZ2VyKCkudmVyYm9zZShcIkd1YXJkIC0gYXQgbGVhc3QgMSBhY2NvdW50IGV4aXN0cywgY2FuIGFjdGl2YXRlIG9yIGxvYWRcIik7XHJcblxyXG4gICAgICAgICAgICAgICAgICAgIC8vIFByZXZlbnQgbmF2aWdhdGluZyB0aGUgYXBwIHRvIC8jY29kZT0gb3IgL2NvZGU9XHJcbiAgICAgICAgICAgICAgICAgICAgaWYgKHN0YXRlICYmIGN1cnJlbnRQYXRoLmluZGV4T2YoXCJjb2RlPVwiKT4gLTEpIHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgdGhpcy5hdXRoU2VydmljZS5nZXRMb2dnZXIoKS5pbmZvKFwiR3VhcmQgLSBIYXNoIGNvbnRhaW5zIGtub3duIGNvZGUgcmVzcG9uc2UsIHN0b3BwaW5nIG5hdmlnYXRpb24uXCIpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBcclxuICAgICAgICAgICAgICAgICAgICAgICAgLy8gUGF0aCByb3V0aW5nIChuYXZpZ2F0ZSB0byBjdXJyZW50IHBhdGggd2l0aG91dCBoYXNoKVxyXG4gICAgICAgICAgICAgICAgICAgICAgICBpZiAoY3VycmVudFBhdGguaW5kZXhPZihcIiNcIikgPiAtMSkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIG9mKHRoaXMucGFyc2VVcmwodGhpcy5sb2NhdGlvbi5wYXRoKCkpKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgICAgICBcclxuICAgICAgICAgICAgICAgICAgICAgICAgLy8gSGFzaCByb3V0aW5nIChuYXZpZ2F0ZSB0byByb290IHBhdGgpXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiBvZih0aGlzLnBhcnNlVXJsKFwiXCIpKTtcclxuICAgICAgICAgICAgICAgICAgICB9XHJcblxyXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiBvZih0cnVlKTtcclxuXHJcbiAgICAgICAgICAgICAgICB9KSxcclxuICAgICAgICAgICAgICAgIGNhdGNoRXJyb3IoKGVycm9yOiBFcnJvcikgPT4ge1xyXG4gICAgICAgICAgICAgICAgICAgIHRoaXMuYXV0aFNlcnZpY2UuZ2V0TG9nZ2VyKCkuZXJyb3IoXCJHdWFyZCAtIGVycm9yIHdoaWxlIGxvZ2dpbmcgaW4sIHVuYWJsZSB0byBhY3RpdmF0ZVwiKTtcclxuICAgICAgICAgICAgICAgICAgICB0aGlzLmF1dGhTZXJ2aWNlLmdldExvZ2dlcigpLmVycm9yUGlpKGBHdWFyZCAtIGVycm9yOiAke2Vycm9yLm1lc3NhZ2V9YCk7XHJcbiAgICAgICAgICAgICAgICAgICAgLyoqXHJcbiAgICAgICAgICAgICAgICAgICAgICogSWYgYSBsb2dpbkZhaWxlZFJvdXRlIGlzIHNldCwgY2hlY2tzIHRvIHNlZSBpZiBBbmd1bGFyIDEwKyBpcyB1c2VkIGFuZCBzdGF0ZSBpcyBwYXNzZWQgaW4gYmVmb3JlIHJldHVybmluZyByb3V0ZVxyXG4gICAgICAgICAgICAgICAgICAgICAqIEFwcHMgdXNpbmcgQW5ndWxhciA5IHdpbGwgcmVjZWl2ZSBvZihmYWxzZSkgaW4gY2FuTG9hZCBpbnRlcmZhY2UsIGFzIGl0IGRvZXMgbm90IHN1cHBvcnQgVXJsVHJlZSByZXR1cm4gdHlwZXNcclxuICAgICAgICAgICAgICAgICAgICAgKi9cclxuICAg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c3Q6IE1zYWxJbnRlcmNlcHRvckF1dGhSZXF1ZXN0KSA9PiBNc2FsSW50ZXJjZXB0b3JBdXRoUmVxdWVzdCk7XHJcbn07XHJcblxyXG5leHBvcnQgdHlwZSBQcm90ZWN0ZWRSZXNvdXJjZVNjb3BlcyA9IHtcclxuICAgIGh0dHBNZXRob2Q6IHN0cmluZyxcclxuICAgIHNjb3BlczogQXJyYXk8c3RyaW5nPlxyXG59O1xyXG4iXX0= |
@@ -24,3 +24,3 @@ /* | ||
this.authService.getLogger().verbose("MSAL Interceptor activated"); | ||
const scopes = this.getScopesForEndpoint(req.url); | ||
const scopes = this.getScopesForEndpoint(req.url, req.method); | ||
// If no scopes for endpoint, does not acquire token | ||
@@ -83,6 +83,7 @@ if (!scopes || scopes.length === 0) { | ||
* @param endpoint Url of the request | ||
* @param endpoint Http method of the request | ||
* @returns Array of scopes, or null if not found | ||
* | ||
*/ | ||
getScopesForEndpoint(endpoint) { | ||
getScopesForEndpoint(endpoint, httpMethod) { | ||
this.authService.getLogger().verbose("Interceptor - getting scopes for endpoint"); | ||
@@ -92,3 +93,17 @@ // Ensures endpoints and protected resources compared are normalized | ||
const protectedResourcesArray = Array.from(this.msalInterceptorConfig.protectedResourceMap.keys()); | ||
const keyMatchesEndpointArray = protectedResourcesArray.filter(key => { | ||
const matchingProtectedResources = this.matchResourcesToEndpoint(protectedResourcesArray, normalizedEndpoint); | ||
if (matchingProtectedResources.length > 0) { | ||
return this.matchScopesToEndpoint(this.msalInterceptorConfig.protectedResourceMap, matchingProtectedResources, httpMethod); | ||
} | ||
return null; | ||
} | ||
/** | ||
* Finds resource endpoints that match request endpoint | ||
* @param protectedResourcesArray | ||
* @param endpoint | ||
* @param location | ||
* @returns | ||
*/ | ||
matchResourcesToEndpoint(protectedResourcesEndpoints, endpoint) { | ||
return protectedResourcesEndpoints.filter(key => { | ||
const normalizedKey = this.location.normalize(key); | ||
@@ -100,15 +115,56 @@ // Normalized key should include query strings if applicable | ||
if (relativeNormalizedKey === "" || relativeNormalizedKey === "/*") { | ||
return StringUtils.matchPattern(normalizedKey, normalizedEndpoint); | ||
return StringUtils.matchPattern(normalizedKey, endpoint); | ||
} | ||
else { | ||
// Matching endpoint with both protected resource and relative url of protected resource | ||
return StringUtils.matchPattern(normalizedKey, normalizedEndpoint) || StringUtils.matchPattern(relativeNormalizedKey, normalizedEndpoint); | ||
return StringUtils.matchPattern(normalizedKey, endpoint) || StringUtils.matchPattern(relativeNormalizedKey, endpoint); | ||
} | ||
}); | ||
// Process all protected resources and send the first matched resource | ||
if (keyMatchesEndpointArray.length > 0) { | ||
const keyForEndpoint = keyMatchesEndpointArray[0]; | ||
if (keyForEndpoint) { | ||
return this.msalInterceptorConfig.protectedResourceMap.get(keyForEndpoint); | ||
} | ||
/** | ||
* Finds scopes from first matching endpoint with HTTP method that matches request | ||
* @param protectedResourceMap Protected resource map | ||
* @param endpointArray Array of resources that match request endpoint | ||
* @param httpMethod Http method of the request | ||
* @returns | ||
*/ | ||
matchScopesToEndpoint(protectedResourceMap, endpointArray, httpMethod) { | ||
const allMatchedScopes = []; | ||
// Check each matched endpoint for matching HttpMethod and scopes | ||
endpointArray.forEach(matchedEndpoint => { | ||
const scopesForEndpoint = []; | ||
const methodAndScopesArray = protectedResourceMap.get(matchedEndpoint); | ||
// Return if resource is unprotected | ||
if (methodAndScopesArray === null) { | ||
allMatchedScopes.push(null); | ||
return; | ||
} | ||
methodAndScopesArray.forEach(entry => { | ||
// Entry is either array of scopes or ProtectedResourceScopes object | ||
if (typeof entry === "string") { | ||
scopesForEndpoint.push(entry); | ||
} | ||
else { | ||
// Ensure methods being compared are normalized | ||
const normalizedRequestMethod = httpMethod.toLowerCase(); | ||
const normalizedResourceMethod = entry.httpMethod.toLowerCase(); | ||
// Method in protectedResourceMap matches request http method | ||
if (normalizedResourceMethod === normalizedRequestMethod) { | ||
entry.scopes.forEach(scope => { | ||
scopesForEndpoint.push(scope); | ||
}); | ||
} | ||
} | ||
}); | ||
// Only add to all scopes if scopes for endpoint and method is found | ||
if (scopesForEndpoint.length > 0) { | ||
allMatchedScopes.push(scopesForEndpoint); | ||
} | ||
}); | ||
if (allMatchedScopes.length > 0) { | ||
if (allMatchedScopes.length > 1) { | ||
this.authService.getLogger().warning("Interceptor - More than 1 matching scopes for endpoint found."); | ||
} | ||
// Returns scopes for first matching endpoint | ||
return allMatchedScopes[0]; | ||
} | ||
@@ -126,2 +182,2 @@ return null; | ||
]; | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibXNhbC5pbnRlcmNlcHRvci5qcyIsInNvdXJjZVJvb3QiOiJDOi9Vc2Vycy9qYW51dHRlci9Db2RlL21pY3Jvc29mdC1hdXRoZW50aWNhdGlvbi1saWJyYXJ5LWZvci1qcy9saWIvbXNhbC1hbmd1bGFyL3NyYy8iLCJzb3VyY2VzIjpbIm1zYWwuaW50ZXJjZXB0b3IudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUE7OztHQUdHO0FBUUgsT0FBTyxFQUFFLFFBQVEsRUFBRSxNQUFNLGlCQUFpQixDQUFDO0FBQzNDLE9BQU8sRUFBYyxLQUFLLEVBQUUsRUFBRSxFQUFFLE1BQU0sTUFBTSxDQUFDO0FBQzdDLE9BQU8sRUFBRSxTQUFTLEVBQUUsVUFBVSxFQUFFLE1BQU0sZ0JBQWdCLENBQUM7QUFDdkQsT0FBTyxFQUFFLFdBQVcsRUFBRSxNQUFNLGdCQUFnQixDQUFDO0FBQzdDLE9BQU8sRUFBcUMsNkJBQTZCLEVBQUUsZUFBZSxFQUFFLFdBQVcsRUFBRSxTQUFTLEVBQUUsTUFBTSxxQkFBcUIsQ0FBQztBQUNoSixPQUFPLEVBQUUsVUFBVSxFQUFFLE1BQU0sRUFBRSxNQUFNLGVBQWUsQ0FBQztBQUNuRCxPQUFPLEVBQUUsdUJBQXVCLEVBQUUsTUFBTSxhQUFhLENBQUM7QUFJdEQsTUFBTSxPQUFP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b2x2ZWQgd2l0aCBudWxsIGFjY2VzcyB0b2tlbi4gS25vd24gaXNzdWUgd2l0aCBCMkMgdGVuYW50cywgaW52b2tpbmcgaW50ZXJhY3Rpb24gdG8gcmVzb2x2ZS5cIik7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiB0aGlzLmFjcXVpcmVUb2tlbkludGVyYWN0aXZlbHkoYXV0aFJlcXVlc3QsIHNjb3Blcyk7XHJcbiAgICAgICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiBvZihyZXN1bHQpO1xyXG4gICAgICAgICAgICAgICAgfSksXHJcbiAgICAgICAgICAgICAgICBzd2l0Y2hNYXAoKHJlc3VsdDogQXV0aGVudGljYXRpb25SZXN1bHQpID0+IHtcclxuICAgICAgICAgICAgICAgICAgICB0aGlzLmF1dGhTZXJ2aWNlLmdldExvZ2dlcigpLnZlcmJvc2UoXCJJbnRlcmNlcHRvciAtIHNldHRpbmcgYXV0aG9yaXphdGlvbiBoZWFkZXJzXCIpO1xyXG4gICAgICAgICAgICAgICAgICAgIGNvbnN0IGhlYWRlcnMgPSByZXEuaGVhZGVyc1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAuc2V0KFwiQXV0aG9yaXphdGlvblwiLCBgQmVhcmVyICR7cmVzdWx0LmFjY2Vzc1Rva2VufWApO1xyXG5cclxuICAgICAgICAgICAgICAgICAgICBjb25zdCByZXF1ZXN0Q2xvbmUgPSByZXEuY2xvbmUoe2hlYWRlcnN9KTtcclxuICAgICAgICAgICAgICAgICAgICByZXR1cm4gbmV4dC5oYW5kbGUocmVxdWVzdENsb25lKTtcclxuICAgICAgICAgICAgICAgIH0pXHJcbiAgICAgICAgICAgICk7XHJcbiAgICB9XHJcblxyXG4gICAgLyoqXHJcbiAgICAgKiBJbnZva2UgaW50ZXJhY3Rpb24gZm9yIHRoZSBnaXZlbiBzZXQgb2Ygc2NvcGVzXHJcbiAgICAgKiBAcGFyYW0gc2Nvc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CByZXNvdXJjZVxyXG4gICAgICAgICAgICAgICAgcmV0dXJuIFN0cmluZ1V0aWxzLm1hdGNoUGF0dGVybihub3JtYWxpemVkS2V5LCBub3JtYWxpemVkRW5kcG9pbnQpIHx8IFN0cmluZ1V0aWxzLm1hdGNoUGF0dGVybihyZWxhdGl2ZU5vcm1hbGl6ZWRLZXksIG5vcm1hbGl6ZWRFbmRwb2ludCk7XHJcbiAgICAgICAgICAgIH1cclxuICAgICAgICB9KTtcclxuXHJcbiAgICAgICAgLy8gUHJvY2VzcyBhbGwgcHJvdGVjdGVkIHJlc291cmNlcyBhbmQgc2VuZCB0aGUgZmlyc3QgbWF0Y2hlZCByZXNvdXJjZVxyXG4gICAgICAgIGlmIChrZXlNYXRjaGVzRW5kcG9pbnRBcnJheS5sZW5ndGggPiAwKSB7XHJcbiAgICAgICAgICAgIGNvbnN0IGtleUZvckVuZHBvaW50ID0ga2V5TWF0Y2hlc0VuZHBvaW50QXJyYXlbMF07XHJcbiAgICAgICAgICAgIGlmIChrZXlGb3JFbmRwb2ludCkge1xyXG4gICAgICAgICAgICAgICAgcmV0dXJuIHRoaXMubXNhbEludGVyY2VwdG9yQ29uZmlnLnByb3RlY3RlZFJlc291cmNlTWFwLmdldChrZXlGb3JFbmRwb2ludCk7XHJcbiAgICAgICAgICAgIH1cclxuICAgICAgICB9XHJcblxyXG4gICAgICAgIHJldHVybiBudWxsO1xyXG4gICAgfVxyXG5cclxufVxyXG4iXX0= | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibXNhbC5pbnRlcmNlcHRvci5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uL3NyYy9tc2FsLmludGVyY2VwdG9yLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBOzs7R0FHRztBQVFILE9BQU8sRUFBRSxRQUFRLEVBQUUsTUFBTSxpQkFBaUIsQ0FBQztBQUMzQyxPQUFPL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ICAgICAgIHRoaXMuYXV0aFNlcnZpY2UuZ2V0TG9nZ2VyKCkuZXJyb3IoXCJJbnRlcmNlcHRvciAtIGFjcXVpcmVUb2tlblNpbGVudCByZXNvbHZlZCB3aXRoIG51bGwgYWNjZXNzIHRva2VuLiBLbm93biBpc3N1ZSB3aXRoIEIyQyB0ZW5hbnRzLCBpbnZva2luZyBpbnRlcmFjdGlvbiB0byByZXNvbHZlLlwiKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIHRoaXMuYWNxdWlyZVRva2VuSW50ZXJhY3RpdmVseShhdXRoUmVxdWVzdCwgc2NvcGVzKTtcclxuICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgICAgcmV0dXJuIG9mKHJlc3VsdCk7XHJcbiAgICAgICAgICAgICAgICB9KSxcclxuICAgICAgICAgICAgICAgIHN3aXRjaE1hcCgocmVzdWx0OiBBdXRoZW50aWNhdGlvblJlc3VsdCkgPT4ge1xyXG4gICAgICAgICAgICAgICAgICAgIHRoaXMuYXV0aFNlcnZpY2UuZ2V0TG9nZ2VyKCkudmVyYm9zZShcIkludGVyY2VwdG9yIC0gc2V0dGluZyBhdXRob3JpemF0aW9uIGhlYWRlcnNcIik7XHJcbiAgICAgICAgICAgICAgICAgICAgY29uc3QgaGVhZGVycyA9IHJlcS5oZWFkZXJzXHJcbiAgICAgICAgICAgICAgICAgICAgICAgIC5zZXQoXCJBdXRob3JpemF0aW9uXCIsIGBCZWFyZXIgJHtyZXN1bHQuYWNjZXNzVG9rZW59YCk7XHJcblxyXG4gICAgICAgICAgICAgICAgICAgIGNvbnN0IHJlcXVlc3RDbG9uZSA9IHJlcS5jbG9uZSh7aGVhZGVyc30pO1xyXG4gICAgICAgICAgICAgICAgICAgIHJldHVybiBuZXh0LmhhbmRsZShyZXF1ZXN0Q2xvbmUpO1xyXG4gICAgICAgICAgICAgICAgfSlcclxuICAgICAgICAgICAgKTtcclxuICAgIH1cclxuXHJcbiAg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lbmRwb2ludEFycmF5LmZvckVhY2gobWF0Y2hlZEVuZHBvaW50ID0+IHtcclxuICAgICAgICAgICAgY29uc3Qgc2NvcGVzRm9yRW5kcG9pbnQgPSBbXTtcclxuICAgICAgICAgICAgY29uc3QgbWV0aG9kQW5kU2NvcGVzQXJyYXkgPSBwcm90ZWN0ZWRSZXNvdXJjZU1hcC5nZXQobWF0Y2hlZEVuZHBvaW50KTtcclxuXHJcbiAgICAgICAgICAgIC8vIFJldHVybiBpZiByZXNvdXJjZSBpcyB1bnByb3RlY3RlZFxyXG4gICAgICAgICAgICBpZiAobWV0aG9kQW5kU2NvcGVzQXJyYXkgPT09IG51bGwpIHtcclxuICAgICAgICAgICAgICAgIGFsbE1hdGNoZWRTY29wZXMucHVzaChudWxsKTtcclxuICAgICAgICAgICAgICAgIHJldHVybjtcclxuICAgICAgICAgICAgfVxyXG5cclxuICAgICAgICAgICAgbWV0aG9kQW5kU2NvcGVzQXJyYXkuZm9yRWFjaChlbnRyeSA9PiB7XHJcbiAgICAgICAgICAgICAgICAvLyBFbnRyeSBpcyBlaXRoZXIgYXJyYXkgb2Ygc2NvcGVzIG9yIFByb3RlY3RlZFJlc291cmNlU2NvcGVzIG9iamVjdFxyXG4gICAgICAgICAgICAgICAgaWYgKHR5cGVvZiBlbnRyeSA9PT0gXCJzdHJpbmdcIikge1xyXG4gICAgICAgICAgICAgICAgICAgIHNjb3Blc0ZvckVuZHBvaW50LnB1c2goZW50cnkpO1xyXG4gICAgICAgICAgICAgICAgfSBlbHNlIHtcclxuICAgICAgICAgICAgICAgICAgICAvLyBFbnN1cmUgbWV0aG9kcyBiZWluZyBjb21wYXJlZCBhcmUgbm9ybWFsaXplZFxyXG4gICAgICAgICAgICAgICAgICAgIGNvbnN0IG5vcm1hbGl6ZWRSZXF1ZXN0TWV0aG9kID0gaHR0cE1ldGhvZC50b0xvd2VyQ2FzZSgpO1xyXG4gICAgICAgICAgICAgICAgICAgIGNvbnN0IG5vcm1hbGl6ZWRSZXNvdXJjZU1ldGhvZCA9IGVudHJ5Lmh0dHBNZXRob2QudG9Mb3dlckNhc2UoKTtcclxuXHJcbiAgICAgICAgICAgICAgICAgICAgLy8gTWV0aG9kIGluIHByb3RlY3RlZFJlc291cmNlTWFwIG1hdGNoZXMgcmVxdWVzdCBodHRwIG1ldGhvZFxyXG4gICAgICAgICAgICAgICAgICAgIGlmIChub3JtYWxpemVkUmVzb3VyY2VNZXRob2QgPT09IG5vcm1hbGl6ZWRSZXF1ZXN0TWV0aG9kKSB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGVudHJ5LnNjb3Blcy5mb3JFYWNoKHNjb3BlID0+IHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHNjb3Blc0ZvckVuZHBvaW50LnB1c2goc2NvcGUpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICB9KTtcclxuICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgIH0pO1xyXG5cclxuICAgICAgICAgICAgLy8gT25seSBhZGQgdG8gYWxsIHNjb3BlcyBpZiBzY29wZXMgZm9yIGVuZHBvaW50IGFuZCBtZXRob2QgaXMgZm91bmRcclxuICAgICAgICAgICAgaWYgKHNjb3Blc0ZvckVuZHBvaW50Lmxlbmd0aCA+IDApIHtcclxuICAgICAgICAgICAgICAgIGFsbE1hdGNoZWRTY29wZXMucHVzaChzY29wZXNGb3JFbmRwb2ludCk7XHJcbiAgICAgICAgICAgIH1cclxuICAgICAgICB9KTtcclxuXHJcbiAgICAgICAgaWYgKGFsbE1hdGNoZWRTY29wZXMubGVuZ3RoID4gMCkge1xyXG4gICAgICAgICAgICBpZiAoYWxsTWF0Y2hlZFNjb3Blcy5sZW5ndGggPiAxKSB7XHJcbiAgICAgICAgICAgICAgICB0aGlzLmF1dGhTZXJ2aWNlLmdldExvZ2dlcigpLndhcm5pbmcoXCJJbnRlcmNlcHRvciAtIE1vcmUgdGhhbiAxIG1hdGN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kQ29uZmlndXJhdGlvbixcclxuICAgICAgICBpbnRlcmNlcHRvckNvbmZpZzogTXNhbEludGVyY2VwdG9yQ29uZmlndXJhdGlvblxyXG4gICAgKTogTW9kdWxlV2l0aFByb3ZpZGVyczxNc2FsTW9kdWxlPiB7XHJcbiAgICAgICAgcmV0dXJuIHtcclxuICAgICAgICAgICAgbmdNb2R1bGU6IE1zYWxNb2R1bGUsXHJcbiAgICAgICAgICAgIHByb3ZpZGVyczogW1xyXG4gICAgICAgICAgICAgICAge1xyXG4gICAgICAgICAgICAgICAgICAgIHByb3ZpZGU6IE1TQUxfSU5TVEFOQ0UsXHJcbiAgICAgICAgICAgICAgICAgICAgdXNlVmFsdWU6IG1zYWxJbnN0YW5jZVxyXG4gICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgIHtcclxuICAgICAgICAgICAgICAgICAgICBwcm92aWRlOiBNU0FMX0dVQVJEX0NPTkZJRyxcclxuICAgICAgICAgICAgICAgICAgICB1c2VWYWx1ZTogZ3VhcmRDb25maWdcclxuICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICB7XHJcbiAgICAgICAgICAgICAgICAgICAgcHJvdmlkZTogTVNBTF9JTlRFUkNFUFRPUl9DT05GSUcsXHJcbiAgICAgICAgICAgICAgICAgICAgdXNlVmFsdWU6IGludGVyY2VwdG9yQ29uZmlnXHJcbiAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAgTXNhbFNlcnZpY2VcclxuICAgICAgICAgICAgXVxyXG4gICAgICAgIH07XHJcbiAgICB9XHJcblxyXG59XHJcbiJdfQ== | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibXNhbC5tb2R1bGUuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi9zcmMvbXNhbC5tb2R1bGUudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUE7OztHQUdHO0FBRU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uY29tcG9uZW50XCI7XHJcblxyXG5ATmdNb2R1bGUoe1xyXG4gICAgZGVjbGFyYXRpb25zOiBbTXNhbFJlZGlyZWN0Q29tcG9uZW50XSxcclxuICAgIGltcG9ydHM6IFtcclxuICAgICAgICBDb21tb25Nb2R1bGVcclxuICAgIF0sXHJcbiAgICBwcm92aWRlcnM6IFtcclxuICAgICAgICBNc2FsR3VhcmQsXHJcbiAgICAgICAgTXNhbEJyb2FkY2FzdFNlcnZpY2VcclxuICAgIF1cclxufSlcclxuZXhwb3J0IGNsYXNzIE1zYWxNb2R1bGUge1xyXG4gICAgc3RhdGljIGZvclJvb3QoXHJcbiAgICAgICAgbXNhbEluc3RhbmNlOiBJUHVibGljQ2xpZW50QXBwbGljYXRpb24sXHJcbiAgICAgICAgZ3VhcmRDb25maWc6IE1zYWxHdWFyZENvbmZpZ3VyYXRpb24sXHJcbiAgICAgICAgaW50ZXJjZXB0b3JDb25maWc6IE1zYWxJbnRlcmNlcHRvckNvbmZpZ3VyYXRpb25cclxuICAgICk6IE1vZHVsZVdpdGhQcm92aWRlcnM8TXNhbE1vZHVsZT4ge1xyXG4gICAgICAgIHJldHVybiB7XHJcbiAgICAgICAgICAgIG5nTW9kdWxlOiBNc2FsTW9kdWxlLFxyXG4gICAgICAgICAgICBwcm92aWRlcnM6IFtcclxuICAgICAgICAgICAgICAgIHtcclxuICAgICAgICAgICAgICAgICAgICBwcm92aWRlOiBNU0FMX0lOU1RBTkNFLFxyXG4gICAgICAgICAgICAgICAgICAgIHVzZVZhbHVlOiBtc2FsSW5zdGFuY2VcclxuICAgICAgICAgICAgICAgIH0sXHJcbiAgICAgICAgICAgICAgICB7XHJcbiAgICAgICAgICAgICAgICAgICAgcHJvdmlkZTogTVNBTF9HVUFSRF9DT05GSUcsXHJcbiAgICAgICAgICAgICAgICAgICAgdXNlVmFsdWU6IGd1YXJkQ29uZmlnXHJcbiAgICAgICAgICAgICAgICB9LFxyXG4gICAgICAgICAgICAgICAge1xyXG4gICAgICAgICAgICAgICAgICAgIHByb3ZpZGU6IE1TQUxfSU5URVJDRVBUT1JfQ09ORklHLFxyXG4gICAgICAgICAgICAgICAgICAgIHVzZVZhbHVlOiBpbnRlcmNlcHRvckNvbmZpZ1xyXG4gICAgICAgICAgICAgICAgfSxcclxuICAgICAgICAgICAgICAgIE1zYWxTZXJ2aWNlXHJcbiAgICAgICAgICAgIF1cclxuICAgICAgICB9O1xyXG4gICAgfVxyXG5cclxufVxyXG4iXX0= |
@@ -31,4 +31,10 @@ /* | ||
this.authService.getLogger().verbosePii(`MsalCustomNavigationClient - navigating to newUrl: ${newUrl}`); | ||
this.router.navigateByUrl(newUrl, { replaceUrl: options.noHistory }); | ||
return Promise.resolve(false); | ||
// Prevent hash clearing from causing an issue with Client-side navigation after redirect is handled | ||
if (options.noHistory) { | ||
window.location.replace(newUrl); | ||
} | ||
else { | ||
this.router.navigateByUrl(newUrl, { replaceUrl: options.noHistory }); | ||
} | ||
return Promise.resolve(options.noHistory); | ||
}); | ||
@@ -45,2 +51,2 @@ } | ||
]; | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibXNhbC5uYXZpZ2F0aW9uLmNsaWVudC5qcyIsInNvdXJjZVJvb3QiOiJDOi9Vc2Vycy9qYW51dHRlci9Db2RlL21pY3Jvc29mdC1hdXRoZW50aWNhdGlvbi1saWJyYXJ5LWZvci1qcy9saWIvbXNhbC1hbmd1bGFyL3NyYy8iLCJzb3VyY2VzIjpbIm1zYWwubmF2aWdhdGlvbi5jbGllbnQudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUE7OztHQUdHOztBQUVILE9BQU8sRUFBRSxnQkFBZ0IsRUFBcUIsU0FBUyxFQUFFLE1BQU0scUJBQXFCLENBQUM7QUFDckYsT0FBTyxFQUFFLE1BQU0sRUFBRSxNQUFNLGlCQUFpQixDQUFDO0FBQ3pDLE9BQU8sRUFBRSxRQUFRLEVBQUUsTUFBTSxp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TogTG9nZ2VyIHtcclxuICAgICAgICBpZiAoIXRoaXMubG9nZ2VyKSB7XHJcbiAgICAgICAgICAgIHRoaXMubG9nZ2VyID0gdGhpcy5pbnN0YW5jZS5nZXRMb2dnZXIoKS5jbG9uZShuYW1lLCB2ZXJzaW9uKTtcclxuICAgICAgICB9XHJcbiAgICAgICAgcmV0dXJuIHRoaXMubG9nZ2VyO1xyXG4gICAgfVxyXG4gICAgLy8gQ3JlYXRlIGEgbG9nZ2VyIGluc3RhbmNlIGZvciBtc2FsLWFuZ3VsYXIgd2l0aCB0aGUgc2FtZSBvcHRpb25zIGFzIG1zYWwtYnJvd3NlclxyXG4gICAgc2V0TG9nZ2VyKGxvZ2dlcjogTG9nZ2VyKTogdm9pZCB7XHJcbiAgICAgICAgdGhpcy5sb2dnZXIgPSBsb2dnZXIuY2xvbmUobmFtZSwgdmVyc2lvbik7XHJcbiAgICAgICAgdGhpcy5pbnN0YW5jZS5zZXRMb2dnZXIobG9nZ2VyKTtcclxuICAgIH1cclxuXHJcbn1cclxuIl19 |
/* eslint-disable header/header */ | ||
export const name = "@azure/msal-angular"; | ||
export const version = "2.0.0-beta.5"; | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicGFja2FnZU1ldGFkYXRhLmpzIiwic291cmNlUm9vdCI6IkM6L1VzZXJzL2phbnV0dGVyL0NvZGUvbWljcm9zb2Z0LWF1dGhlbnRpY2F0aW9uLWxpYnJhcnktZm9yLWpzL2xpYi9tc2FsLWFuZ3VsYXIvc3JjLyIsInNvdXJjZXMiOlsicGFja2FnZU1ldGFkYXRhLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLGtDQUFrQztBQUNsQyxNQUFNLENBQUMsTUFBTSxJQUFJLEdBQUcscUJBQXFCLENBQUM7QUFDMUMsTUFBTSxDQUFDLE1BQU0sT0FBTyxHQUFHLGNBQWMsQ0FBQyIsInNvdXJjZXNDb250ZW50IjpbIi8qIGVzbGludC1kaXNhYmxlIGhlYWRlci9oZWFkZXIgKi9cbmV4cG9ydCBjb25zdCBuYW1lID0gXCJAYXp1cmUvbXNhbC1hbmd1bGFyXCI7XG5leHBvcnQgY29uc3QgdmVyc2lvbiA9IFwiMi4wLjAtYmV0YS41XCI7XG4iXX0= | ||
export const version = "2.0.0-beta.6"; | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicGFja2FnZU1ldGFkYXRhLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vc3JjL3BhY2thZ2VNZXRhZGF0YS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxrQ0FBa0M7QUFDbEMsTUFBTSxDQUFDLE1BQU0sSUFBSSxHQUFHLHFCQUFxQixDQUFDO0FBQzFDLE1BQU0sQ0FBQyxNQUFNLE9BQU8sR0FBRyxjQUFjLENBQUMiLCJzb3VyY2VzQ29udGVudCI6WyIvKiBlc2xpbnQtZGlzYWJsZSBoZWFkZXIvaGVhZGVyICovXG5leHBvcnQgY29uc3QgbmFtZSA9IFwiQGF6dXJlL21zYWwtYW5ndWxhclwiO1xuZXhwb3J0IGNvbnN0IHZlcnNpb24gPSBcIjIuMC4wLWJldGEuNlwiO1xuIl19 |
@@ -17,2 +17,2 @@ /* | ||
export { MsalCustomNavigationClient } from "./msal.navigation.client"; | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicHVibGljLWFwaS5qcyIsInNvdXJjZVJvb3QiOiJDOi9Vc2Vycy9qYW51dHRlci9Db2RlL21pY3Jvc29mdC1hdXRoZW50aWNhdGlvbi1saWJyYXJ5LWZvci1qcy9saWIvbXNhbC1hbmd1bGFyL3NyYy8iLCJzb3VyY2VzIjpbInB1YmxpYy1hcGkudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUE7OztHQUdHO0FBRUg7OztHQUdHO0FBR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sLmludGVyY2VwdG9yXCI7XHJcbmV4cG9ydCB7IE1zYWxJbnRlcmNlcHRvckNvbmZpZ3VyYXRpb24sIE1zYWxJbnRlcmNlcHRvckF1dGhSZXF1ZXN0LCBQcm90ZWN0ZWRSZXNvdXJjZVNjb3BlcyB9IGZyb20gXCIuL21zYWwuaW50ZXJjZXB0b3IuY29uZmlnXCI7XHJcbmV4cG9ydCB7IE1TQUxfSU5TVEFOQ0UsIE1TQUxfR1VBUkRfQ09ORklHLCBNU0FMX0lOVEVSQ0VQVE9SX0NPTkZJRyB9IGZyb20gXCIuL2NvbnN0YW50c1wiO1xyXG5leHBvcnQgeyBNc2FsQnJvYWRjYXN0U2VydmljZSB9IGZyb20gXCIuL21zYWwuYnJvYWRjYXN0LnNlcnZpY2VcIjtcclxuZXhwb3J0IHsgTXNhbE1vZHVsZSB9IGZyb20gXCIuL21zYWwubW9kdWxlXCI7XHJcbmV4cG9ydCB7IE1zYWxSZWRpcmVjdENvbXBvbmVudCB9IGZyb20gXCIuL21zYWwucmVkaXJlY3QuY29tcG9uZW50XCI7XHJcbmV4cG9ydCB7IE1zYWxDdXN0b21OYXZpZ2F0aW9uQ2xpZW50IH0gZnJvbSBcIi4vbXNhbC5uYXZpZ2F0aW9uLmNsaWVudFwiO1xyXG4iXX0= |
@@ -19,3 +19,3 @@ import { InjectionToken, Injectable, Inject, VERSION, Component, NgModule } from '@angular/core'; | ||
const name = "@azure/msal-angular"; | ||
const version = "2.0.0-beta.5"; | ||
const version = "2.0.0-beta.6"; | ||
@@ -211,2 +211,4 @@ /* | ||
} | ||
// Capture current path before it gets changed by handleRedirectObservable | ||
const currentPath = this.location.path(true); | ||
return this.authService.handleRedirectObservable() | ||
@@ -223,10 +225,16 @@ .pipe(concatMap(() => { | ||
this.authService.getLogger().verbose("Guard - at least 1 account exists, can activate or load"); | ||
// Prevent navigating the app to /#code= | ||
if (state && state.url.indexOf("#") > -1 && state.url.indexOf("code=") > -1) { | ||
// Prevent navigating the app to /#code= or /code= | ||
if (state && currentPath.indexOf("code=") > -1) { | ||
this.authService.getLogger().info("Guard - Hash contains known code response, stopping navigation."); | ||
return of(false); | ||
// Path routing (navigate to current path without hash) | ||
if (currentPath.indexOf("#") > -1) { | ||
return of(this.parseUrl(this.location.path())); | ||
} | ||
// Hash routing (navigate to root path) | ||
return of(this.parseUrl("")); | ||
} | ||
return of(true); | ||
}), catchError(() => { | ||
this.authService.getLogger().verbose("Guard - error while logging in, unable to activate"); | ||
}), catchError((error) => { | ||
this.authService.getLogger().error("Guard - error while logging in, unable to activate"); | ||
this.authService.getLogger().errorPii(`Guard - error: ${error.message}`); | ||
/** | ||
@@ -284,3 +292,3 @@ * If a loginFailedRoute is set, checks to see if Angular 10+ is used and state is passed in before returning route | ||
this.authService.getLogger().verbose("MSAL Interceptor activated"); | ||
const scopes = this.getScopesForEndpoint(req.url); | ||
const scopes = this.getScopesForEndpoint(req.url, req.method); | ||
// If no scopes for endpoint, does not acquire token | ||
@@ -343,6 +351,7 @@ if (!scopes || scopes.length === 0) { | ||
* @param endpoint Url of the request | ||
* @param endpoint Http method of the request | ||
* @returns Array of scopes, or null if not found | ||
* | ||
*/ | ||
getScopesForEndpoint(endpoint) { | ||
getScopesForEndpoint(endpoint, httpMethod) { | ||
this.authService.getLogger().verbose("Interceptor - getting scopes for endpoint"); | ||
@@ -352,3 +361,17 @@ // Ensures endpoints and protected resources compared are normalized | ||
const protectedResourcesArray = Array.from(this.msalInterceptorConfig.protectedResourceMap.keys()); | ||
const keyMatchesEndpointArray = protectedResourcesArray.filter(key => { | ||
const matchingProtectedResources = this.matchResourcesToEndpoint(protectedResourcesArray, normalizedEndpoint); | ||
if (matchingProtectedResources.length > 0) { | ||
return this.matchScopesToEndpoint(this.msalInterceptorConfig.protectedResourceMap, matchingProtectedResources, httpMethod); | ||
} | ||
return null; | ||
} | ||
/** | ||
* Finds resource endpoints that match request endpoint | ||
* @param protectedResourcesArray | ||
* @param endpoint | ||
* @param location | ||
* @returns | ||
*/ | ||
matchResourcesToEndpoint(protectedResourcesEndpoints, endpoint) { | ||
return protectedResourcesEndpoints.filter(key => { | ||
const normalizedKey = this.location.normalize(key); | ||
@@ -360,15 +383,56 @@ // Normalized key should include query strings if applicable | ||
if (relativeNormalizedKey === "" || relativeNormalizedKey === "/*") { | ||
return StringUtils.matchPattern(normalizedKey, normalizedEndpoint); | ||
return StringUtils.matchPattern(normalizedKey, endpoint); | ||
} | ||
else { | ||
// Matching endpoint with both protected resource and relative url of protected resource | ||
return StringUtils.matchPattern(normalizedKey, normalizedEndpoint) || StringUtils.matchPattern(relativeNormalizedKey, normalizedEndpoint); | ||
return StringUtils.matchPattern(normalizedKey, endpoint) || StringUtils.matchPattern(relativeNormalizedKey, endpoint); | ||
} | ||
}); | ||
// Process all protected resources and send the first matched resource | ||
if (keyMatchesEndpointArray.length > 0) { | ||
const keyForEndpoint = keyMatchesEndpointArray[0]; | ||
if (keyForEndpoint) { | ||
return this.msalInterceptorConfig.protectedResourceMap.get(keyForEndpoint); | ||
} | ||
/** | ||
* Finds scopes from first matching endpoint with HTTP method that matches request | ||
* @param protectedResourceMap Protected resource map | ||
* @param endpointArray Array of resources that match request endpoint | ||
* @param httpMethod Http method of the request | ||
* @returns | ||
*/ | ||
matchScopesToEndpoint(protectedResourceMap, endpointArray, httpMethod) { | ||
const allMatchedScopes = []; | ||
// Check each matched endpoint for matching HttpMethod and scopes | ||
endpointArray.forEach(matchedEndpoint => { | ||
const scopesForEndpoint = []; | ||
const methodAndScopesArray = protectedResourceMap.get(matchedEndpoint); | ||
// Return if resource is unprotected | ||
if (methodAndScopesArray === null) { | ||
allMatchedScopes.push(null); | ||
return; | ||
} | ||
methodAndScopesArray.forEach(entry => { | ||
// Entry is either array of scopes or ProtectedResourceScopes object | ||
if (typeof entry === "string") { | ||
scopesForEndpoint.push(entry); | ||
} | ||
else { | ||
// Ensure methods being compared are normalized | ||
const normalizedRequestMethod = httpMethod.toLowerCase(); | ||
const normalizedResourceMethod = entry.httpMethod.toLowerCase(); | ||
// Method in protectedResourceMap matches request http method | ||
if (normalizedResourceMethod === normalizedRequestMethod) { | ||
entry.scopes.forEach(scope => { | ||
scopesForEndpoint.push(scope); | ||
}); | ||
} | ||
} | ||
}); | ||
// Only add to all scopes if scopes for endpoint and method is found | ||
if (scopesForEndpoint.length > 0) { | ||
allMatchedScopes.push(scopesForEndpoint); | ||
} | ||
}); | ||
if (allMatchedScopes.length > 0) { | ||
if (allMatchedScopes.length > 1) { | ||
this.authService.getLogger().warning("Interceptor - More than 1 matching scopes for endpoint found."); | ||
} | ||
// Returns scopes for first matching endpoint | ||
return allMatchedScopes[0]; | ||
} | ||
@@ -473,4 +537,10 @@ return null; | ||
this.authService.getLogger().verbosePii(`MsalCustomNavigationClient - navigating to newUrl: ${newUrl}`); | ||
this.router.navigateByUrl(newUrl, { replaceUrl: options.noHistory }); | ||
return Promise.resolve(false); | ||
// Prevent hash clearing from causing an issue with Client-side navigation after redirect is handled | ||
if (options.noHistory) { | ||
window.location.replace(newUrl); | ||
} | ||
else { | ||
this.router.navigateByUrl(newUrl, { replaceUrl: options.noHistory }); | ||
} | ||
return Promise.resolve(options.noHistory); | ||
}); | ||
@@ -477,0 +547,0 @@ } |
@@ -15,1 +15,2 @@ import { EndSessionRequest, AuthorizationUrlRequest, AuthenticationResult, PopupRequest, RedirectRequest, SilentRequest, Logger } from "@azure/msal-browser"; | ||
} | ||
//# sourceMappingURL=IMsalService.d.ts.map |
@@ -13,1 +13,2 @@ import { Observable } from "rxjs"; | ||
} | ||
//# sourceMappingURL=msal.broadcast.service.d.ts.map |
@@ -10,1 +10,2 @@ import { RouterStateSnapshot } from "@angular/router"; | ||
}; | ||
//# sourceMappingURL=msal.guard.config.d.ts.map |
@@ -40,1 +40,2 @@ import { CanActivate, ActivatedRouteSnapshot, RouterStateSnapshot, CanActivateChild, CanLoad, UrlTree, Router } from "@angular/router"; | ||
} | ||
//# sourceMappingURL=msal.guard.d.ts.map |
@@ -7,4 +7,9 @@ import { HttpRequest } from "@angular/common/http"; | ||
interactionType: InteractionType.Popup | InteractionType.Redirect; | ||
protectedResourceMap: Map<string, Array<string> | null>; | ||
protectedResourceMap: Map<string, Array<string | ProtectedResourceScopes> | null>; | ||
authRequest?: MsalInterceptorAuthRequest | ((msalService: MsalService, req: HttpRequest<unknown>, originalAuthRequest: MsalInterceptorAuthRequest) => MsalInterceptorAuthRequest); | ||
}; | ||
export declare type ProtectedResourceScopes = { | ||
httpMethod: string; | ||
scopes: Array<string>; | ||
}; | ||
//# sourceMappingURL=msal.interceptor.config.d.ts.map |
@@ -21,2 +21,3 @@ import { HttpRequest, HttpHandler, HttpEvent, HttpInterceptor } from "@angular/common/http"; | ||
* @param endpoint Url of the request | ||
* @param endpoint Http method of the request | ||
* @returns Array of scopes, or null if not found | ||
@@ -26,2 +27,19 @@ * | ||
private getScopesForEndpoint; | ||
/** | ||
* Finds resource endpoints that match request endpoint | ||
* @param protectedResourcesArray | ||
* @param endpoint | ||
* @param location | ||
* @returns | ||
*/ | ||
private matchResourcesToEndpoint; | ||
/** | ||
* Finds scopes from first matching endpoint with HTTP method that matches request | ||
* @param protectedResourceMap Protected resource map | ||
* @param endpointArray Array of resources that match request endpoint | ||
* @param httpMethod Http method of the request | ||
* @returns | ||
*/ | ||
private matchScopesToEndpoint; | ||
} | ||
//# sourceMappingURL=msal.interceptor.d.ts.map |
@@ -8,1 +8,2 @@ import { ModuleWithProviders } from "@angular/core"; | ||
} | ||
//# sourceMappingURL=msal.module.d.ts.map |
@@ -17,1 +17,2 @@ import { NavigationClient, NavigationOptions } from "@azure/msal-browser"; | ||
} | ||
//# sourceMappingURL=msal.navigation.client.d.ts.map |
@@ -13,1 +13,2 @@ /** | ||
} | ||
//# sourceMappingURL=msal.redirect.component.d.ts.map |
@@ -28,1 +28,2 @@ import { Location } from "@angular/common"; | ||
} | ||
//# sourceMappingURL=msal.service.d.ts.map |
{ | ||
"name": "@azure/msal-angular", | ||
"version": "2.0.0-beta.5", | ||
"version": "2.0.0-beta.6", | ||
"main": "bundles/azure-msal-angular.umd.js", | ||
"typings": "azure-msal-angular.d.ts", | ||
"peerDependencies": { | ||
"@angular/common": "9 - 11", | ||
"@angular/core": "9 - 11", | ||
"@azure/msal-browser": "^2.14.1", | ||
"@azure/msal-browser": "^2.14.2", | ||
"rxjs": "^6.0.0" | ||
@@ -21,2 +19,2 @@ }, | ||
"sideEffects": false | ||
} | ||
} |
export declare const name = "@azure/msal-angular"; | ||
export declare const version = "2.0.0-beta.5"; | ||
export declare const version = "2.0.0-beta.6"; | ||
//# sourceMappingURL=packageMetadata.d.ts.map |
@@ -10,3 +10,3 @@ /** | ||
export { MsalInterceptor } from "./msal.interceptor"; | ||
export { MsalInterceptorConfiguration, MsalInterceptorAuthRequest } from "./msal.interceptor.config"; | ||
export { MsalInterceptorConfiguration, MsalInterceptorAuthRequest, ProtectedResourceScopes } from "./msal.interceptor.config"; | ||
export { MSAL_INSTANCE, MSAL_GUARD_CONFIG, MSAL_INTERCEPTOR_CONFIG } from "./constants"; | ||
@@ -17,1 +17,2 @@ export { MsalBroadcastService } from "./msal.broadcast.service"; | ||
export { MsalCustomNavigationClient } from "./msal.navigation.client"; | ||
//# sourceMappingURL=public-api.d.ts.map |
@@ -44,3 +44,3 @@ # Microsoft Authentication Library for Angular | ||
|----------------------|-------------------------|----------------------------| | ||
| MSAL Angular v2 | Active development | 9, 10, 11 | | ||
| MSAL Angular v2 | Active development | 9, 10, 11, 12 | | ||
| MSAL Angular v1 | Active development | 6, 7, 8, 9 | | ||
@@ -66,2 +66,3 @@ | MSAL Angular v0 | In maintenance | 4, 5 | | ||
1. [Using redirects](https://github.com/AzureAD/microsoft-authentication-library-for-js/tree/dev/lib/msal-angular/docs/v2-docs/redirects.md) | ||
1. [Using the MsalInterceptor](https://github.com/AzureAD/microsoft-authentication-library-for-js/blob/dev/lib/msal-angular/docs/v2-docs/msal-interceptor.md) | ||
1. [Known issues](https://github.com/AzureAD/microsoft-authentication-library-for-js/tree/dev/lib/msal-angular/docs/v2-docs/known-issues.md) | ||
@@ -96,2 +97,3 @@ | ||
* [Angular v11 B2C Sample](https://github.com/AzureAD/microsoft-authentication-library-for-js/tree/dev/samples/msal-angular-v2-samples/angular11-b2c-sample) | ||
* [Angular v12](https://github.com/AzureAD/microsoft-authentication-library-for-js/tree/dev/samples/msal-angular-v2-samples/angular12-sample-app) | ||
@@ -101,5 +103,5 @@ See [here](https://github.com/AzureAD/microsoft-authentication-library-for-js/blob/dev/samples/msal-angular-v2-samples/README.md) for specific features demonstrated by our MSAL Angular v2 samples. | ||
### Advanced MSAL Angular v2 Samples | ||
* [Angular SPA with ASP.NET Core web API](https://github.com/Azure-Samples/ms-identity-javascript-angular-spa-aspnetcore-webapi) | ||
* [Angular SPA with APS.NET Core web API using App Roles and RBAC](https://github.com/Azure-Samples/ms-identity-javascript-angular-spa-dotnetcore-webapi-roles-groups) | ||
* [Multi-tenant tutorial using MSAL Angular v2](https://github.com/Azure-Samples/ms-identity-javascript-angular-spa-aspnet-webapi-multitenant) | ||
* [Angular SPA with ASP.NET Core web API](https://github.com/Azure-Samples/ms-identity-javascript-angular-tutorial/tree/main/3-Authorization-II/1-call-api) | ||
* [Angular SPA with APS.NET Core web API using App Roles and RBAC](https://github.com/Azure-Samples/ms-identity-javascript-angular-tutorial/tree/main/5-AccessControl/1-call-api-roles) | ||
* [Multi-tenant tutorial using MSAL Angular v2](https://github.com/Azure-Samples/ms-identity-javascript-angular-tutorial/tree/main/6-Multitenancy/1-call-api-mt) | ||
@@ -106,0 +108,0 @@ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
407438
3
52
2328
146