@azure/msal-common 6.0.0 → 6.3.0-beta.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (188) hide show
  1. package/LICENSE +21 -21
  2. package/README.md +62 -62
  3. package/dist/_virtual/_tslib.js +1 -1
  4. package/dist/account/AccountInfo.d.ts +6 -1
  5. package/dist/account/AccountInfo.d.ts.map +1 -1
  6. package/dist/account/AuthToken.js +1 -1
  7. package/dist/account/AuthToken.js.map +1 -1
  8. package/dist/account/CcsCredential.js +1 -1
  9. package/dist/account/CcsCredential.js.map +1 -1
  10. package/dist/account/ClientInfo.js +1 -1
  11. package/dist/account/ClientInfo.js.map +1 -1
  12. package/dist/account/TokenClaims.d.ts +30 -0
  13. package/dist/account/TokenClaims.d.ts.map +1 -1
  14. package/dist/authority/Authority.d.ts +9 -1
  15. package/dist/authority/Authority.d.ts.map +1 -1
  16. package/dist/authority/Authority.js +36 -11
  17. package/dist/authority/Authority.js.map +1 -1
  18. package/dist/authority/AuthorityFactory.d.ts +2 -2
  19. package/dist/authority/AuthorityFactory.d.ts.map +1 -1
  20. package/dist/authority/AuthorityFactory.js +5 -5
  21. package/dist/authority/AuthorityFactory.js.map +1 -1
  22. package/dist/authority/AuthorityOptions.d.ts +8 -0
  23. package/dist/authority/AuthorityOptions.d.ts.map +1 -1
  24. package/dist/authority/AuthorityOptions.js +24 -0
  25. package/dist/authority/AuthorityOptions.js.map +1 -0
  26. package/dist/authority/AuthorityType.js +1 -1
  27. package/dist/authority/AuthorityType.js.map +1 -1
  28. package/dist/authority/CloudInstanceDiscoveryResponse.js +1 -1
  29. package/dist/authority/CloudInstanceDiscoveryResponse.js.map +1 -1
  30. package/dist/authority/ImdsOptions.d.ts +7 -0
  31. package/dist/authority/ImdsOptions.d.ts.map +1 -0
  32. package/dist/authority/OpenIdConfigResponse.js +1 -1
  33. package/dist/authority/OpenIdConfigResponse.js.map +1 -1
  34. package/dist/authority/ProtocolMode.js +1 -1
  35. package/dist/authority/ProtocolMode.js.map +1 -1
  36. package/dist/authority/RegionDiscovery.d.ts +3 -6
  37. package/dist/authority/RegionDiscovery.d.ts.map +1 -1
  38. package/dist/authority/RegionDiscovery.js +19 -11
  39. package/dist/authority/RegionDiscovery.js.map +1 -1
  40. package/dist/cache/CacheManager.d.ts +1 -1
  41. package/dist/cache/CacheManager.js +3 -3
  42. package/dist/cache/CacheManager.js.map +1 -1
  43. package/dist/cache/entities/AccessTokenEntity.js +1 -1
  44. package/dist/cache/entities/AccessTokenEntity.js.map +1 -1
  45. package/dist/cache/entities/AccountEntity.d.ts +3 -1
  46. package/dist/cache/entities/AccountEntity.d.ts.map +1 -1
  47. package/dist/cache/entities/AccountEntity.js +16 -12
  48. package/dist/cache/entities/AccountEntity.js.map +1 -1
  49. package/dist/cache/entities/AppMetadataEntity.js +1 -1
  50. package/dist/cache/entities/AppMetadataEntity.js.map +1 -1
  51. package/dist/cache/entities/AuthorityMetadataEntity.js +1 -1
  52. package/dist/cache/entities/AuthorityMetadataEntity.js.map +1 -1
  53. package/dist/cache/entities/CacheRecord.js +1 -1
  54. package/dist/cache/entities/CacheRecord.js.map +1 -1
  55. package/dist/cache/entities/CredentialEntity.js +5 -5
  56. package/dist/cache/entities/CredentialEntity.js.map +1 -1
  57. package/dist/cache/entities/IdTokenEntity.js +1 -1
  58. package/dist/cache/entities/IdTokenEntity.js.map +1 -1
  59. package/dist/cache/entities/RefreshTokenEntity.js +1 -1
  60. package/dist/cache/entities/RefreshTokenEntity.js.map +1 -1
  61. package/dist/cache/entities/ServerTelemetryEntity.js +1 -1
  62. package/dist/cache/entities/ServerTelemetryEntity.js.map +1 -1
  63. package/dist/cache/entities/ThrottlingEntity.js +1 -1
  64. package/dist/cache/entities/ThrottlingEntity.js.map +1 -1
  65. package/dist/cache/persistence/TokenCacheContext.js +1 -1
  66. package/dist/cache/persistence/TokenCacheContext.js.map +1 -1
  67. package/dist/client/AuthorizationCodeClient.d.ts.map +1 -1
  68. package/dist/client/AuthorizationCodeClient.js +122 -93
  69. package/dist/client/AuthorizationCodeClient.js.map +1 -1
  70. package/dist/client/BaseClient.js +2 -2
  71. package/dist/client/BaseClient.js.map +1 -1
  72. package/dist/client/ClientCredentialClient.d.ts.map +1 -1
  73. package/dist/client/ClientCredentialClient.js +4 -3
  74. package/dist/client/ClientCredentialClient.js.map +1 -1
  75. package/dist/client/DeviceCodeClient.d.ts.map +1 -1
  76. package/dist/client/DeviceCodeClient.js +4 -2
  77. package/dist/client/DeviceCodeClient.js.map +1 -1
  78. package/dist/client/OnBehalfOfClient.js +3 -2
  79. package/dist/client/OnBehalfOfClient.js.map +1 -1
  80. package/dist/client/RefreshTokenClient.js +2 -1
  81. package/dist/client/RefreshTokenClient.js.map +1 -1
  82. package/dist/client/SilentFlowClient.js +1 -1
  83. package/dist/client/SilentFlowClient.js.map +1 -1
  84. package/dist/client/UsernamePasswordClient.d.ts.map +1 -1
  85. package/dist/client/UsernamePasswordClient.js +3 -1
  86. package/dist/client/UsernamePasswordClient.js.map +1 -1
  87. package/dist/config/ClientConfiguration.d.ts +29 -1
  88. package/dist/config/ClientConfiguration.d.ts.map +1 -1
  89. package/dist/config/ClientConfiguration.js +21 -8
  90. package/dist/config/ClientConfiguration.js.map +1 -1
  91. package/dist/crypto/ICrypto.d.ts +4 -2
  92. package/dist/crypto/ICrypto.d.ts.map +1 -1
  93. package/dist/crypto/ICrypto.js +1 -1
  94. package/dist/crypto/ICrypto.js.map +1 -1
  95. package/dist/crypto/IGuidGenerator.d.ts +5 -0
  96. package/dist/crypto/IGuidGenerator.d.ts.map +1 -0
  97. package/dist/crypto/PopTokenGenerator.d.ts +30 -0
  98. package/dist/crypto/PopTokenGenerator.d.ts.map +1 -1
  99. package/dist/crypto/PopTokenGenerator.js +38 -2
  100. package/dist/crypto/PopTokenGenerator.js.map +1 -1
  101. package/dist/error/AuthError.js +3 -3
  102. package/dist/error/AuthError.js.map +1 -1
  103. package/dist/error/ClientAuthError.js +1 -1
  104. package/dist/error/ClientAuthError.js.map +1 -1
  105. package/dist/error/ClientConfigurationError.d.ts +11 -0
  106. package/dist/error/ClientConfigurationError.d.ts.map +1 -1
  107. package/dist/error/ClientConfigurationError.js +12 -2
  108. package/dist/error/ClientConfigurationError.js.map +1 -1
  109. package/dist/error/InteractionRequiredAuthError.js +1 -1
  110. package/dist/error/InteractionRequiredAuthError.js.map +1 -1
  111. package/dist/error/ServerError.js +1 -1
  112. package/dist/error/ServerError.js.map +1 -1
  113. package/dist/index.cjs.js +764 -176
  114. package/dist/index.cjs.js.map +1 -1
  115. package/dist/index.d.ts +8 -2
  116. package/dist/index.d.ts.map +1 -1
  117. package/dist/index.js +5 -1
  118. package/dist/index.js.map +1 -1
  119. package/dist/logger/Logger.js +13 -13
  120. package/dist/logger/Logger.js.map +1 -1
  121. package/dist/network/INetworkModule.d.ts +1 -0
  122. package/dist/network/INetworkModule.d.ts.map +1 -1
  123. package/dist/network/INetworkModule.js +1 -1
  124. package/dist/network/INetworkModule.js.map +1 -1
  125. package/dist/network/NetworkManager.js +1 -1
  126. package/dist/network/NetworkManager.js.map +1 -1
  127. package/dist/network/ThrottlingUtils.js +1 -1
  128. package/dist/network/ThrottlingUtils.js.map +1 -1
  129. package/dist/packageMetadata.d.ts +1 -1
  130. package/dist/packageMetadata.d.ts.map +1 -1
  131. package/dist/packageMetadata.js +2 -2
  132. package/dist/packageMetadata.js.map +1 -1
  133. package/dist/request/AuthenticationHeaderParser.js +3 -3
  134. package/dist/request/AuthenticationHeaderParser.js.map +1 -1
  135. package/dist/request/BaseAuthRequest.d.ts +8 -5
  136. package/dist/request/BaseAuthRequest.d.ts.map +1 -1
  137. package/dist/request/CommonAuthorizationUrlRequest.d.ts +1 -0
  138. package/dist/request/CommonAuthorizationUrlRequest.d.ts.map +1 -1
  139. package/dist/request/CommonEndSessionRequest.d.ts +2 -0
  140. package/dist/request/CommonEndSessionRequest.d.ts.map +1 -1
  141. package/dist/request/RequestParameterBuilder.d.ts +18 -1
  142. package/dist/request/RequestParameterBuilder.d.ts.map +1 -1
  143. package/dist/request/RequestParameterBuilder.js +37 -3
  144. package/dist/request/RequestParameterBuilder.js.map +1 -1
  145. package/dist/request/RequestValidator.js +1 -1
  146. package/dist/request/RequestValidator.js.map +1 -1
  147. package/dist/request/ScopeSet.js +4 -4
  148. package/dist/request/ScopeSet.js.map +1 -1
  149. package/dist/response/AuthenticationResult.d.ts +1 -0
  150. package/dist/response/AuthenticationResult.d.ts.map +1 -1
  151. package/dist/response/ResponseHandler.d.ts.map +1 -1
  152. package/dist/response/ResponseHandler.js +6 -5
  153. package/dist/response/ResponseHandler.js.map +1 -1
  154. package/dist/response/ServerAuthorizationCodeResponse.d.ts +1 -0
  155. package/dist/response/ServerAuthorizationCodeResponse.d.ts.map +1 -1
  156. package/dist/telemetry/performance/IPerformanceClient.d.ts +22 -0
  157. package/dist/telemetry/performance/IPerformanceClient.d.ts.map +1 -0
  158. package/dist/telemetry/performance/IPerformanceMeasurement.d.ts +6 -0
  159. package/dist/telemetry/performance/IPerformanceMeasurement.d.ts.map +1 -0
  160. package/dist/telemetry/performance/PerformanceClient.d.ts +125 -0
  161. package/dist/telemetry/performance/PerformanceClient.d.ts.map +1 -0
  162. package/dist/telemetry/performance/PerformanceClient.js +275 -0
  163. package/dist/telemetry/performance/PerformanceClient.js.map +1 -0
  164. package/dist/telemetry/performance/PerformanceEvent.d.ts +203 -0
  165. package/dist/telemetry/performance/PerformanceEvent.d.ts.map +1 -0
  166. package/dist/telemetry/performance/PerformanceEvent.js +100 -0
  167. package/dist/telemetry/performance/PerformanceEvent.js.map +1 -0
  168. package/dist/telemetry/performance/StubPerformanceClient.d.ts +13 -0
  169. package/dist/telemetry/performance/StubPerformanceClient.d.ts.map +1 -0
  170. package/dist/telemetry/performance/StubPerformanceClient.js +37 -0
  171. package/dist/telemetry/performance/StubPerformanceClient.js.map +1 -0
  172. package/dist/telemetry/server/ServerTelemetryManager.js +4 -4
  173. package/dist/telemetry/server/ServerTelemetryManager.js.map +1 -1
  174. package/dist/url/UrlString.js +2 -2
  175. package/dist/url/UrlString.js.map +1 -1
  176. package/dist/utils/Constants.d.ts +8 -1
  177. package/dist/utils/Constants.d.ts.map +1 -1
  178. package/dist/utils/Constants.js +9 -2
  179. package/dist/utils/Constants.js.map +1 -1
  180. package/dist/utils/ProtocolUtils.js +3 -3
  181. package/dist/utils/ProtocolUtils.js.map +1 -1
  182. package/dist/utils/StringUtils.js +1 -1
  183. package/dist/utils/StringUtils.js.map +1 -1
  184. package/dist/utils/TimeUtils.js +1 -1
  185. package/dist/utils/TimeUtils.js.map +1 -1
  186. package/package.json +74 -76
  187. package/CHANGELOG.json +0 -1282
  188. package/CHANGELOG.md +0 -491
package/dist/index.d.ts CHANGED
@@ -9,7 +9,7 @@ export { ClientCredentialClient } from "./client/ClientCredentialClient";
9
9
  export { OnBehalfOfClient } from "./client/OnBehalfOfClient";
10
10
  export { SilentFlowClient } from "./client/SilentFlowClient";
11
11
  export { UsernamePasswordClient } from "./client/UsernamePasswordClient";
12
- export { AuthOptions, SystemOptions, LoggerOptions, DEFAULT_SYSTEM_OPTIONS } from "./config/ClientConfiguration";
12
+ export { AuthOptions, SystemOptions, LoggerOptions, DEFAULT_SYSTEM_OPTIONS, AzureCloudOptions, ApplicationTelemetry } from "./config/ClientConfiguration";
13
13
  export { ClientConfiguration } from "./config/ClientConfiguration";
14
14
  export { AccountInfo } from "./account/AccountInfo";
15
15
  export { AuthToken } from "./account/AuthToken";
@@ -18,7 +18,7 @@ export { TokenClaims } from "./account/TokenClaims";
18
18
  export { TokenClaims as IdTokenClaims } from "./account/TokenClaims";
19
19
  export { CcsCredential, CcsCredentialType } from "./account/CcsCredential";
20
20
  export { Authority } from "./authority/Authority";
21
- export { AuthorityOptions } from "./authority/AuthorityOptions";
21
+ export { AuthorityOptions, AzureCloudInstance } from "./authority/AuthorityOptions";
22
22
  export { AuthorityFactory } from "./authority/AuthorityFactory";
23
23
  export { AuthorityType } from "./authority/AuthorityType";
24
24
  export { ProtocolMode } from "./authority/ProtocolMode";
@@ -44,6 +44,7 @@ export { IUri } from "./url/IUri";
44
44
  export { UrlString } from "./url/UrlString";
45
45
  export { ICrypto, PkceCodes, DEFAULT_CRYPTO_IMPLEMENTATION, SignedHttpRequestParameters } from "./crypto/ICrypto";
46
46
  export { SignedHttpRequest } from "./crypto/SignedHttpRequest";
47
+ export { IGuidGenerator } from "./crypto/IGuidGenerator";
47
48
  export { BaseAuthRequest } from "./request/BaseAuthRequest";
48
49
  export { CommonAuthorizationUrlRequest } from "./request/CommonAuthorizationUrlRequest";
49
50
  export { CommonAuthorizationCodeRequest } from "./request/CommonAuthorizationCodeRequest";
@@ -77,6 +78,11 @@ export { ProtocolUtils, RequestStateObject, LibraryStateObject } from "./utils/P
77
78
  export { TimeUtils } from "./utils/TimeUtils";
78
79
  export { ServerTelemetryManager } from "./telemetry/server/ServerTelemetryManager";
79
80
  export { ServerTelemetryRequest } from "./telemetry/server/ServerTelemetryRequest";
81
+ export { IPerformanceClient, PerformanceCallbackFunction, InProgressPerformanceEvent } from "./telemetry/performance/IPerformanceClient";
82
+ export { PerformanceEvent, PerformanceEvents, PerformanceEventStatus } from "./telemetry/performance/PerformanceEvent";
83
+ export { IPerformanceMeasurement } from "./telemetry/performance/IPerformanceMeasurement";
84
+ export { PerformanceClient } from "./telemetry/performance/PerformanceClient";
85
+ export { StubPerformanceClient } from "./telemetry/performance/StubPerformanceClient";
80
86
  export { PopTokenGenerator } from "./crypto/PopTokenGenerator";
81
87
  export { version } from "./packageMetadata";
82
88
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAKA;;;GAGG;AAEH,OAAO,EAAE,uBAAuB,EAAC,MAAM,kCAAkC,CAAC;AAC1E,OAAO,EAAE,gBAAgB,EAAE,MAAM,2BAA2B,CAAC;AAC7D,OAAO,EAAE,kBAAkB,EAAE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,CAAC;AACvM,OAAO,EAAE,WAAW,EAAE,MAAM,qBAAqB,CAAC;AAClD,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAC/C,OAAO,EAAE,aAAa,EAAE,kBAAkB,EAAE,kBAAkB,EAAE,MAAM,uBAAuB,CAAC;AAC9F,OAAO,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAE9C,OAAO,EAAE,sBAAsB,EAAE,MAAM,2CAA2C,CAAC;AACnF,OAAO,EAAE,sBAAsB,EAAE,MAAM,2CAA2C,CAAC;AAGnF,OAAO,EAAE,kBAAkB,EAAE,2BAA2B,EAAE,0BAA0B,EAAE,MAAM,4CAA4C,CAAC;AACzI,OAAO,EAAE,gBAAgB,EAAE,iBAAiB,EAAE,sBAAsB,EAAE,MAAM,0CAA0C,CAAC;AACvH,OAAO,EAAE,uBAAuB,EAAE,MAAM,iDAAiD,CAAC;AAC1F,OAAO,EAAE,iBAAiB,EAAE,MAAM,2CAA2C,CAAC;AAC9E,OAAO,EAAE,qBAAqB,EAAE,MAAM,+CAA+C,CAAC;AAEtF,OAAO,EAAE,iBAAiB,EAAE,MAAM,4BAA4B,CAAC;AAE/D,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC"}
package/dist/index.js CHANGED
@@ -1,4 +1,4 @@
1
- /*! @azure/msal-common v6.0.0 2022-01-04 */
1
+ /*! @azure/msal-common v6.3.0-beta.0 2022-04-27 */
2
2
  'use strict';
3
3
  export { AuthorizationCodeClient } from './client/AuthorizationCodeClient.js';
4
4
  export { DeviceCodeClient } from './client/DeviceCodeClient.js';
@@ -11,6 +11,7 @@ export { DEFAULT_SYSTEM_OPTIONS } from './config/ClientConfiguration.js';
11
11
  export { AuthToken, AuthToken as IdToken } from './account/AuthToken.js';
12
12
  export { CcsCredentialType } from './account/CcsCredential.js';
13
13
  export { Authority } from './authority/Authority.js';
14
+ export { AzureCloudInstance } from './authority/AuthorityOptions.js';
14
15
  export { AuthorityFactory } from './authority/AuthorityFactory.js';
15
16
  export { AuthorityType } from './authority/AuthorityType.js';
16
17
  export { ProtocolMode } from './authority/ProtocolMode.js';
@@ -43,6 +44,9 @@ export { StringUtils } from './utils/StringUtils.js';
43
44
  export { ProtocolUtils } from './utils/ProtocolUtils.js';
44
45
  export { TimeUtils } from './utils/TimeUtils.js';
45
46
  export { ServerTelemetryManager } from './telemetry/server/ServerTelemetryManager.js';
47
+ export { PerformanceEventStatus, PerformanceEvents } from './telemetry/performance/PerformanceEvent.js';
48
+ export { PerformanceClient } from './telemetry/performance/PerformanceClient.js';
49
+ export { StubPerformanceClient } from './telemetry/performance/StubPerformanceClient.js';
46
50
  export { PopTokenGenerator } from './crypto/PopTokenGenerator.js';
47
51
  export { version } from './packageMetadata.js';
48
52
  //# sourceMappingURL=index.js.map
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -1,4 +1,4 @@
1
- /*! @azure/msal-common v6.0.0 2022-01-04 */
1
+ /*! @azure/msal-common v6.3.0-beta.0 2022-04-27 */
2
2
  'use strict';
3
3
  import { StringUtils } from '../utils/StringUtils.js';
4
4
  import { Constants } from '../utils/Constants.js';
@@ -31,7 +31,7 @@ var Logger = /** @class */ (function () {
31
31
  this.localCallback = loggerOptions.loggerCallback || defaultLoggerCallback;
32
32
  this.piiLoggingEnabled = loggerOptions.piiLoggingEnabled || false;
33
33
  this.level = typeof (loggerOptions.logLevel) === "number" ? loggerOptions.logLevel : LogLevel.Info;
34
- this.correlationId = loggerOptions.correlationId || "";
34
+ this.correlationId = loggerOptions.correlationId || Constants.EMPTY_STRING;
35
35
  this.packageName = packageName || Constants.EMPTY_STRING;
36
36
  this.packageVersion = packageVersion || Constants.EMPTY_STRING;
37
37
  }
@@ -61,7 +61,7 @@ var Logger = /** @class */ (function () {
61
61
  logHeader = "[" + timestamp + "]";
62
62
  }
63
63
  var log = logHeader + " : " + this.packageName + "@" + this.packageVersion + " : " + LogLevel[options.logLevel] + " - " + logMessage;
64
- // debug(`msal:${LogLevel[options.logLevel]}${options.containsPii ? "-Pii": ""}${options.context ? `:${options.context}` : ""}`)(logMessage);
64
+ // debug(`msal:${LogLevel[options.logLevel]}${options.containsPii ? "-Pii": Constants.EMPTY_STRING}${options.context ? `:${options.context}` : Constants.EMPTY_STRING}`)(logMessage);
65
65
  this.executeCallback(options.logLevel, log, options.containsPii || false);
66
66
  };
67
67
  /**
@@ -79,7 +79,7 @@ var Logger = /** @class */ (function () {
79
79
  this.logMessage(message, {
80
80
  logLevel: LogLevel.Error,
81
81
  containsPii: false,
82
- correlationId: correlationId || ""
82
+ correlationId: correlationId || Constants.EMPTY_STRING
83
83
  });
84
84
  };
85
85
  /**
@@ -89,7 +89,7 @@ var Logger = /** @class */ (function () {
89
89
  this.logMessage(message, {
90
90
  logLevel: LogLevel.Error,
91
91
  containsPii: true,
92
- correlationId: correlationId || ""
92
+ correlationId: correlationId || Constants.EMPTY_STRING
93
93
  });
94
94
  };
95
95
  /**
@@ -99,7 +99,7 @@ var Logger = /** @class */ (function () {
99
99
  this.logMessage(message, {
100
100
  logLevel: LogLevel.Warning,
101
101
  containsPii: false,
102
- correlationId: correlationId || ""
102
+ correlationId: correlationId || Constants.EMPTY_STRING
103
103
  });
104
104
  };
105
105
  /**
@@ -109,7 +109,7 @@ var Logger = /** @class */ (function () {
109
109
  this.logMessage(message, {
110
110
  logLevel: LogLevel.Warning,
111
111
  containsPii: true,
112
- correlationId: correlationId || ""
112
+ correlationId: correlationId || Constants.EMPTY_STRING
113
113
  });
114
114
  };
115
115
  /**
@@ -119,7 +119,7 @@ var Logger = /** @class */ (function () {
119
119
  this.logMessage(message, {
120
120
  logLevel: LogLevel.Info,
121
121
  containsPii: false,
122
- correlationId: correlationId || ""
122
+ correlationId: correlationId || Constants.EMPTY_STRING
123
123
  });
124
124
  };
125
125
  /**
@@ -129,7 +129,7 @@ var Logger = /** @class */ (function () {
129
129
  this.logMessage(message, {
130
130
  logLevel: LogLevel.Info,
131
131
  containsPii: true,
132
- correlationId: correlationId || ""
132
+ correlationId: correlationId || Constants.EMPTY_STRING
133
133
  });
134
134
  };
135
135
  /**
@@ -139,7 +139,7 @@ var Logger = /** @class */ (function () {
139
139
  this.logMessage(message, {
140
140
  logLevel: LogLevel.Verbose,
141
141
  containsPii: false,
142
- correlationId: correlationId || ""
142
+ correlationId: correlationId || Constants.EMPTY_STRING
143
143
  });
144
144
  };
145
145
  /**
@@ -149,7 +149,7 @@ var Logger = /** @class */ (function () {
149
149
  this.logMessage(message, {
150
150
  logLevel: LogLevel.Verbose,
151
151
  containsPii: true,
152
- correlationId: correlationId || ""
152
+ correlationId: correlationId || Constants.EMPTY_STRING
153
153
  });
154
154
  };
155
155
  /**
@@ -159,7 +159,7 @@ var Logger = /** @class */ (function () {
159
159
  this.logMessage(message, {
160
160
  logLevel: LogLevel.Trace,
161
161
  containsPii: false,
162
- correlationId: correlationId || ""
162
+ correlationId: correlationId || Constants.EMPTY_STRING
163
163
  });
164
164
  };
165
165
  /**
@@ -169,7 +169,7 @@ var Logger = /** @class */ (function () {
169
169
  this.logMessage(message, {
170
170
  logLevel: LogLevel.Trace,
171
171
  containsPii: true,
172
- correlationId: correlationId || ""
172
+ correlationId: correlationId || Constants.EMPTY_STRING
173
173
  });
174
174
  };
175
175
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"Logger.js","sources":["../../src/logger/Logger.ts"],"sourcesContent":["/*\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport { StringUtils } from \"../utils/StringUtils\";\nimport { LoggerOptions } from \"../config/ClientConfiguration\";\nimport { Constants } from \"../utils/Constants\";\n\n/**\n * Options for logger messages.\n */\nexport type LoggerMessageOptions = {\n logLevel: LogLevel,\n containsPii?: boolean,\n context?: string,\n correlationId?: string\n};\n\n/**\n * Log message level.\n */\nexport enum LogLevel {\n Error,\n Warning,\n Info,\n Verbose,\n Trace\n}\n\n/**\n * Callback to send the messages to.\n */\nexport interface ILoggerCallback {\n (level: LogLevel, message: string, containsPii: boolean): void;\n}\n\n/**\n * Class which facilitates logging of messages to a specific place.\n */\nexport class Logger {\n\n // Correlation ID for request, usually set by user.\n private correlationId: string;\n\n // Current log level, defaults to info.\n private level: LogLevel = LogLevel.Info;\n\n // Boolean describing whether PII logging is allowed.\n private piiLoggingEnabled: boolean;\n\n // Callback to send messages to.\n private localCallback: ILoggerCallback;\n\n // Package name implementing this logger\n private packageName: string;\n\n // Package version implementing this logger\n private packageVersion: string;\n\n constructor(loggerOptions: LoggerOptions, packageName?: string, packageVersion?: string) {\n const defaultLoggerCallback = () => {\n return;\n };\n this.localCallback = loggerOptions.loggerCallback || defaultLoggerCallback;\n this.piiLoggingEnabled = loggerOptions.piiLoggingEnabled || false;\n this.level = typeof(loggerOptions.logLevel) === \"number\" ? loggerOptions.logLevel : LogLevel.Info;\n this.correlationId = loggerOptions.correlationId || \"\";\n\n this.packageName = packageName || Constants.EMPTY_STRING;\n this.packageVersion = packageVersion || Constants.EMPTY_STRING;\n }\n\n /**\n * Create new Logger with existing configurations.\n */\n public clone(packageName: string, packageVersion: string, correlationId?: string): Logger {\n return new Logger({loggerCallback: this.localCallback, piiLoggingEnabled: this.piiLoggingEnabled, logLevel: this.level, correlationId: correlationId || this.correlationId}, packageName, packageVersion);\n }\n\n /**\n * Log message with required options.\n */\n private logMessage(logMessage: string, options: LoggerMessageOptions): void {\n if ((options.logLevel > this.level) || (!this.piiLoggingEnabled && options.containsPii)) {\n return;\n }\n const timestamp = new Date().toUTCString();\n\n // Add correlationId to logs if set, correlationId provided on log messages take precedence\n let logHeader: string;\n if (!StringUtils.isEmpty(options.correlationId)) {\n logHeader = `[${timestamp}] : [${options.correlationId}]`;\n } else if (!StringUtils.isEmpty(this.correlationId)) {\n logHeader = `[${timestamp}] : [${this.correlationId}]`;\n } else {\n logHeader = `[${timestamp}]`;\n }\n\n const log = `${logHeader} : ${this.packageName}@${this.packageVersion} : ${LogLevel[options.logLevel]} - ${logMessage}`;\n // debug(`msal:${LogLevel[options.logLevel]}${options.containsPii ? \"-Pii\": \"\"}${options.context ? `:${options.context}` : \"\"}`)(logMessage);\n this.executeCallback(options.logLevel, log, options.containsPii || false);\n }\n\n /**\n * Execute callback with message.\n */\n executeCallback(level: LogLevel, message: string, containsPii: boolean): void {\n if (this.localCallback) {\n this.localCallback(level, message, containsPii);\n }\n }\n\n /**\n * Logs error messages.\n */\n error(message: string, correlationId?: string): void {\n this.logMessage(message, {\n logLevel: LogLevel.Error,\n containsPii: false,\n correlationId: correlationId || \"\"\n });\n }\n\n /**\n * Logs error messages with PII.\n */\n errorPii(message: string, correlationId?: string): void {\n this.logMessage(message, {\n logLevel: LogLevel.Error,\n containsPii: true,\n correlationId: correlationId || \"\"\n });\n }\n\n /**\n * Logs warning messages.\n */\n warning(message: string, correlationId?: string): void {\n this.logMessage(message, {\n logLevel: LogLevel.Warning,\n containsPii: false,\n correlationId: correlationId || \"\"\n });\n }\n\n /**\n * Logs warning messages with PII.\n */\n warningPii(message: string, correlationId?: string): void {\n this.logMessage(message, {\n logLevel: LogLevel.Warning,\n containsPii: true,\n correlationId: correlationId || \"\"\n });\n }\n\n /**\n * Logs info messages.\n */\n info(message: string, correlationId?: string): void {\n this.logMessage(message, {\n logLevel: LogLevel.Info,\n containsPii: false,\n correlationId: correlationId || \"\"\n });\n }\n\n /**\n * Logs info messages with PII.\n */\n infoPii(message: string, correlationId?: string): void {\n this.logMessage(message, {\n logLevel: LogLevel.Info,\n containsPii: true,\n correlationId: correlationId || \"\"\n });\n }\n\n /**\n * Logs verbose messages.\n */\n verbose(message: string, correlationId?: string): void {\n this.logMessage(message, {\n logLevel: LogLevel.Verbose,\n containsPii: false,\n correlationId: correlationId || \"\"\n });\n }\n\n /**\n * Logs verbose messages with PII.\n */\n verbosePii(message: string, correlationId?: string): void {\n this.logMessage(message, {\n logLevel: LogLevel.Verbose,\n containsPii: true,\n correlationId: correlationId || \"\"\n });\n }\n\n /**\n * Logs trace messages.\n */\n trace(message: string, correlationId?: string): void {\n this.logMessage(message, {\n logLevel: LogLevel.Trace,\n containsPii: false,\n correlationId: correlationId || \"\"\n });\n }\n\n /**\n * Logs trace messages with PII.\n */\n tracePii(message: string, correlationId?: string): void {\n this.logMessage(message, {\n logLevel: LogLevel.Trace,\n containsPii: true,\n correlationId: correlationId || \"\"\n });\n }\n\n /**\n * Returns whether PII Logging is enabled or not.\n */\n isPiiLoggingEnabled(): boolean {\n return this.piiLoggingEnabled || false;\n }\n}\n"],"names":[],"mappings":";;;;;AAAA;;;;AAmBA;;;IAGY;AAAZ,WAAY,QAAQ;IAChB,yCAAK,CAAA;IACL,6CAAO,CAAA;IACP,uCAAI,CAAA;IACJ,6CAAO,CAAA;IACP,yCAAK,CAAA;AACT,CAAC,EANW,QAAQ,KAAR,QAAQ,QAMnB;AASD;;;;IAuBI,gBAAY,aAA4B,EAAE,WAAoB,EAAE,cAAuB;;QAd/E,UAAK,GAAa,QAAQ,CAAC,IAAI,CAAC;QAepC,IAAM,qBAAqB,GAAG;YAC1B,OAAO;SACV,CAAC;QACF,IAAI,CAAC,aAAa,GAAG,aAAa,CAAC,cAAc,IAAI,qBAAqB,CAAC;QAC3E,IAAI,CAAC,iBAAiB,GAAG,aAAa,CAAC,iBAAiB,IAAI,KAAK,CAAC;QAClE,IAAI,CAAC,KAAK,GAAG,QAAO,aAAa,CAAC,QAAQ,CAAC,KAAK,QAAQ,GAAG,aAAa,CAAC,QAAQ,GAAG,QAAQ,CAAC,IAAI,CAAC;QAClG,IAAI,CAAC,aAAa,GAAG,aAAa,CAAC,aAAa,IAAI,EAAE,CAAC;QAEvD,IAAI,CAAC,WAAW,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AI,KAAK,CAAC;KAC1C;IACL,aAAC;AAAD,CAAC;;;;"}
1
+ {"version":3,"file":"Logger.js","sources":["../../src/logger/Logger.ts"],"sourcesContent":["/*\r\n * Copyright (c) Microsoft Corporation. All rights reserved.\r\n * Licensed under the MIT License.\r\n */\r\n\r\nimport { StringUtils } from \"../utils/StringUtils\";\r\nimport { LoggerOptions } from \"../config/ClientConfiguration\";\r\nimport { Constants } from \"../utils/Constants\";\r\n\r\n/**\r\n * Options for logger messages.\r\n */\r\nexport type LoggerMessageOptions = {\r\n logLevel: LogLevel,\r\n containsPii?: boolean,\r\n context?: string,\r\n correlationId?: string\r\n};\r\n\r\n/**\r\n * Log message level.\r\n */\r\nexport enum LogLevel {\r\n Error,\r\n Warning,\r\n Info,\r\n Verbose,\r\n Trace\r\n}\r\n\r\n/**\r\n * Callback to send the messages to.\r\n */\r\nexport interface ILoggerCallback {\r\n (level: LogLevel, message: string, containsPii: boolean): void;\r\n}\r\n\r\n/**\r\n * Class which facilitates logging of messages to a specific place.\r\n */\r\nexport class Logger {\r\n\r\n // Correlation ID for request, usually set by user.\r\n private correlationId: string;\r\n\r\n // Current log level, defaults to info.\r\n private level: LogLevel = LogLevel.Info;\r\n\r\n // Boolean describing whether PII logging is allowed.\r\n private piiLoggingEnabled: boolean;\r\n\r\n // Callback to send messages to.\r\n private localCallback: ILoggerCallback;\r\n\r\n // Package name implementing this logger\r\n private packageName: string;\r\n\r\n // Package version implementing this logger\r\n private packageVersion: string;\r\n\r\n constructor(loggerOptions: LoggerOptions, packageName?: string, packageVersion?: string) {\r\n const defaultLoggerCallback = () => {\r\n return;\r\n };\r\n this.localCallback = loggerOptions.loggerCallback || defaultLoggerCallback;\r\n this.piiLoggingEnabled = loggerOptions.piiLoggingEnabled || false;\r\n this.level = typeof(loggerOptions.logLevel) === \"number\" ? loggerOptions.logLevel : LogLevel.Info;\r\n this.correlationId = loggerOptions.correlationId || Constants.EMPTY_STRING;\r\n\r\n this.packageName = packageName || Constants.EMPTY_STRING;\r\n this.packageVersion = packageVersion || Constants.EMPTY_STRING;\r\n }\r\n\r\n /**\r\n * Create new Logger with existing configurations.\r\n */\r\n public clone(packageName: string, packageVersion: string, correlationId?: string): Logger {\r\n return new Logger({loggerCallback: this.localCallback, piiLoggingEnabled: this.piiLoggingEnabled, logLevel: this.level, correlationId: correlationId || this.correlationId}, packageName, packageVersion);\r\n }\r\n\r\n /**\r\n * Log message with required options.\r\n */\r\n private logMessage(logMessage: string, options: LoggerMessageOptions): void {\r\n if ((options.logLevel > this.level) || (!this.piiLoggingEnabled && options.containsPii)) {\r\n return;\r\n }\r\n const timestamp = new Date().toUTCString();\r\n\r\n // Add correlationId to logs if set, correlationId provided on log messages take precedence\r\n let logHeader: string;\r\n if (!StringUtils.isEmpty(options.correlationId)) {\r\n logHeader = `[${timestamp}] : [${options.correlationId}]`;\r\n } else if (!StringUtils.isEmpty(this.correlationId)) {\r\n logHeader = `[${timestamp}] : [${this.correlationId}]`;\r\n } else {\r\n logHeader = `[${timestamp}]`;\r\n }\r\n\r\n const log = `${logHeader} : ${this.packageName}@${this.packageVersion} : ${LogLevel[options.logLevel]} - ${logMessage}`;\r\n // debug(`msal:${LogLevel[options.logLevel]}${options.containsPii ? \"-Pii\": Constants.EMPTY_STRING}${options.context ? `:${options.context}` : Constants.EMPTY_STRING}`)(logMessage);\r\n this.executeCallback(options.logLevel, log, options.containsPii || false);\r\n }\r\n\r\n /**\r\n * Execute callback with message.\r\n */\r\n executeCallback(level: LogLevel, message: string, containsPii: boolean): void {\r\n if (this.localCallback) {\r\n this.localCallback(level, message, containsPii);\r\n }\r\n }\r\n\r\n /**\r\n * Logs error messages.\r\n */\r\n error(message: string, correlationId?: string): void {\r\n this.logMessage(message, {\r\n logLevel: LogLevel.Error,\r\n containsPii: false,\r\n correlationId: correlationId || Constants.EMPTY_STRING\r\n });\r\n }\r\n\r\n /**\r\n * Logs error messages with PII.\r\n */\r\n errorPii(message: string, correlationId?: string): void {\r\n this.logMessage(message, {\r\n logLevel: LogLevel.Error,\r\n containsPii: true,\r\n correlationId: correlationId || Constants.EMPTY_STRING\r\n });\r\n }\r\n\r\n /**\r\n * Logs warning messages.\r\n */\r\n warning(message: string, correlationId?: string): void {\r\n this.logMessage(message, {\r\n logLevel: LogLevel.Warning,\r\n containsPii: false,\r\n correlationId: correlationId || Constants.EMPTY_STRING\r\n });\r\n }\r\n\r\n /**\r\n * Logs warning messages with PII.\r\n */\r\n warningPii(message: string, correlationId?: string): void {\r\n this.logMessage(message, {\r\n logLevel: LogLevel.Warning,\r\n containsPii: true,\r\n correlationId: correlationId || Constants.EMPTY_STRING\r\n });\r\n }\r\n\r\n /**\r\n * Logs info messages.\r\n */\r\n info(message: string, correlationId?: string): void {\r\n this.logMessage(message, {\r\n logLevel: LogLevel.Info,\r\n containsPii: false,\r\n correlationId: correlationId || Constants.EMPTY_STRING\r\n });\r\n }\r\n\r\n /**\r\n * Logs info messages with PII.\r\n */\r\n infoPii(message: string, correlationId?: string): void {\r\n this.logMessage(message, {\r\n logLevel: LogLevel.Info,\r\n containsPii: true,\r\n correlationId: correlationId || Constants.EMPTY_STRING\r\n });\r\n }\r\n\r\n /**\r\n * Logs verbose messages.\r\n */\r\n verbose(message: string, correlationId?: string): void {\r\n this.logMessage(message, {\r\n logLevel: LogLevel.Verbose,\r\n containsPii: false,\r\n correlationId: correlationId || Constants.EMPTY_STRING\r\n });\r\n }\r\n\r\n /**\r\n * Logs verbose messages with PII.\r\n */\r\n verbosePii(message: string, correlationId?: string): void {\r\n this.logMessage(message, {\r\n logLevel: LogLevel.Verbose,\r\n containsPii: true,\r\n correlationId: correlationId || Constants.EMPTY_STRING\r\n });\r\n }\r\n\r\n /**\r\n * Logs trace messages.\r\n */\r\n trace(message: string, correlationId?: string): void {\r\n this.logMessage(message, {\r\n logLevel: LogLevel.Trace,\r\n containsPii: false,\r\n correlationId: correlationId || Constants.EMPTY_STRING\r\n });\r\n }\r\n\r\n /**\r\n * Logs trace messages with PII.\r\n */\r\n tracePii(message: string, correlationId?: string): void {\r\n this.logMessage(message, {\r\n logLevel: LogLevel.Trace,\r\n containsPii: true,\r\n correlationId: correlationId || Constants.EMPTY_STRING\r\n });\r\n }\r\n\r\n /**\r\n * Returns whether PII Logging is enabled or not.\r\n */\r\n isPiiLoggingEnabled(): boolean {\r\n return this.piiLoggingEnabled || false;\r\n }\r\n}\r\n"],"names":[],"mappings":";;;;;AAAA;;;;AAmBA;;;IAGY;AAAZ,WAAY,QAAQ;IAChB,yCAAK,CAAA;IACL,6CAAO,CAAA;IACP,uCAAI,CAAA;IACJ,6CAAO,CAAA;IACP,yCAAK,CAAA;AACT,CAAC,EANW,QAAQ,KAAR,QAAQ,QAMnB;AASD;;;;IAuBI,gBAAY,aAA4B,EAAE,WAAoB,EAAE,cAAuB;;QAd/E,UAAK,GAAa,QAAQ,CAAC,IAAI,CAAC;QAepC,IAAM,qBAAqB,GAAG;YAC1B,OAAO;SACV,CAAC;QACF,IAAI,CAAC,aAAa,GAAG,aAAa,CAAC,cAAc,IAAI,qBAAqB,CAAC;QAC3E,IAAI,CAAC,iBAAiB,GAAG,aAAa,CAAC,iBAAiB,IAAI,KAAK,CAAC;QAClE,IAAI,CAAC,KAAK,GAAG,QAAO,aAAa,CAAC,QAAQ,CAAC,KAAK,QAAQ,GAAG,aAAa,CAAC,QAAQ,GAAG,QAAQ,CAAC,IAAI,CAAC;QAClG,IAAI,CAAC,aAAa,GAAG,aAAa,CAAC,aAAa,IAAI,SAAS,CAAC,YAAY,CAAC;QAE3E,IAAI,CAAC,WAAW,GAAG,WAAW,IAAI,SAAS,CAAC,YAAY,CAAC;QACzD,IAAI,CAAC,cAAc,GAAG,cAAc,IAAI,SAAS,CAAC,YAAY,CAAC;KAClE;;;;IAKM,sBAAK,GAAZ,UAAa,WAAmB,EAAE,cAAsB,EAAE,aAAsB;QAC5E,OAAO,IAAI,MAAM,CAAC,EAAC,cAAc,EAAE,IAAI,CAAC,aAAa,EAAE,iBAAiB,EAAE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
7
7
  body?: string;
8
+ proxyUrl?: string;
8
9
  };
9
10
  /**
10
11
  * Client network interface to send backend requests.
@@ -1 +1 @@
1
- {"version":3,"file":"INetworkModule.d.ts","sourceRoot":"","sources":["../../src/network/INetworkModule.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,eAAe,EAAE,MAAM,kBAAkB,CAAC;AAEnD;;GAEG;AACH,oBAAY,qBAAqB,GAAG;IAChC,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACjC,IAAI,CAAC,EAAE,MAAM,CAAC;CACjB,CAAC;AAEF;;;GAGG;AACH,MAAM,WAAW,cAAc;IAE3B;;;;;OAKG;IACH,mBAAmB,CAAC,CAAC,EAAE,GAAG,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,qBAAqB,EAAE,iBAAiB,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC,eAAe,CAAC,CAAC,CAAC,CAAC,CAAC;IAE9H;;;;;OAKG;IACH,oBAAoB,CAAC,CAAC,EAAE,GAAG,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,qBAAqB,GAAG,OAAO,CAAC,eAAe,CAAC,CAAC,CAAC,CAAC,CAAC;CACtG;AAED,eAAO,MAAM,oBAAoB,EAAE,cASlC,CAAC"}
1
+ {"version":3,"file":"INetworkModule.d.ts","sourceRoot":"","sources":["../../src/network/INetworkModule.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,eAAe,EAAE,MAAM,kBAAkB,CAAC;AAEnD;;GAEG;AACH,oBAAY,qBAAqB,GAAG;IAChC,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACjC,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,QAAQ,CAAC,EAAE,MAAM,CAAC;CACrB,CAAC;AAEF;;;GAGG;AACH,MAAM,WAAW,cAAc;IAE3B;;;;;OAKG;IACH,mBAAmB,CAAC,CAAC,EAAE,GAAG,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,qBAAqB,EAAE,iBAAiB,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC,eAAe,CAAC,CAAC,CAAC,CAAC,CAAC;IAE9H;;;;;OAKG;IACH,oBAAoB,CAAC,CAAC,EAAE,GAAG,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,qBAAqB,GAAG,OAAO,CAAC,eAAe,CAAC,CAAC,CAAC,CAAC,CAAC;CACtG;AAED,eAAO,MAAM,oBAAoB,EAAE,cASlC,CAAC"}
@@ -1,4 +1,4 @@
1
- /*! @azure/msal-common v6.0.0 2022-01-04 */
1
+ /*! @azure/msal-common v6.3.0-beta.0 2022-04-27 */
2
2
  'use strict';
3
3
  import { AuthError } from '../error/AuthError.js';
4
4
 
@@ -1 +1 @@
1
- {"version":3,"file":"INetworkModule.js","sources":["../../src/network/INetworkModule.ts"],"sourcesContent":["/*\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport { AuthError } from \"../error/AuthError\";\nimport { NetworkResponse } from \"./NetworkManager\";\n\n/**\n * Options allowed by network request APIs.\n */\nexport type NetworkRequestOptions = {\n headers?: Record<string, string>,\n body?: string;\n};\n\n/**\n * Client network interface to send backend requests.\n * @interface\n */\nexport interface INetworkModule {\n\n /**\n * Interface function for async network \"GET\" requests. Based on the Fetch standard: https://fetch.spec.whatwg.org/\n * @param url\n * @param requestParams\n * @param enableCaching\n */\n sendGetRequestAsync<T>(url: string, options?: NetworkRequestOptions, cancellationToken?: number): Promise<NetworkResponse<T>>;\n\n /**\n * Interface function for async network \"POST\" requests. Based on the Fetch standard: https://fetch.spec.whatwg.org/\n * @param url\n * @param requestParams\n * @param enableCaching\n */\n sendPostRequestAsync<T>(url: string, options?: NetworkRequestOptions): Promise<NetworkResponse<T>>;\n}\n\nexport const StubbedNetworkModule: INetworkModule = {\n sendGetRequestAsync: () => {\n const notImplErr = \"Network interface - sendGetRequestAsync() has not been implemented for the Network interface.\";\n return Promise.reject(AuthError.createUnexpectedError(notImplErr));\n },\n sendPostRequestAsync: () => {\n const notImplErr = \"Network interface - sendPostRequestAsync() has not been implemented for the Network interface.\";\n return Promise.reject(AuthError.createUnexpectedError(notImplErr));\n }\n};\n"],"names":[],"mappings":";;;;AAAA;;;;IAuCa,oBAAoB,GAAmB;IAChD,mBAAmB,EAAE;QACjB,IAAM,UAAU,GAAG,+FAA+F,CAAC;QACnH,OAAO,OAAO,CAAC,MAAM,CAAC,SAAS,CAAC,qBAAqB,CAAC,UAAU,CAAC,CAAC,CAAC;KACtE;IACD,oBAAoB,EAAE;QAClB,IAAM,UAAU,GAAG,gGAAgG,CAAC;QACpH,OAAO,OAAO,CAAC,MAAM,CAAC,SAAS,CAAC,qBAAqB,CAAC,UAAU,CAAC,CAAC,CAAC;KACtE;;;;;"}
1
+ {"version":3,"file":"INetworkModule.js","sources":["../../src/network/INetworkModule.ts"],"sourcesContent":["/*\r\n * Copyright (c) Microsoft Corporation. All rights reserved.\r\n * Licensed under the MIT License.\r\n */\r\n\r\nimport { AuthError } from \"../error/AuthError\";\r\nimport { NetworkResponse } from \"./NetworkManager\";\r\n\r\n/**\r\n * Options allowed by network request APIs.\r\n */\r\nexport type NetworkRequestOptions = {\r\n headers?: Record<string, string>,\r\n body?: string;\r\n proxyUrl?: string;\r\n};\r\n\r\n/**\r\n * Client network interface to send backend requests.\r\n * @interface\r\n */\r\nexport interface INetworkModule {\r\n\r\n /**\r\n * Interface function for async network \"GET\" requests. Based on the Fetch standard: https://fetch.spec.whatwg.org/\r\n * @param url\r\n * @param requestParams\r\n * @param enableCaching\r\n */\r\n sendGetRequestAsync<T>(url: string, options?: NetworkRequestOptions, cancellationToken?: number): Promise<NetworkResponse<T>>;\r\n\r\n /**\r\n * Interface function for async network \"POST\" requests. Based on the Fetch standard: https://fetch.spec.whatwg.org/\r\n * @param url\r\n * @param requestParams\r\n * @param enableCaching\r\n */\r\n sendPostRequestAsync<T>(url: string, options?: NetworkRequestOptions): Promise<NetworkResponse<T>>;\r\n}\r\n\r\nexport const StubbedNetworkModule: INetworkModule = {\r\n sendGetRequestAsync: () => {\r\n const notImplErr = \"Network interface - sendGetRequestAsync() has not been implemented for the Network interface.\";\r\n return Promise.reject(AuthError.createUnexpectedError(notImplErr));\r\n },\r\n sendPostRequestAsync: () => {\r\n const notImplErr = \"Network interface - sendPostRequestAsync() has not been implemented for the Network interface.\";\r\n return Promise.reject(AuthError.createUnexpectedError(notImplErr));\r\n }\r\n};\r\n"],"names":[],"mappings":";;;;AAAA;;;;IAwCa,oBAAoB,GAAmB;IAChD,mBAAmB,EAAE;QACjB,IAAM,UAAU,GAAG,+FAA+F,CAAC;QACnH,OAAO,OAAO,CAAC,MAAM,CAAC,SAAS,CAAC,qBAAqB,CAAC,UAAU,CAAC,CAAC,CAAC;KACtE;IACD,oBAAoB,EAAE;QAClB,IAAM,UAAU,GAAG,gGAAgG,CAAC;QACpH,OAAO,OAAO,CAAC,MAAM,CAAC,SAAS,CAAC,qBAAqB,CAAC,UAAU,CAAC,CAAC,CAAC;KACtE;;;;;"}
@@ -1,4 +1,4 @@
1
- /*! @azure/msal-common v6.0.0 2022-01-04 */
1
+ /*! @azure/msal-common v6.3.0-beta.0 2022-04-27 */
2
2
  'use strict';
3
3
  import { __awaiter, __generator } from '../_virtual/_tslib.js';
4
4
  import { ThrottlingUtils } from './ThrottlingUtils.js';
@@ -1 +1 @@
1
- {"version":3,"file":"NetworkManager.js","sources":["../../src/network/NetworkManager.ts"],"sourcesContent":["/*\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport { INetworkModule, NetworkRequestOptions } from \"./INetworkModule\";\nimport { RequestThumbprint } from \"./RequestThumbprint\";\nimport { ThrottlingUtils } from \"./ThrottlingUtils\";\nimport { CacheManager } from \"../cache/CacheManager\";\nimport { ClientAuthError } from \"../error/ClientAuthError\";\nimport { AuthError } from \"../error/AuthError\";\n\nexport type NetworkResponse<T> = {\n headers: Record<string, string>;\n body: T;\n status: number;\n};\n\nexport class NetworkManager {\n private networkClient: INetworkModule;\n private cacheManager: CacheManager;\n\n constructor(networkClient: INetworkModule, cacheManager: CacheManager) {\n this.networkClient = networkClient;\n this.cacheManager = cacheManager;\n }\n\n /**\n * Wraps sendPostRequestAsync with necessary preflight and postflight logic\n * @param thumbprint\n * @param tokenEndpoint\n * @param options\n */\n async sendPostRequest<T>(thumbprint: RequestThumbprint, tokenEndpoint: string, options: NetworkRequestOptions): Promise<NetworkResponse<T>> {\n ThrottlingUtils.preProcess(this.cacheManager, thumbprint);\n\n let response;\n try {\n response = await this.networkClient.sendPostRequestAsync<T>(tokenEndpoint, options);\n } catch (e) {\n if (e instanceof AuthError) {\n throw e;\n } else {\n throw ClientAuthError.createNetworkError(tokenEndpoint, e);\n }\n }\n\n ThrottlingUtils.postProcess(this.cacheManager, thumbprint, response);\n\n return response;\n }\n}\n"],"names":[],"mappings":";;;;;;;AAAA;;;;;IAsBI,wBAAY,aAA6B,EAAE,YAA0B;QACjE,IAAI,CAAC,aAAa,GAAG,aAAa,CAAC;QACnC,IAAI,CAAC,YAAY,GAAG,YAAY,CAAC;KACpC;;;;;;;IAQK,wCAAe,GAArB,UAAyB,UAA6B,EAAE,aAAqB,EAAE,OAA8B;;;;;;wBACzG,eAAe,CAAC,UAAU,CAAC,IAAI,CAAC,YAAY,EAAE,UAAU,CAAC,CAAC;;;;wBAI3C,qBAAM,IAAI,CAAC,aAAa,CAAC,oBAAoB,CAAI,aAAa,EAAE,OAAO,CAAC,EAAA;;wBAAnF,QAAQ,GAAG,SAAwE,CAAC;;;;wBAEpF,IAAI,GAAC,YAAY,SAAS,EAAE;4BACxB,MAAM,GAAC,CAAC;yBACX;6BAAM;4BACH,MAAM,eAAe,CAAC,kBAAkB,CAAC,aAAa,EAAE,GAAC,CAAC,CAAC;yBAC9D;;wBAGL,eAAe,CAAC,WAAW,CAAC,IAAI,CAAC,YAAY,EAAE,UAAU,EAAE,QAAQ,CAAC,CAAC;wBAErE,sBAAO,QAAQ,EAAC;;;;KACnB;IACL,qBAAC;AAAD,CAAC;;;;"}
1
+ {"version":3,"file":"NetworkManager.js","sources":["../../src/network/NetworkManager.ts"],"sourcesContent":["/*\r\n * Copyright (c) Microsoft Corporation. All rights reserved.\r\n * Licensed under the MIT License.\r\n */\r\n\r\nimport { INetworkModule, NetworkRequestOptions } from \"./INetworkModule\";\r\nimport { RequestThumbprint } from \"./RequestThumbprint\";\r\nimport { ThrottlingUtils } from \"./ThrottlingUtils\";\r\nimport { CacheManager } from \"../cache/CacheManager\";\r\nimport { ClientAuthError } from \"../error/ClientAuthError\";\r\nimport { AuthError } from \"../error/AuthError\";\r\n\r\nexport type NetworkResponse<T> = {\r\n headers: Record<string, string>;\r\n body: T;\r\n status: number;\r\n};\r\n\r\nexport class NetworkManager {\r\n private networkClient: INetworkModule;\r\n private cacheManager: CacheManager;\r\n\r\n constructor(networkClient: INetworkModule, cacheManager: CacheManager) {\r\n this.networkClient = networkClient;\r\n this.cacheManager = cacheManager;\r\n }\r\n\r\n /**\r\n * Wraps sendPostRequestAsync with necessary preflight and postflight logic\r\n * @param thumbprint\r\n * @param tokenEndpoint\r\n * @param options\r\n */\r\n async sendPostRequest<T>(thumbprint: RequestThumbprint, tokenEndpoint: string, options: NetworkRequestOptions): Promise<NetworkResponse<T>> {\r\n ThrottlingUtils.preProcess(this.cacheManager, thumbprint);\r\n\r\n let response;\r\n try {\r\n response = await this.networkClient.sendPostRequestAsync<T>(tokenEndpoint, options);\r\n } catch (e) {\r\n if (e instanceof AuthError) {\r\n throw e;\r\n } else {\r\n throw ClientAuthError.createNetworkError(tokenEndpoint, e);\r\n }\r\n }\r\n\r\n ThrottlingUtils.postProcess(this.cacheManager, thumbprint, response);\r\n\r\n return response;\r\n }\r\n}\r\n"],"names":[],"mappings":";;;;;;;AAAA;;;;;IAsBI,wBAAY,aAA6B,EAAE,YAA0B;QACjE,IAAI,CAAC,aAAa,GAAG,aAAa,CAAC;QACnC,IAAI,CAAC,YAAY,GAAG,YAAY,CAAC;KACpC;;;;;;;IAQK,wCAAe,GAArB,UAAyB,UAA6B,EAAE,aAAqB,EAAE,OAA8B;;;;;;wBACzG,eAAe,CAAC,UAAU,CAAC,IAAI,CAAC,YAAY,EAAE,UAAU,CAAC,CAAC;;;;wBAI3C,qBAAM,IAAI,CAAC,aAAa,CAAC,oBAAoB,CAAI,aAAa,EAAE,OAAO,CAAC,EAAA;;wBAAnF,QAAQ,GAAG,SAAwE,CAAC;;;;wBAEpF,IAAI,GAAC,YAAY,SAAS,EAAE;4BACxB,MAAM,GAAC,CAAC;yBACX;6BAAM;4BACH,MAAM,eAAe,CAAC,kBAAkB,CAAC,aAAa,EAAE,GAAC,CAAC,CAAC;yBAC9D;;wBAGL,eAAe,CAAC,WAAW,CAAC,IAAI,CAAC,YAAY,EAAE,UAAU,EAAE,QAAQ,CAAC,CAAC;wBAErE,sBAAO,QAAQ,EAAC;;;;KACnB;IACL,qBAAC;AAAD,CAAC;;;;"}
@@ -1,4 +1,4 @@
1
- /*! @azure/msal-common v6.0.0 2022-01-04 */
1
+ /*! @azure/msal-common v6.3.0-beta.0 2022-04-27 */
2
2
  'use strict';
3
3
  import { ThrottlingConstants, CacheSchemaType, Constants, HeaderNames } from '../utils/Constants.js';
4
4
  import { ServerError } from '../error/ServerError.js';
@@ -1 +1 @@
1
- {"version":3,"file":"ThrottlingUtils.js","sources":["../../src/network/ThrottlingUtils.ts"],"sourcesContent":["/*\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport { NetworkResponse } from \"./NetworkManager\";\nimport { ServerAuthorizationTokenResponse } from \"../response/ServerAuthorizationTokenResponse\";\nimport { HeaderNames, CacheSchemaType, ThrottlingConstants, Constants } from \"../utils/Constants\";\nimport { CacheManager } from \"../cache/CacheManager\";\nimport { ServerError } from \"../error/ServerError\";\nimport { RequestThumbprint } from \"./RequestThumbprint\";\nimport { ThrottlingEntity } from \"../cache/entities/ThrottlingEntity\";\nimport { BaseAuthRequest } from \"../request/BaseAuthRequest\";\n\nexport class ThrottlingUtils {\n\n /**\n * Prepares a RequestThumbprint to be stored as a key.\n * @param thumbprint\n */\n static generateThrottlingStorageKey(thumbprint: RequestThumbprint): string {\n return `${ThrottlingConstants.THROTTLING_PREFIX}.${JSON.stringify(thumbprint)}`;\n }\n\n /**\n * Performs necessary throttling checks before a network request.\n * @param cacheManager\n * @param thumbprint\n */\n static preProcess(cacheManager: CacheManager, thumbprint: RequestThumbprint): void {\n const key = ThrottlingUtils.generateThrottlingStorageKey(thumbprint);\n const value = cacheManager.getThrottlingCache(key);\n\n if (value) {\n if (value.throttleTime < Date.now()) {\n cacheManager.removeItem(key, CacheSchemaType.THROTTLING);\n return;\n }\n throw new ServerError(value.errorCodes?.join(\" \") || Constants.EMPTY_STRING, value.errorMessage, value.subError);\n }\n }\n\n /**\n * Performs necessary throttling checks after a network request.\n * @param cacheManager\n * @param thumbprint\n * @param response\n */\n static postProcess(cacheManager: CacheManager, thumbprint: RequestThumbprint, response: NetworkResponse<ServerAuthorizationTokenResponse>): void {\n if (ThrottlingUtils.checkResponseStatus(response) || ThrottlingUtils.checkResponseForRetryAfter(response)) {\n const thumbprintValue: ThrottlingEntity = {\n throttleTime: ThrottlingUtils.calculateThrottleTime(parseInt(response.headers[HeaderNames.RETRY_AFTER])),\n error: response.body.error,\n errorCodes: response.body.error_codes,\n errorMessage: response.body.error_description,\n subError: response.body.suberror\n };\n cacheManager.setThrottlingCache(\n ThrottlingUtils.generateThrottlingStorageKey(thumbprint),\n thumbprintValue\n );\n }\n }\n\n /**\n * Checks a NetworkResponse object's status codes against 429 or 5xx\n * @param response\n */\n static checkResponseStatus(response: NetworkResponse<ServerAuthorizationTokenResponse>): boolean {\n return response.status === 429 || response.status >= 500 && response.status < 600;\n }\n\n /**\n * Checks a NetworkResponse object's RetryAfter header\n * @param response\n */\n static checkResponseForRetryAfter(response: NetworkResponse<ServerAuthorizationTokenResponse>): boolean {\n if (response.headers) {\n return response.headers.hasOwnProperty(HeaderNames.RETRY_AFTER) && (response.status < 200 || response.status >= 300);\n }\n return false;\n }\n\n /**\n * Calculates the Unix-time value for a throttle to expire given throttleTime in seconds.\n * @param throttleTime\n */\n static calculateThrottleTime(throttleTime: number): number {\n const time = throttleTime <= 0 ? 0 : throttleTime;\n\n const currentSeconds = Date.now() / 1000;\n return Math.floor(Math.min(\n currentSeconds + (time || ThrottlingConstants.DEFAULT_THROTTLE_TIME_SECONDS),\n currentSeconds + ThrottlingConstants.DEFAULT_MAX_THROTTLE_TIME_SECONDS\n ) * 1000);\n }\n\n static removeThrottle(cacheManager: CacheManager, clientId: string, request: BaseAuthRequest, homeAccountIdentifier?: string): boolean {\n const thumbprint: RequestThumbprint = {\n clientId: clientId,\n authority: request.authority,\n scopes: request.scopes,\n homeAccountIdentifier: homeAccountIdentifier,\n claims: request.claims,\n authenticationScheme: request.authenticationScheme,\n resourceRequestMethod: request.resourceRequestMethod,\n resourceRequestUri: request.resourceRequestUri,\n shrClaims: request.shrClaims,\n sshKid: request.sshKid\n };\n\n const key = this.generateThrottlingStorageKey(thumbprint);\n return cacheManager.removeItem(key, CacheSchemaType.THROTTLING);\n }\n}\n"],"names":[],"mappings":";;;;;AAAA;;;;;IAcA;KAoGC;;;;;IA9FU,4CAA4B,GAAnC,UAAoC,UAA6B;QAC7D,OAAU,mBAAmB,CAAC,iBAAiB,SAAI,IAAI,CAAC,SAAS,CAAC,UAAU,CAAG,CAAC;KACnF;;;;;;IAOM,0BAAU,GAAjB,UAAkB,YAA0B,EAAE,UAA6B;;QACvE,IAAM,GAAG,GAAG,eAAe,CAAC,4BAA4B,CAAC,UAAU,CAAC,CAAC;QACrE,IAAM,KAAK,GAAG,YAAY,CAAC,kBAAkB,CAAC,GAAG,CAAC,CAAC;QAEnD,IAAI,KAAK,EAAE;YACP,IAAI,KAAK,CAAC,YAAY,GAAG,IAAI,CAAC,GAAG,EAAE,EAAE;gBACjC,YAAY,CAAC,UAAU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rights reserved.\r\n * Licensed under the MIT License.\r\n */\r\n\r\nimport { NetworkResponse } from \"./NetworkManager\";\r\nimport { ServerAuthorizationTokenResponse } from \"../response/ServerAuthorizationTokenResponse\";\r\nimport { HeaderNames, CacheSchemaType, ThrottlingConstants, Constants } from \"../utils/Constants\";\r\nimport { CacheManager } from \"../cache/CacheManager\";\r\nimport { ServerError } from \"../error/ServerError\";\r\nimport { RequestThumbprint } from \"./RequestThumbprint\";\r\nimport { ThrottlingEntity } from \"../cache/entities/ThrottlingEntity\";\r\nimport { BaseAuthRequest } from \"../request/BaseAuthRequest\";\r\n\r\nexport class ThrottlingUtils {\r\n\r\n /**\r\n * Prepares a RequestThumbprint to be stored as a key.\r\n * @param thumbprint\r\n */\r\n static generateThrottlingStorageKey(thumbprint: RequestThumbprint): string {\r\n return `${ThrottlingConstants.THROTTLING_PREFIX}.${JSON.stringify(thumbprint)}`;\r\n }\r\n\r\n /**\r\n * Performs necessary throttling checks before a network request.\r\n * @param cacheManager\r\n * @param thumbprint\r\n */\r\n static preProcess(cacheManager: CacheManager, thumbprint: RequestThumbprint): void {\r\n const key = ThrottlingUtils.generateThrottlingStorageKey(thumbprint);\r\n const value = cacheManager.getThrottlingCache(key);\r\n\r\n if (value) {\r\n if (value.throttleTime < Date.now()) {\r\n cacheManager.removeItem(key, CacheSchemaType.THROTTLING);\r\n return;\r\n }\r\n throw new ServerError(value.errorCodes?.join(\" \") || Constants.EMPTY_STRING, value.errorMessage, value.subError);\r\n }\r\n }\r\n\r\n /**\r\n * Performs necessary throttling checks after a network request.\r\n * @param cacheManager\r\n * @param thumbprint\r\n * @param response\r\n */\r\n static postProcess(cacheManager: CacheManager, thumbprint: RequestThumbprint, response: NetworkResponse<ServerAuthorizationTokenResponse>): void {\r\n if (ThrottlingUtils.checkResponseStatus(response) || ThrottlingUtils.checkResponseForRetryAfter(response)) {\r\n const thumbprintValue: ThrottlingEntity = {\r\n throttleTime: ThrottlingUtils.calculateThrottleTime(parseInt(response.headers[HeaderNames.RETRY_AFTER])),\r\n error: response.body.error,\r\n errorCodes: response.body.error_codes,\r\n errorMessage: response.body.error_description,\r\n subError: response.body.suberror\r\n };\r\n cacheManager.setThrottlingCache(\r\n ThrottlingUtils.generateThrottlingStorageKey(thumbprint),\r\n thumbprintValue\r\n );\r\n }\r\n }\r\n\r\n /**\r\n * Checks a NetworkResponse object's status codes against 429 or 5xx\r\n * @param response\r\n */\r\n static checkResponseStatus(response: NetworkResponse<ServerAuthorizationTokenResponse>): boolean {\r\n return response.status === 429 || response.status >= 500 && response.status < 600;\r\n }\r\n\r\n /**\r\n * Checks a NetworkResponse object's RetryAfter header\r\n * @param response\r\n */\r\n static checkResponseForRetryAfter(response: NetworkResponse<ServerAuthorizationTokenResponse>): boolean {\r\n if (response.headers) {\r\n return response.headers.hasOwnProperty(HeaderNames.RETRY_AFTER) && (response.status < 200 || response.status >= 300);\r\n }\r\n return false;\r\n }\r\n\r\n /**\r\n * Calculates the Unix-time value for a throttle to expire given throttleTime in seconds.\r\n * @param throttleTime\r\n */\r\n static calculateThrottleTime(throttleTime: number): number {\r\n const time = throttleTime <= 0 ? 0 : throttleTime;\r\n\r\n const currentSeconds = Date.now() / 1000;\r\n return Math.floor(Math.min(\r\n currentSeconds + (time || ThrottlingConstants.DEFAULT_THROTTLE_TIME_SECONDS),\r\n currentSeconds + ThrottlingConstants.DEFAULT_MAX_THROTTLE_TIME_SECONDS\r\n ) * 1000);\r\n }\r\n\r\n static removeThrottle(cacheManager: CacheManager, clientId: string, request: BaseAuthRequest, homeAccountIdentifier?: string): boolean {\r\n const thumbprint: RequestThumbprint = {\r\n clientId: clientId,\r\n authority: request.authority,\r\n scopes: request.scopes,\r\n homeAccountIdentifier: homeAccountIdentifier,\r\n claims: request.claims,\r\n authenticationScheme: request.authenticationScheme,\r\n resourceRequestMethod: request.resourceRequestMethod,\r\n resourceRequestUri: request.resourceRequestUri,\r\n shrClaims: request.shrClaims,\r\n sshKid: request.sshKid\r\n };\r\n\r\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AC,MAAM;YACtB,qBAAqB,EAAE,qBAAqB;YAC5C,MAAM,EAAE,OAAO,CAAC,MAAM;YACtB,oBAAoB,EAAE,OAAO,CAAC,oBAAoB;YAClD,qBAAqB,EAAE,OAAO,CAAC,qBAAqB;YACpD,kBAAkB,EAAE,OAAO,CAAC,kBAAkB;YAC9C,SAAS,EAAE,OAAO,CAAC,SAAS;YAC5B,MAAM,EAAE,OAAO,CAAC,MAAM;SACzB,CAAC;QAEF,IAAM,GAAG,GAAG,IAAI,CAAC,4BAA4B,CAAC,UAAU,CAAC,CAAC;QAC1D,OAAO,YAAY,CAAC,UAAU,CAAC,GAAG,EAAE,eAAe,CAAC,UAAU,CAAC,CAAC;KACnE;IACL,sBAAC;AAAD,CAAC;;;;"}
@@ -1,3 +1,3 @@
1
1
  export declare const name = "@azure/msal-common";
2
- export declare const version = "6.0.0";
2
+ export declare const version = "6.3.0-beta.0";
3
3
  //# sourceMappingURL=packageMetadata.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"packageMetadata.d.ts","sourceRoot":"","sources":["../src/packageMetadata.ts"],"names":[],"mappings":"AACA,eAAO,MAAM,IAAI,uBAAuB,CAAC;AACzC,eAAO,MAAM,OAAO,UAAU,CAAC"}
1
+ {"version":3,"file":"packageMetadata.d.ts","sourceRoot":"","sources":["../src/packageMetadata.ts"],"names":[],"mappings":"AACA,eAAO,MAAM,IAAI,uBAAuB,CAAC;AACzC,eAAO,MAAM,OAAO,iBAAiB,CAAC"}
@@ -1,8 +1,8 @@
1
- /*! @azure/msal-common v6.0.0 2022-01-04 */
1
+ /*! @azure/msal-common v6.3.0-beta.0 2022-04-27 */
2
2
  'use strict';
3
3
  /* eslint-disable header/header */
4
4
  var name = "@azure/msal-common";
5
- var version = "6.0.0";
5
+ var version = "6.3.0-beta.0";
6
6
 
7
7
  export { name, version };
8
8
  //# sourceMappingURL=packageMetadata.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"packageMetadata.js","sources":["../src/packageMetadata.ts"],"sourcesContent":["/* eslint-disable header/header */\nexport const name = \"@azure/msal-common\";\nexport const version = \"6.0.0\";\n"],"names":[],"mappings":";;AAAA;IACa,IAAI,GAAG,qBAAqB;IAC5B,OAAO,GAAG;;;;"}
1
+ {"version":3,"file":"packageMetadata.js","sources":["../src/packageMetadata.ts"],"sourcesContent":["/* eslint-disable header/header */\nexport const name = \"@azure/msal-common\";\nexport const version = \"6.3.0-beta.0\";\n"],"names":[],"mappings":";;AAAA;IACa,IAAI,GAAG,qBAAqB;IAC5B,OAAO,GAAG;;;;"}
@@ -1,7 +1,7 @@
1
- /*! @azure/msal-common v6.0.0 2022-01-04 */
1
+ /*! @azure/msal-common v6.3.0-beta.0 2022-04-27 */
2
2
  'use strict';
3
3
  import { ClientConfigurationError } from '../error/ClientConfigurationError.js';
4
- import { HeaderNames } from '../utils/Constants.js';
4
+ import { HeaderNames, Constants } from '../utils/Constants.js';
5
5
 
6
6
  /*
7
7
  * Copyright (c) Microsoft Corporation. All rights reserved.
@@ -53,7 +53,7 @@ var AuthenticationHeaderParser = /** @class */ (function () {
53
53
  challenges.forEach(function (challenge) {
54
54
  var _a = challenge.split("="), key = _a[0], value = _a[1];
55
55
  // Remove escaped quotation marks (', ") from challenge string to keep only the challenge value
56
- challengeMap[key] = unescape(value.replace(/['"]+/g, ""));
56
+ challengeMap[key] = unescape(value.replace(/['"]+/g, Constants.EMPTY_STRING));
57
57
  });
58
58
  return challengeMap;
59
59
  };
@@ -1 +1 @@
1
- {"version":3,"file":"AuthenticationHeaderParser.js","sources":["../../src/request/AuthenticationHeaderParser.ts"],"sourcesContent":["/*\n * Copyright (c) Microsoft Corporation. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport { ClientConfigurationError } from \"../error/ClientConfigurationError\";\nimport { HeaderNames } from \"../utils/Constants\";\n\ntype WWWAuthenticateChallenges = {\n nonce?: string,\n};\n\ntype AuthenticationInfoChallenges = {\n nextnonce?: string\n};\n\n/**\n * This is a helper class that parses supported HTTP response authentication headers to extract and return\n * header challenge values that can be used outside the basic authorization flows.\n */\nexport class AuthenticationHeaderParser {\n private headers: Record<string, string>;\n\n constructor(headers: Record<string, string>) {\n this.headers = headers;\n }\n\n /**\n * This method parses the SHR nonce value out of either the Authentication-Info or WWW-Authenticate authentication headers.\n * @returns \n */\n getShrNonce(): string {\n // Attempt to parse nonce from Authentiacation-Info\n const authenticationInfo = this.headers[HeaderNames.AuthenticationInfo];\n if (authenticationInfo) {\n const authenticationInfoChallenges = this.parseChallenges<AuthenticationInfoChallenges>(authenticationInfo);\n if (authenticationInfoChallenges.nextnonce) {\n return authenticationInfoChallenges.nextnonce;\n }\n throw ClientConfigurationError.createInvalidAuthenticationHeaderError(HeaderNames.AuthenticationInfo, \"nextnonce challenge is missing.\");\n }\n\n // Attempt to parse nonce from WWW-Authenticate\n const wwwAuthenticate = this.headers[HeaderNames.WWWAuthenticate];\n if (wwwAuthenticate) {\n const wwwAuthenticateChallenges = this.parseChallenges<WWWAuthenticateChallenges>(wwwAuthenticate); \n if (wwwAuthenticateChallenges.nonce){\n return wwwAuthenticateChallenges.nonce;\n }\n throw ClientConfigurationError.createInvalidAuthenticationHeaderError(HeaderNames.WWWAuthenticate, \"nonce challenge is missing.\");\n }\n\n // If neither header is present, throw missing headers error\n throw ClientConfigurationError.createMissingNonceAuthenticationHeadersError();\n }\n\n /**\n * Parses an HTTP header's challenge set into a key/value map.\n * @param header \n * @returns \n */\n private parseChallenges<T>(header: string): T {\n const schemeSeparator = header.indexOf(\" \");\n const challenges = header.substr(schemeSeparator + 1).split(\",\");\n const challengeMap = {} as T;\n\n challenges.forEach((challenge: string) => {\n const [ key, value ] = challenge.split(\"=\");\n // Remove escaped quotation marks (', \") from challenge string to keep only the challenge value\n challengeMap[key] = unescape(value.replace(/['\"]+/g, \"\"));\n });\n\n return challengeMap;\n }\n}\n"],"names":[],"mappings":";;;;;AAAA;;;;AAgBA;;;;;IAOI,oCAAY,OAA+B;QACvC,IAAI,CAAC,OAAO,G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AAG,CAAC,GAAG,QAAQ,CAAC,KAAK,CAAC,OAAO,CAAC,QAAQ,EAAE,EAAE,CAAC,CAAC,CAAC;SAC7D,CAAC,CAAC;QAEH,OAAO,YAAY,CAAC;KACvB;IACL,iCAAC;AAAD,CAAC;;;;"}
1
+ {"version":3,"file":"AuthenticationHeaderParser.js","sources":["../../src/request/AuthenticationHeaderParser.ts"],"sourcesContent":["/*\r\n * Copyright (c) Microsoft Corporation. All rights reserved.\r\n * Licensed under the MIT License.\r\n */\r\n\r\nimport { ClientConfigurationError } from \"../error/ClientConfigurationError\";\r\nimport { Constants, HeaderNames } from \"../utils/Constants\";\r\n\r\ntype WWWAuthenticateChallenges = {\r\n nonce?: string,\r\n};\r\n\r\ntype AuthenticationInfoChallenges = {\r\n nextnonce?: string\r\n};\r\n\r\n/**\r\n * This is a helper class that parses supported HTTP response authentication headers to extract and return\r\n * header challenge values that can be used outside the basic authorization flows.\r\n */\r\nexport class AuthenticationHeaderParser {\r\n private headers: Record<string, string>;\r\n\r\n constructor(headers: Record<string, string>) {\r\n this.headers = headers;\r\n }\r\n\r\n /**\r\n * This method parses the SHR nonce value out of either the Authentication-Info or WWW-Authenticate authentication headers.\r\n * @returns \r\n */\r\n getShrNonce(): string {\r\n // Attempt to parse nonce from Authentiacation-Info\r\n const authenticationInfo = this.headers[HeaderNames.AuthenticationInfo];\r\n if (authenticationInfo) {\r\n const authenticationInfoChallenges = this.parseChallenges<AuthenticationInfoChallenges>(authenticationInfo);\r\n if (authenticationInfoChallenges.nextnonce) {\r\n return authenticationInfoChallenges.nextnonce;\r\n }\r\n throw ClientConfigurationError.createInvalidAuthenticationHeaderError(HeaderNames.AuthenticationInfo, \"nextnonce challenge is missing.\");\r\n }\r\n\r\n // Attempt to parse nonce from WWW-Authenticate\r\n const wwwAuthenticate = this.headers[HeaderNames.WWWAuthenticate];\r\n if (wwwAuthenticate) {\r\n const wwwAuthenticateChallenges = this.parseChallenges<WWWAuthenticateChallenges>(wwwAuthenticate); \r\n if (wwwAuthenticateChallenges.nonce){\r\n return wwwAuthenticateChallenges.nonce;\r\n }\r\n throw ClientConfigurationError.createInvalidAuthenticationHeaderError(HeaderNames.WWWAuthenticate, \"nonce challenge is missing.\");\r\n }\r\n\r\n // If neither header is present, throw missing headers error\r\n throw ClientConfigurationError.createMissingNonceAuthenticationHeadersError();\r\n }\r\n\r\n /**\r\n * Parses an HTTP header's challenge set into a key/value map.\r\n * @param header \r\n * @returns \r\n */\r\n private parseChallenges<T>(header: string): T {\r\n const schemeSeparator = header.indexOf(\" \");\r\n const challenges = header.substr(schemeSeparator + 1).split(\",\");\r\n const challengeMap = {} as T;\r\n\r\n challenges.forEach((challenge: string) => {\r\n const [ key, value ] = challenge.split(\"=\");\r\n // Remove escaped quotation marks (', \") from challenge string to keep only the challenge value\r\n challengeMap[key] = unescape(value.replace(/['\"]+/g, Constants.EMPTY_STRING));\r\n });\r\n\r\n return challengeMap;\r\n }\r\n}\r\n"],"names":[],"mappings":";;;;;AAAA;;;;AAgBA;;;;;IAOI,oCAAY,OAA+B;QACvC,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;KAC1B;;;;;IAMD,gDAAW,GAAX;;QAEI,IAAM,kBAAkB,GAAG,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,kBAAkB,CAAC,CAAC;QACxE,IAAI,kBAAkB,EAAE;YACpB,IAAM,4BAA4B,GAAG,IAAI,CAAC,eAAe,CAA+B,kBAAkB,CAAC,CAAC;YAC5G,IAAI,4BAA4B,CAAC,SAAS,EAAE;gBACxC,OAAO,4BAA4B,CAAC,SAAS,CAAC;aACjD;YACD,MAAM,wBAAwB,CAAC,sCAAsC,CAAC,WAAW,CAAC,kBAAkB,EAAE,iCAAiC,CAAC,CAAC;SAC5I;;QAGD,IAAM,eAAe,GAAG,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,eAAe,CAAC,CAAC;QAClE,IAAI,eAAe,EAAE;YACjB,IAAM,yBAAyB,GAAG,IAAI,CAAC,eAAe,CAA4B,eAAe,CAAC,CAAC;YACnG,IAAI,yBAAyB,CAAC,KAAK,EAAC;gBAChC,OAAO,yBAAyB,CAAC,KAAK,CAAC;aAC1C;YACD,MAAM,wBAAwB,CAAC,sCAAsC,CAAC,WAAW,CAAC,eAAe,EAAE,6BAA6B,CAAC,CAAC;SACrI;;QAGD,MAAM,wBAAwB,CAAC,4CAA4C,EAAE,CAAC;KACjF;;;;;;IAOO,oDAAe,GAAvB,UAA2B,MAAc;QACrC,IAAM,eAAe,GAAG,MAAM,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC;QAC5C,IAAM,UAAU,GAAG,MAAM,CAAC,MAAM,CAAC,eAAe,GAAG,CAAC,CAAC,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;QACjE,IAAM,YAAY,GAAG,EAAO,CAAC;QAE7B,UAAU,CAAC,OAAO,CAAC,UAAC,SAAiB;YAC3B,IAAA,KAAiB,SAAS,CAAC,KAAK,CAAC,GAAG,CAAC,EAAnC,GAAG,QAAA,EAAE,KAAK,QAAyB,CAAC;;YAE5C,YAAY,CAAC,GAAG,CAAC,GAAG,QAAQ,CAAC,KAAK,CAAC,OAAO,CAAC,QAAQ,EAAE,SAAS,CAAC,YAAY,CAAC,CAAC,CAAC;SACjF,CAAC,CAAC;QAEH,OAAO,YAAY,CAAC;KACvB;IACL,iCAAC;AAAD,CAAC;;;;"}
@@ -1,17 +1,19 @@
1
1
  import { AuthenticationScheme } from "../utils/Constants";
2
+ import { AzureCloudOptions } from "../config/ClientConfiguration";
2
3
  /**
3
4
  * BaseAuthRequest
4
5
  * - authority - URL of the authority, the security token service (STS) from which MSAL will acquire tokens. Defaults to https://login.microsoftonline.com/common. If using the same authority for all request, authority should set on client application object and not request, to avoid resolving authority endpoints multiple times.
5
6
  * - correlationId - Unique GUID set per request to trace a request end-to-end for telemetry purposes.
6
7
  * - scopes - Array of scopes the application is requesting access to.
7
- * - authenticationScheme - The type of token retrieved. Defaults to "Bearer". Can also be type "pop" or "SSH".
8
+ * - authenticationScheme - The type of token retrieved. Defaults to "Bearer". Can also be type "pop" or "SSH".
8
9
  * - claims - A stringified claims request which will be added to all /authorize and /token calls
9
10
  * - shrClaims - A stringified claims object which will be added to a Signed HTTP Request
10
11
  * - shrNonce - A server-generated timestamp that has been encrypted and base64URL encoded, which will be added to a Signed HTTP Request.
11
- * - resourceRequestMethod - HTTP Request type used to request data from the resource (i.e. "GET", "POST", etc.). Used for proof-of-possession flows.
12
- * - resourceRequestUri - URI that token will be used for. Used for proof-of-possession flows.
13
- * - sshJwk - A stringified JSON Web Key representing a public key that can be signed by an SSH certificate.
14
- * - sshKid - Key ID that uniquely identifies the SSH public key mentioned above.
12
+ * - resourceRequestMethod - HTTP Request type used to request data from the resource (i.e. "GET", "POST", etc.). Used for proof-of-possession flows.
13
+ * - resourceRequestUri - URI that token will be used for. Used for proof-of-possession flows.
14
+ * - sshJwk - A stringified JSON Web Key representing a public key that can be signed by an SSH certificate.
15
+ * - sshKid - Key ID that uniquely identifies the SSH public key mentioned above.
16
+ * - azureCloudOptions - Convenience string enums for users to provide public/sovereign cloud ids
15
17
  * - requestedClaimsHash - SHA 256 hash string of the requested claims string, used as part of an access token cache key so tokens can be filtered by requested claims
16
18
  */
17
19
  export declare type BaseAuthRequest = {
@@ -26,6 +28,7 @@ export declare type BaseAuthRequest = {
26
28
  resourceRequestUri?: string;
27
29
  sshJwk?: string;
28
30
  sshKid?: string;
31
+ azureCloudOptions?: AzureCloudOptions;
29
32
  requestedClaimsHash?: string;
30
33
  };
31
34
  //# sourceMappingURL=BaseAuthRequest.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"BaseAuthRequest.d.ts","sourceRoot":"","sources":["../../src/request/BaseAuthRequest.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,oBAAoB,EAAE,MAAM,oBAAoB,CAAC;AAE1D;;;;;;;;;;;;;;GAcG;AACH,oBAAY,eAAe,GAAG;IAC1B,SAAS,EAAE,MAAM,CAAC;IAClB,aAAa,EAAE,MAAM,CAAC;IACtB,MAAM,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC;IACtB,oBAAoB,CAAC,EAAE,oBAAoB,CAAC;IAC5C,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,qBAAqB,CAAC,EAAE,MAAM,CAAC;IAC/B,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAC5B,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,mBAAmB,CAAC,EAAE,MAAM,CAAC;CAChC,CAAC"}
1
+ {"version":3,"file":"BaseAuthRequest.d.ts","sourceRoot":"","sources":["../../src/request/BaseAuthRequest.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,oBAAoB,EAAE,MAAM,oBAAoB,CAAC;AAC1D,OAAO,EAAE,iBAAiB,EAAE,MAAM,+BAA+B,CAAC;AAElE;;;;;;;;;;;;;;;GAeG;AACH,oBAAY,eAAe,GAAG;IAC1B,SAAS,EAAE,MAAM,CAAC;IAClB,aAAa,EAAE,MAAM,CAAC;IACtB,MAAM,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC;IACtB,oBAAoB,CAAC,EAAE,oBAAoB,CAAC;IAC5C,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,qBAAqB,CAAC,EAAE,MAAM,CAAC;IAC/B,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAC5B,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,iBAAiB,CAAC,EAAE,iBAAiB,CAAC;IACtC,mBAAmB,CAAC,EAAE,MAAM,CAAC;CAChC,CAAC"}
@@ -46,5 +46,6 @@ export declare type CommonAuthorizationUrlRequest = BaseAuthRequest & {
46
46
  prompt?: string;
47
47
  sid?: string;
48
48
  state?: string;
49
+ nativeBroker?: boolean;
49
50
  };
50
51
  //# sourceMappingURL=CommonAuthorizationUrlRequest.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"CommonAuthorizationUrlRequest.d.ts","sourceRoot":"","sources":["../../src/request/CommonAuthorizationUrlRequest.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAClD,OAAO,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAChD,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,WAAW,EAAE,MAAM,wBAAwB,CAAC;AAErD;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA4BG;AACH,oBAAY,6BAA6B,GAAG,eAAe,GAAG;IAC1D,WAAW,EAAE,MAAM,CAAC;IACpB,YAAY,EAAE,YAAY,CAAC;IAC3B,OAAO,CAAC,EAAE,WAAW,CAAC;IACtB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,mBAAmB,CAAC,EAAE,MAAM,CAAC;IAC7B,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,oBAAoB,CAAC,EAAE,UAAU,CAAC;IAClC,oBAAoB,CAAC,EAAE,UAAU,CAAC;IAClC,oBAAoB,CAAC,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC;IACrC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,KAAK,CAAC,EAAE,MAAM,CAAC;CAClB,CAAC"}
1
+ {"version":3,"file":"CommonAuthorizationUrlRequest.d.ts","sourceRoot":"","sources":["../../src/request/CommonAuthorizationUrlRequest.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAClD,OAAO,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAChD,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,WAAW,EAAE,MAAM,wBAAwB,CAAC;AAErD;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA4BG;AACH,oBAAY,6BAA6B,GAAG,eAAe,GAAG;IAC1D,WAAW,EAAE,MAAM,CAAC;IACpB,YAAY,EAAE,YAAY,CAAC;IAC3B,OAAO,CAAC,EAAE,WAAW,CAAC;IACtB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,mBAAmB,CAAC,EAAE,MAAM,CAAC;IAC7B,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,oBAAoB,CAAC,EAAE,UAAU,CAAC;IAClC,oBAAoB,CAAC,EAAE,UAAU,CAAC;IAClC,oBAAoB,CAAC,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC;IACrC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,YAAY,CAAC,EAAE,OAAO,CAAC;CAC1B,CAAC"}
@@ -7,6 +7,7 @@ import { StringDict } from "../utils/MsalTypes";
7
7
  * - correlationId - Unique GUID set per request to trace a request end-to-end for telemetry purposes.
8
8
  * - idTokenHint - ID Token used by B2C to validate logout if required by the policy
9
9
  * - state - A value included in the request to the logout endpoint which will be returned in the query string upon post logout redirection
10
+ * - logoutHint - A string that specifies the account that is being logged out in order to skip the server account picker on logout
10
11
  */
11
12
  export declare type CommonEndSessionRequest = {
12
13
  correlationId: string;
@@ -14,6 +15,7 @@ export declare type CommonEndSessionRequest = {
14
15
  postLogoutRedirectUri?: string | null;
15
16
  idTokenHint?: string;
16
17
  state?: string;
18
+ logoutHint?: string;
17
19
  extraQueryParameters?: StringDict;
18
20
  };
19
21
  //# sourceMappingURL=CommonEndSessionRequest.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"CommonEndSessionRequest.d.ts","sourceRoot":"","sources":["../../src/request/CommonEndSessionRequest.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,WAAW,EAAE,MAAM,wBAAwB,CAAC;AACrD,OAAO,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAEhD;;;;;;;GAOG;AACH,oBAAY,uBAAuB,GAAG;IAClC,aAAa,EAAE,MAAM,CAAA;IACrB,OAAO,CAAC,EAAE,WAAW,GAAG,IAAI,CAAC;IAC7B,qBAAqB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACtC,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,oBAAoB,CAAC,EAAE,UAAU,CAAA;CACpC,CAAC"}
1
+ {"version":3,"file":"CommonEndSessionRequest.d.ts","sourceRoot":"","sources":["../../src/request/CommonEndSessionRequest.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,WAAW,EAAE,MAAM,wBAAwB,CAAC;AACrD,OAAO,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAEhD;;;;;;;;GAQG;AACH,oBAAY,uBAAuB,GAAG;IAClC,aAAa,EAAE,MAAM,CAAA;IACrB,OAAO,CAAC,EAAE,WAAW,GAAG,IAAI,CAAC;IAC7B,qBAAqB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACtC,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,oBAAoB,CAAC,EAAE,UAAU,CAAA;CACpC,CAAC"}
@@ -1,6 +1,6 @@
1
1
  import { ResponseMode } from "../utils/Constants";
2
2
  import { StringDict } from "../utils/MsalTypes";
3
- import { LibraryInfo } from "../config/ClientConfiguration";
3
+ import { ApplicationTelemetry, LibraryInfo } from "../config/ClientConfiguration";
4
4
  import { ServerTelemetryManager } from "../telemetry/server/ServerTelemetryManager";
5
5
  import { ClientInfo } from "../account/ClientInfo";
6
6
  export declare class RequestParameterBuilder {
@@ -10,11 +10,19 @@ export declare class RequestParameterBuilder {
10
10
  * add response_type = code
11
11
  */
12
12
  addResponseTypeCode(): void;
13
+ /**
14
+ * add response_type = token id_token
15
+ */
16
+ addResponseTypeForTokenAndIdToken(): void;
13
17
  /**
14
18
  * add response_mode. defaults to query.
15
19
  * @param responseMode
16
20
  */
17
21
  addResponseMode(responseMode?: ResponseMode): void;
22
+ /**
23
+ * Add flag to indicate STS should attempt to use WAM if available
24
+ */
25
+ addNativeBroker(): void;
18
26
  /**
19
27
  * add scopes. set addOidcScopes to false to prevent default scopes in non-user scenarios
20
28
  * @param scopeSet
@@ -81,6 +89,11 @@ export declare class RequestParameterBuilder {
81
89
  * @param libraryInfo
82
90
  */
83
91
  addLibraryInfo(libraryInfo: LibraryInfo): void;
92
+ /**
93
+ * Add client telemetry parameters
94
+ * @param appTelemetry
95
+ */
96
+ addApplicationTelemetry(appTelemetry: ApplicationTelemetry): void;
84
97
  /**
85
98
  * add prompt
86
99
  * @param prompt
@@ -192,6 +205,10 @@ export declare class RequestParameterBuilder {
192
205
  * Adds parameter that indicates to the server that throttling is supported
193
206
  */
194
207
  addThrottling(): void;
208
+ /**
209
+ * Adds logout_hint parameter for "silent" logout which prevent server account picker
210
+ */
211
+ addLogoutHint(logoutHint: string): void;
195
212
  /**
196
213
  * Utility to create a URL from the params map
197
214
  */
@@ -1 +1 @@
1
- {"version":3,"file":"RequestParameterBuilder.d.ts","sourceRoot":"","sources":["../../src/request/RequestParameterBuilder.ts"],"names":[],"mappings":"AAKA,OAAO,EAAiC,YAAY,EAAgJ,MAAM,oBAAoB,CAAC;AAG/N,OAAO,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAEhD,OAAO,EAAE,WAAW,EAAE,MAAM,+BAA+B,CAAC;AAE5D,O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