@cypress/github-action 7.1.1 → 7.1.3
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.
- package/README.md +1 -1
- package/dist/index.js +463 -1652
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -67081,17 +67081,15 @@ const core_util_1 = __nccwpck_require__(87779);
|
|
|
67081
67081
|
const core_auth_1 = __nccwpck_require__(50417);
|
|
67082
67082
|
const core_rest_pipeline_1 = __nccwpck_require__(20778);
|
|
67083
67083
|
const core_util_2 = __nccwpck_require__(87779);
|
|
67084
|
-
const
|
|
67084
|
+
const storage_common_1 = __nccwpck_require__(51382);
|
|
67085
67085
|
const Clients_js_1 = __nccwpck_require__(90372);
|
|
67086
67086
|
const Mutex_js_1 = __nccwpck_require__(58913);
|
|
67087
67087
|
const Pipeline_js_1 = __nccwpck_require__(25984);
|
|
67088
67088
|
const utils_common_js_1 = __nccwpck_require__(47764);
|
|
67089
67089
|
const core_xml_1 = __nccwpck_require__(78756);
|
|
67090
67090
|
const constants_js_1 = __nccwpck_require__(27323);
|
|
67091
|
-
const StorageSharedKeyCredential_js_1 = __nccwpck_require__(68999);
|
|
67092
67091
|
const tracing_js_1 = __nccwpck_require__(53952);
|
|
67093
67092
|
const core_client_1 = __nccwpck_require__(60160);
|
|
67094
|
-
const StorageSharedKeyCredentialPolicyV2_js_1 = __nccwpck_require__(97999);
|
|
67095
67093
|
/**
|
|
67096
67094
|
* A BlobBatch represents an aggregated set of operations on blobs.
|
|
67097
67095
|
* Currently, only `delete` and `setAccessTier` are supported.
|
|
@@ -67146,8 +67144,8 @@ class BlobBatch {
|
|
|
67146
67144
|
let url;
|
|
67147
67145
|
let credential;
|
|
67148
67146
|
if (typeof urlOrBlobClient === "string" &&
|
|
67149
|
-
((core_util_2.isNodeLike && credentialOrOptions instanceof
|
|
67150
|
-
credentialOrOptions instanceof
|
|
67147
|
+
((core_util_2.isNodeLike && credentialOrOptions instanceof storage_common_1.StorageSharedKeyCredential) ||
|
|
67148
|
+
credentialOrOptions instanceof storage_common_1.AnonymousCredential ||
|
|
67151
67149
|
(0, core_auth_1.isTokenCredential)(credentialOrOptions))) {
|
|
67152
67150
|
// First overload
|
|
67153
67151
|
url = urlOrBlobClient;
|
|
@@ -67180,8 +67178,8 @@ class BlobBatch {
|
|
|
67180
67178
|
let credential;
|
|
67181
67179
|
let tier;
|
|
67182
67180
|
if (typeof urlOrBlobClient === "string" &&
|
|
67183
|
-
((core_util_2.isNodeLike && credentialOrTier instanceof
|
|
67184
|
-
credentialOrTier instanceof
|
|
67181
|
+
((core_util_2.isNodeLike && credentialOrTier instanceof storage_common_1.StorageSharedKeyCredential) ||
|
|
67182
|
+
credentialOrTier instanceof storage_common_1.AnonymousCredential ||
|
|
67185
67183
|
(0, core_auth_1.isTokenCredential)(credentialOrTier))) {
|
|
67186
67184
|
// First overload
|
|
67187
67185
|
url = urlOrBlobClient;
|
|
@@ -67269,8 +67267,8 @@ class InnerBatchRequest {
|
|
|
67269
67267
|
challengeCallbacks: { authorizeRequestOnChallenge: core_client_1.authorizeRequestOnTenantChallenge },
|
|
67270
67268
|
}), { phase: "Sign" });
|
|
67271
67269
|
}
|
|
67272
|
-
else if (credential instanceof
|
|
67273
|
-
corePipeline.addPolicy((0,
|
|
67270
|
+
else if (credential instanceof storage_common_1.StorageSharedKeyCredential) {
|
|
67271
|
+
corePipeline.addPolicy((0, storage_common_1.storageSharedKeyCredentialPolicy)({
|
|
67274
67272
|
accountName: credential.accountName,
|
|
67275
67273
|
accountKey: credential.accountKey,
|
|
67276
67274
|
}), { phase: "Sign" });
|
|
@@ -67368,7 +67366,7 @@ const BatchResponseParser_js_1 = __nccwpck_require__(41564);
|
|
|
67368
67366
|
const BatchUtils_js_1 = __nccwpck_require__(72995);
|
|
67369
67367
|
const BlobBatch_js_1 = __nccwpck_require__(95561);
|
|
67370
67368
|
const tracing_js_1 = __nccwpck_require__(53952);
|
|
67371
|
-
const
|
|
67369
|
+
const storage_common_1 = __nccwpck_require__(51382);
|
|
67372
67370
|
const StorageContextClient_js_1 = __nccwpck_require__(53789);
|
|
67373
67371
|
const Pipeline_js_1 = __nccwpck_require__(25984);
|
|
67374
67372
|
const utils_common_js_1 = __nccwpck_require__(47764);
|
|
@@ -67389,7 +67387,7 @@ class BlobBatchClient {
|
|
|
67389
67387
|
}
|
|
67390
67388
|
else if (!credentialOrPipeline) {
|
|
67391
67389
|
// no credential provided
|
|
67392
|
-
pipeline = (0, Pipeline_js_1.newPipeline)(new
|
|
67390
|
+
pipeline = (0, Pipeline_js_1.newPipeline)(new storage_common_1.AnonymousCredential(), options);
|
|
67393
67391
|
}
|
|
67394
67392
|
else {
|
|
67395
67393
|
pipeline = (0, Pipeline_js_1.newPipeline)(credentialOrPipeline, options);
|
|
@@ -67512,9 +67510,9 @@ class BlobBatchClient {
|
|
|
67512
67510
|
return tracing_js_1.tracingClient.withSpan("BlobBatchClient-submitBatch", options, async (updatedOptions) => {
|
|
67513
67511
|
const batchRequestBody = batchRequest.getHttpRequestBody();
|
|
67514
67512
|
// ServiceSubmitBatchResponseModel and ContainerSubmitBatchResponse are compatible for now.
|
|
67515
|
-
const rawBatchResponse = (0, utils_common_js_1.assertResponse)(await this.serviceOrContainerContext.submitBatch((0, BatchUtils_js_1.utf8ByteLength)(batchRequestBody), batchRequest.getMultiPartContentType(), batchRequestBody, {
|
|
67513
|
+
const rawBatchResponse = (0, utils_common_js_1.assertResponse)((await this.serviceOrContainerContext.submitBatch((0, BatchUtils_js_1.utf8ByteLength)(batchRequestBody), batchRequest.getMultiPartContentType(), batchRequestBody, {
|
|
67516
67514
|
...updatedOptions,
|
|
67517
|
-
}));
|
|
67515
|
+
})));
|
|
67518
67516
|
// Parse the sub responses result, if logic reaches here(i.e. the batch request succeeded with status code 202).
|
|
67519
67517
|
const batchResponseParser = new BatchResponseParser_js_1.BatchResponseParser(rawBatchResponse, batchRequest.getSubRequests());
|
|
67520
67518
|
const responseSummary = await batchResponseParser.parseBatchResponse();
|
|
@@ -68619,8 +68617,7 @@ const core_util_1 = __nccwpck_require__(87779);
|
|
|
68619
68617
|
const Pipeline_js_1 = __nccwpck_require__(25984);
|
|
68620
68618
|
const ContainerClient_js_1 = __nccwpck_require__(81884);
|
|
68621
68619
|
const utils_common_js_1 = __nccwpck_require__(47764);
|
|
68622
|
-
const
|
|
68623
|
-
const AnonymousCredential_js_1 = __nccwpck_require__(35345);
|
|
68620
|
+
const storage_common_1 = __nccwpck_require__(51382);
|
|
68624
68621
|
const utils_common_js_2 = __nccwpck_require__(47764);
|
|
68625
68622
|
const tracing_js_1 = __nccwpck_require__(53952);
|
|
68626
68623
|
const BlobBatchClient_js_1 = __nccwpck_require__(12094);
|
|
@@ -68657,7 +68654,7 @@ class BlobServiceClient extends StorageClient_js_1.StorageClient {
|
|
|
68657
68654
|
const extractedCreds = (0, utils_common_js_1.extractConnectionStringParts)(connectionString);
|
|
68658
68655
|
if (extractedCreds.kind === "AccountConnString") {
|
|
68659
68656
|
if (core_util_1.isNodeLike) {
|
|
68660
|
-
const sharedKeyCredential = new
|
|
68657
|
+
const sharedKeyCredential = new storage_common_1.StorageSharedKeyCredential(extractedCreds.accountName, extractedCreds.accountKey);
|
|
68661
68658
|
if (!options.proxyOptions) {
|
|
68662
68659
|
options.proxyOptions = (0, core_rest_pipeline_1.getDefaultProxySettings)(extractedCreds.proxyUri);
|
|
68663
68660
|
}
|
|
@@ -68669,7 +68666,7 @@ class BlobServiceClient extends StorageClient_js_1.StorageClient {
|
|
|
68669
68666
|
}
|
|
68670
68667
|
}
|
|
68671
68668
|
else if (extractedCreds.kind === "SASConnString") {
|
|
68672
|
-
const pipeline = (0, Pipeline_js_1.newPipeline)(new
|
|
68669
|
+
const pipeline = (0, Pipeline_js_1.newPipeline)(new storage_common_1.AnonymousCredential(), options);
|
|
68673
68670
|
return new BlobServiceClient(extractedCreds.url + "?" + extractedCreds.accountSas, pipeline);
|
|
68674
68671
|
}
|
|
68675
68672
|
else {
|
|
@@ -68684,14 +68681,14 @@ class BlobServiceClient extends StorageClient_js_1.StorageClient {
|
|
|
68684
68681
|
if ((0, Pipeline_js_1.isPipelineLike)(credentialOrPipeline)) {
|
|
68685
68682
|
pipeline = credentialOrPipeline;
|
|
68686
68683
|
}
|
|
68687
|
-
else if ((core_util_1.isNodeLike && credentialOrPipeline instanceof
|
|
68688
|
-
credentialOrPipeline instanceof
|
|
68684
|
+
else if ((core_util_1.isNodeLike && credentialOrPipeline instanceof storage_common_1.StorageSharedKeyCredential) ||
|
|
68685
|
+
credentialOrPipeline instanceof storage_common_1.AnonymousCredential ||
|
|
68689
68686
|
(0, core_auth_1.isTokenCredential)(credentialOrPipeline)) {
|
|
68690
68687
|
pipeline = (0, Pipeline_js_1.newPipeline)(credentialOrPipeline, options);
|
|
68691
68688
|
}
|
|
68692
68689
|
else {
|
|
68693
68690
|
// The second parameter is undefined. Use anonymous credential
|
|
68694
|
-
pipeline = (0, Pipeline_js_1.newPipeline)(new
|
|
68691
|
+
pipeline = (0, Pipeline_js_1.newPipeline)(new storage_common_1.AnonymousCredential(), options);
|
|
68695
68692
|
}
|
|
68696
68693
|
super(url, pipeline);
|
|
68697
68694
|
this.serviceContext = this.storageClientContext.service;
|
|
@@ -69268,7 +69265,7 @@ class BlobServiceClient extends StorageClient_js_1.StorageClient {
|
|
|
69268
69265
|
* @returns An account SAS URI consisting of the URI to the resource represented by this client, followed by the generated SAS token.
|
|
69269
69266
|
*/
|
|
69270
69267
|
generateAccountSasUrl(expiresOn, permissions = AccountSASPermissions_js_1.AccountSASPermissions.parse("r"), resourceTypes = "sco", options = {}) {
|
|
69271
|
-
if (!(this.credential instanceof
|
|
69268
|
+
if (!(this.credential instanceof storage_common_1.StorageSharedKeyCredential)) {
|
|
69272
69269
|
throw RangeError("Can only generate the account SAS when the client is initialized with a shared key credential");
|
|
69273
69270
|
}
|
|
69274
69271
|
if (expiresOn === undefined) {
|
|
@@ -69299,7 +69296,7 @@ class BlobServiceClient extends StorageClient_js_1.StorageClient {
|
|
|
69299
69296
|
* @returns An account SAS URI consisting of the URI to the resource represented by this client, followed by the generated SAS token.
|
|
69300
69297
|
*/
|
|
69301
69298
|
generateSasStringToSign(expiresOn, permissions = AccountSASPermissions_js_1.AccountSASPermissions.parse("r"), resourceTypes = "sco", options = {}) {
|
|
69302
|
-
if (!(this.credential instanceof
|
|
69299
|
+
if (!(this.credential instanceof storage_common_1.StorageSharedKeyCredential)) {
|
|
69303
69300
|
throw RangeError("Can only generate the account SAS when the client is initialized with a shared key credential");
|
|
69304
69301
|
}
|
|
69305
69302
|
if (expiresOn === undefined) {
|
|
@@ -69335,8 +69332,7 @@ const core_util_1 = __nccwpck_require__(87779);
|
|
|
69335
69332
|
const core_util_2 = __nccwpck_require__(87779);
|
|
69336
69333
|
const BlobDownloadResponse_js_1 = __nccwpck_require__(4894);
|
|
69337
69334
|
const BlobQueryResponse_js_1 = __nccwpck_require__(95602);
|
|
69338
|
-
const
|
|
69339
|
-
const StorageSharedKeyCredential_js_1 = __nccwpck_require__(68999);
|
|
69335
|
+
const storage_common_1 = __nccwpck_require__(51382);
|
|
69340
69336
|
const models_js_1 = __nccwpck_require__(58560);
|
|
69341
69337
|
const PageBlobRangeResponse_js_1 = __nccwpck_require__(95302);
|
|
69342
69338
|
const Pipeline_js_1 = __nccwpck_require__(25984);
|
|
@@ -69344,7 +69340,7 @@ const BlobStartCopyFromUrlPoller_js_1 = __nccwpck_require__(73145);
|
|
|
69344
69340
|
const Range_js_1 = __nccwpck_require__(52045);
|
|
69345
69341
|
const StorageClient_js_1 = __nccwpck_require__(73542);
|
|
69346
69342
|
const Batch_js_1 = __nccwpck_require__(81582);
|
|
69347
|
-
const
|
|
69343
|
+
const storage_common_2 = __nccwpck_require__(51382);
|
|
69348
69344
|
const constants_js_1 = __nccwpck_require__(27323);
|
|
69349
69345
|
const tracing_js_1 = __nccwpck_require__(53952);
|
|
69350
69346
|
const utils_common_js_1 = __nccwpck_require__(47764);
|
|
@@ -69388,8 +69384,8 @@ class BlobClient extends StorageClient_js_1.StorageClient {
|
|
|
69388
69384
|
url = urlOrConnectionString;
|
|
69389
69385
|
pipeline = credentialOrPipelineOrContainerName;
|
|
69390
69386
|
}
|
|
69391
|
-
else if ((core_util_1.isNodeLike && credentialOrPipelineOrContainerName instanceof
|
|
69392
|
-
credentialOrPipelineOrContainerName instanceof
|
|
69387
|
+
else if ((core_util_1.isNodeLike && credentialOrPipelineOrContainerName instanceof storage_common_1.StorageSharedKeyCredential) ||
|
|
69388
|
+
credentialOrPipelineOrContainerName instanceof storage_common_1.AnonymousCredential ||
|
|
69393
69389
|
(0, core_auth_1.isTokenCredential)(credentialOrPipelineOrContainerName)) {
|
|
69394
69390
|
// (url: string, credential?: StorageSharedKeyCredential | AnonymousCredential | TokenCredential, options?: StoragePipelineOptions)
|
|
69395
69391
|
url = urlOrConnectionString;
|
|
@@ -69404,7 +69400,7 @@ class BlobClient extends StorageClient_js_1.StorageClient {
|
|
|
69404
69400
|
if (blobNameOrOptions && typeof blobNameOrOptions !== "string") {
|
|
69405
69401
|
options = blobNameOrOptions;
|
|
69406
69402
|
}
|
|
69407
|
-
pipeline = (0, Pipeline_js_1.newPipeline)(new
|
|
69403
|
+
pipeline = (0, Pipeline_js_1.newPipeline)(new storage_common_1.AnonymousCredential(), options);
|
|
69408
69404
|
}
|
|
69409
69405
|
else if (credentialOrPipelineOrContainerName &&
|
|
69410
69406
|
typeof credentialOrPipelineOrContainerName === "string" &&
|
|
@@ -69416,7 +69412,7 @@ class BlobClient extends StorageClient_js_1.StorageClient {
|
|
|
69416
69412
|
const extractedCreds = (0, utils_common_js_1.extractConnectionStringParts)(urlOrConnectionString);
|
|
69417
69413
|
if (extractedCreds.kind === "AccountConnString") {
|
|
69418
69414
|
if (core_util_1.isNodeLike) {
|
|
69419
|
-
const sharedKeyCredential = new
|
|
69415
|
+
const sharedKeyCredential = new storage_common_1.StorageSharedKeyCredential(extractedCreds.accountName, extractedCreds.accountKey);
|
|
69420
69416
|
url = (0, utils_common_js_1.appendToURLPath)((0, utils_common_js_1.appendToURLPath)(extractedCreds.url, encodeURIComponent(containerName)), encodeURIComponent(blobName));
|
|
69421
69417
|
if (!options.proxyOptions) {
|
|
69422
69418
|
options.proxyOptions = (0, core_rest_pipeline_1.getDefaultProxySettings)(extractedCreds.proxyUri);
|
|
@@ -69432,7 +69428,7 @@ class BlobClient extends StorageClient_js_1.StorageClient {
|
|
|
69432
69428
|
(0, utils_common_js_1.appendToURLPath)((0, utils_common_js_1.appendToURLPath)(extractedCreds.url, encodeURIComponent(containerName)), encodeURIComponent(blobName)) +
|
|
69433
69429
|
"?" +
|
|
69434
69430
|
extractedCreds.accountSas;
|
|
69435
|
-
pipeline = (0, Pipeline_js_1.newPipeline)(new
|
|
69431
|
+
pipeline = (0, Pipeline_js_1.newPipeline)(new storage_common_1.AnonymousCredential(), options);
|
|
69436
69432
|
}
|
|
69437
69433
|
else {
|
|
69438
69434
|
throw new Error("Connection string must be either an Account connection string or a SAS connection string");
|
|
@@ -69575,7 +69571,7 @@ class BlobClient extends StorageClient_js_1.StorageClient {
|
|
|
69575
69571
|
options.conditions = options.conditions || {};
|
|
69576
69572
|
(0, models_js_1.ensureCpkIfSpecified)(options.customerProvidedKey, this.isHttps);
|
|
69577
69573
|
return tracing_js_1.tracingClient.withSpan("BlobClient-download", options, async (updatedOptions) => {
|
|
69578
|
-
const res = (0, utils_common_js_1.assertResponse)(await this.blobContext.download({
|
|
69574
|
+
const res = (0, utils_common_js_1.assertResponse)((await this.blobContext.download({
|
|
69579
69575
|
abortSignal: options.abortSignal,
|
|
69580
69576
|
leaseAccessConditions: options.conditions,
|
|
69581
69577
|
modifiedAccessConditions: {
|
|
@@ -69591,7 +69587,7 @@ class BlobClient extends StorageClient_js_1.StorageClient {
|
|
|
69591
69587
|
snapshot: options.snapshot,
|
|
69592
69588
|
cpkInfo: options.customerProvidedKey,
|
|
69593
69589
|
tracingOptions: updatedOptions.tracingOptions,
|
|
69594
|
-
}));
|
|
69590
|
+
})));
|
|
69595
69591
|
const wrappedRes = {
|
|
69596
69592
|
...res,
|
|
69597
69593
|
_response: res._response, // _response is made non-enumerable
|
|
@@ -69872,6 +69868,7 @@ class BlobClient extends StorageClient_js_1.StorageClient {
|
|
|
69872
69868
|
...options.conditions,
|
|
69873
69869
|
ifTags: options.conditions?.tagConditions,
|
|
69874
69870
|
},
|
|
69871
|
+
blobModifiedAccessConditions: options.conditions,
|
|
69875
69872
|
tracingOptions: updatedOptions.tracingOptions,
|
|
69876
69873
|
tags: (0, utils_common_js_1.toBlobTags)(tags),
|
|
69877
69874
|
}));
|
|
@@ -69891,6 +69888,7 @@ class BlobClient extends StorageClient_js_1.StorageClient {
|
|
|
69891
69888
|
...options.conditions,
|
|
69892
69889
|
ifTags: options.conditions?.tagConditions,
|
|
69893
69890
|
},
|
|
69891
|
+
blobModifiedAccessConditions: options.conditions,
|
|
69894
69892
|
tracingOptions: updatedOptions.tracingOptions,
|
|
69895
69893
|
}));
|
|
69896
69894
|
const wrappedResponse = {
|
|
@@ -70329,7 +70327,7 @@ class BlobClient extends StorageClient_js_1.StorageClient {
|
|
|
70329
70327
|
*/
|
|
70330
70328
|
generateSasUrl(options) {
|
|
70331
70329
|
return new Promise((resolve) => {
|
|
70332
|
-
if (!(this.credential instanceof
|
|
70330
|
+
if (!(this.credential instanceof storage_common_1.StorageSharedKeyCredential)) {
|
|
70333
70331
|
throw new RangeError("Can only generate the SAS when the client is initialized with a shared key credential");
|
|
70334
70332
|
}
|
|
70335
70333
|
const sas = (0, BlobSASSignatureValues_js_1.generateBlobSASQueryParameters)({
|
|
@@ -70355,7 +70353,7 @@ class BlobClient extends StorageClient_js_1.StorageClient {
|
|
|
70355
70353
|
*/
|
|
70356
70354
|
/* eslint-disable-next-line @azure/azure-sdk/ts-naming-options*/
|
|
70357
70355
|
generateSasStringToSign(options) {
|
|
70358
|
-
if (!(this.credential instanceof
|
|
70356
|
+
if (!(this.credential instanceof storage_common_1.StorageSharedKeyCredential)) {
|
|
70359
70357
|
throw new RangeError("Can only generate the SAS when the client is initialized with a shared key credential");
|
|
70360
70358
|
}
|
|
70361
70359
|
return (0, BlobSASSignatureValues_js_1.generateBlobSASQueryParametersInternal)({
|
|
@@ -70490,8 +70488,8 @@ class AppendBlobClient extends BlobClient {
|
|
|
70490
70488
|
url = urlOrConnectionString;
|
|
70491
70489
|
pipeline = credentialOrPipelineOrContainerName;
|
|
70492
70490
|
}
|
|
70493
|
-
else if ((core_util_1.isNodeLike && credentialOrPipelineOrContainerName instanceof
|
|
70494
|
-
credentialOrPipelineOrContainerName instanceof
|
|
70491
|
+
else if ((core_util_1.isNodeLike && credentialOrPipelineOrContainerName instanceof storage_common_1.StorageSharedKeyCredential) ||
|
|
70492
|
+
credentialOrPipelineOrContainerName instanceof storage_common_1.AnonymousCredential ||
|
|
70495
70493
|
(0, core_auth_1.isTokenCredential)(credentialOrPipelineOrContainerName)) {
|
|
70496
70494
|
// (url: string, credential?: StorageSharedKeyCredential | AnonymousCredential | TokenCredential, options?: StoragePipelineOptions) url = urlOrConnectionString;
|
|
70497
70495
|
url = urlOrConnectionString;
|
|
@@ -70503,7 +70501,7 @@ class AppendBlobClient extends BlobClient {
|
|
|
70503
70501
|
// (url: string, credential?: StorageSharedKeyCredential | AnonymousCredential | TokenCredential, options?: StoragePipelineOptions)
|
|
70504
70502
|
url = urlOrConnectionString;
|
|
70505
70503
|
// The second parameter is undefined. Use anonymous credential.
|
|
70506
|
-
pipeline = (0, Pipeline_js_1.newPipeline)(new
|
|
70504
|
+
pipeline = (0, Pipeline_js_1.newPipeline)(new storage_common_1.AnonymousCredential(), options);
|
|
70507
70505
|
}
|
|
70508
70506
|
else if (credentialOrPipelineOrContainerName &&
|
|
70509
70507
|
typeof credentialOrPipelineOrContainerName === "string" &&
|
|
@@ -70515,7 +70513,7 @@ class AppendBlobClient extends BlobClient {
|
|
|
70515
70513
|
const extractedCreds = (0, utils_common_js_1.extractConnectionStringParts)(urlOrConnectionString);
|
|
70516
70514
|
if (extractedCreds.kind === "AccountConnString") {
|
|
70517
70515
|
if (core_util_1.isNodeLike) {
|
|
70518
|
-
const sharedKeyCredential = new
|
|
70516
|
+
const sharedKeyCredential = new storage_common_1.StorageSharedKeyCredential(extractedCreds.accountName, extractedCreds.accountKey);
|
|
70519
70517
|
url = (0, utils_common_js_1.appendToURLPath)((0, utils_common_js_1.appendToURLPath)(extractedCreds.url, encodeURIComponent(containerName)), encodeURIComponent(blobName));
|
|
70520
70518
|
if (!options.proxyOptions) {
|
|
70521
70519
|
options.proxyOptions = (0, core_rest_pipeline_1.getDefaultProxySettings)(extractedCreds.proxyUri);
|
|
@@ -70531,7 +70529,7 @@ class AppendBlobClient extends BlobClient {
|
|
|
70531
70529
|
(0, utils_common_js_1.appendToURLPath)((0, utils_common_js_1.appendToURLPath)(extractedCreds.url, encodeURIComponent(containerName)), encodeURIComponent(blobName)) +
|
|
70532
70530
|
"?" +
|
|
70533
70531
|
extractedCreds.accountSas;
|
|
70534
|
-
pipeline = (0, Pipeline_js_1.newPipeline)(new
|
|
70532
|
+
pipeline = (0, Pipeline_js_1.newPipeline)(new storage_common_1.AnonymousCredential(), options);
|
|
70535
70533
|
}
|
|
70536
70534
|
else {
|
|
70537
70535
|
throw new Error("Connection string must be either an Account connection string or a SAS connection string");
|
|
@@ -70792,8 +70790,8 @@ class BlockBlobClient extends BlobClient {
|
|
|
70792
70790
|
url = urlOrConnectionString;
|
|
70793
70791
|
pipeline = credentialOrPipelineOrContainerName;
|
|
70794
70792
|
}
|
|
70795
|
-
else if ((core_util_1.isNodeLike && credentialOrPipelineOrContainerName instanceof
|
|
70796
|
-
credentialOrPipelineOrContainerName instanceof
|
|
70793
|
+
else if ((core_util_1.isNodeLike && credentialOrPipelineOrContainerName instanceof storage_common_1.StorageSharedKeyCredential) ||
|
|
70794
|
+
credentialOrPipelineOrContainerName instanceof storage_common_1.AnonymousCredential ||
|
|
70797
70795
|
(0, core_auth_1.isTokenCredential)(credentialOrPipelineOrContainerName)) {
|
|
70798
70796
|
// (url: string, credential?: StorageSharedKeyCredential | AnonymousCredential | TokenCredential, options?: StoragePipelineOptions)
|
|
70799
70797
|
url = urlOrConnectionString;
|
|
@@ -70808,7 +70806,7 @@ class BlockBlobClient extends BlobClient {
|
|
|
70808
70806
|
if (blobNameOrOptions && typeof blobNameOrOptions !== "string") {
|
|
70809
70807
|
options = blobNameOrOptions;
|
|
70810
70808
|
}
|
|
70811
|
-
pipeline = (0, Pipeline_js_1.newPipeline)(new
|
|
70809
|
+
pipeline = (0, Pipeline_js_1.newPipeline)(new storage_common_1.AnonymousCredential(), options);
|
|
70812
70810
|
}
|
|
70813
70811
|
else if (credentialOrPipelineOrContainerName &&
|
|
70814
70812
|
typeof credentialOrPipelineOrContainerName === "string" &&
|
|
@@ -70820,7 +70818,7 @@ class BlockBlobClient extends BlobClient {
|
|
|
70820
70818
|
const extractedCreds = (0, utils_common_js_1.extractConnectionStringParts)(urlOrConnectionString);
|
|
70821
70819
|
if (extractedCreds.kind === "AccountConnString") {
|
|
70822
70820
|
if (core_util_1.isNodeLike) {
|
|
70823
|
-
const sharedKeyCredential = new
|
|
70821
|
+
const sharedKeyCredential = new storage_common_1.StorageSharedKeyCredential(extractedCreds.accountName, extractedCreds.accountKey);
|
|
70824
70822
|
url = (0, utils_common_js_1.appendToURLPath)((0, utils_common_js_1.appendToURLPath)(extractedCreds.url, encodeURIComponent(containerName)), encodeURIComponent(blobName));
|
|
70825
70823
|
if (!options.proxyOptions) {
|
|
70826
70824
|
options.proxyOptions = (0, core_rest_pipeline_1.getDefaultProxySettings)(extractedCreds.proxyUri);
|
|
@@ -70836,7 +70834,7 @@ class BlockBlobClient extends BlobClient {
|
|
|
70836
70834
|
(0, utils_common_js_1.appendToURLPath)((0, utils_common_js_1.appendToURLPath)(extractedCreds.url, encodeURIComponent(containerName)), encodeURIComponent(blobName)) +
|
|
70837
70835
|
"?" +
|
|
70838
70836
|
extractedCreds.accountSas;
|
|
70839
|
-
pipeline = (0, Pipeline_js_1.newPipeline)(new
|
|
70837
|
+
pipeline = (0, Pipeline_js_1.newPipeline)(new storage_common_1.AnonymousCredential(), options);
|
|
70840
70838
|
}
|
|
70841
70839
|
else {
|
|
70842
70840
|
throw new Error("Connection string must be either an Account connection string or a SAS connection string");
|
|
@@ -70913,7 +70911,7 @@ class BlockBlobClient extends BlobClient {
|
|
|
70913
70911
|
throw new Error("This operation currently is only supported in Node.js.");
|
|
70914
70912
|
}
|
|
70915
70913
|
return tracing_js_1.tracingClient.withSpan("BlockBlobClient-query", options, async (updatedOptions) => {
|
|
70916
|
-
const response = (0, utils_common_js_1.assertResponse)(await this._blobContext.query({
|
|
70914
|
+
const response = (0, utils_common_js_1.assertResponse)((await this._blobContext.query({
|
|
70917
70915
|
abortSignal: options.abortSignal,
|
|
70918
70916
|
queryRequest: {
|
|
70919
70917
|
queryType: "SQL",
|
|
@@ -70928,7 +70926,7 @@ class BlockBlobClient extends BlobClient {
|
|
|
70928
70926
|
},
|
|
70929
70927
|
cpkInfo: options.customerProvidedKey,
|
|
70930
70928
|
tracingOptions: updatedOptions.tracingOptions,
|
|
70931
|
-
}));
|
|
70929
|
+
})));
|
|
70932
70930
|
return new BlobQueryResponse_js_1.BlobQueryResponse(response, {
|
|
70933
70931
|
abortSignal: options.abortSignal,
|
|
70934
70932
|
onProgress: options.onProgress,
|
|
@@ -71383,7 +71381,7 @@ class BlockBlobClient extends BlobClient {
|
|
|
71383
71381
|
const blockIDPrefix = (0, core_util_2.randomUUID)();
|
|
71384
71382
|
let transferProgress = 0;
|
|
71385
71383
|
const blockList = [];
|
|
71386
|
-
const scheduler = new
|
|
71384
|
+
const scheduler = new storage_common_2.BufferScheduler(stream, bufferSize, maxConcurrency, async (body, length) => {
|
|
71387
71385
|
const blockID = (0, utils_common_js_1.generateBlockID)(blockIDPrefix, blockNum);
|
|
71388
71386
|
blockList.push(blockID);
|
|
71389
71387
|
blockNum++;
|
|
@@ -71435,8 +71433,8 @@ class PageBlobClient extends BlobClient {
|
|
|
71435
71433
|
url = urlOrConnectionString;
|
|
71436
71434
|
pipeline = credentialOrPipelineOrContainerName;
|
|
71437
71435
|
}
|
|
71438
|
-
else if ((core_util_1.isNodeLike && credentialOrPipelineOrContainerName instanceof
|
|
71439
|
-
credentialOrPipelineOrContainerName instanceof
|
|
71436
|
+
else if ((core_util_1.isNodeLike && credentialOrPipelineOrContainerName instanceof storage_common_1.StorageSharedKeyCredential) ||
|
|
71437
|
+
credentialOrPipelineOrContainerName instanceof storage_common_1.AnonymousCredential ||
|
|
71440
71438
|
(0, core_auth_1.isTokenCredential)(credentialOrPipelineOrContainerName)) {
|
|
71441
71439
|
// (url: string, credential?: StorageSharedKeyCredential | AnonymousCredential | TokenCredential, options?: StoragePipelineOptions)
|
|
71442
71440
|
url = urlOrConnectionString;
|
|
@@ -71448,7 +71446,7 @@ class PageBlobClient extends BlobClient {
|
|
|
71448
71446
|
// (url: string, credential?: StorageSharedKeyCredential | AnonymousCredential | TokenCredential, options?: StoragePipelineOptions)
|
|
71449
71447
|
// The second parameter is undefined. Use anonymous credential.
|
|
71450
71448
|
url = urlOrConnectionString;
|
|
71451
|
-
pipeline = (0, Pipeline_js_1.newPipeline)(new
|
|
71449
|
+
pipeline = (0, Pipeline_js_1.newPipeline)(new storage_common_1.AnonymousCredential(), options);
|
|
71452
71450
|
}
|
|
71453
71451
|
else if (credentialOrPipelineOrContainerName &&
|
|
71454
71452
|
typeof credentialOrPipelineOrContainerName === "string" &&
|
|
@@ -71460,7 +71458,7 @@ class PageBlobClient extends BlobClient {
|
|
|
71460
71458
|
const extractedCreds = (0, utils_common_js_1.extractConnectionStringParts)(urlOrConnectionString);
|
|
71461
71459
|
if (extractedCreds.kind === "AccountConnString") {
|
|
71462
71460
|
if (core_util_1.isNodeLike) {
|
|
71463
|
-
const sharedKeyCredential = new
|
|
71461
|
+
const sharedKeyCredential = new storage_common_1.StorageSharedKeyCredential(extractedCreds.accountName, extractedCreds.accountKey);
|
|
71464
71462
|
url = (0, utils_common_js_1.appendToURLPath)((0, utils_common_js_1.appendToURLPath)(extractedCreds.url, encodeURIComponent(containerName)), encodeURIComponent(blobName));
|
|
71465
71463
|
if (!options.proxyOptions) {
|
|
71466
71464
|
options.proxyOptions = (0, core_rest_pipeline_1.getDefaultProxySettings)(extractedCreds.proxyUri);
|
|
@@ -71476,7 +71474,7 @@ class PageBlobClient extends BlobClient {
|
|
|
71476
71474
|
(0, utils_common_js_1.appendToURLPath)((0, utils_common_js_1.appendToURLPath)(extractedCreds.url, encodeURIComponent(containerName)), encodeURIComponent(blobName)) +
|
|
71477
71475
|
"?" +
|
|
71478
71476
|
extractedCreds.accountSas;
|
|
71479
|
-
pipeline = (0, Pipeline_js_1.newPipeline)(new
|
|
71477
|
+
pipeline = (0, Pipeline_js_1.newPipeline)(new storage_common_1.AnonymousCredential(), options);
|
|
71480
71478
|
}
|
|
71481
71479
|
else {
|
|
71482
71480
|
throw new Error("Connection string must be either an Account connection string or a SAS connection string");
|
|
@@ -72188,8 +72186,7 @@ exports.ContainerClient = void 0;
|
|
|
72188
72186
|
const core_rest_pipeline_1 = __nccwpck_require__(20778);
|
|
72189
72187
|
const core_util_1 = __nccwpck_require__(87779);
|
|
72190
72188
|
const core_auth_1 = __nccwpck_require__(50417);
|
|
72191
|
-
const
|
|
72192
|
-
const StorageSharedKeyCredential_js_1 = __nccwpck_require__(68999);
|
|
72189
|
+
const storage_common_1 = __nccwpck_require__(51382);
|
|
72193
72190
|
const Pipeline_js_1 = __nccwpck_require__(25984);
|
|
72194
72191
|
const StorageClient_js_1 = __nccwpck_require__(73542);
|
|
72195
72192
|
const tracing_js_1 = __nccwpck_require__(53952);
|
|
@@ -72225,8 +72222,8 @@ class ContainerClient extends StorageClient_js_1.StorageClient {
|
|
|
72225
72222
|
url = urlOrConnectionString;
|
|
72226
72223
|
pipeline = credentialOrPipelineOrContainerName;
|
|
72227
72224
|
}
|
|
72228
|
-
else if ((core_util_1.isNodeLike && credentialOrPipelineOrContainerName instanceof
|
|
72229
|
-
credentialOrPipelineOrContainerName instanceof
|
|
72225
|
+
else if ((core_util_1.isNodeLike && credentialOrPipelineOrContainerName instanceof storage_common_1.StorageSharedKeyCredential) ||
|
|
72226
|
+
credentialOrPipelineOrContainerName instanceof storage_common_1.AnonymousCredential ||
|
|
72230
72227
|
(0, core_auth_1.isTokenCredential)(credentialOrPipelineOrContainerName)) {
|
|
72231
72228
|
// (url: string, credential?: StorageSharedKeyCredential | AnonymousCredential | TokenCredential, options?: StoragePipelineOptions)
|
|
72232
72229
|
url = urlOrConnectionString;
|
|
@@ -72237,7 +72234,7 @@ class ContainerClient extends StorageClient_js_1.StorageClient {
|
|
|
72237
72234
|
// (url: string, credential?: StorageSharedKeyCredential | AnonymousCredential | TokenCredential, options?: StoragePipelineOptions)
|
|
72238
72235
|
// The second parameter is undefined. Use anonymous credential.
|
|
72239
72236
|
url = urlOrConnectionString;
|
|
72240
|
-
pipeline = (0, Pipeline_js_1.newPipeline)(new
|
|
72237
|
+
pipeline = (0, Pipeline_js_1.newPipeline)(new storage_common_1.AnonymousCredential(), options);
|
|
72241
72238
|
}
|
|
72242
72239
|
else if (credentialOrPipelineOrContainerName &&
|
|
72243
72240
|
typeof credentialOrPipelineOrContainerName === "string") {
|
|
@@ -72246,7 +72243,7 @@ class ContainerClient extends StorageClient_js_1.StorageClient {
|
|
|
72246
72243
|
const extractedCreds = (0, utils_common_js_1.extractConnectionStringParts)(urlOrConnectionString);
|
|
72247
72244
|
if (extractedCreds.kind === "AccountConnString") {
|
|
72248
72245
|
if (core_util_1.isNodeLike) {
|
|
72249
|
-
const sharedKeyCredential = new
|
|
72246
|
+
const sharedKeyCredential = new storage_common_1.StorageSharedKeyCredential(extractedCreds.accountName, extractedCreds.accountKey);
|
|
72250
72247
|
url = (0, utils_common_js_1.appendToURLPath)(extractedCreds.url, encodeURIComponent(containerName));
|
|
72251
72248
|
if (!options.proxyOptions) {
|
|
72252
72249
|
options.proxyOptions = (0, core_rest_pipeline_1.getDefaultProxySettings)(extractedCreds.proxyUri);
|
|
@@ -72262,7 +72259,7 @@ class ContainerClient extends StorageClient_js_1.StorageClient {
|
|
|
72262
72259
|
(0, utils_common_js_1.appendToURLPath)(extractedCreds.url, encodeURIComponent(containerName)) +
|
|
72263
72260
|
"?" +
|
|
72264
72261
|
extractedCreds.accountSas;
|
|
72265
|
-
pipeline = (0, Pipeline_js_1.newPipeline)(new
|
|
72262
|
+
pipeline = (0, Pipeline_js_1.newPipeline)(new storage_common_1.AnonymousCredential(), options);
|
|
72266
72263
|
}
|
|
72267
72264
|
else {
|
|
72268
72265
|
throw new Error("Connection string must be either an Account connection string or a SAS connection string");
|
|
@@ -73401,7 +73398,7 @@ class ContainerClient extends StorageClient_js_1.StorageClient {
|
|
|
73401
73398
|
*/
|
|
73402
73399
|
generateSasUrl(options) {
|
|
73403
73400
|
return new Promise((resolve) => {
|
|
73404
|
-
if (!(this.credential instanceof
|
|
73401
|
+
if (!(this.credential instanceof storage_common_1.StorageSharedKeyCredential)) {
|
|
73405
73402
|
throw new RangeError("Can only generate the SAS when the client is initialized with a shared key credential");
|
|
73406
73403
|
}
|
|
73407
73404
|
const sas = (0, BlobSASSignatureValues_js_1.generateBlobSASQueryParameters)({
|
|
@@ -73424,7 +73421,7 @@ class ContainerClient extends StorageClient_js_1.StorageClient {
|
|
|
73424
73421
|
*/
|
|
73425
73422
|
/* eslint-disable-next-line @azure/azure-sdk/ts-naming-options*/
|
|
73426
73423
|
generateSasStringToSign(options) {
|
|
73427
|
-
if (!(this.credential instanceof
|
|
73424
|
+
if (!(this.credential instanceof storage_common_1.StorageSharedKeyCredential)) {
|
|
73428
73425
|
throw new RangeError("Can only generate the SAS when the client is initialized with a shared key credential");
|
|
73429
73426
|
}
|
|
73430
73427
|
return (0, BlobSASSignatureValues_js_1.generateBlobSASQueryParametersInternal)({
|
|
@@ -73543,17 +73540,9 @@ const core_client_1 = __nccwpck_require__(60160);
|
|
|
73543
73540
|
const core_xml_1 = __nccwpck_require__(78756);
|
|
73544
73541
|
const core_auth_1 = __nccwpck_require__(50417);
|
|
73545
73542
|
const log_js_1 = __nccwpck_require__(46370);
|
|
73546
|
-
const
|
|
73547
|
-
const StorageSharedKeyCredential_js_1 = __nccwpck_require__(68999);
|
|
73548
|
-
const AnonymousCredential_js_1 = __nccwpck_require__(35345);
|
|
73543
|
+
const storage_common_1 = __nccwpck_require__(51382);
|
|
73549
73544
|
const constants_js_1 = __nccwpck_require__(27323);
|
|
73550
73545
|
Object.defineProperty(exports, "StorageOAuthScopes", ({ enumerable: true, get: function () { return constants_js_1.StorageOAuthScopes; } }));
|
|
73551
|
-
const storage_common_1 = __nccwpck_require__(51382);
|
|
73552
|
-
const StorageBrowserPolicyV2_js_1 = __nccwpck_require__(490);
|
|
73553
|
-
const StorageRetryPolicyV2_js_1 = __nccwpck_require__(31160);
|
|
73554
|
-
const StorageSharedKeyCredentialPolicyV2_js_1 = __nccwpck_require__(97999);
|
|
73555
|
-
const StorageBrowserPolicyFactory_js_1 = __nccwpck_require__(31821);
|
|
73556
|
-
const StorageCorrectContentLengthPolicy_js_1 = __nccwpck_require__(99359);
|
|
73557
73546
|
/**
|
|
73558
73547
|
* A helper to decide if a given argument satisfies the Pipeline contract
|
|
73559
73548
|
* @param pipeline - An argument that may be a Pipeline
|
|
@@ -73618,7 +73607,7 @@ exports.Pipeline = Pipeline;
|
|
|
73618
73607
|
*/
|
|
73619
73608
|
function newPipeline(credential, pipelineOptions = {}) {
|
|
73620
73609
|
if (!credential) {
|
|
73621
|
-
credential = new
|
|
73610
|
+
credential = new storage_common_1.AnonymousCredential();
|
|
73622
73611
|
}
|
|
73623
73612
|
const pipeline = new Pipeline([], pipelineOptions);
|
|
73624
73613
|
pipeline._credential = credential;
|
|
@@ -73695,10 +73684,10 @@ function getCoreClientOptions(pipeline) {
|
|
|
73695
73684
|
});
|
|
73696
73685
|
corePipeline.removePolicy({ phase: "Retry" });
|
|
73697
73686
|
corePipeline.removePolicy({ name: core_rest_pipeline_1.decompressResponsePolicyName });
|
|
73698
|
-
corePipeline.addPolicy((0,
|
|
73699
|
-
corePipeline.addPolicy((0,
|
|
73687
|
+
corePipeline.addPolicy((0, storage_common_1.storageCorrectContentLengthPolicy)());
|
|
73688
|
+
corePipeline.addPolicy((0, storage_common_1.storageRetryPolicy)(restOptions.retryOptions), { phase: "Retry" });
|
|
73700
73689
|
corePipeline.addPolicy((0, storage_common_1.storageRequestFailureDetailsParserPolicy)());
|
|
73701
|
-
corePipeline.addPolicy((0,
|
|
73690
|
+
corePipeline.addPolicy((0, storage_common_1.storageBrowserPolicy)());
|
|
73702
73691
|
const downlevelResults = processDownlevelPipeline(pipeline);
|
|
73703
73692
|
if (downlevelResults) {
|
|
73704
73693
|
corePipeline.addPolicy(downlevelResults.wrappedPolicies, downlevelResults.afterRetry ? { afterPhase: "Retry" } : undefined);
|
|
@@ -73711,8 +73700,8 @@ function getCoreClientOptions(pipeline) {
|
|
|
73711
73700
|
challengeCallbacks: { authorizeRequestOnChallenge: core_client_1.authorizeRequestOnTenantChallenge },
|
|
73712
73701
|
}), { phase: "Sign" });
|
|
73713
73702
|
}
|
|
73714
|
-
else if (credential instanceof
|
|
73715
|
-
corePipeline.addPolicy((0,
|
|
73703
|
+
else if (credential instanceof storage_common_1.StorageSharedKeyCredential) {
|
|
73704
|
+
corePipeline.addPolicy((0, storage_common_1.storageSharedKeyCredentialPolicy)({
|
|
73716
73705
|
accountName: credential.accountName,
|
|
73717
73706
|
accountKey: credential.accountKey,
|
|
73718
73707
|
}), { phase: "Sign" });
|
|
@@ -73732,7 +73721,7 @@ function getCredentialFromPipeline(pipeline) {
|
|
|
73732
73721
|
return pipeline._credential;
|
|
73733
73722
|
}
|
|
73734
73723
|
// if it came from another package, loop over the factories and look for one like before
|
|
73735
|
-
let credential = new
|
|
73724
|
+
let credential = new storage_common_1.AnonymousCredential();
|
|
73736
73725
|
for (const factory of pipeline.factories) {
|
|
73737
73726
|
if ((0, core_auth_1.isTokenCredential)(factory.credential)) {
|
|
73738
73727
|
// Only works if the factory has been attached a "credential" property.
|
|
@@ -73746,13 +73735,13 @@ function getCredentialFromPipeline(pipeline) {
|
|
|
73746
73735
|
return credential;
|
|
73747
73736
|
}
|
|
73748
73737
|
function isStorageSharedKeyCredential(factory) {
|
|
73749
|
-
if (factory instanceof
|
|
73738
|
+
if (factory instanceof storage_common_1.StorageSharedKeyCredential) {
|
|
73750
73739
|
return true;
|
|
73751
73740
|
}
|
|
73752
73741
|
return factory.constructor.name === "StorageSharedKeyCredential";
|
|
73753
73742
|
}
|
|
73754
73743
|
function isAnonymousCredential(factory) {
|
|
73755
|
-
if (factory instanceof
|
|
73744
|
+
if (factory instanceof storage_common_1.AnonymousCredential) {
|
|
73756
73745
|
return true;
|
|
73757
73746
|
}
|
|
73758
73747
|
return factory.constructor.name === "AnonymousCredential";
|
|
@@ -73761,13 +73750,13 @@ function isCoreHttpBearerTokenFactory(factory) {
|
|
|
73761
73750
|
return (0, core_auth_1.isTokenCredential)(factory.credential);
|
|
73762
73751
|
}
|
|
73763
73752
|
function isStorageBrowserPolicyFactory(factory) {
|
|
73764
|
-
if (factory instanceof
|
|
73753
|
+
if (factory instanceof storage_common_1.StorageBrowserPolicyFactory) {
|
|
73765
73754
|
return true;
|
|
73766
73755
|
}
|
|
73767
73756
|
return factory.constructor.name === "StorageBrowserPolicyFactory";
|
|
73768
73757
|
}
|
|
73769
73758
|
function isStorageRetryPolicyFactory(factory) {
|
|
73770
|
-
if (factory instanceof
|
|
73759
|
+
if (factory instanceof storage_common_1.StorageRetryPolicyFactory) {
|
|
73771
73760
|
return true;
|
|
73772
73761
|
}
|
|
73773
73762
|
return factory.constructor.name === "StorageRetryPolicyFactory";
|
|
@@ -73847,36 +73836,6 @@ function rangeToString(iRange) {
|
|
|
73847
73836
|
|
|
73848
73837
|
/***/ }),
|
|
73849
73838
|
|
|
73850
|
-
/***/ 31821:
|
|
73851
|
-
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
|
73852
|
-
|
|
73853
|
-
"use strict";
|
|
73854
|
-
|
|
73855
|
-
// Copyright (c) Microsoft Corporation.
|
|
73856
|
-
// Licensed under the MIT License.
|
|
73857
|
-
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
73858
|
-
exports.StorageBrowserPolicyFactory = exports.StorageBrowserPolicy = void 0;
|
|
73859
|
-
const StorageBrowserPolicy_js_1 = __nccwpck_require__(78654);
|
|
73860
|
-
Object.defineProperty(exports, "StorageBrowserPolicy", ({ enumerable: true, get: function () { return StorageBrowserPolicy_js_1.StorageBrowserPolicy; } }));
|
|
73861
|
-
/**
|
|
73862
|
-
* StorageBrowserPolicyFactory is a factory class helping generating StorageBrowserPolicy objects.
|
|
73863
|
-
*/
|
|
73864
|
-
class StorageBrowserPolicyFactory {
|
|
73865
|
-
/**
|
|
73866
|
-
* Creates a StorageBrowserPolicyFactory object.
|
|
73867
|
-
*
|
|
73868
|
-
* @param nextPolicy -
|
|
73869
|
-
* @param options -
|
|
73870
|
-
*/
|
|
73871
|
-
create(nextPolicy, options) {
|
|
73872
|
-
return new StorageBrowserPolicy_js_1.StorageBrowserPolicy(nextPolicy, options);
|
|
73873
|
-
}
|
|
73874
|
-
}
|
|
73875
|
-
exports.StorageBrowserPolicyFactory = StorageBrowserPolicyFactory;
|
|
73876
|
-
//# sourceMappingURL=StorageBrowserPolicyFactory.js.map
|
|
73877
|
-
|
|
73878
|
-
/***/ }),
|
|
73879
|
-
|
|
73880
73839
|
/***/ 73542:
|
|
73881
73840
|
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
|
73882
73841
|
|
|
@@ -73968,221 +73927,6 @@ exports.StorageContextClient = StorageContextClient;
|
|
|
73968
73927
|
|
|
73969
73928
|
/***/ }),
|
|
73970
73929
|
|
|
73971
|
-
/***/ 98335:
|
|
73972
|
-
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
|
73973
|
-
|
|
73974
|
-
"use strict";
|
|
73975
|
-
|
|
73976
|
-
// Copyright (c) Microsoft Corporation.
|
|
73977
|
-
// Licensed under the MIT License.
|
|
73978
|
-
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
73979
|
-
exports.StorageRetryPolicyFactory = exports.StorageRetryPolicy = exports.StorageRetryPolicyType = void 0;
|
|
73980
|
-
const StorageRetryPolicy_js_1 = __nccwpck_require__(57996);
|
|
73981
|
-
Object.defineProperty(exports, "StorageRetryPolicy", ({ enumerable: true, get: function () { return StorageRetryPolicy_js_1.StorageRetryPolicy; } }));
|
|
73982
|
-
const StorageRetryPolicyType_js_1 = __nccwpck_require__(16308);
|
|
73983
|
-
Object.defineProperty(exports, "StorageRetryPolicyType", ({ enumerable: true, get: function () { return StorageRetryPolicyType_js_1.StorageRetryPolicyType; } }));
|
|
73984
|
-
/**
|
|
73985
|
-
* StorageRetryPolicyFactory is a factory class helping generating {@link StorageRetryPolicy} objects.
|
|
73986
|
-
*/
|
|
73987
|
-
class StorageRetryPolicyFactory {
|
|
73988
|
-
retryOptions;
|
|
73989
|
-
/**
|
|
73990
|
-
* Creates an instance of StorageRetryPolicyFactory.
|
|
73991
|
-
* @param retryOptions -
|
|
73992
|
-
*/
|
|
73993
|
-
constructor(retryOptions) {
|
|
73994
|
-
this.retryOptions = retryOptions;
|
|
73995
|
-
}
|
|
73996
|
-
/**
|
|
73997
|
-
* Creates a StorageRetryPolicy object.
|
|
73998
|
-
*
|
|
73999
|
-
* @param nextPolicy -
|
|
74000
|
-
* @param options -
|
|
74001
|
-
*/
|
|
74002
|
-
create(nextPolicy, options) {
|
|
74003
|
-
return new StorageRetryPolicy_js_1.StorageRetryPolicy(nextPolicy, options, this.retryOptions);
|
|
74004
|
-
}
|
|
74005
|
-
}
|
|
74006
|
-
exports.StorageRetryPolicyFactory = StorageRetryPolicyFactory;
|
|
74007
|
-
//# sourceMappingURL=StorageRetryPolicyFactory.js.map
|
|
74008
|
-
|
|
74009
|
-
/***/ }),
|
|
74010
|
-
|
|
74011
|
-
/***/ 35345:
|
|
74012
|
-
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
|
74013
|
-
|
|
74014
|
-
"use strict";
|
|
74015
|
-
|
|
74016
|
-
// Copyright (c) Microsoft Corporation.
|
|
74017
|
-
// Licensed under the MIT License.
|
|
74018
|
-
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
74019
|
-
exports.AnonymousCredential = void 0;
|
|
74020
|
-
const AnonymousCredentialPolicy_js_1 = __nccwpck_require__(13501);
|
|
74021
|
-
const Credential_js_1 = __nccwpck_require__(52596);
|
|
74022
|
-
/**
|
|
74023
|
-
* AnonymousCredential provides a credentialPolicyCreator member used to create
|
|
74024
|
-
* AnonymousCredentialPolicy objects. AnonymousCredentialPolicy is used with
|
|
74025
|
-
* HTTP(S) requests that read public resources or for use with Shared Access
|
|
74026
|
-
* Signatures (SAS).
|
|
74027
|
-
*/
|
|
74028
|
-
class AnonymousCredential extends Credential_js_1.Credential {
|
|
74029
|
-
/**
|
|
74030
|
-
* Creates an {@link AnonymousCredentialPolicy} object.
|
|
74031
|
-
*
|
|
74032
|
-
* @param nextPolicy -
|
|
74033
|
-
* @param options -
|
|
74034
|
-
*/
|
|
74035
|
-
create(nextPolicy, options) {
|
|
74036
|
-
return new AnonymousCredentialPolicy_js_1.AnonymousCredentialPolicy(nextPolicy, options);
|
|
74037
|
-
}
|
|
74038
|
-
}
|
|
74039
|
-
exports.AnonymousCredential = AnonymousCredential;
|
|
74040
|
-
//# sourceMappingURL=AnonymousCredential.js.map
|
|
74041
|
-
|
|
74042
|
-
/***/ }),
|
|
74043
|
-
|
|
74044
|
-
/***/ 52596:
|
|
74045
|
-
/***/ ((__unused_webpack_module, exports) => {
|
|
74046
|
-
|
|
74047
|
-
"use strict";
|
|
74048
|
-
|
|
74049
|
-
// Copyright (c) Microsoft Corporation.
|
|
74050
|
-
// Licensed under the MIT License.
|
|
74051
|
-
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
74052
|
-
exports.Credential = void 0;
|
|
74053
|
-
/**
|
|
74054
|
-
* Credential is an abstract class for Azure Storage HTTP requests signing. This
|
|
74055
|
-
* class will host an credentialPolicyCreator factory which generates CredentialPolicy.
|
|
74056
|
-
*/
|
|
74057
|
-
class Credential {
|
|
74058
|
-
/**
|
|
74059
|
-
* Creates a RequestPolicy object.
|
|
74060
|
-
*
|
|
74061
|
-
* @param _nextPolicy -
|
|
74062
|
-
* @param _options -
|
|
74063
|
-
*/
|
|
74064
|
-
create(_nextPolicy, _options) {
|
|
74065
|
-
throw new Error("Method should be implemented in children classes.");
|
|
74066
|
-
}
|
|
74067
|
-
}
|
|
74068
|
-
exports.Credential = Credential;
|
|
74069
|
-
//# sourceMappingURL=Credential.js.map
|
|
74070
|
-
|
|
74071
|
-
/***/ }),
|
|
74072
|
-
|
|
74073
|
-
/***/ 68999:
|
|
74074
|
-
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
|
74075
|
-
|
|
74076
|
-
"use strict";
|
|
74077
|
-
|
|
74078
|
-
// Copyright (c) Microsoft Corporation.
|
|
74079
|
-
// Licensed under the MIT License.
|
|
74080
|
-
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
74081
|
-
exports.StorageSharedKeyCredential = void 0;
|
|
74082
|
-
const node_crypto_1 = __nccwpck_require__(77598);
|
|
74083
|
-
const StorageSharedKeyCredentialPolicy_js_1 = __nccwpck_require__(45511);
|
|
74084
|
-
const Credential_js_1 = __nccwpck_require__(52596);
|
|
74085
|
-
/**
|
|
74086
|
-
* ONLY AVAILABLE IN NODE.JS RUNTIME.
|
|
74087
|
-
*
|
|
74088
|
-
* StorageSharedKeyCredential for account key authorization of Azure Storage service.
|
|
74089
|
-
*/
|
|
74090
|
-
class StorageSharedKeyCredential extends Credential_js_1.Credential {
|
|
74091
|
-
/**
|
|
74092
|
-
* Azure Storage account name; readonly.
|
|
74093
|
-
*/
|
|
74094
|
-
accountName;
|
|
74095
|
-
/**
|
|
74096
|
-
* Azure Storage account key; readonly.
|
|
74097
|
-
*/
|
|
74098
|
-
accountKey;
|
|
74099
|
-
/**
|
|
74100
|
-
* Creates an instance of StorageSharedKeyCredential.
|
|
74101
|
-
* @param accountName -
|
|
74102
|
-
* @param accountKey -
|
|
74103
|
-
*/
|
|
74104
|
-
constructor(accountName, accountKey) {
|
|
74105
|
-
super();
|
|
74106
|
-
this.accountName = accountName;
|
|
74107
|
-
this.accountKey = Buffer.from(accountKey, "base64");
|
|
74108
|
-
}
|
|
74109
|
-
/**
|
|
74110
|
-
* Creates a StorageSharedKeyCredentialPolicy object.
|
|
74111
|
-
*
|
|
74112
|
-
* @param nextPolicy -
|
|
74113
|
-
* @param options -
|
|
74114
|
-
*/
|
|
74115
|
-
create(nextPolicy, options) {
|
|
74116
|
-
return new StorageSharedKeyCredentialPolicy_js_1.StorageSharedKeyCredentialPolicy(nextPolicy, options, this);
|
|
74117
|
-
}
|
|
74118
|
-
/**
|
|
74119
|
-
* Generates a hash signature for an HTTP request or for a SAS.
|
|
74120
|
-
*
|
|
74121
|
-
* @param stringToSign -
|
|
74122
|
-
*/
|
|
74123
|
-
computeHMACSHA256(stringToSign) {
|
|
74124
|
-
return (0, node_crypto_1.createHmac)("sha256", this.accountKey).update(stringToSign, "utf8").digest("base64");
|
|
74125
|
-
}
|
|
74126
|
-
}
|
|
74127
|
-
exports.StorageSharedKeyCredential = StorageSharedKeyCredential;
|
|
74128
|
-
//# sourceMappingURL=StorageSharedKeyCredential.js.map
|
|
74129
|
-
|
|
74130
|
-
/***/ }),
|
|
74131
|
-
|
|
74132
|
-
/***/ 10992:
|
|
74133
|
-
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
|
74134
|
-
|
|
74135
|
-
"use strict";
|
|
74136
|
-
|
|
74137
|
-
// Copyright (c) Microsoft Corporation.
|
|
74138
|
-
// Licensed under the MIT License.
|
|
74139
|
-
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
74140
|
-
exports.UserDelegationKeyCredential = void 0;
|
|
74141
|
-
const node_crypto_1 = __nccwpck_require__(77598);
|
|
74142
|
-
/**
|
|
74143
|
-
* ONLY AVAILABLE IN NODE.JS RUNTIME.
|
|
74144
|
-
*
|
|
74145
|
-
* UserDelegationKeyCredential is only used for generation of user delegation SAS.
|
|
74146
|
-
* @see https://learn.microsoft.com/rest/api/storageservices/create-user-delegation-sas
|
|
74147
|
-
*/
|
|
74148
|
-
class UserDelegationKeyCredential {
|
|
74149
|
-
/**
|
|
74150
|
-
* Azure Storage account name; readonly.
|
|
74151
|
-
*/
|
|
74152
|
-
accountName;
|
|
74153
|
-
/**
|
|
74154
|
-
* Azure Storage user delegation key; readonly.
|
|
74155
|
-
*/
|
|
74156
|
-
userDelegationKey;
|
|
74157
|
-
/**
|
|
74158
|
-
* Key value in Buffer type.
|
|
74159
|
-
*/
|
|
74160
|
-
key;
|
|
74161
|
-
/**
|
|
74162
|
-
* Creates an instance of UserDelegationKeyCredential.
|
|
74163
|
-
* @param accountName -
|
|
74164
|
-
* @param userDelegationKey -
|
|
74165
|
-
*/
|
|
74166
|
-
constructor(accountName, userDelegationKey) {
|
|
74167
|
-
this.accountName = accountName;
|
|
74168
|
-
this.userDelegationKey = userDelegationKey;
|
|
74169
|
-
this.key = Buffer.from(userDelegationKey.value, "base64");
|
|
74170
|
-
}
|
|
74171
|
-
/**
|
|
74172
|
-
* Generates a hash signature for an HTTP request or for a SAS.
|
|
74173
|
-
*
|
|
74174
|
-
* @param stringToSign -
|
|
74175
|
-
*/
|
|
74176
|
-
computeHMACSHA256(stringToSign) {
|
|
74177
|
-
// console.log(`stringToSign: ${JSON.stringify(stringToSign)}`);
|
|
74178
|
-
return (0, node_crypto_1.createHmac)("sha256", this.key).update(stringToSign, "utf8").digest("base64");
|
|
74179
|
-
}
|
|
74180
|
-
}
|
|
74181
|
-
exports.UserDelegationKeyCredential = UserDelegationKeyCredential;
|
|
74182
|
-
//# sourceMappingURL=UserDelegationKeyCredential.js.map
|
|
74183
|
-
|
|
74184
|
-
/***/ }),
|
|
74185
|
-
|
|
74186
73930
|
/***/ 30247:
|
|
74187
73931
|
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
|
74188
73932
|
|
|
@@ -82837,8 +82581,8 @@ exports.BlockBlobGetBlockListExceptionHeaders = {
|
|
|
82837
82581
|
*/
|
|
82838
82582
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
82839
82583
|
exports.action3 = exports.action2 = exports.leaseId1 = exports.action1 = exports.proposedLeaseId = exports.duration = exports.action = exports.comp10 = exports.sourceLeaseId = exports.sourceContainerName = exports.comp9 = exports.deletedContainerVersion = exports.deletedContainerName = exports.comp8 = exports.containerAcl = exports.comp7 = exports.comp6 = exports.ifUnmodifiedSince = exports.ifModifiedSince = exports.leaseId = exports.preventEncryptionScopeOverride = exports.defaultEncryptionScope = exports.access = exports.metadata = exports.restype2 = exports.where = exports.comp5 = exports.multipartContentType = exports.contentLength = exports.comp4 = exports.body = exports.restype1 = exports.comp3 = exports.keyInfo = exports.include = exports.maxPageSize = exports.marker = exports.prefix = exports.comp2 = exports.comp1 = exports.accept1 = exports.requestId = exports.version = exports.timeoutInSeconds = exports.comp = exports.restype = exports.url = exports.accept = exports.blobServiceProperties = exports.contentType = void 0;
|
|
82840
|
-
exports.
|
|
82841
|
-
exports.listType = exports.comp25 = exports.blocks = exports.blockId = exports.comp24 = exports.copySourceBlobProperties = exports.blobType2 = exports.comp23 = exports.sourceRange1 = exports.appendPosition = exports.maxSize = exports.comp22 = exports.blobType1 = exports.comp21 = exports.sequenceNumberAction = exports.prevSnapshotUrl = exports.prevsnapshot = exports.comp20 = exports.range1 = exports.sourceContentCrc64 = exports.sourceRange = exports.sourceUrl = exports.pageWrite1 = exports.ifSequenceNumberEqualTo = exports.ifSequenceNumberLessThan = exports.ifSequenceNumberLessThanOrEqualTo = exports.pageWrite = exports.comp19 = exports.accept2 = exports.body1 = exports.contentType1 = exports.blobSequenceNumber = exports.blobContentLength = exports.blobType = exports.transactionalContentCrc64 = exports.transactionalContentMD5 = exports.tags = exports.comp18 = exports.comp17 = exports.queryRequest = exports.tier1 = exports.comp16 = exports.copyId = exports.copyActionAbortConstant = exports.comp15 = void 0;
|
|
82584
|
+
exports.copySourceTags = exports.copySourceAuthorization = exports.sourceContentMD5 = exports.xMsRequiresSync = exports.legalHold1 = exports.sealBlob = exports.blobTagsString = exports.copySource = exports.sourceIfTags = exports.sourceIfNoneMatch = exports.sourceIfMatch = exports.sourceIfUnmodifiedSince = exports.sourceIfModifiedSince = exports.rehydratePriority = exports.tier = exports.comp14 = exports.encryptionScope = exports.legalHold = exports.comp13 = exports.immutabilityPolicyMode = exports.immutabilityPolicyExpiry = exports.comp12 = exports.blobContentDisposition = exports.blobContentLanguage = exports.blobContentEncoding = exports.blobContentMD5 = exports.blobContentType = exports.blobCacheControl = exports.expiresOn = exports.expiryOptions = exports.comp11 = exports.blobDeleteType = exports.deleteSnapshots = exports.ifTags = exports.ifNoneMatch = exports.ifMatch = exports.encryptionAlgorithm = exports.encryptionKeySha256 = exports.encryptionKey = exports.rangeGetContentCRC64 = exports.rangeGetContentMD5 = exports.range = exports.versionId = exports.snapshot = exports.delimiter = exports.startFrom = exports.include1 = exports.proposedLeaseId1 = exports.action4 = exports.breakPeriod = void 0;
|
|
82585
|
+
exports.listType = exports.comp25 = exports.blocks = exports.blockId = exports.comp24 = exports.copySourceBlobProperties = exports.blobType2 = exports.comp23 = exports.sourceRange1 = exports.appendPosition = exports.maxSize = exports.comp22 = exports.blobType1 = exports.comp21 = exports.sequenceNumberAction = exports.prevSnapshotUrl = exports.prevsnapshot = exports.comp20 = exports.range1 = exports.sourceContentCrc64 = exports.sourceRange = exports.sourceUrl = exports.pageWrite1 = exports.ifSequenceNumberEqualTo = exports.ifSequenceNumberLessThan = exports.ifSequenceNumberLessThanOrEqualTo = exports.pageWrite = exports.comp19 = exports.accept2 = exports.body1 = exports.contentType1 = exports.blobSequenceNumber = exports.blobContentLength = exports.blobType = exports.transactionalContentCrc64 = exports.transactionalContentMD5 = exports.tags = exports.ifNoneMatch1 = exports.ifMatch1 = exports.ifUnmodifiedSince1 = exports.ifModifiedSince1 = exports.comp18 = exports.comp17 = exports.queryRequest = exports.tier1 = exports.comp16 = exports.copyId = exports.copyActionAbortConstant = exports.comp15 = exports.fileRequestIntent = void 0;
|
|
82842
82586
|
const mappers_js_1 = __nccwpck_require__(84424);
|
|
82843
82587
|
exports.contentType = {
|
|
82844
82588
|
parameterPath: ["options", "contentType"],
|
|
@@ -82916,7 +82660,7 @@ exports.timeoutInSeconds = {
|
|
|
82916
82660
|
exports.version = {
|
|
82917
82661
|
parameterPath: "version",
|
|
82918
82662
|
mapper: {
|
|
82919
|
-
defaultValue: "
|
|
82663
|
+
defaultValue: "2026-02-06",
|
|
82920
82664
|
isConstant: true,
|
|
82921
82665
|
serializedName: "x-ms-version",
|
|
82922
82666
|
type: {
|
|
@@ -83451,6 +83195,16 @@ exports.include1 = {
|
|
|
83451
83195
|
},
|
|
83452
83196
|
collectionFormat: "CSV",
|
|
83453
83197
|
};
|
|
83198
|
+
exports.startFrom = {
|
|
83199
|
+
parameterPath: ["options", "startFrom"],
|
|
83200
|
+
mapper: {
|
|
83201
|
+
serializedName: "startFrom",
|
|
83202
|
+
xmlName: "startFrom",
|
|
83203
|
+
type: {
|
|
83204
|
+
name: "String",
|
|
83205
|
+
},
|
|
83206
|
+
},
|
|
83207
|
+
};
|
|
83454
83208
|
exports.delimiter = {
|
|
83455
83209
|
parameterPath: "delimiter",
|
|
83456
83210
|
mapper: {
|
|
@@ -84051,6 +83805,50 @@ exports.comp18 = {
|
|
|
84051
83805
|
},
|
|
84052
83806
|
},
|
|
84053
83807
|
};
|
|
83808
|
+
exports.ifModifiedSince1 = {
|
|
83809
|
+
parameterPath: ["options", "blobModifiedAccessConditions", "ifModifiedSince"],
|
|
83810
|
+
mapper: {
|
|
83811
|
+
serializedName: "x-ms-blob-if-modified-since",
|
|
83812
|
+
xmlName: "x-ms-blob-if-modified-since",
|
|
83813
|
+
type: {
|
|
83814
|
+
name: "DateTimeRfc1123",
|
|
83815
|
+
},
|
|
83816
|
+
},
|
|
83817
|
+
};
|
|
83818
|
+
exports.ifUnmodifiedSince1 = {
|
|
83819
|
+
parameterPath: [
|
|
83820
|
+
"options",
|
|
83821
|
+
"blobModifiedAccessConditions",
|
|
83822
|
+
"ifUnmodifiedSince",
|
|
83823
|
+
],
|
|
83824
|
+
mapper: {
|
|
83825
|
+
serializedName: "x-ms-blob-if-unmodified-since",
|
|
83826
|
+
xmlName: "x-ms-blob-if-unmodified-since",
|
|
83827
|
+
type: {
|
|
83828
|
+
name: "DateTimeRfc1123",
|
|
83829
|
+
},
|
|
83830
|
+
},
|
|
83831
|
+
};
|
|
83832
|
+
exports.ifMatch1 = {
|
|
83833
|
+
parameterPath: ["options", "blobModifiedAccessConditions", "ifMatch"],
|
|
83834
|
+
mapper: {
|
|
83835
|
+
serializedName: "x-ms-blob-if-match",
|
|
83836
|
+
xmlName: "x-ms-blob-if-match",
|
|
83837
|
+
type: {
|
|
83838
|
+
name: "String",
|
|
83839
|
+
},
|
|
83840
|
+
},
|
|
83841
|
+
};
|
|
83842
|
+
exports.ifNoneMatch1 = {
|
|
83843
|
+
parameterPath: ["options", "blobModifiedAccessConditions", "ifNoneMatch"],
|
|
83844
|
+
mapper: {
|
|
83845
|
+
serializedName: "x-ms-blob-if-none-match",
|
|
83846
|
+
xmlName: "x-ms-blob-if-none-match",
|
|
83847
|
+
type: {
|
|
83848
|
+
name: "String",
|
|
83849
|
+
},
|
|
83850
|
+
},
|
|
83851
|
+
};
|
|
84054
83852
|
exports.tags = {
|
|
84055
83853
|
parameterPath: ["options", "tags"],
|
|
84056
83854
|
mapper: mappers_js_1.BlobTags,
|
|
@@ -85682,6 +85480,10 @@ const getTagsOperationSpec = {
|
|
|
85682
85480
|
Parameters.accept1,
|
|
85683
85481
|
Parameters.leaseId,
|
|
85684
85482
|
Parameters.ifTags,
|
|
85483
|
+
Parameters.ifModifiedSince1,
|
|
85484
|
+
Parameters.ifUnmodifiedSince1,
|
|
85485
|
+
Parameters.ifMatch1,
|
|
85486
|
+
Parameters.ifNoneMatch1,
|
|
85685
85487
|
],
|
|
85686
85488
|
isXML: true,
|
|
85687
85489
|
serializer: xmlSerializer,
|
|
@@ -85712,6 +85514,10 @@ const setTagsOperationSpec = {
|
|
|
85712
85514
|
Parameters.requestId,
|
|
85713
85515
|
Parameters.leaseId,
|
|
85714
85516
|
Parameters.ifTags,
|
|
85517
|
+
Parameters.ifModifiedSince1,
|
|
85518
|
+
Parameters.ifUnmodifiedSince1,
|
|
85519
|
+
Parameters.ifMatch1,
|
|
85520
|
+
Parameters.ifNoneMatch1,
|
|
85715
85521
|
Parameters.transactionalContentMD5,
|
|
85716
85522
|
Parameters.transactionalContentCrc64,
|
|
85717
85523
|
],
|
|
@@ -86758,6 +86564,7 @@ const listBlobFlatSegmentOperationSpec = {
|
|
|
86758
86564
|
Parameters.maxPageSize,
|
|
86759
86565
|
Parameters.restype2,
|
|
86760
86566
|
Parameters.include1,
|
|
86567
|
+
Parameters.startFrom,
|
|
86761
86568
|
],
|
|
86762
86569
|
urlParameters: [Parameters.url],
|
|
86763
86570
|
headerParameters: [
|
|
@@ -86789,6 +86596,7 @@ const listBlobHierarchySegmentOperationSpec = {
|
|
|
86789
86596
|
Parameters.maxPageSize,
|
|
86790
86597
|
Parameters.restype2,
|
|
86791
86598
|
Parameters.include1,
|
|
86599
|
+
Parameters.startFrom,
|
|
86792
86600
|
Parameters.delimiter,
|
|
86793
86601
|
],
|
|
86794
86602
|
urlParameters: [Parameters.url],
|
|
@@ -87823,7 +87631,7 @@ class StorageClient extends coreHttpCompat.ExtendedServiceClient {
|
|
|
87823
87631
|
const defaults = {
|
|
87824
87632
|
requestContentType: "application/json; charset=utf-8",
|
|
87825
87633
|
};
|
|
87826
|
-
const packageDetails = `azsdk-js-azure-storage-blob/12.
|
|
87634
|
+
const packageDetails = `azsdk-js-azure-storage-blob/12.30.0`;
|
|
87827
87635
|
const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix
|
|
87828
87636
|
? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}`
|
|
87829
87637
|
: `${packageDetails}`;
|
|
@@ -87839,7 +87647,7 @@ class StorageClient extends coreHttpCompat.ExtendedServiceClient {
|
|
|
87839
87647
|
// Parameter assignments
|
|
87840
87648
|
this.url = url;
|
|
87841
87649
|
// Assigning values to Constant parameters
|
|
87842
|
-
this.version = options.version || "
|
|
87650
|
+
this.version = options.version || "2026-02-06";
|
|
87843
87651
|
this.service = new index_js_1.ServiceImpl(this);
|
|
87844
87652
|
this.container = new index_js_1.ContainerImpl(this);
|
|
87845
87653
|
this.blob = new index_js_1.BlobImpl(this);
|
|
@@ -87885,7 +87693,7 @@ var KnownEncryptionAlgorithmType;
|
|
|
87885
87693
|
// Copyright (c) Microsoft Corporation.
|
|
87886
87694
|
// Licensed under the MIT License.
|
|
87887
87695
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
87888
|
-
exports.logger = exports.RestError = exports.BaseRequestPolicy = exports.StorageOAuthScopes = exports.newPipeline = exports.isPipelineLike = exports.Pipeline = exports.getBlobServiceAccountAudience = exports.StorageBlobAudience = exports.PremiumPageBlobTier = exports.BlockBlobTier = exports.generateBlobSASQueryParameters = exports.generateAccountSASQueryParameters = void 0;
|
|
87696
|
+
exports.logger = exports.RestError = exports.StorageBrowserPolicyFactory = exports.StorageBrowserPolicy = exports.StorageSharedKeyCredentialPolicy = exports.StorageSharedKeyCredential = exports.StorageRetryPolicyFactory = exports.StorageRetryPolicy = exports.StorageRetryPolicyType = exports.Credential = exports.CredentialPolicy = exports.BaseRequestPolicy = exports.AnonymousCredentialPolicy = exports.AnonymousCredential = exports.StorageOAuthScopes = exports.newPipeline = exports.isPipelineLike = exports.Pipeline = exports.getBlobServiceAccountAudience = exports.StorageBlobAudience = exports.PremiumPageBlobTier = exports.BlockBlobTier = exports.generateBlobSASQueryParameters = exports.generateAccountSASQueryParameters = void 0;
|
|
87889
87697
|
const tslib_1 = __nccwpck_require__(61860);
|
|
87890
87698
|
const core_rest_pipeline_1 = __nccwpck_require__(20778);
|
|
87891
87699
|
Object.defineProperty(exports, "RestError", ({ enumerable: true, get: function () { return core_rest_pipeline_1.RestError; } }));
|
|
@@ -87904,11 +87712,7 @@ tslib_1.__exportStar(__nccwpck_require__(48175), exports);
|
|
|
87904
87712
|
tslib_1.__exportStar(__nccwpck_require__(2232), exports);
|
|
87905
87713
|
var BlobSASSignatureValues_js_1 = __nccwpck_require__(656);
|
|
87906
87714
|
Object.defineProperty(exports, "generateBlobSASQueryParameters", ({ enumerable: true, get: function () { return BlobSASSignatureValues_js_1.generateBlobSASQueryParameters; } }));
|
|
87907
|
-
tslib_1.__exportStar(__nccwpck_require__(31821), exports);
|
|
87908
87715
|
tslib_1.__exportStar(__nccwpck_require__(51622), exports);
|
|
87909
|
-
tslib_1.__exportStar(__nccwpck_require__(35345), exports);
|
|
87910
|
-
tslib_1.__exportStar(__nccwpck_require__(52596), exports);
|
|
87911
|
-
tslib_1.__exportStar(__nccwpck_require__(68999), exports);
|
|
87912
87716
|
var models_js_1 = __nccwpck_require__(58560);
|
|
87913
87717
|
Object.defineProperty(exports, "BlockBlobTier", ({ enumerable: true, get: function () { return models_js_1.BlockBlobTier; } }));
|
|
87914
87718
|
Object.defineProperty(exports, "PremiumPageBlobTier", ({ enumerable: true, get: function () { return models_js_1.PremiumPageBlobTier; } }));
|
|
@@ -87919,13 +87723,19 @@ Object.defineProperty(exports, "Pipeline", ({ enumerable: true, get: function ()
|
|
|
87919
87723
|
Object.defineProperty(exports, "isPipelineLike", ({ enumerable: true, get: function () { return Pipeline_js_1.isPipelineLike; } }));
|
|
87920
87724
|
Object.defineProperty(exports, "newPipeline", ({ enumerable: true, get: function () { return Pipeline_js_1.newPipeline; } }));
|
|
87921
87725
|
Object.defineProperty(exports, "StorageOAuthScopes", ({ enumerable: true, get: function () { return Pipeline_js_1.StorageOAuthScopes; } }));
|
|
87922
|
-
|
|
87923
|
-
|
|
87924
|
-
Object.defineProperty(exports, "
|
|
87925
|
-
|
|
87926
|
-
|
|
87927
|
-
|
|
87928
|
-
|
|
87726
|
+
var storage_common_1 = __nccwpck_require__(51382);
|
|
87727
|
+
Object.defineProperty(exports, "AnonymousCredential", ({ enumerable: true, get: function () { return storage_common_1.AnonymousCredential; } }));
|
|
87728
|
+
Object.defineProperty(exports, "AnonymousCredentialPolicy", ({ enumerable: true, get: function () { return storage_common_1.AnonymousCredentialPolicy; } }));
|
|
87729
|
+
Object.defineProperty(exports, "BaseRequestPolicy", ({ enumerable: true, get: function () { return storage_common_1.BaseRequestPolicy; } }));
|
|
87730
|
+
Object.defineProperty(exports, "CredentialPolicy", ({ enumerable: true, get: function () { return storage_common_1.CredentialPolicy; } }));
|
|
87731
|
+
Object.defineProperty(exports, "Credential", ({ enumerable: true, get: function () { return storage_common_1.Credential; } }));
|
|
87732
|
+
Object.defineProperty(exports, "StorageRetryPolicyType", ({ enumerable: true, get: function () { return storage_common_1.StorageRetryPolicyType; } }));
|
|
87733
|
+
Object.defineProperty(exports, "StorageRetryPolicy", ({ enumerable: true, get: function () { return storage_common_1.StorageRetryPolicy; } }));
|
|
87734
|
+
Object.defineProperty(exports, "StorageRetryPolicyFactory", ({ enumerable: true, get: function () { return storage_common_1.StorageRetryPolicyFactory; } }));
|
|
87735
|
+
Object.defineProperty(exports, "StorageSharedKeyCredential", ({ enumerable: true, get: function () { return storage_common_1.StorageSharedKeyCredential; } }));
|
|
87736
|
+
Object.defineProperty(exports, "StorageSharedKeyCredentialPolicy", ({ enumerable: true, get: function () { return storage_common_1.StorageSharedKeyCredentialPolicy; } }));
|
|
87737
|
+
Object.defineProperty(exports, "StorageBrowserPolicy", ({ enumerable: true, get: function () { return storage_common_1.StorageBrowserPolicy; } }));
|
|
87738
|
+
Object.defineProperty(exports, "StorageBrowserPolicyFactory", ({ enumerable: true, get: function () { return storage_common_1.StorageBrowserPolicyFactory; } }));
|
|
87929
87739
|
tslib_1.__exportStar(__nccwpck_require__(26823), exports);
|
|
87930
87740
|
tslib_1.__exportStar(__nccwpck_require__(83627), exports);
|
|
87931
87741
|
var log_js_1 = __nccwpck_require__(46370);
|
|
@@ -88481,1094 +88291,52 @@ class AvroReader {
|
|
|
88481
88291
|
}
|
|
88482
88292
|
}
|
|
88483
88293
|
}
|
|
88484
|
-
hasNext() {
|
|
88485
|
-
return !this._initialized || this._itemsRemainingInBlock > 0;
|
|
88486
|
-
}
|
|
88487
|
-
async *parseObjects(options = {}) {
|
|
88488
|
-
if (!this._initialized) {
|
|
88489
|
-
await this.initialize(options);
|
|
88490
|
-
}
|
|
88491
|
-
while (this.hasNext()) {
|
|
88492
|
-
const result = await this._itemType.read(this._dataStream, {
|
|
88493
|
-
abortSignal: options.abortSignal,
|
|
88494
|
-
});
|
|
88495
|
-
this._itemsRemainingInBlock--;
|
|
88496
|
-
this._objectIndex++;
|
|
88497
|
-
if (this._itemsRemainingInBlock === 0) {
|
|
88498
|
-
const marker = await AvroParser_js_1.AvroParser.readFixedBytes(this._dataStream, AvroConstants_js_1.AVRO_SYNC_MARKER_SIZE, {
|
|
88499
|
-
abortSignal: options.abortSignal,
|
|
88500
|
-
});
|
|
88501
|
-
this._blockOffset = this._initialBlockOffset + this._dataStream.position;
|
|
88502
|
-
this._objectIndex = 0;
|
|
88503
|
-
if (!(0, utils_common_js_1.arraysEqual)(this._syncMarker, marker)) {
|
|
88504
|
-
throw new Error("Stream is not a valid Avro file.");
|
|
88505
|
-
}
|
|
88506
|
-
try {
|
|
88507
|
-
this._itemsRemainingInBlock = await AvroParser_js_1.AvroParser.readLong(this._dataStream, {
|
|
88508
|
-
abortSignal: options.abortSignal,
|
|
88509
|
-
});
|
|
88510
|
-
}
|
|
88511
|
-
catch {
|
|
88512
|
-
// We hit the end of the stream.
|
|
88513
|
-
this._itemsRemainingInBlock = 0;
|
|
88514
|
-
}
|
|
88515
|
-
if (this._itemsRemainingInBlock > 0) {
|
|
88516
|
-
// Ignore block size
|
|
88517
|
-
await AvroParser_js_1.AvroParser.readLong(this._dataStream, { abortSignal: options.abortSignal });
|
|
88518
|
-
}
|
|
88519
|
-
}
|
|
88520
|
-
yield result;
|
|
88521
|
-
}
|
|
88522
|
-
}
|
|
88523
|
-
}
|
|
88524
|
-
exports.AvroReader = AvroReader;
|
|
88525
|
-
//# sourceMappingURL=AvroReader.js.map
|
|
88526
|
-
|
|
88527
|
-
/***/ }),
|
|
88528
|
-
|
|
88529
|
-
/***/ 96147:
|
|
88530
|
-
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
|
88531
|
-
|
|
88532
|
-
"use strict";
|
|
88533
|
-
|
|
88534
|
-
// Copyright (c) Microsoft Corporation.
|
|
88535
|
-
// Licensed under the MIT License.
|
|
88536
|
-
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
88537
|
-
exports.AvroReadableFromStream = exports.AvroReadable = exports.AvroReader = void 0;
|
|
88538
|
-
var AvroReader_js_1 = __nccwpck_require__(52888);
|
|
88539
|
-
Object.defineProperty(exports, "AvroReader", ({ enumerable: true, get: function () { return AvroReader_js_1.AvroReader; } }));
|
|
88540
|
-
var AvroReadable_js_1 = __nccwpck_require__(41675);
|
|
88541
|
-
Object.defineProperty(exports, "AvroReadable", ({ enumerable: true, get: function () { return AvroReadable_js_1.AvroReadable; } }));
|
|
88542
|
-
var AvroReadableFromStream_js_1 = __nccwpck_require__(48059);
|
|
88543
|
-
Object.defineProperty(exports, "AvroReadableFromStream", ({ enumerable: true, get: function () { return AvroReadableFromStream_js_1.AvroReadableFromStream; } }));
|
|
88544
|
-
//# sourceMappingURL=index.js.map
|
|
88545
|
-
|
|
88546
|
-
/***/ }),
|
|
88547
|
-
|
|
88548
|
-
/***/ 4337:
|
|
88549
|
-
/***/ ((__unused_webpack_module, exports) => {
|
|
88550
|
-
|
|
88551
|
-
"use strict";
|
|
88552
|
-
|
|
88553
|
-
// Copyright (c) Microsoft Corporation.
|
|
88554
|
-
// Licensed under the MIT License.
|
|
88555
|
-
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
88556
|
-
exports.arraysEqual = arraysEqual;
|
|
88557
|
-
function arraysEqual(a, b) {
|
|
88558
|
-
if (a === b)
|
|
88559
|
-
return true;
|
|
88560
|
-
if (a == null || b == null)
|
|
88561
|
-
return false;
|
|
88562
|
-
if (a.length !== b.length)
|
|
88563
|
-
return false;
|
|
88564
|
-
for (let i = 0; i < a.length; ++i) {
|
|
88565
|
-
if (a[i] !== b[i])
|
|
88566
|
-
return false;
|
|
88567
|
-
}
|
|
88568
|
-
return true;
|
|
88569
|
-
}
|
|
88570
|
-
//# sourceMappingURL=utils.common.js.map
|
|
88571
|
-
|
|
88572
|
-
/***/ }),
|
|
88573
|
-
|
|
88574
|
-
/***/ 46370:
|
|
88575
|
-
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
|
88576
|
-
|
|
88577
|
-
"use strict";
|
|
88578
|
-
|
|
88579
|
-
// Copyright (c) Microsoft Corporation.
|
|
88580
|
-
// Licensed under the MIT License.
|
|
88581
|
-
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
88582
|
-
exports.logger = void 0;
|
|
88583
|
-
const logger_1 = __nccwpck_require__(26515);
|
|
88584
|
-
/**
|
|
88585
|
-
* The `@azure/logger` configuration for this package.
|
|
88586
|
-
*/
|
|
88587
|
-
exports.logger = (0, logger_1.createClientLogger)("storage-blob");
|
|
88588
|
-
//# sourceMappingURL=log.js.map
|
|
88589
|
-
|
|
88590
|
-
/***/ }),
|
|
88591
|
-
|
|
88592
|
-
/***/ 58560:
|
|
88593
|
-
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
|
88594
|
-
|
|
88595
|
-
"use strict";
|
|
88596
|
-
|
|
88597
|
-
// Copyright (c) Microsoft Corporation.
|
|
88598
|
-
// Licensed under the MIT License.
|
|
88599
|
-
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
88600
|
-
exports.StorageBlobAudience = exports.PremiumPageBlobTier = exports.BlockBlobTier = void 0;
|
|
88601
|
-
exports.toAccessTier = toAccessTier;
|
|
88602
|
-
exports.ensureCpkIfSpecified = ensureCpkIfSpecified;
|
|
88603
|
-
exports.getBlobServiceAccountAudience = getBlobServiceAccountAudience;
|
|
88604
|
-
const constants_js_1 = __nccwpck_require__(27323);
|
|
88605
|
-
/**
|
|
88606
|
-
* Represents the access tier on a blob.
|
|
88607
|
-
* For detailed information about block blob level tiering see {@link https://learn.microsoft.com/azure/storage/blobs/storage-blob-storage-tiers|Hot, cool and archive storage tiers.}
|
|
88608
|
-
*/
|
|
88609
|
-
var BlockBlobTier;
|
|
88610
|
-
(function (BlockBlobTier) {
|
|
88611
|
-
/**
|
|
88612
|
-
* Optimized for storing data that is accessed frequently.
|
|
88613
|
-
*/
|
|
88614
|
-
BlockBlobTier["Hot"] = "Hot";
|
|
88615
|
-
/**
|
|
88616
|
-
* Optimized for storing data that is infrequently accessed and stored for at least 30 days.
|
|
88617
|
-
*/
|
|
88618
|
-
BlockBlobTier["Cool"] = "Cool";
|
|
88619
|
-
/**
|
|
88620
|
-
* Optimized for storing data that is rarely accessed.
|
|
88621
|
-
*/
|
|
88622
|
-
BlockBlobTier["Cold"] = "Cold";
|
|
88623
|
-
/**
|
|
88624
|
-
* Optimized for storing data that is rarely accessed and stored for at least 180 days
|
|
88625
|
-
* with flexible latency requirements (on the order of hours).
|
|
88626
|
-
*/
|
|
88627
|
-
BlockBlobTier["Archive"] = "Archive";
|
|
88628
|
-
})(BlockBlobTier || (exports.BlockBlobTier = BlockBlobTier = {}));
|
|
88629
|
-
/**
|
|
88630
|
-
* Specifies the page blob tier to set the blob to. This is only applicable to page blobs on premium storage accounts.
|
|
88631
|
-
* Please see {@link https://learn.microsoft.com/azure/storage/storage-premium-storage#scalability-and-performance-targets|here}
|
|
88632
|
-
* for detailed information on the corresponding IOPS and throughput per PageBlobTier.
|
|
88633
|
-
*/
|
|
88634
|
-
var PremiumPageBlobTier;
|
|
88635
|
-
(function (PremiumPageBlobTier) {
|
|
88636
|
-
/**
|
|
88637
|
-
* P4 Tier.
|
|
88638
|
-
*/
|
|
88639
|
-
PremiumPageBlobTier["P4"] = "P4";
|
|
88640
|
-
/**
|
|
88641
|
-
* P6 Tier.
|
|
88642
|
-
*/
|
|
88643
|
-
PremiumPageBlobTier["P6"] = "P6";
|
|
88644
|
-
/**
|
|
88645
|
-
* P10 Tier.
|
|
88646
|
-
*/
|
|
88647
|
-
PremiumPageBlobTier["P10"] = "P10";
|
|
88648
|
-
/**
|
|
88649
|
-
* P15 Tier.
|
|
88650
|
-
*/
|
|
88651
|
-
PremiumPageBlobTier["P15"] = "P15";
|
|
88652
|
-
/**
|
|
88653
|
-
* P20 Tier.
|
|
88654
|
-
*/
|
|
88655
|
-
PremiumPageBlobTier["P20"] = "P20";
|
|
88656
|
-
/**
|
|
88657
|
-
* P30 Tier.
|
|
88658
|
-
*/
|
|
88659
|
-
PremiumPageBlobTier["P30"] = "P30";
|
|
88660
|
-
/**
|
|
88661
|
-
* P40 Tier.
|
|
88662
|
-
*/
|
|
88663
|
-
PremiumPageBlobTier["P40"] = "P40";
|
|
88664
|
-
/**
|
|
88665
|
-
* P50 Tier.
|
|
88666
|
-
*/
|
|
88667
|
-
PremiumPageBlobTier["P50"] = "P50";
|
|
88668
|
-
/**
|
|
88669
|
-
* P60 Tier.
|
|
88670
|
-
*/
|
|
88671
|
-
PremiumPageBlobTier["P60"] = "P60";
|
|
88672
|
-
/**
|
|
88673
|
-
* P70 Tier.
|
|
88674
|
-
*/
|
|
88675
|
-
PremiumPageBlobTier["P70"] = "P70";
|
|
88676
|
-
/**
|
|
88677
|
-
* P80 Tier.
|
|
88678
|
-
*/
|
|
88679
|
-
PremiumPageBlobTier["P80"] = "P80";
|
|
88680
|
-
})(PremiumPageBlobTier || (exports.PremiumPageBlobTier = PremiumPageBlobTier = {}));
|
|
88681
|
-
function toAccessTier(tier) {
|
|
88682
|
-
if (tier === undefined) {
|
|
88683
|
-
return undefined;
|
|
88684
|
-
}
|
|
88685
|
-
return tier; // No more check if string is a valid AccessTier, and left this to underlay logic to decide(service).
|
|
88686
|
-
}
|
|
88687
|
-
function ensureCpkIfSpecified(cpk, isHttps) {
|
|
88688
|
-
if (cpk && !isHttps) {
|
|
88689
|
-
throw new RangeError("Customer-provided encryption key must be used over HTTPS.");
|
|
88690
|
-
}
|
|
88691
|
-
if (cpk && !cpk.encryptionAlgorithm) {
|
|
88692
|
-
cpk.encryptionAlgorithm = constants_js_1.EncryptionAlgorithmAES25;
|
|
88693
|
-
}
|
|
88694
|
-
}
|
|
88695
|
-
/**
|
|
88696
|
-
* Defines the known cloud audiences for Storage.
|
|
88697
|
-
*/
|
|
88698
|
-
var StorageBlobAudience;
|
|
88699
|
-
(function (StorageBlobAudience) {
|
|
88700
|
-
/**
|
|
88701
|
-
* The OAuth scope to use to retrieve an AAD token for Azure Storage.
|
|
88702
|
-
*/
|
|
88703
|
-
StorageBlobAudience["StorageOAuthScopes"] = "https://storage.azure.com/.default";
|
|
88704
|
-
/**
|
|
88705
|
-
* The OAuth scope to use to retrieve an AAD token for Azure Disk.
|
|
88706
|
-
*/
|
|
88707
|
-
StorageBlobAudience["DiskComputeOAuthScopes"] = "https://disk.compute.azure.com/.default";
|
|
88708
|
-
})(StorageBlobAudience || (exports.StorageBlobAudience = StorageBlobAudience = {}));
|
|
88709
|
-
/**
|
|
88710
|
-
*
|
|
88711
|
-
* To get OAuth audience for a storage account for blob service.
|
|
88712
|
-
*/
|
|
88713
|
-
function getBlobServiceAccountAudience(storageAccountName) {
|
|
88714
|
-
return `https://${storageAccountName}.blob.core.windows.net/.default`;
|
|
88715
|
-
}
|
|
88716
|
-
//# sourceMappingURL=models.js.map
|
|
88717
|
-
|
|
88718
|
-
/***/ }),
|
|
88719
|
-
|
|
88720
|
-
/***/ 13501:
|
|
88721
|
-
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
|
88722
|
-
|
|
88723
|
-
"use strict";
|
|
88724
|
-
|
|
88725
|
-
// Copyright (c) Microsoft Corporation.
|
|
88726
|
-
// Licensed under the MIT License.
|
|
88727
|
-
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
88728
|
-
exports.AnonymousCredentialPolicy = void 0;
|
|
88729
|
-
const CredentialPolicy_js_1 = __nccwpck_require__(63064);
|
|
88730
|
-
/**
|
|
88731
|
-
* AnonymousCredentialPolicy is used with HTTP(S) requests that read public resources
|
|
88732
|
-
* or for use with Shared Access Signatures (SAS).
|
|
88733
|
-
*/
|
|
88734
|
-
class AnonymousCredentialPolicy extends CredentialPolicy_js_1.CredentialPolicy {
|
|
88735
|
-
/**
|
|
88736
|
-
* Creates an instance of AnonymousCredentialPolicy.
|
|
88737
|
-
* @param nextPolicy -
|
|
88738
|
-
* @param options -
|
|
88739
|
-
*/
|
|
88740
|
-
// The base class has a protected constructor. Adding a public one to enable constructing of this class.
|
|
88741
|
-
/* eslint-disable-next-line @typescript-eslint/no-useless-constructor*/
|
|
88742
|
-
constructor(nextPolicy, options) {
|
|
88743
|
-
super(nextPolicy, options);
|
|
88744
|
-
}
|
|
88745
|
-
}
|
|
88746
|
-
exports.AnonymousCredentialPolicy = AnonymousCredentialPolicy;
|
|
88747
|
-
//# sourceMappingURL=AnonymousCredentialPolicy.js.map
|
|
88748
|
-
|
|
88749
|
-
/***/ }),
|
|
88750
|
-
|
|
88751
|
-
/***/ 63064:
|
|
88752
|
-
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
|
88753
|
-
|
|
88754
|
-
"use strict";
|
|
88755
|
-
|
|
88756
|
-
// Copyright (c) Microsoft Corporation.
|
|
88757
|
-
// Licensed under the MIT License.
|
|
88758
|
-
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
88759
|
-
exports.CredentialPolicy = void 0;
|
|
88760
|
-
const RequestPolicy_js_1 = __nccwpck_require__(70336);
|
|
88761
|
-
/**
|
|
88762
|
-
* Credential policy used to sign HTTP(S) requests before sending. This is an
|
|
88763
|
-
* abstract class.
|
|
88764
|
-
*/
|
|
88765
|
-
class CredentialPolicy extends RequestPolicy_js_1.BaseRequestPolicy {
|
|
88766
|
-
/**
|
|
88767
|
-
* Sends out request.
|
|
88768
|
-
*
|
|
88769
|
-
* @param request -
|
|
88770
|
-
*/
|
|
88771
|
-
sendRequest(request) {
|
|
88772
|
-
return this._nextPolicy.sendRequest(this.signRequest(request));
|
|
88773
|
-
}
|
|
88774
|
-
/**
|
|
88775
|
-
* Child classes must implement this method with request signing. This method
|
|
88776
|
-
* will be executed in {@link sendRequest}.
|
|
88777
|
-
*
|
|
88778
|
-
* @param request -
|
|
88779
|
-
*/
|
|
88780
|
-
signRequest(request) {
|
|
88781
|
-
// Child classes must override this method with request signing. This method
|
|
88782
|
-
// will be executed in sendRequest().
|
|
88783
|
-
return request;
|
|
88784
|
-
}
|
|
88785
|
-
}
|
|
88786
|
-
exports.CredentialPolicy = CredentialPolicy;
|
|
88787
|
-
//# sourceMappingURL=CredentialPolicy.js.map
|
|
88788
|
-
|
|
88789
|
-
/***/ }),
|
|
88790
|
-
|
|
88791
|
-
/***/ 70336:
|
|
88792
|
-
/***/ ((__unused_webpack_module, exports) => {
|
|
88793
|
-
|
|
88794
|
-
"use strict";
|
|
88795
|
-
|
|
88796
|
-
// Copyright (c) Microsoft Corporation.
|
|
88797
|
-
// Licensed under the MIT License.
|
|
88798
|
-
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
88799
|
-
exports.BaseRequestPolicy = void 0;
|
|
88800
|
-
/**
|
|
88801
|
-
* The base class from which all request policies derive.
|
|
88802
|
-
*/
|
|
88803
|
-
class BaseRequestPolicy {
|
|
88804
|
-
_nextPolicy;
|
|
88805
|
-
_options;
|
|
88806
|
-
/**
|
|
88807
|
-
* The main method to implement that manipulates a request/response.
|
|
88808
|
-
*/
|
|
88809
|
-
constructor(
|
|
88810
|
-
/**
|
|
88811
|
-
* The next policy in the pipeline. Each policy is responsible for executing the next one if the request is to continue through the pipeline.
|
|
88812
|
-
*/
|
|
88813
|
-
_nextPolicy,
|
|
88814
|
-
/**
|
|
88815
|
-
* The options that can be passed to a given request policy.
|
|
88816
|
-
*/
|
|
88817
|
-
_options) {
|
|
88818
|
-
this._nextPolicy = _nextPolicy;
|
|
88819
|
-
this._options = _options;
|
|
88820
|
-
}
|
|
88821
|
-
/**
|
|
88822
|
-
* Get whether or not a log with the provided log level should be logged.
|
|
88823
|
-
* @param logLevel - The log level of the log that will be logged.
|
|
88824
|
-
* @returns Whether or not a log with the provided log level should be logged.
|
|
88825
|
-
*/
|
|
88826
|
-
shouldLog(logLevel) {
|
|
88827
|
-
return this._options.shouldLog(logLevel);
|
|
88828
|
-
}
|
|
88829
|
-
/**
|
|
88830
|
-
* Attempt to log the provided message to the provided logger. If no logger was provided or if
|
|
88831
|
-
* the log level does not meat the logger's threshold, then nothing will be logged.
|
|
88832
|
-
* @param logLevel - The log level of this log.
|
|
88833
|
-
* @param message - The message of this log.
|
|
88834
|
-
*/
|
|
88835
|
-
log(logLevel, message) {
|
|
88836
|
-
this._options.log(logLevel, message);
|
|
88837
|
-
}
|
|
88838
|
-
}
|
|
88839
|
-
exports.BaseRequestPolicy = BaseRequestPolicy;
|
|
88840
|
-
//# sourceMappingURL=RequestPolicy.js.map
|
|
88841
|
-
|
|
88842
|
-
/***/ }),
|
|
88843
|
-
|
|
88844
|
-
/***/ 78654:
|
|
88845
|
-
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
|
88846
|
-
|
|
88847
|
-
"use strict";
|
|
88848
|
-
|
|
88849
|
-
// Copyright (c) Microsoft Corporation.
|
|
88850
|
-
// Licensed under the MIT License.
|
|
88851
|
-
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
88852
|
-
exports.StorageBrowserPolicy = void 0;
|
|
88853
|
-
const RequestPolicy_js_1 = __nccwpck_require__(70336);
|
|
88854
|
-
const core_util_1 = __nccwpck_require__(87779);
|
|
88855
|
-
const constants_js_1 = __nccwpck_require__(27323);
|
|
88856
|
-
const utils_common_js_1 = __nccwpck_require__(47764);
|
|
88857
|
-
/**
|
|
88858
|
-
* StorageBrowserPolicy will handle differences between Node.js and browser runtime, including:
|
|
88859
|
-
*
|
|
88860
|
-
* 1. Browsers cache GET/HEAD requests by adding conditional headers such as 'IF_MODIFIED_SINCE'.
|
|
88861
|
-
* StorageBrowserPolicy is a policy used to add a timestamp query to GET/HEAD request URL
|
|
88862
|
-
* thus avoid the browser cache.
|
|
88863
|
-
*
|
|
88864
|
-
* 2. Remove cookie header for security
|
|
88865
|
-
*
|
|
88866
|
-
* 3. Remove content-length header to avoid browsers warning
|
|
88867
|
-
*/
|
|
88868
|
-
class StorageBrowserPolicy extends RequestPolicy_js_1.BaseRequestPolicy {
|
|
88869
|
-
/**
|
|
88870
|
-
* Creates an instance of StorageBrowserPolicy.
|
|
88871
|
-
* @param nextPolicy -
|
|
88872
|
-
* @param options -
|
|
88873
|
-
*/
|
|
88874
|
-
// The base class has a protected constructor. Adding a public one to enable constructing of this class.
|
|
88875
|
-
/* eslint-disable-next-line @typescript-eslint/no-useless-constructor*/
|
|
88876
|
-
constructor(nextPolicy, options) {
|
|
88877
|
-
super(nextPolicy, options);
|
|
88878
|
-
}
|
|
88879
|
-
/**
|
|
88880
|
-
* Sends out request.
|
|
88881
|
-
*
|
|
88882
|
-
* @param request -
|
|
88883
|
-
*/
|
|
88884
|
-
async sendRequest(request) {
|
|
88885
|
-
if (core_util_1.isNodeLike) {
|
|
88886
|
-
return this._nextPolicy.sendRequest(request);
|
|
88887
|
-
}
|
|
88888
|
-
if (request.method.toUpperCase() === "GET" || request.method.toUpperCase() === "HEAD") {
|
|
88889
|
-
request.url = (0, utils_common_js_1.setURLParameter)(request.url, constants_js_1.URLConstants.Parameters.FORCE_BROWSER_NO_CACHE, new Date().getTime().toString());
|
|
88890
|
-
}
|
|
88891
|
-
request.headers.remove(constants_js_1.HeaderConstants.COOKIE);
|
|
88892
|
-
// According to XHR standards, content-length should be fully controlled by browsers
|
|
88893
|
-
request.headers.remove(constants_js_1.HeaderConstants.CONTENT_LENGTH);
|
|
88894
|
-
return this._nextPolicy.sendRequest(request);
|
|
88895
|
-
}
|
|
88896
|
-
}
|
|
88897
|
-
exports.StorageBrowserPolicy = StorageBrowserPolicy;
|
|
88898
|
-
//# sourceMappingURL=StorageBrowserPolicy.js.map
|
|
88899
|
-
|
|
88900
|
-
/***/ }),
|
|
88901
|
-
|
|
88902
|
-
/***/ 490:
|
|
88903
|
-
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
|
88904
|
-
|
|
88905
|
-
"use strict";
|
|
88906
|
-
|
|
88907
|
-
// Copyright (c) Microsoft Corporation.
|
|
88908
|
-
// Licensed under the MIT License.
|
|
88909
|
-
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
88910
|
-
exports.storageBrowserPolicyName = void 0;
|
|
88911
|
-
exports.storageBrowserPolicy = storageBrowserPolicy;
|
|
88912
|
-
const core_util_1 = __nccwpck_require__(87779);
|
|
88913
|
-
const constants_js_1 = __nccwpck_require__(27323);
|
|
88914
|
-
const utils_common_js_1 = __nccwpck_require__(47764);
|
|
88915
|
-
/**
|
|
88916
|
-
* The programmatic identifier of the StorageBrowserPolicy.
|
|
88917
|
-
*/
|
|
88918
|
-
exports.storageBrowserPolicyName = "storageBrowserPolicy";
|
|
88919
|
-
/**
|
|
88920
|
-
* storageBrowserPolicy is a policy used to prevent browsers from caching requests
|
|
88921
|
-
* and to remove cookies and explicit content-length headers.
|
|
88922
|
-
*/
|
|
88923
|
-
function storageBrowserPolicy() {
|
|
88924
|
-
return {
|
|
88925
|
-
name: exports.storageBrowserPolicyName,
|
|
88926
|
-
async sendRequest(request, next) {
|
|
88927
|
-
if (core_util_1.isNodeLike) {
|
|
88928
|
-
return next(request);
|
|
88929
|
-
}
|
|
88930
|
-
if (request.method === "GET" || request.method === "HEAD") {
|
|
88931
|
-
request.url = (0, utils_common_js_1.setURLParameter)(request.url, constants_js_1.URLConstants.Parameters.FORCE_BROWSER_NO_CACHE, new Date().getTime().toString());
|
|
88932
|
-
}
|
|
88933
|
-
request.headers.delete(constants_js_1.HeaderConstants.COOKIE);
|
|
88934
|
-
// According to XHR standards, content-length should be fully controlled by browsers
|
|
88935
|
-
request.headers.delete(constants_js_1.HeaderConstants.CONTENT_LENGTH);
|
|
88936
|
-
return next(request);
|
|
88937
|
-
},
|
|
88938
|
-
};
|
|
88939
|
-
}
|
|
88940
|
-
//# sourceMappingURL=StorageBrowserPolicyV2.js.map
|
|
88941
|
-
|
|
88942
|
-
/***/ }),
|
|
88943
|
-
|
|
88944
|
-
/***/ 99359:
|
|
88945
|
-
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
|
88946
|
-
|
|
88947
|
-
"use strict";
|
|
88948
|
-
|
|
88949
|
-
// Copyright (c) Microsoft Corporation.
|
|
88950
|
-
// Licensed under the MIT License.
|
|
88951
|
-
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
88952
|
-
exports.storageCorrectContentLengthPolicyName = void 0;
|
|
88953
|
-
exports.storageCorrectContentLengthPolicy = storageCorrectContentLengthPolicy;
|
|
88954
|
-
const constants_js_1 = __nccwpck_require__(27323);
|
|
88955
|
-
/**
|
|
88956
|
-
* The programmatic identifier of the storageCorrectContentLengthPolicy.
|
|
88957
|
-
*/
|
|
88958
|
-
exports.storageCorrectContentLengthPolicyName = "StorageCorrectContentLengthPolicy";
|
|
88959
|
-
/**
|
|
88960
|
-
* storageCorrectContentLengthPolicy to correctly set Content-Length header with request body length.
|
|
88961
|
-
*/
|
|
88962
|
-
function storageCorrectContentLengthPolicy() {
|
|
88963
|
-
function correctContentLength(request) {
|
|
88964
|
-
if (request.body &&
|
|
88965
|
-
(typeof request.body === "string" || Buffer.isBuffer(request.body)) &&
|
|
88966
|
-
request.body.length > 0) {
|
|
88967
|
-
request.headers.set(constants_js_1.HeaderConstants.CONTENT_LENGTH, Buffer.byteLength(request.body));
|
|
88968
|
-
}
|
|
88969
|
-
}
|
|
88970
|
-
return {
|
|
88971
|
-
name: exports.storageCorrectContentLengthPolicyName,
|
|
88972
|
-
async sendRequest(request, next) {
|
|
88973
|
-
correctContentLength(request);
|
|
88974
|
-
return next(request);
|
|
88975
|
-
},
|
|
88976
|
-
};
|
|
88977
|
-
}
|
|
88978
|
-
//# sourceMappingURL=StorageCorrectContentLengthPolicy.js.map
|
|
88979
|
-
|
|
88980
|
-
/***/ }),
|
|
88981
|
-
|
|
88982
|
-
/***/ 57996:
|
|
88983
|
-
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
|
88984
|
-
|
|
88985
|
-
"use strict";
|
|
88986
|
-
|
|
88987
|
-
// Copyright (c) Microsoft Corporation.
|
|
88988
|
-
// Licensed under the MIT License.
|
|
88989
|
-
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
88990
|
-
exports.StorageRetryPolicy = void 0;
|
|
88991
|
-
exports.NewRetryPolicyFactory = NewRetryPolicyFactory;
|
|
88992
|
-
const abort_controller_1 = __nccwpck_require__(24517);
|
|
88993
|
-
const RequestPolicy_js_1 = __nccwpck_require__(70336);
|
|
88994
|
-
const constants_js_1 = __nccwpck_require__(27323);
|
|
88995
|
-
const utils_common_js_1 = __nccwpck_require__(47764);
|
|
88996
|
-
const log_js_1 = __nccwpck_require__(46370);
|
|
88997
|
-
const StorageRetryPolicyType_js_1 = __nccwpck_require__(16308);
|
|
88998
|
-
/**
|
|
88999
|
-
* A factory method used to generated a RetryPolicy factory.
|
|
89000
|
-
*
|
|
89001
|
-
* @param retryOptions -
|
|
89002
|
-
*/
|
|
89003
|
-
function NewRetryPolicyFactory(retryOptions) {
|
|
89004
|
-
return {
|
|
89005
|
-
create: (nextPolicy, options) => {
|
|
89006
|
-
return new StorageRetryPolicy(nextPolicy, options, retryOptions);
|
|
89007
|
-
},
|
|
89008
|
-
};
|
|
89009
|
-
}
|
|
89010
|
-
// Default values of StorageRetryOptions
|
|
89011
|
-
const DEFAULT_RETRY_OPTIONS = {
|
|
89012
|
-
maxRetryDelayInMs: 120 * 1000,
|
|
89013
|
-
maxTries: 4,
|
|
89014
|
-
retryDelayInMs: 4 * 1000,
|
|
89015
|
-
retryPolicyType: StorageRetryPolicyType_js_1.StorageRetryPolicyType.EXPONENTIAL,
|
|
89016
|
-
secondaryHost: "",
|
|
89017
|
-
tryTimeoutInMs: undefined, // Use server side default timeout strategy
|
|
89018
|
-
};
|
|
89019
|
-
const RETRY_ABORT_ERROR = new abort_controller_1.AbortError("The operation was aborted.");
|
|
89020
|
-
/**
|
|
89021
|
-
* Retry policy with exponential retry and linear retry implemented.
|
|
89022
|
-
*/
|
|
89023
|
-
class StorageRetryPolicy extends RequestPolicy_js_1.BaseRequestPolicy {
|
|
89024
|
-
/**
|
|
89025
|
-
* RetryOptions.
|
|
89026
|
-
*/
|
|
89027
|
-
retryOptions;
|
|
89028
|
-
/**
|
|
89029
|
-
* Creates an instance of RetryPolicy.
|
|
89030
|
-
*
|
|
89031
|
-
* @param nextPolicy -
|
|
89032
|
-
* @param options -
|
|
89033
|
-
* @param retryOptions -
|
|
89034
|
-
*/
|
|
89035
|
-
constructor(nextPolicy, options, retryOptions = DEFAULT_RETRY_OPTIONS) {
|
|
89036
|
-
super(nextPolicy, options);
|
|
89037
|
-
// Initialize retry options
|
|
89038
|
-
this.retryOptions = {
|
|
89039
|
-
retryPolicyType: retryOptions.retryPolicyType
|
|
89040
|
-
? retryOptions.retryPolicyType
|
|
89041
|
-
: DEFAULT_RETRY_OPTIONS.retryPolicyType,
|
|
89042
|
-
maxTries: retryOptions.maxTries && retryOptions.maxTries >= 1
|
|
89043
|
-
? Math.floor(retryOptions.maxTries)
|
|
89044
|
-
: DEFAULT_RETRY_OPTIONS.maxTries,
|
|
89045
|
-
tryTimeoutInMs: retryOptions.tryTimeoutInMs && retryOptions.tryTimeoutInMs >= 0
|
|
89046
|
-
? retryOptions.tryTimeoutInMs
|
|
89047
|
-
: DEFAULT_RETRY_OPTIONS.tryTimeoutInMs,
|
|
89048
|
-
retryDelayInMs: retryOptions.retryDelayInMs && retryOptions.retryDelayInMs >= 0
|
|
89049
|
-
? Math.min(retryOptions.retryDelayInMs, retryOptions.maxRetryDelayInMs
|
|
89050
|
-
? retryOptions.maxRetryDelayInMs
|
|
89051
|
-
: DEFAULT_RETRY_OPTIONS.maxRetryDelayInMs)
|
|
89052
|
-
: DEFAULT_RETRY_OPTIONS.retryDelayInMs,
|
|
89053
|
-
maxRetryDelayInMs: retryOptions.maxRetryDelayInMs && retryOptions.maxRetryDelayInMs >= 0
|
|
89054
|
-
? retryOptions.maxRetryDelayInMs
|
|
89055
|
-
: DEFAULT_RETRY_OPTIONS.maxRetryDelayInMs,
|
|
89056
|
-
secondaryHost: retryOptions.secondaryHost
|
|
89057
|
-
? retryOptions.secondaryHost
|
|
89058
|
-
: DEFAULT_RETRY_OPTIONS.secondaryHost,
|
|
89059
|
-
};
|
|
89060
|
-
}
|
|
89061
|
-
/**
|
|
89062
|
-
* Sends request.
|
|
89063
|
-
*
|
|
89064
|
-
* @param request -
|
|
89065
|
-
*/
|
|
89066
|
-
async sendRequest(request) {
|
|
89067
|
-
return this.attemptSendRequest(request, false, 1);
|
|
89068
|
-
}
|
|
89069
|
-
/**
|
|
89070
|
-
* Decide and perform next retry. Won't mutate request parameter.
|
|
89071
|
-
*
|
|
89072
|
-
* @param request -
|
|
89073
|
-
* @param secondaryHas404 - If attempt was against the secondary & it returned a StatusNotFound (404), then
|
|
89074
|
-
* the resource was not found. This may be due to replication delay. So, in this
|
|
89075
|
-
* case, we'll never try the secondary again for this operation.
|
|
89076
|
-
* @param attempt - How many retries has been attempted to performed, starting from 1, which includes
|
|
89077
|
-
* the attempt will be performed by this method call.
|
|
89078
|
-
*/
|
|
89079
|
-
async attemptSendRequest(request, secondaryHas404, attempt) {
|
|
89080
|
-
const newRequest = request.clone();
|
|
89081
|
-
const isPrimaryRetry = secondaryHas404 ||
|
|
89082
|
-
!this.retryOptions.secondaryHost ||
|
|
89083
|
-
!(request.method === "GET" || request.method === "HEAD" || request.method === "OPTIONS") ||
|
|
89084
|
-
attempt % 2 === 1;
|
|
89085
|
-
if (!isPrimaryRetry) {
|
|
89086
|
-
newRequest.url = (0, utils_common_js_1.setURLHost)(newRequest.url, this.retryOptions.secondaryHost);
|
|
89087
|
-
}
|
|
89088
|
-
// Set the server-side timeout query parameter "timeout=[seconds]"
|
|
89089
|
-
if (this.retryOptions.tryTimeoutInMs) {
|
|
89090
|
-
newRequest.url = (0, utils_common_js_1.setURLParameter)(newRequest.url, constants_js_1.URLConstants.Parameters.TIMEOUT, Math.floor(this.retryOptions.tryTimeoutInMs / 1000).toString());
|
|
89091
|
-
}
|
|
89092
|
-
let response;
|
|
89093
|
-
try {
|
|
89094
|
-
log_js_1.logger.info(`RetryPolicy: =====> Try=${attempt} ${isPrimaryRetry ? "Primary" : "Secondary"}`);
|
|
89095
|
-
response = await this._nextPolicy.sendRequest(newRequest);
|
|
89096
|
-
if (!this.shouldRetry(isPrimaryRetry, attempt, response)) {
|
|
89097
|
-
return response;
|
|
89098
|
-
}
|
|
89099
|
-
secondaryHas404 = secondaryHas404 || (!isPrimaryRetry && response.status === 404);
|
|
89100
|
-
}
|
|
89101
|
-
catch (err) {
|
|
89102
|
-
log_js_1.logger.error(`RetryPolicy: Caught error, message: ${err.message}, code: ${err.code}`);
|
|
89103
|
-
if (!this.shouldRetry(isPrimaryRetry, attempt, response, err)) {
|
|
89104
|
-
throw err;
|
|
89105
|
-
}
|
|
89106
|
-
}
|
|
89107
|
-
await this.delay(isPrimaryRetry, attempt, request.abortSignal);
|
|
89108
|
-
return this.attemptSendRequest(request, secondaryHas404, ++attempt);
|
|
89109
|
-
}
|
|
89110
|
-
/**
|
|
89111
|
-
* Decide whether to retry according to last HTTP response and retry counters.
|
|
89112
|
-
*
|
|
89113
|
-
* @param isPrimaryRetry -
|
|
89114
|
-
* @param attempt -
|
|
89115
|
-
* @param response -
|
|
89116
|
-
* @param err -
|
|
89117
|
-
*/
|
|
89118
|
-
shouldRetry(isPrimaryRetry, attempt, response, err) {
|
|
89119
|
-
if (attempt >= this.retryOptions.maxTries) {
|
|
89120
|
-
log_js_1.logger.info(`RetryPolicy: Attempt(s) ${attempt} >= maxTries ${this.retryOptions
|
|
89121
|
-
.maxTries}, no further try.`);
|
|
89122
|
-
return false;
|
|
89123
|
-
}
|
|
89124
|
-
// Handle network failures, you may need to customize the list when you implement
|
|
89125
|
-
// your own http client
|
|
89126
|
-
const retriableErrors = [
|
|
89127
|
-
"ETIMEDOUT",
|
|
89128
|
-
"ESOCKETTIMEDOUT",
|
|
89129
|
-
"ECONNREFUSED",
|
|
89130
|
-
"ECONNRESET",
|
|
89131
|
-
"ENOENT",
|
|
89132
|
-
"ENOTFOUND",
|
|
89133
|
-
"TIMEOUT",
|
|
89134
|
-
"EPIPE",
|
|
89135
|
-
"REQUEST_SEND_ERROR", // For default xhr based http client provided in ms-rest-js
|
|
89136
|
-
];
|
|
89137
|
-
if (err) {
|
|
89138
|
-
for (const retriableError of retriableErrors) {
|
|
89139
|
-
if (err.name.toUpperCase().includes(retriableError) ||
|
|
89140
|
-
err.message.toUpperCase().includes(retriableError) ||
|
|
89141
|
-
(err.code && err.code.toString().toUpperCase() === retriableError)) {
|
|
89142
|
-
log_js_1.logger.info(`RetryPolicy: Network error ${retriableError} found, will retry.`);
|
|
89143
|
-
return true;
|
|
89144
|
-
}
|
|
89145
|
-
}
|
|
89146
|
-
}
|
|
89147
|
-
// If attempt was against the secondary & it returned a StatusNotFound (404), then
|
|
89148
|
-
// the resource was not found. This may be due to replication delay. So, in this
|
|
89149
|
-
// case, we'll never try the secondary again for this operation.
|
|
89150
|
-
if (response || err) {
|
|
89151
|
-
const statusCode = response ? response.status : err ? err.statusCode : 0;
|
|
89152
|
-
if (!isPrimaryRetry && statusCode === 404) {
|
|
89153
|
-
log_js_1.logger.info(`RetryPolicy: Secondary access with 404, will retry.`);
|
|
89154
|
-
return true;
|
|
89155
|
-
}
|
|
89156
|
-
// Server internal error or server timeout
|
|
89157
|
-
if (statusCode === 503 || statusCode === 500) {
|
|
89158
|
-
log_js_1.logger.info(`RetryPolicy: Will retry for status code ${statusCode}.`);
|
|
89159
|
-
return true;
|
|
89160
|
-
}
|
|
89161
|
-
}
|
|
89162
|
-
if (response) {
|
|
89163
|
-
// Retry select Copy Source Error Codes.
|
|
89164
|
-
if (response?.status >= 400) {
|
|
89165
|
-
const copySourceError = response.headers.get(constants_js_1.HeaderConstants.X_MS_CopySourceErrorCode);
|
|
89166
|
-
if (copySourceError !== undefined) {
|
|
89167
|
-
switch (copySourceError) {
|
|
89168
|
-
case "InternalError":
|
|
89169
|
-
case "OperationTimedOut":
|
|
89170
|
-
case "ServerBusy":
|
|
89171
|
-
return true;
|
|
89172
|
-
}
|
|
89173
|
-
}
|
|
89174
|
-
}
|
|
89175
|
-
}
|
|
89176
|
-
if (err?.code === "PARSE_ERROR" && err?.message.startsWith(`Error "Error: Unclosed root tag`)) {
|
|
89177
|
-
log_js_1.logger.info("RetryPolicy: Incomplete XML response likely due to service timeout, will retry.");
|
|
89178
|
-
return true;
|
|
89179
|
-
}
|
|
89180
|
-
return false;
|
|
89181
|
-
}
|
|
89182
|
-
/**
|
|
89183
|
-
* Delay a calculated time between retries.
|
|
89184
|
-
*
|
|
89185
|
-
* @param isPrimaryRetry -
|
|
89186
|
-
* @param attempt -
|
|
89187
|
-
* @param abortSignal -
|
|
89188
|
-
*/
|
|
89189
|
-
async delay(isPrimaryRetry, attempt, abortSignal) {
|
|
89190
|
-
let delayTimeInMs = 0;
|
|
89191
|
-
if (isPrimaryRetry) {
|
|
89192
|
-
switch (this.retryOptions.retryPolicyType) {
|
|
89193
|
-
case StorageRetryPolicyType_js_1.StorageRetryPolicyType.EXPONENTIAL:
|
|
89194
|
-
delayTimeInMs = Math.min((Math.pow(2, attempt - 1) - 1) * this.retryOptions.retryDelayInMs, this.retryOptions.maxRetryDelayInMs);
|
|
89195
|
-
break;
|
|
89196
|
-
case StorageRetryPolicyType_js_1.StorageRetryPolicyType.FIXED:
|
|
89197
|
-
delayTimeInMs = this.retryOptions.retryDelayInMs;
|
|
89198
|
-
break;
|
|
89199
|
-
}
|
|
89200
|
-
}
|
|
89201
|
-
else {
|
|
89202
|
-
delayTimeInMs = Math.random() * 1000;
|
|
89203
|
-
}
|
|
89204
|
-
log_js_1.logger.info(`RetryPolicy: Delay for ${delayTimeInMs}ms`);
|
|
89205
|
-
return (0, utils_common_js_1.delay)(delayTimeInMs, abortSignal, RETRY_ABORT_ERROR);
|
|
89206
|
-
}
|
|
89207
|
-
}
|
|
89208
|
-
exports.StorageRetryPolicy = StorageRetryPolicy;
|
|
89209
|
-
//# sourceMappingURL=StorageRetryPolicy.js.map
|
|
89210
|
-
|
|
89211
|
-
/***/ }),
|
|
89212
|
-
|
|
89213
|
-
/***/ 16308:
|
|
89214
|
-
/***/ ((__unused_webpack_module, exports) => {
|
|
89215
|
-
|
|
89216
|
-
"use strict";
|
|
89217
|
-
|
|
89218
|
-
// Copyright (c) Microsoft Corporation.
|
|
89219
|
-
// Licensed under the MIT License.
|
|
89220
|
-
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
89221
|
-
exports.StorageRetryPolicyType = void 0;
|
|
89222
|
-
/**
|
|
89223
|
-
* RetryPolicy types.
|
|
89224
|
-
*/
|
|
89225
|
-
var StorageRetryPolicyType;
|
|
89226
|
-
(function (StorageRetryPolicyType) {
|
|
89227
|
-
/**
|
|
89228
|
-
* Exponential retry. Retry time delay grows exponentially.
|
|
89229
|
-
*/
|
|
89230
|
-
StorageRetryPolicyType[StorageRetryPolicyType["EXPONENTIAL"] = 0] = "EXPONENTIAL";
|
|
89231
|
-
/**
|
|
89232
|
-
* Linear retry. Retry time delay grows linearly.
|
|
89233
|
-
*/
|
|
89234
|
-
StorageRetryPolicyType[StorageRetryPolicyType["FIXED"] = 1] = "FIXED";
|
|
89235
|
-
})(StorageRetryPolicyType || (exports.StorageRetryPolicyType = StorageRetryPolicyType = {}));
|
|
89236
|
-
//# sourceMappingURL=StorageRetryPolicyType.js.map
|
|
89237
|
-
|
|
89238
|
-
/***/ }),
|
|
89239
|
-
|
|
89240
|
-
/***/ 31160:
|
|
89241
|
-
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
|
89242
|
-
|
|
89243
|
-
"use strict";
|
|
89244
|
-
|
|
89245
|
-
// Copyright (c) Microsoft Corporation.
|
|
89246
|
-
// Licensed under the MIT License.
|
|
89247
|
-
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
89248
|
-
exports.storageRetryPolicyName = void 0;
|
|
89249
|
-
exports.storageRetryPolicy = storageRetryPolicy;
|
|
89250
|
-
const abort_controller_1 = __nccwpck_require__(24517);
|
|
89251
|
-
const core_rest_pipeline_1 = __nccwpck_require__(20778);
|
|
89252
|
-
const core_util_1 = __nccwpck_require__(87779);
|
|
89253
|
-
const StorageRetryPolicyFactory_js_1 = __nccwpck_require__(98335);
|
|
89254
|
-
const constants_js_1 = __nccwpck_require__(27323);
|
|
89255
|
-
const utils_common_js_1 = __nccwpck_require__(47764);
|
|
89256
|
-
const log_js_1 = __nccwpck_require__(46370);
|
|
89257
|
-
/**
|
|
89258
|
-
* Name of the {@link storageRetryPolicy}
|
|
89259
|
-
*/
|
|
89260
|
-
exports.storageRetryPolicyName = "storageRetryPolicy";
|
|
89261
|
-
// Default values of StorageRetryOptions
|
|
89262
|
-
const DEFAULT_RETRY_OPTIONS = {
|
|
89263
|
-
maxRetryDelayInMs: 120 * 1000,
|
|
89264
|
-
maxTries: 4,
|
|
89265
|
-
retryDelayInMs: 4 * 1000,
|
|
89266
|
-
retryPolicyType: StorageRetryPolicyFactory_js_1.StorageRetryPolicyType.EXPONENTIAL,
|
|
89267
|
-
secondaryHost: "",
|
|
89268
|
-
tryTimeoutInMs: undefined, // Use server side default timeout strategy
|
|
89269
|
-
};
|
|
89270
|
-
const retriableErrors = [
|
|
89271
|
-
"ETIMEDOUT",
|
|
89272
|
-
"ESOCKETTIMEDOUT",
|
|
89273
|
-
"ECONNREFUSED",
|
|
89274
|
-
"ECONNRESET",
|
|
89275
|
-
"ENOENT",
|
|
89276
|
-
"ENOTFOUND",
|
|
89277
|
-
"TIMEOUT",
|
|
89278
|
-
"EPIPE",
|
|
89279
|
-
"REQUEST_SEND_ERROR",
|
|
89280
|
-
];
|
|
89281
|
-
const RETRY_ABORT_ERROR = new abort_controller_1.AbortError("The operation was aborted.");
|
|
89282
|
-
/**
|
|
89283
|
-
* Retry policy with exponential retry and linear retry implemented.
|
|
89284
|
-
*/
|
|
89285
|
-
function storageRetryPolicy(options = {}) {
|
|
89286
|
-
const retryPolicyType = options.retryPolicyType ?? DEFAULT_RETRY_OPTIONS.retryPolicyType;
|
|
89287
|
-
const maxTries = options.maxTries ?? DEFAULT_RETRY_OPTIONS.maxTries;
|
|
89288
|
-
const retryDelayInMs = options.retryDelayInMs ?? DEFAULT_RETRY_OPTIONS.retryDelayInMs;
|
|
89289
|
-
const maxRetryDelayInMs = options.maxRetryDelayInMs ?? DEFAULT_RETRY_OPTIONS.maxRetryDelayInMs;
|
|
89290
|
-
const secondaryHost = options.secondaryHost ?? DEFAULT_RETRY_OPTIONS.secondaryHost;
|
|
89291
|
-
const tryTimeoutInMs = options.tryTimeoutInMs ?? DEFAULT_RETRY_OPTIONS.tryTimeoutInMs;
|
|
89292
|
-
function shouldRetry({ isPrimaryRetry, attempt, response, error, }) {
|
|
89293
|
-
if (attempt >= maxTries) {
|
|
89294
|
-
log_js_1.logger.info(`RetryPolicy: Attempt(s) ${attempt} >= maxTries ${maxTries}, no further try.`);
|
|
89295
|
-
return false;
|
|
89296
|
-
}
|
|
89297
|
-
if (error) {
|
|
89298
|
-
for (const retriableError of retriableErrors) {
|
|
89299
|
-
if (error.name.toUpperCase().includes(retriableError) ||
|
|
89300
|
-
error.message.toUpperCase().includes(retriableError) ||
|
|
89301
|
-
(error.code && error.code.toString().toUpperCase() === retriableError)) {
|
|
89302
|
-
log_js_1.logger.info(`RetryPolicy: Network error ${retriableError} found, will retry.`);
|
|
89303
|
-
return true;
|
|
89304
|
-
}
|
|
89305
|
-
}
|
|
89306
|
-
if (error?.code === "PARSE_ERROR" &&
|
|
89307
|
-
error?.message.startsWith(`Error "Error: Unclosed root tag`)) {
|
|
89308
|
-
log_js_1.logger.info("RetryPolicy: Incomplete XML response likely due to service timeout, will retry.");
|
|
89309
|
-
return true;
|
|
89310
|
-
}
|
|
89311
|
-
}
|
|
89312
|
-
// If attempt was against the secondary & it returned a StatusNotFound (404), then
|
|
89313
|
-
// the resource was not found. This may be due to replication delay. So, in this
|
|
89314
|
-
// case, we'll never try the secondary again for this operation.
|
|
89315
|
-
if (response || error) {
|
|
89316
|
-
const statusCode = response?.status ?? error?.statusCode ?? 0;
|
|
89317
|
-
if (!isPrimaryRetry && statusCode === 404) {
|
|
89318
|
-
log_js_1.logger.info(`RetryPolicy: Secondary access with 404, will retry.`);
|
|
89319
|
-
return true;
|
|
89320
|
-
}
|
|
89321
|
-
// Server internal error or server timeout
|
|
89322
|
-
if (statusCode === 503 || statusCode === 500) {
|
|
89323
|
-
log_js_1.logger.info(`RetryPolicy: Will retry for status code ${statusCode}.`);
|
|
89324
|
-
return true;
|
|
89325
|
-
}
|
|
89326
|
-
}
|
|
89327
|
-
if (response) {
|
|
89328
|
-
// Retry select Copy Source Error Codes.
|
|
89329
|
-
if (response?.status >= 400) {
|
|
89330
|
-
const copySourceError = response.headers.get(constants_js_1.HeaderConstants.X_MS_CopySourceErrorCode);
|
|
89331
|
-
if (copySourceError !== undefined) {
|
|
89332
|
-
switch (copySourceError) {
|
|
89333
|
-
case "InternalError":
|
|
89334
|
-
case "OperationTimedOut":
|
|
89335
|
-
case "ServerBusy":
|
|
89336
|
-
return true;
|
|
89337
|
-
}
|
|
89338
|
-
}
|
|
89339
|
-
}
|
|
89340
|
-
}
|
|
89341
|
-
return false;
|
|
89342
|
-
}
|
|
89343
|
-
function calculateDelay(isPrimaryRetry, attempt) {
|
|
89344
|
-
let delayTimeInMs = 0;
|
|
89345
|
-
if (isPrimaryRetry) {
|
|
89346
|
-
switch (retryPolicyType) {
|
|
89347
|
-
case StorageRetryPolicyFactory_js_1.StorageRetryPolicyType.EXPONENTIAL:
|
|
89348
|
-
delayTimeInMs = Math.min((Math.pow(2, attempt - 1) - 1) * retryDelayInMs, maxRetryDelayInMs);
|
|
89349
|
-
break;
|
|
89350
|
-
case StorageRetryPolicyFactory_js_1.StorageRetryPolicyType.FIXED:
|
|
89351
|
-
delayTimeInMs = retryDelayInMs;
|
|
89352
|
-
break;
|
|
89353
|
-
}
|
|
89354
|
-
}
|
|
89355
|
-
else {
|
|
89356
|
-
delayTimeInMs = Math.random() * 1000;
|
|
89357
|
-
}
|
|
89358
|
-
log_js_1.logger.info(`RetryPolicy: Delay for ${delayTimeInMs}ms`);
|
|
89359
|
-
return delayTimeInMs;
|
|
89360
|
-
}
|
|
89361
|
-
return {
|
|
89362
|
-
name: exports.storageRetryPolicyName,
|
|
89363
|
-
async sendRequest(request, next) {
|
|
89364
|
-
// Set the server-side timeout query parameter "timeout=[seconds]"
|
|
89365
|
-
if (tryTimeoutInMs) {
|
|
89366
|
-
request.url = (0, utils_common_js_1.setURLParameter)(request.url, constants_js_1.URLConstants.Parameters.TIMEOUT, String(Math.floor(tryTimeoutInMs / 1000)));
|
|
89367
|
-
}
|
|
89368
|
-
const primaryUrl = request.url;
|
|
89369
|
-
const secondaryUrl = secondaryHost ? (0, utils_common_js_1.setURLHost)(request.url, secondaryHost) : undefined;
|
|
89370
|
-
let secondaryHas404 = false;
|
|
89371
|
-
let attempt = 1;
|
|
89372
|
-
let retryAgain = true;
|
|
89373
|
-
let response;
|
|
89374
|
-
let error;
|
|
89375
|
-
while (retryAgain) {
|
|
89376
|
-
const isPrimaryRetry = secondaryHas404 ||
|
|
89377
|
-
!secondaryUrl ||
|
|
89378
|
-
!["GET", "HEAD", "OPTIONS"].includes(request.method) ||
|
|
89379
|
-
attempt % 2 === 1;
|
|
89380
|
-
request.url = isPrimaryRetry ? primaryUrl : secondaryUrl;
|
|
89381
|
-
response = undefined;
|
|
89382
|
-
error = undefined;
|
|
89383
|
-
try {
|
|
89384
|
-
log_js_1.logger.info(`RetryPolicy: =====> Try=${attempt} ${isPrimaryRetry ? "Primary" : "Secondary"}`);
|
|
89385
|
-
response = await next(request);
|
|
89386
|
-
secondaryHas404 = secondaryHas404 || (!isPrimaryRetry && response.status === 404);
|
|
89387
|
-
}
|
|
89388
|
-
catch (e) {
|
|
89389
|
-
if ((0, core_rest_pipeline_1.isRestError)(e)) {
|
|
89390
|
-
log_js_1.logger.error(`RetryPolicy: Caught error, message: ${e.message}, code: ${e.code}`);
|
|
89391
|
-
error = e;
|
|
89392
|
-
}
|
|
89393
|
-
else {
|
|
89394
|
-
log_js_1.logger.error(`RetryPolicy: Caught error, message: ${(0, core_util_1.getErrorMessage)(e)}`);
|
|
89395
|
-
throw e;
|
|
89396
|
-
}
|
|
89397
|
-
}
|
|
89398
|
-
retryAgain = shouldRetry({ isPrimaryRetry, attempt, response, error });
|
|
89399
|
-
if (retryAgain) {
|
|
89400
|
-
await (0, utils_common_js_1.delay)(calculateDelay(isPrimaryRetry, attempt), request.abortSignal, RETRY_ABORT_ERROR);
|
|
89401
|
-
}
|
|
89402
|
-
attempt++;
|
|
89403
|
-
}
|
|
89404
|
-
if (response) {
|
|
89405
|
-
return response;
|
|
89406
|
-
}
|
|
89407
|
-
throw error ?? new core_rest_pipeline_1.RestError("RetryPolicy failed without known error.");
|
|
89408
|
-
},
|
|
89409
|
-
};
|
|
89410
|
-
}
|
|
89411
|
-
//# sourceMappingURL=StorageRetryPolicyV2.js.map
|
|
89412
|
-
|
|
89413
|
-
/***/ }),
|
|
89414
|
-
|
|
89415
|
-
/***/ 45511:
|
|
89416
|
-
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
|
89417
|
-
|
|
89418
|
-
"use strict";
|
|
89419
|
-
|
|
89420
|
-
// Copyright (c) Microsoft Corporation.
|
|
89421
|
-
// Licensed under the MIT License.
|
|
89422
|
-
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
89423
|
-
exports.StorageSharedKeyCredentialPolicy = void 0;
|
|
89424
|
-
const constants_js_1 = __nccwpck_require__(27323);
|
|
89425
|
-
const utils_common_js_1 = __nccwpck_require__(47764);
|
|
89426
|
-
const CredentialPolicy_js_1 = __nccwpck_require__(63064);
|
|
89427
|
-
const SharedKeyComparator_js_1 = __nccwpck_require__(21902);
|
|
89428
|
-
/**
|
|
89429
|
-
* StorageSharedKeyCredentialPolicy is a policy used to sign HTTP request with a shared key.
|
|
89430
|
-
*/
|
|
89431
|
-
class StorageSharedKeyCredentialPolicy extends CredentialPolicy_js_1.CredentialPolicy {
|
|
89432
|
-
/**
|
|
89433
|
-
* Reference to StorageSharedKeyCredential which generates StorageSharedKeyCredentialPolicy
|
|
89434
|
-
*/
|
|
89435
|
-
factory;
|
|
89436
|
-
/**
|
|
89437
|
-
* Creates an instance of StorageSharedKeyCredentialPolicy.
|
|
89438
|
-
* @param nextPolicy -
|
|
89439
|
-
* @param options -
|
|
89440
|
-
* @param factory -
|
|
89441
|
-
*/
|
|
89442
|
-
constructor(nextPolicy, options, factory) {
|
|
89443
|
-
super(nextPolicy, options);
|
|
89444
|
-
this.factory = factory;
|
|
89445
|
-
}
|
|
89446
|
-
/**
|
|
89447
|
-
* Signs request.
|
|
89448
|
-
*
|
|
89449
|
-
* @param request -
|
|
89450
|
-
*/
|
|
89451
|
-
signRequest(request) {
|
|
89452
|
-
request.headers.set(constants_js_1.HeaderConstants.X_MS_DATE, new Date().toUTCString());
|
|
89453
|
-
if (request.body &&
|
|
89454
|
-
(typeof request.body === "string" || request.body !== undefined) &&
|
|
89455
|
-
request.body.length > 0) {
|
|
89456
|
-
request.headers.set(constants_js_1.HeaderConstants.CONTENT_LENGTH, Buffer.byteLength(request.body));
|
|
89457
|
-
}
|
|
89458
|
-
const stringToSign = [
|
|
89459
|
-
request.method.toUpperCase(),
|
|
89460
|
-
this.getHeaderValueToSign(request, constants_js_1.HeaderConstants.CONTENT_LANGUAGE),
|
|
89461
|
-
this.getHeaderValueToSign(request, constants_js_1.HeaderConstants.CONTENT_ENCODING),
|
|
89462
|
-
this.getHeaderValueToSign(request, constants_js_1.HeaderConstants.CONTENT_LENGTH),
|
|
89463
|
-
this.getHeaderValueToSign(request, constants_js_1.HeaderConstants.CONTENT_MD5),
|
|
89464
|
-
this.getHeaderValueToSign(request, constants_js_1.HeaderConstants.CONTENT_TYPE),
|
|
89465
|
-
this.getHeaderValueToSign(request, constants_js_1.HeaderConstants.DATE),
|
|
89466
|
-
this.getHeaderValueToSign(request, constants_js_1.HeaderConstants.IF_MODIFIED_SINCE),
|
|
89467
|
-
this.getHeaderValueToSign(request, constants_js_1.HeaderConstants.IF_MATCH),
|
|
89468
|
-
this.getHeaderValueToSign(request, constants_js_1.HeaderConstants.IF_NONE_MATCH),
|
|
89469
|
-
this.getHeaderValueToSign(request, constants_js_1.HeaderConstants.IF_UNMODIFIED_SINCE),
|
|
89470
|
-
this.getHeaderValueToSign(request, constants_js_1.HeaderConstants.RANGE),
|
|
89471
|
-
].join("\n") +
|
|
89472
|
-
"\n" +
|
|
89473
|
-
this.getCanonicalizedHeadersString(request) +
|
|
89474
|
-
this.getCanonicalizedResourceString(request);
|
|
89475
|
-
const signature = this.factory.computeHMACSHA256(stringToSign);
|
|
89476
|
-
request.headers.set(constants_js_1.HeaderConstants.AUTHORIZATION, `SharedKey ${this.factory.accountName}:${signature}`);
|
|
89477
|
-
// console.log(`[URL]:${request.url}`);
|
|
89478
|
-
// console.log(`[HEADERS]:${request.headers.toString()}`);
|
|
89479
|
-
// console.log(`[STRING TO SIGN]:${JSON.stringify(stringToSign)}`);
|
|
89480
|
-
// console.log(`[KEY]: ${request.headers.get(HeaderConstants.AUTHORIZATION)}`);
|
|
89481
|
-
return request;
|
|
89482
|
-
}
|
|
89483
|
-
/**
|
|
89484
|
-
* Retrieve header value according to shared key sign rules.
|
|
89485
|
-
* @see https://learn.microsoft.com/rest/api/storageservices/authenticate-with-shared-key
|
|
89486
|
-
*
|
|
89487
|
-
* @param request -
|
|
89488
|
-
* @param headerName -
|
|
89489
|
-
*/
|
|
89490
|
-
getHeaderValueToSign(request, headerName) {
|
|
89491
|
-
const value = request.headers.get(headerName);
|
|
89492
|
-
if (!value) {
|
|
89493
|
-
return "";
|
|
89494
|
-
}
|
|
89495
|
-
// When using version 2015-02-21 or later, if Content-Length is zero, then
|
|
89496
|
-
// set the Content-Length part of the StringToSign to an empty string.
|
|
89497
|
-
// https://learn.microsoft.com/rest/api/storageservices/authenticate-with-shared-key
|
|
89498
|
-
if (headerName === constants_js_1.HeaderConstants.CONTENT_LENGTH && value === "0") {
|
|
89499
|
-
return "";
|
|
89500
|
-
}
|
|
89501
|
-
return value;
|
|
89502
|
-
}
|
|
89503
|
-
/**
|
|
89504
|
-
* To construct the CanonicalizedHeaders portion of the signature string, follow these steps:
|
|
89505
|
-
* 1. Retrieve all headers for the resource that begin with x-ms-, including the x-ms-date header.
|
|
89506
|
-
* 2. Convert each HTTP header name to lowercase.
|
|
89507
|
-
* 3. Sort the headers lexicographically by header name, in ascending order.
|
|
89508
|
-
* Each header may appear only once in the string.
|
|
89509
|
-
* 4. Replace any linear whitespace in the header value with a single space.
|
|
89510
|
-
* 5. Trim any whitespace around the colon in the header.
|
|
89511
|
-
* 6. Finally, append a new-line character to each canonicalized header in the resulting list.
|
|
89512
|
-
* Construct the CanonicalizedHeaders string by concatenating all headers in this list into a single string.
|
|
89513
|
-
*
|
|
89514
|
-
* @param request -
|
|
89515
|
-
*/
|
|
89516
|
-
getCanonicalizedHeadersString(request) {
|
|
89517
|
-
let headersArray = request.headers.headersArray().filter((value) => {
|
|
89518
|
-
return value.name.toLowerCase().startsWith(constants_js_1.HeaderConstants.PREFIX_FOR_STORAGE);
|
|
89519
|
-
});
|
|
89520
|
-
headersArray.sort((a, b) => {
|
|
89521
|
-
return (0, SharedKeyComparator_js_1.compareHeader)(a.name.toLowerCase(), b.name.toLowerCase());
|
|
89522
|
-
});
|
|
89523
|
-
// Remove duplicate headers
|
|
89524
|
-
headersArray = headersArray.filter((value, index, array) => {
|
|
89525
|
-
if (index > 0 && value.name.toLowerCase() === array[index - 1].name.toLowerCase()) {
|
|
89526
|
-
return false;
|
|
89527
|
-
}
|
|
89528
|
-
return true;
|
|
89529
|
-
});
|
|
89530
|
-
let canonicalizedHeadersStringToSign = "";
|
|
89531
|
-
headersArray.forEach((header) => {
|
|
89532
|
-
canonicalizedHeadersStringToSign += `${header.name
|
|
89533
|
-
.toLowerCase()
|
|
89534
|
-
.trimRight()}:${header.value.trimLeft()}\n`;
|
|
89535
|
-
});
|
|
89536
|
-
return canonicalizedHeadersStringToSign;
|
|
89537
|
-
}
|
|
89538
|
-
/**
|
|
89539
|
-
* Retrieves the webResource canonicalized resource string.
|
|
89540
|
-
*
|
|
89541
|
-
* @param request -
|
|
89542
|
-
*/
|
|
89543
|
-
getCanonicalizedResourceString(request) {
|
|
89544
|
-
const path = (0, utils_common_js_1.getURLPath)(request.url) || "/";
|
|
89545
|
-
let canonicalizedResourceString = "";
|
|
89546
|
-
canonicalizedResourceString += `/${this.factory.accountName}${path}`;
|
|
89547
|
-
const queries = (0, utils_common_js_1.getURLQueries)(request.url);
|
|
89548
|
-
const lowercaseQueries = {};
|
|
89549
|
-
if (queries) {
|
|
89550
|
-
const queryKeys = [];
|
|
89551
|
-
for (const key in queries) {
|
|
89552
|
-
if (Object.prototype.hasOwnProperty.call(queries, key)) {
|
|
89553
|
-
const lowercaseKey = key.toLowerCase();
|
|
89554
|
-
lowercaseQueries[lowercaseKey] = queries[key];
|
|
89555
|
-
queryKeys.push(lowercaseKey);
|
|
88294
|
+
hasNext() {
|
|
88295
|
+
return !this._initialized || this._itemsRemainingInBlock > 0;
|
|
88296
|
+
}
|
|
88297
|
+
async *parseObjects(options = {}) {
|
|
88298
|
+
if (!this._initialized) {
|
|
88299
|
+
await this.initialize(options);
|
|
88300
|
+
}
|
|
88301
|
+
while (this.hasNext()) {
|
|
88302
|
+
const result = await this._itemType.read(this._dataStream, {
|
|
88303
|
+
abortSignal: options.abortSignal,
|
|
88304
|
+
});
|
|
88305
|
+
this._itemsRemainingInBlock--;
|
|
88306
|
+
this._objectIndex++;
|
|
88307
|
+
if (this._itemsRemainingInBlock === 0) {
|
|
88308
|
+
const marker = await AvroParser_js_1.AvroParser.readFixedBytes(this._dataStream, AvroConstants_js_1.AVRO_SYNC_MARKER_SIZE, {
|
|
88309
|
+
abortSignal: options.abortSignal,
|
|
88310
|
+
});
|
|
88311
|
+
this._blockOffset = this._initialBlockOffset + this._dataStream.position;
|
|
88312
|
+
this._objectIndex = 0;
|
|
88313
|
+
if (!(0, utils_common_js_1.arraysEqual)(this._syncMarker, marker)) {
|
|
88314
|
+
throw new Error("Stream is not a valid Avro file.");
|
|
88315
|
+
}
|
|
88316
|
+
try {
|
|
88317
|
+
this._itemsRemainingInBlock = await AvroParser_js_1.AvroParser.readLong(this._dataStream, {
|
|
88318
|
+
abortSignal: options.abortSignal,
|
|
88319
|
+
});
|
|
88320
|
+
}
|
|
88321
|
+
catch {
|
|
88322
|
+
// We hit the end of the stream.
|
|
88323
|
+
this._itemsRemainingInBlock = 0;
|
|
88324
|
+
}
|
|
88325
|
+
if (this._itemsRemainingInBlock > 0) {
|
|
88326
|
+
// Ignore block size
|
|
88327
|
+
await AvroParser_js_1.AvroParser.readLong(this._dataStream, { abortSignal: options.abortSignal });
|
|
89556
88328
|
}
|
|
89557
88329
|
}
|
|
89558
|
-
|
|
89559
|
-
for (const key of queryKeys) {
|
|
89560
|
-
canonicalizedResourceString += `\n${key}:${decodeURIComponent(lowercaseQueries[key])}`;
|
|
89561
|
-
}
|
|
88330
|
+
yield result;
|
|
89562
88331
|
}
|
|
89563
|
-
return canonicalizedResourceString;
|
|
89564
88332
|
}
|
|
89565
88333
|
}
|
|
89566
|
-
exports.
|
|
89567
|
-
//# sourceMappingURL=
|
|
88334
|
+
exports.AvroReader = AvroReader;
|
|
88335
|
+
//# sourceMappingURL=AvroReader.js.map
|
|
89568
88336
|
|
|
89569
88337
|
/***/ }),
|
|
89570
88338
|
|
|
89571
|
-
/***/
|
|
88339
|
+
/***/ 96147:
|
|
89572
88340
|
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
|
89573
88341
|
|
|
89574
88342
|
"use strict";
|
|
@@ -89576,138 +88344,186 @@ exports.StorageSharedKeyCredentialPolicy = StorageSharedKeyCredentialPolicy;
|
|
|
89576
88344
|
// Copyright (c) Microsoft Corporation.
|
|
89577
88345
|
// Licensed under the MIT License.
|
|
89578
88346
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
89579
|
-
exports.
|
|
89580
|
-
|
|
89581
|
-
|
|
88347
|
+
exports.AvroReadableFromStream = exports.AvroReadable = exports.AvroReader = void 0;
|
|
88348
|
+
var AvroReader_js_1 = __nccwpck_require__(52888);
|
|
88349
|
+
Object.defineProperty(exports, "AvroReader", ({ enumerable: true, get: function () { return AvroReader_js_1.AvroReader; } }));
|
|
88350
|
+
var AvroReadable_js_1 = __nccwpck_require__(41675);
|
|
88351
|
+
Object.defineProperty(exports, "AvroReadable", ({ enumerable: true, get: function () { return AvroReadable_js_1.AvroReadable; } }));
|
|
88352
|
+
var AvroReadableFromStream_js_1 = __nccwpck_require__(48059);
|
|
88353
|
+
Object.defineProperty(exports, "AvroReadableFromStream", ({ enumerable: true, get: function () { return AvroReadableFromStream_js_1.AvroReadableFromStream; } }));
|
|
88354
|
+
//# sourceMappingURL=index.js.map
|
|
88355
|
+
|
|
88356
|
+
/***/ }),
|
|
88357
|
+
|
|
88358
|
+
/***/ 4337:
|
|
88359
|
+
/***/ ((__unused_webpack_module, exports) => {
|
|
88360
|
+
|
|
88361
|
+
"use strict";
|
|
88362
|
+
|
|
88363
|
+
// Copyright (c) Microsoft Corporation.
|
|
88364
|
+
// Licensed under the MIT License.
|
|
88365
|
+
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
88366
|
+
exports.arraysEqual = arraysEqual;
|
|
88367
|
+
function arraysEqual(a, b) {
|
|
88368
|
+
if (a === b)
|
|
88369
|
+
return true;
|
|
88370
|
+
if (a == null || b == null)
|
|
88371
|
+
return false;
|
|
88372
|
+
if (a.length !== b.length)
|
|
88373
|
+
return false;
|
|
88374
|
+
for (let i = 0; i < a.length; ++i) {
|
|
88375
|
+
if (a[i] !== b[i])
|
|
88376
|
+
return false;
|
|
88377
|
+
}
|
|
88378
|
+
return true;
|
|
88379
|
+
}
|
|
88380
|
+
//# sourceMappingURL=utils.common.js.map
|
|
88381
|
+
|
|
88382
|
+
/***/ }),
|
|
88383
|
+
|
|
88384
|
+
/***/ 46370:
|
|
88385
|
+
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
|
88386
|
+
|
|
88387
|
+
"use strict";
|
|
88388
|
+
|
|
88389
|
+
// Copyright (c) Microsoft Corporation.
|
|
88390
|
+
// Licensed under the MIT License.
|
|
88391
|
+
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
88392
|
+
exports.logger = void 0;
|
|
88393
|
+
const logger_1 = __nccwpck_require__(26515);
|
|
88394
|
+
/**
|
|
88395
|
+
* The `@azure/logger` configuration for this package.
|
|
88396
|
+
*/
|
|
88397
|
+
exports.logger = (0, logger_1.createClientLogger)("storage-blob");
|
|
88398
|
+
//# sourceMappingURL=log.js.map
|
|
88399
|
+
|
|
88400
|
+
/***/ }),
|
|
88401
|
+
|
|
88402
|
+
/***/ 58560:
|
|
88403
|
+
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
|
88404
|
+
|
|
88405
|
+
"use strict";
|
|
88406
|
+
|
|
88407
|
+
// Copyright (c) Microsoft Corporation.
|
|
88408
|
+
// Licensed under the MIT License.
|
|
88409
|
+
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
88410
|
+
exports.StorageBlobAudience = exports.PremiumPageBlobTier = exports.BlockBlobTier = void 0;
|
|
88411
|
+
exports.toAccessTier = toAccessTier;
|
|
88412
|
+
exports.ensureCpkIfSpecified = ensureCpkIfSpecified;
|
|
88413
|
+
exports.getBlobServiceAccountAudience = getBlobServiceAccountAudience;
|
|
89582
88414
|
const constants_js_1 = __nccwpck_require__(27323);
|
|
89583
|
-
const utils_common_js_1 = __nccwpck_require__(47764);
|
|
89584
|
-
const SharedKeyComparator_js_1 = __nccwpck_require__(21902);
|
|
89585
88415
|
/**
|
|
89586
|
-
*
|
|
88416
|
+
* Represents the access tier on a blob.
|
|
88417
|
+
* For detailed information about block blob level tiering see {@link https://learn.microsoft.com/azure/storage/blobs/storage-blob-storage-tiers|Hot, cool and archive storage tiers.}
|
|
89587
88418
|
*/
|
|
89588
|
-
|
|
88419
|
+
var BlockBlobTier;
|
|
88420
|
+
(function (BlockBlobTier) {
|
|
88421
|
+
/**
|
|
88422
|
+
* Optimized for storing data that is accessed frequently.
|
|
88423
|
+
*/
|
|
88424
|
+
BlockBlobTier["Hot"] = "Hot";
|
|
88425
|
+
/**
|
|
88426
|
+
* Optimized for storing data that is infrequently accessed and stored for at least 30 days.
|
|
88427
|
+
*/
|
|
88428
|
+
BlockBlobTier["Cool"] = "Cool";
|
|
88429
|
+
/**
|
|
88430
|
+
* Optimized for storing data that is rarely accessed.
|
|
88431
|
+
*/
|
|
88432
|
+
BlockBlobTier["Cold"] = "Cold";
|
|
88433
|
+
/**
|
|
88434
|
+
* Optimized for storing data that is rarely accessed and stored for at least 180 days
|
|
88435
|
+
* with flexible latency requirements (on the order of hours).
|
|
88436
|
+
*/
|
|
88437
|
+
BlockBlobTier["Archive"] = "Archive";
|
|
88438
|
+
})(BlockBlobTier || (exports.BlockBlobTier = BlockBlobTier = {}));
|
|
89589
88439
|
/**
|
|
89590
|
-
*
|
|
88440
|
+
* Specifies the page blob tier to set the blob to. This is only applicable to page blobs on premium storage accounts.
|
|
88441
|
+
* Please see {@link https://learn.microsoft.com/azure/storage/storage-premium-storage#scalability-and-performance-targets|here}
|
|
88442
|
+
* for detailed information on the corresponding IOPS and throughput per PageBlobTier.
|
|
89591
88443
|
*/
|
|
89592
|
-
|
|
89593
|
-
|
|
89594
|
-
request.headers.set(constants_js_1.HeaderConstants.X_MS_DATE, new Date().toUTCString());
|
|
89595
|
-
if (request.body &&
|
|
89596
|
-
(typeof request.body === "string" || Buffer.isBuffer(request.body)) &&
|
|
89597
|
-
request.body.length > 0) {
|
|
89598
|
-
request.headers.set(constants_js_1.HeaderConstants.CONTENT_LENGTH, Buffer.byteLength(request.body));
|
|
89599
|
-
}
|
|
89600
|
-
const stringToSign = [
|
|
89601
|
-
request.method.toUpperCase(),
|
|
89602
|
-
getHeaderValueToSign(request, constants_js_1.HeaderConstants.CONTENT_LANGUAGE),
|
|
89603
|
-
getHeaderValueToSign(request, constants_js_1.HeaderConstants.CONTENT_ENCODING),
|
|
89604
|
-
getHeaderValueToSign(request, constants_js_1.HeaderConstants.CONTENT_LENGTH),
|
|
89605
|
-
getHeaderValueToSign(request, constants_js_1.HeaderConstants.CONTENT_MD5),
|
|
89606
|
-
getHeaderValueToSign(request, constants_js_1.HeaderConstants.CONTENT_TYPE),
|
|
89607
|
-
getHeaderValueToSign(request, constants_js_1.HeaderConstants.DATE),
|
|
89608
|
-
getHeaderValueToSign(request, constants_js_1.HeaderConstants.IF_MODIFIED_SINCE),
|
|
89609
|
-
getHeaderValueToSign(request, constants_js_1.HeaderConstants.IF_MATCH),
|
|
89610
|
-
getHeaderValueToSign(request, constants_js_1.HeaderConstants.IF_NONE_MATCH),
|
|
89611
|
-
getHeaderValueToSign(request, constants_js_1.HeaderConstants.IF_UNMODIFIED_SINCE),
|
|
89612
|
-
getHeaderValueToSign(request, constants_js_1.HeaderConstants.RANGE),
|
|
89613
|
-
].join("\n") +
|
|
89614
|
-
"\n" +
|
|
89615
|
-
getCanonicalizedHeadersString(request) +
|
|
89616
|
-
getCanonicalizedResourceString(request);
|
|
89617
|
-
const signature = (0, node_crypto_1.createHmac)("sha256", options.accountKey)
|
|
89618
|
-
.update(stringToSign, "utf8")
|
|
89619
|
-
.digest("base64");
|
|
89620
|
-
request.headers.set(constants_js_1.HeaderConstants.AUTHORIZATION, `SharedKey ${options.accountName}:${signature}`);
|
|
89621
|
-
// console.log(`[URL]:${request.url}`);
|
|
89622
|
-
// console.log(`[HEADERS]:${request.headers.toString()}`);
|
|
89623
|
-
// console.log(`[STRING TO SIGN]:${JSON.stringify(stringToSign)}`);
|
|
89624
|
-
// console.log(`[KEY]: ${request.headers.get(HeaderConstants.AUTHORIZATION)}`);
|
|
89625
|
-
}
|
|
88444
|
+
var PremiumPageBlobTier;
|
|
88445
|
+
(function (PremiumPageBlobTier) {
|
|
89626
88446
|
/**
|
|
89627
|
-
*
|
|
89628
|
-
* @see https://learn.microsoft.com/rest/api/storageservices/authenticate-with-shared-key
|
|
88447
|
+
* P4 Tier.
|
|
89629
88448
|
*/
|
|
89630
|
-
|
|
89631
|
-
const value = request.headers.get(headerName);
|
|
89632
|
-
if (!value) {
|
|
89633
|
-
return "";
|
|
89634
|
-
}
|
|
89635
|
-
// When using version 2015-02-21 or later, if Content-Length is zero, then
|
|
89636
|
-
// set the Content-Length part of the StringToSign to an empty string.
|
|
89637
|
-
// https://learn.microsoft.com/rest/api/storageservices/authenticate-with-shared-key
|
|
89638
|
-
if (headerName === constants_js_1.HeaderConstants.CONTENT_LENGTH && value === "0") {
|
|
89639
|
-
return "";
|
|
89640
|
-
}
|
|
89641
|
-
return value;
|
|
89642
|
-
}
|
|
88449
|
+
PremiumPageBlobTier["P4"] = "P4";
|
|
89643
88450
|
/**
|
|
89644
|
-
*
|
|
89645
|
-
* 1. Retrieve all headers for the resource that begin with x-ms-, including the x-ms-date header.
|
|
89646
|
-
* 2. Convert each HTTP header name to lowercase.
|
|
89647
|
-
* 3. Sort the headers lexicographically by header name, in ascending order.
|
|
89648
|
-
* Each header may appear only once in the string.
|
|
89649
|
-
* 4. Replace any linear whitespace in the header value with a single space.
|
|
89650
|
-
* 5. Trim any whitespace around the colon in the header.
|
|
89651
|
-
* 6. Finally, append a new-line character to each canonicalized header in the resulting list.
|
|
89652
|
-
* Construct the CanonicalizedHeaders string by concatenating all headers in this list into a single string.
|
|
89653
|
-
*
|
|
88451
|
+
* P6 Tier.
|
|
89654
88452
|
*/
|
|
89655
|
-
|
|
89656
|
-
|
|
89657
|
-
|
|
89658
|
-
|
|
89659
|
-
|
|
89660
|
-
|
|
89661
|
-
|
|
89662
|
-
|
|
89663
|
-
|
|
89664
|
-
|
|
89665
|
-
|
|
89666
|
-
|
|
89667
|
-
|
|
89668
|
-
|
|
89669
|
-
|
|
89670
|
-
|
|
89671
|
-
|
|
89672
|
-
|
|
89673
|
-
|
|
89674
|
-
|
|
89675
|
-
|
|
89676
|
-
|
|
89677
|
-
|
|
89678
|
-
|
|
88453
|
+
PremiumPageBlobTier["P6"] = "P6";
|
|
88454
|
+
/**
|
|
88455
|
+
* P10 Tier.
|
|
88456
|
+
*/
|
|
88457
|
+
PremiumPageBlobTier["P10"] = "P10";
|
|
88458
|
+
/**
|
|
88459
|
+
* P15 Tier.
|
|
88460
|
+
*/
|
|
88461
|
+
PremiumPageBlobTier["P15"] = "P15";
|
|
88462
|
+
/**
|
|
88463
|
+
* P20 Tier.
|
|
88464
|
+
*/
|
|
88465
|
+
PremiumPageBlobTier["P20"] = "P20";
|
|
88466
|
+
/**
|
|
88467
|
+
* P30 Tier.
|
|
88468
|
+
*/
|
|
88469
|
+
PremiumPageBlobTier["P30"] = "P30";
|
|
88470
|
+
/**
|
|
88471
|
+
* P40 Tier.
|
|
88472
|
+
*/
|
|
88473
|
+
PremiumPageBlobTier["P40"] = "P40";
|
|
88474
|
+
/**
|
|
88475
|
+
* P50 Tier.
|
|
88476
|
+
*/
|
|
88477
|
+
PremiumPageBlobTier["P50"] = "P50";
|
|
88478
|
+
/**
|
|
88479
|
+
* P60 Tier.
|
|
88480
|
+
*/
|
|
88481
|
+
PremiumPageBlobTier["P60"] = "P60";
|
|
88482
|
+
/**
|
|
88483
|
+
* P70 Tier.
|
|
88484
|
+
*/
|
|
88485
|
+
PremiumPageBlobTier["P70"] = "P70";
|
|
88486
|
+
/**
|
|
88487
|
+
* P80 Tier.
|
|
88488
|
+
*/
|
|
88489
|
+
PremiumPageBlobTier["P80"] = "P80";
|
|
88490
|
+
})(PremiumPageBlobTier || (exports.PremiumPageBlobTier = PremiumPageBlobTier = {}));
|
|
88491
|
+
function toAccessTier(tier) {
|
|
88492
|
+
if (tier === undefined) {
|
|
88493
|
+
return undefined;
|
|
89679
88494
|
}
|
|
89680
|
-
|
|
89681
|
-
|
|
89682
|
-
|
|
89683
|
-
|
|
89684
|
-
|
|
89685
|
-
|
|
89686
|
-
|
|
89687
|
-
|
|
89688
|
-
for (const key in queries) {
|
|
89689
|
-
if (Object.prototype.hasOwnProperty.call(queries, key)) {
|
|
89690
|
-
const lowercaseKey = key.toLowerCase();
|
|
89691
|
-
lowercaseQueries[lowercaseKey] = queries[key];
|
|
89692
|
-
queryKeys.push(lowercaseKey);
|
|
89693
|
-
}
|
|
89694
|
-
}
|
|
89695
|
-
queryKeys.sort();
|
|
89696
|
-
for (const key of queryKeys) {
|
|
89697
|
-
canonicalizedResourceString += `\n${key}:${decodeURIComponent(lowercaseQueries[key])}`;
|
|
89698
|
-
}
|
|
89699
|
-
}
|
|
89700
|
-
return canonicalizedResourceString;
|
|
88495
|
+
return tier; // No more check if string is a valid AccessTier, and left this to underlay logic to decide(service).
|
|
88496
|
+
}
|
|
88497
|
+
function ensureCpkIfSpecified(cpk, isHttps) {
|
|
88498
|
+
if (cpk && !isHttps) {
|
|
88499
|
+
throw new RangeError("Customer-provided encryption key must be used over HTTPS.");
|
|
88500
|
+
}
|
|
88501
|
+
if (cpk && !cpk.encryptionAlgorithm) {
|
|
88502
|
+
cpk.encryptionAlgorithm = constants_js_1.EncryptionAlgorithmAES25;
|
|
89701
88503
|
}
|
|
89702
|
-
return {
|
|
89703
|
-
name: exports.storageSharedKeyCredentialPolicyName,
|
|
89704
|
-
async sendRequest(request, next) {
|
|
89705
|
-
signRequest(request);
|
|
89706
|
-
return next(request);
|
|
89707
|
-
},
|
|
89708
|
-
};
|
|
89709
88504
|
}
|
|
89710
|
-
|
|
88505
|
+
/**
|
|
88506
|
+
* Defines the known cloud audiences for Storage.
|
|
88507
|
+
*/
|
|
88508
|
+
var StorageBlobAudience;
|
|
88509
|
+
(function (StorageBlobAudience) {
|
|
88510
|
+
/**
|
|
88511
|
+
* The OAuth scope to use to retrieve an AAD token for Azure Storage.
|
|
88512
|
+
*/
|
|
88513
|
+
StorageBlobAudience["StorageOAuthScopes"] = "https://storage.azure.com/.default";
|
|
88514
|
+
/**
|
|
88515
|
+
* The OAuth scope to use to retrieve an AAD token for Azure Disk.
|
|
88516
|
+
*/
|
|
88517
|
+
StorageBlobAudience["DiskComputeOAuthScopes"] = "https://disk.compute.azure.com/.default";
|
|
88518
|
+
})(StorageBlobAudience || (exports.StorageBlobAudience = StorageBlobAudience = {}));
|
|
88519
|
+
/**
|
|
88520
|
+
*
|
|
88521
|
+
* To get OAuth audience for a storage account for blob service.
|
|
88522
|
+
*/
|
|
88523
|
+
function getBlobServiceAccountAudience(storageAccountName) {
|
|
88524
|
+
return `https://${storageAccountName}.blob.core.windows.net/.default`;
|
|
88525
|
+
}
|
|
88526
|
+
//# sourceMappingURL=models.js.map
|
|
89711
88527
|
|
|
89712
88528
|
/***/ }),
|
|
89713
88529
|
|
|
@@ -90589,23 +89405,23 @@ exports.generateBlobSASQueryParametersInternal = generateBlobSASQueryParametersI
|
|
|
90589
89405
|
// Licensed under the MIT License.
|
|
90590
89406
|
const BlobSASPermissions_js_1 = __nccwpck_require__(2232);
|
|
90591
89407
|
const ContainerSASPermissions_js_1 = __nccwpck_require__(51622);
|
|
90592
|
-
const
|
|
90593
|
-
const UserDelegationKeyCredential_js_1 = __nccwpck_require__(10992);
|
|
89408
|
+
const storage_common_1 = __nccwpck_require__(51382);
|
|
90594
89409
|
const SasIPRange_js_1 = __nccwpck_require__(2977);
|
|
90595
89410
|
const SASQueryParameters_js_1 = __nccwpck_require__(26823);
|
|
90596
89411
|
const constants_js_1 = __nccwpck_require__(27323);
|
|
90597
89412
|
const utils_common_js_1 = __nccwpck_require__(47764);
|
|
89413
|
+
const storage_common_2 = __nccwpck_require__(51382);
|
|
90598
89414
|
function generateBlobSASQueryParameters(blobSASSignatureValues, sharedKeyCredentialOrUserDelegationKey, accountName) {
|
|
90599
89415
|
return generateBlobSASQueryParametersInternal(blobSASSignatureValues, sharedKeyCredentialOrUserDelegationKey, accountName).sasQueryParameters;
|
|
90600
89416
|
}
|
|
90601
89417
|
function generateBlobSASQueryParametersInternal(blobSASSignatureValues, sharedKeyCredentialOrUserDelegationKey, accountName) {
|
|
90602
89418
|
const version = blobSASSignatureValues.version ? blobSASSignatureValues.version : constants_js_1.SERVICE_VERSION;
|
|
90603
|
-
const sharedKeyCredential = sharedKeyCredentialOrUserDelegationKey instanceof
|
|
89419
|
+
const sharedKeyCredential = sharedKeyCredentialOrUserDelegationKey instanceof storage_common_1.StorageSharedKeyCredential
|
|
90604
89420
|
? sharedKeyCredentialOrUserDelegationKey
|
|
90605
89421
|
: undefined;
|
|
90606
89422
|
let userDelegationKeyCredential;
|
|
90607
89423
|
if (sharedKeyCredential === undefined && accountName !== undefined) {
|
|
90608
|
-
userDelegationKeyCredential = new
|
|
89424
|
+
userDelegationKeyCredential = new storage_common_2.UserDelegationKeyCredential(accountName, sharedKeyCredentialOrUserDelegationKey);
|
|
90609
89425
|
}
|
|
90610
89426
|
if (sharedKeyCredential === undefined && userDelegationKeyCredential === undefined) {
|
|
90611
89427
|
throw TypeError("Invalid sharedKeyCredential, userDelegationKey or accountName.");
|
|
@@ -91168,7 +89984,7 @@ function generateBlobSASQueryParametersUDK20250705(blobSASSignatureValues, userD
|
|
|
91168
89984
|
undefined, // agentObjectId
|
|
91169
89985
|
blobSASSignatureValues.correlationId,
|
|
91170
89986
|
undefined, // SignedKeyDelegatedUserTenantId, will be added in a future release.
|
|
91171
|
-
|
|
89987
|
+
blobSASSignatureValues.delegatedUserObjectId,
|
|
91172
89988
|
blobSASSignatureValues.ipRange ? (0, SasIPRange_js_1.ipRangeToString)(blobSASSignatureValues.ipRange) : "",
|
|
91173
89989
|
blobSASSignatureValues.protocol ? blobSASSignatureValues.protocol : "",
|
|
91174
89990
|
blobSASSignatureValues.version,
|
|
@@ -91183,7 +89999,7 @@ function generateBlobSASQueryParametersUDK20250705(blobSASSignatureValues, userD
|
|
|
91183
89999
|
].join("\n");
|
|
91184
90000
|
const signature = userDelegationKeyCredential.computeHMACSHA256(stringToSign);
|
|
91185
90001
|
return {
|
|
91186
|
-
sasQueryParameters: new SASQueryParameters_js_1.SASQueryParameters(blobSASSignatureValues.version, signature, verifiedPermissions, undefined, undefined, blobSASSignatureValues.protocol, blobSASSignatureValues.startsOn, blobSASSignatureValues.expiresOn, blobSASSignatureValues.ipRange, blobSASSignatureValues.identifier, resource, blobSASSignatureValues.cacheControl, blobSASSignatureValues.contentDisposition, blobSASSignatureValues.contentEncoding, blobSASSignatureValues.contentLanguage, blobSASSignatureValues.contentType, userDelegationKeyCredential.userDelegationKey, blobSASSignatureValues.preauthorizedAgentObjectId, blobSASSignatureValues.correlationId, blobSASSignatureValues.encryptionScope),
|
|
90002
|
+
sasQueryParameters: new SASQueryParameters_js_1.SASQueryParameters(blobSASSignatureValues.version, signature, verifiedPermissions, undefined, undefined, blobSASSignatureValues.protocol, blobSASSignatureValues.startsOn, blobSASSignatureValues.expiresOn, blobSASSignatureValues.ipRange, blobSASSignatureValues.identifier, resource, blobSASSignatureValues.cacheControl, blobSASSignatureValues.contentDisposition, blobSASSignatureValues.contentEncoding, blobSASSignatureValues.contentLanguage, blobSASSignatureValues.contentType, userDelegationKeyCredential.userDelegationKey, blobSASSignatureValues.preauthorizedAgentObjectId, blobSASSignatureValues.correlationId, blobSASSignatureValues.encryptionScope, blobSASSignatureValues.delegatedUserObjectId),
|
|
91187
90003
|
stringToSign: stringToSign,
|
|
91188
90004
|
};
|
|
91189
90005
|
}
|
|
@@ -91557,6 +90373,12 @@ class SASQueryParameters {
|
|
|
91557
90373
|
* @see https://learn.microsoft.com/rest/api/storageservices/establishing-a-stored-access-policy
|
|
91558
90374
|
*/
|
|
91559
90375
|
identifier;
|
|
90376
|
+
/**
|
|
90377
|
+
* Optional. Beginning in version 2025-07-05, this value specifies the Entra ID of the user would is authorized to
|
|
90378
|
+
* use the resulting SAS URL. The resulting SAS URL must be used in conjunction with an Entra ID token that has been
|
|
90379
|
+
* issued to the user specified in this value.
|
|
90380
|
+
*/
|
|
90381
|
+
delegatedUserObjectId;
|
|
91560
90382
|
/**
|
|
91561
90383
|
* Optional. Encryption scope to use when sending requests authorized with this SAS URI.
|
|
91562
90384
|
*/
|
|
@@ -91650,7 +90472,7 @@ class SASQueryParameters {
|
|
|
91650
90472
|
}
|
|
91651
90473
|
return undefined;
|
|
91652
90474
|
}
|
|
91653
|
-
constructor(version, signature, permissionsOrOptions, services, resourceTypes, protocol, startsOn, expiresOn, ipRange, identifier, resource, cacheControl, contentDisposition, contentEncoding, contentLanguage, contentType, userDelegationKey, preauthorizedAgentObjectId, correlationId, encryptionScope) {
|
|
90475
|
+
constructor(version, signature, permissionsOrOptions, services, resourceTypes, protocol, startsOn, expiresOn, ipRange, identifier, resource, cacheControl, contentDisposition, contentEncoding, contentLanguage, contentType, userDelegationKey, preauthorizedAgentObjectId, correlationId, encryptionScope, delegatedUserObjectId) {
|
|
91654
90476
|
this.version = version;
|
|
91655
90477
|
this.signature = signature;
|
|
91656
90478
|
if (permissionsOrOptions !== undefined && typeof permissionsOrOptions !== "string") {
|
|
@@ -91663,6 +90485,7 @@ class SASQueryParameters {
|
|
|
91663
90485
|
this.expiresOn = permissionsOrOptions.expiresOn;
|
|
91664
90486
|
this.ipRangeInner = permissionsOrOptions.ipRange;
|
|
91665
90487
|
this.identifier = permissionsOrOptions.identifier;
|
|
90488
|
+
this.delegatedUserObjectId = permissionsOrOptions.delegatedUserObjectId;
|
|
91666
90489
|
this.encryptionScope = permissionsOrOptions.encryptionScope;
|
|
91667
90490
|
this.resource = permissionsOrOptions.resource;
|
|
91668
90491
|
this.cacheControl = permissionsOrOptions.cacheControl;
|
|
@@ -91689,6 +90512,7 @@ class SASQueryParameters {
|
|
|
91689
90512
|
this.protocol = protocol;
|
|
91690
90513
|
this.startsOn = startsOn;
|
|
91691
90514
|
this.ipRangeInner = ipRange;
|
|
90515
|
+
this.delegatedUserObjectId = delegatedUserObjectId;
|
|
91692
90516
|
this.encryptionScope = encryptionScope;
|
|
91693
90517
|
this.identifier = identifier;
|
|
91694
90518
|
this.resource = resource;
|
|
@@ -91740,6 +90564,7 @@ class SASQueryParameters {
|
|
|
91740
90564
|
"rsct",
|
|
91741
90565
|
"saoid",
|
|
91742
90566
|
"scid",
|
|
90567
|
+
"sduoid", // Signed key user delegation object ID
|
|
91743
90568
|
];
|
|
91744
90569
|
const queries = [];
|
|
91745
90570
|
for (const param of params) {
|
|
@@ -91819,6 +90644,9 @@ class SASQueryParameters {
|
|
|
91819
90644
|
case "scid":
|
|
91820
90645
|
this.tryAppendQueryParameter(queries, param, this.correlationId);
|
|
91821
90646
|
break;
|
|
90647
|
+
case "sduoid":
|
|
90648
|
+
this.tryAppendQueryParameter(queries, param, this.delegatedUserObjectId);
|
|
90649
|
+
break;
|
|
91822
90650
|
}
|
|
91823
90651
|
}
|
|
91824
90652
|
return queries.join("&");
|
|
@@ -92351,89 +91179,6 @@ exports.RetriableReadableStream = RetriableReadableStream;
|
|
|
92351
91179
|
|
|
92352
91180
|
/***/ }),
|
|
92353
91181
|
|
|
92354
|
-
/***/ 21902:
|
|
92355
|
-
/***/ ((__unused_webpack_module, exports) => {
|
|
92356
|
-
|
|
92357
|
-
"use strict";
|
|
92358
|
-
|
|
92359
|
-
// Copyright (c) Microsoft Corporation.
|
|
92360
|
-
// Licensed under the MIT License.
|
|
92361
|
-
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
92362
|
-
exports.compareHeader = compareHeader;
|
|
92363
|
-
/*
|
|
92364
|
-
* We need to imitate .Net culture-aware sorting, which is used in storage service.
|
|
92365
|
-
* Below tables contain sort-keys for en-US culture.
|
|
92366
|
-
*/
|
|
92367
|
-
const table_lv0 = new Uint32Array([
|
|
92368
|
-
0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
|
|
92369
|
-
0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x71c, 0x0, 0x71f, 0x721,
|
|
92370
|
-
0x723, 0x725, 0x0, 0x0, 0x0, 0x72d, 0x803, 0x0, 0x0, 0x733, 0x0, 0xd03, 0xd1a, 0xd1c, 0xd1e,
|
|
92371
|
-
0xd20, 0xd22, 0xd24, 0xd26, 0xd28, 0xd2a, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0xe02, 0xe09, 0xe0a,
|
|
92372
|
-
0xe1a, 0xe21, 0xe23, 0xe25, 0xe2c, 0xe32, 0xe35, 0xe36, 0xe48, 0xe51, 0xe70, 0xe7c, 0xe7e, 0xe89,
|
|
92373
|
-
0xe8a, 0xe91, 0xe99, 0xe9f, 0xea2, 0xea4, 0xea6, 0xea7, 0xea9, 0x0, 0x0, 0x0, 0x743, 0x744, 0x748,
|
|
92374
|
-
0xe02, 0xe09, 0xe0a, 0xe1a, 0xe21, 0xe23, 0xe25, 0xe2c, 0xe32, 0xe35, 0xe36, 0xe48, 0xe51, 0xe70,
|
|
92375
|
-
0xe7c, 0xe7e, 0xe89, 0xe8a, 0xe91, 0xe99, 0xe9f, 0xea2, 0xea4, 0xea6, 0xea7, 0xea9, 0x0, 0x74c,
|
|
92376
|
-
0x0, 0x750, 0x0,
|
|
92377
|
-
]);
|
|
92378
|
-
const table_lv2 = new Uint32Array([
|
|
92379
|
-
0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
|
|
92380
|
-
0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
|
|
92381
|
-
0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
|
|
92382
|
-
0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x12, 0x12, 0x12, 0x12, 0x12, 0x12, 0x12, 0x12, 0x12,
|
|
92383
|
-
0x12, 0x12, 0x12, 0x12, 0x12, 0x12, 0x12, 0x12, 0x12, 0x12, 0x12, 0x12, 0x12, 0x12, 0x12, 0x12,
|
|
92384
|
-
0x12, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
|
|
92385
|
-
0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
|
|
92386
|
-
]);
|
|
92387
|
-
const table_lv4 = new Uint32Array([
|
|
92388
|
-
0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
|
|
92389
|
-
0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
|
|
92390
|
-
0x0, 0x8012, 0x0, 0x0, 0x0, 0x0, 0x0, 0x8212, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
|
|
92391
|
-
0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
|
|
92392
|
-
0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
|
|
92393
|
-
0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
|
|
92394
|
-
0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
|
|
92395
|
-
]);
|
|
92396
|
-
function compareHeader(lhs, rhs) {
|
|
92397
|
-
if (isLessThan(lhs, rhs))
|
|
92398
|
-
return -1;
|
|
92399
|
-
return 1;
|
|
92400
|
-
}
|
|
92401
|
-
function isLessThan(lhs, rhs) {
|
|
92402
|
-
const tables = [table_lv0, table_lv2, table_lv4];
|
|
92403
|
-
let curr_level = 0;
|
|
92404
|
-
let i = 0;
|
|
92405
|
-
let j = 0;
|
|
92406
|
-
while (curr_level < tables.length) {
|
|
92407
|
-
if (curr_level === tables.length - 1 && i !== j) {
|
|
92408
|
-
return i > j;
|
|
92409
|
-
}
|
|
92410
|
-
const weight1 = i < lhs.length ? tables[curr_level][lhs[i].charCodeAt(0)] : 0x1;
|
|
92411
|
-
const weight2 = j < rhs.length ? tables[curr_level][rhs[j].charCodeAt(0)] : 0x1;
|
|
92412
|
-
if (weight1 === 0x1 && weight2 === 0x1) {
|
|
92413
|
-
i = 0;
|
|
92414
|
-
j = 0;
|
|
92415
|
-
++curr_level;
|
|
92416
|
-
}
|
|
92417
|
-
else if (weight1 === weight2) {
|
|
92418
|
-
++i;
|
|
92419
|
-
++j;
|
|
92420
|
-
}
|
|
92421
|
-
else if (weight1 === 0) {
|
|
92422
|
-
++i;
|
|
92423
|
-
}
|
|
92424
|
-
else if (weight2 === 0) {
|
|
92425
|
-
++j;
|
|
92426
|
-
}
|
|
92427
|
-
else {
|
|
92428
|
-
return weight1 < weight2;
|
|
92429
|
-
}
|
|
92430
|
-
}
|
|
92431
|
-
return false;
|
|
92432
|
-
}
|
|
92433
|
-
//# sourceMappingURL=SharedKeyComparator.js.map
|
|
92434
|
-
|
|
92435
|
-
/***/ }),
|
|
92436
|
-
|
|
92437
91182
|
/***/ 27323:
|
|
92438
91183
|
/***/ ((__unused_webpack_module, exports) => {
|
|
92439
91184
|
|
|
@@ -92443,8 +91188,8 @@ function isLessThan(lhs, rhs) {
|
|
|
92443
91188
|
// Licensed under the MIT License.
|
|
92444
91189
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
92445
91190
|
exports.PathStylePorts = exports.BlobDoesNotUseCustomerSpecifiedEncryption = exports.BlobUsesCustomerSpecifiedEncryptionMsg = exports.StorageBlobLoggingAllowedQueryParameters = exports.StorageBlobLoggingAllowedHeaderNames = exports.DevelopmentConnectionString = exports.EncryptionAlgorithmAES25 = exports.HTTP_VERSION_1_1 = exports.HTTP_LINE_ENDING = exports.BATCH_MAX_PAYLOAD_IN_BYTES = exports.BATCH_MAX_REQUEST = exports.SIZE_1_MB = exports.ETagAny = exports.ETagNone = exports.HeaderConstants = exports.HTTPURLConnection = exports.URLConstants = exports.StorageOAuthScopes = exports.REQUEST_TIMEOUT = exports.DEFAULT_MAX_DOWNLOAD_RETRY_REQUESTS = exports.DEFAULT_BLOB_DOWNLOAD_BLOCK_BYTES = exports.DEFAULT_BLOCK_BUFFER_SIZE_BYTES = exports.BLOCK_BLOB_MAX_BLOCKS = exports.BLOCK_BLOB_MAX_STAGE_BLOCK_BYTES = exports.BLOCK_BLOB_MAX_UPLOAD_BLOB_BYTES = exports.SERVICE_VERSION = exports.SDK_VERSION = void 0;
|
|
92446
|
-
exports.SDK_VERSION = "12.
|
|
92447
|
-
exports.SERVICE_VERSION = "
|
|
91191
|
+
exports.SDK_VERSION = "12.31.0";
|
|
91192
|
+
exports.SERVICE_VERSION = "2026-02-06";
|
|
92448
91193
|
exports.BLOCK_BLOB_MAX_UPLOAD_BLOB_BYTES = 256 * 1024 * 1024; // 256MB
|
|
92449
91194
|
exports.BLOCK_BLOB_MAX_STAGE_BLOCK_BYTES = 4000 * 1024 * 1024; // 4000MB
|
|
92450
91195
|
exports.BLOCK_BLOB_MAX_BLOCKS = 50000;
|
|
@@ -94250,9 +92995,10 @@ exports.StorageBrowserPolicyFactory = StorageBrowserPolicyFactory;
|
|
|
94250
92995
|
// Copyright (c) Microsoft Corporation.
|
|
94251
92996
|
// Licensed under the MIT License.
|
|
94252
92997
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
94253
|
-
exports.StorageRetryPolicyFactory = exports.StorageRetryPolicy = exports.StorageRetryPolicyType = void 0;
|
|
92998
|
+
exports.StorageRetryPolicyFactory = exports.NewRetryPolicyFactory = exports.StorageRetryPolicy = exports.StorageRetryPolicyType = void 0;
|
|
94254
92999
|
const StorageRetryPolicy_js_1 = __nccwpck_require__(27734);
|
|
94255
93000
|
Object.defineProperty(exports, "StorageRetryPolicy", ({ enumerable: true, get: function () { return StorageRetryPolicy_js_1.StorageRetryPolicy; } }));
|
|
93001
|
+
Object.defineProperty(exports, "NewRetryPolicyFactory", ({ enumerable: true, get: function () { return StorageRetryPolicy_js_1.NewRetryPolicyFactory; } }));
|
|
94256
93002
|
const StorageRetryPolicyType_js_1 = __nccwpck_require__(38622);
|
|
94257
93003
|
Object.defineProperty(exports, "StorageRetryPolicyType", ({ enumerable: true, get: function () { return StorageRetryPolicyType_js_1.StorageRetryPolicyType; } }));
|
|
94258
93004
|
/**
|
|
@@ -94424,6 +93170,60 @@ exports.StorageSharedKeyCredential = StorageSharedKeyCredential;
|
|
|
94424
93170
|
|
|
94425
93171
|
/***/ }),
|
|
94426
93172
|
|
|
93173
|
+
/***/ 3602:
|
|
93174
|
+
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
|
93175
|
+
|
|
93176
|
+
"use strict";
|
|
93177
|
+
|
|
93178
|
+
// Copyright (c) Microsoft Corporation.
|
|
93179
|
+
// Licensed under the MIT License.
|
|
93180
|
+
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
93181
|
+
exports.UserDelegationKeyCredential = void 0;
|
|
93182
|
+
const node_crypto_1 = __nccwpck_require__(77598);
|
|
93183
|
+
/**
|
|
93184
|
+
* ONLY AVAILABLE IN NODE.JS RUNTIME.
|
|
93185
|
+
*
|
|
93186
|
+
* UserDelegationKeyCredential is only used for generation of user delegation SAS.
|
|
93187
|
+
* @see https://learn.microsoft.com/rest/api/storageservices/create-user-delegation-sas
|
|
93188
|
+
*/
|
|
93189
|
+
class UserDelegationKeyCredential {
|
|
93190
|
+
/**
|
|
93191
|
+
* Azure Storage account name; readonly.
|
|
93192
|
+
*/
|
|
93193
|
+
accountName;
|
|
93194
|
+
/**
|
|
93195
|
+
* Azure Storage user delegation key; readonly.
|
|
93196
|
+
*/
|
|
93197
|
+
userDelegationKey;
|
|
93198
|
+
/**
|
|
93199
|
+
* Key value in Buffer type.
|
|
93200
|
+
*/
|
|
93201
|
+
key;
|
|
93202
|
+
/**
|
|
93203
|
+
* Creates an instance of UserDelegationKeyCredential.
|
|
93204
|
+
* @param accountName -
|
|
93205
|
+
* @param userDelegationKey -
|
|
93206
|
+
*/
|
|
93207
|
+
constructor(accountName, userDelegationKey) {
|
|
93208
|
+
this.accountName = accountName;
|
|
93209
|
+
this.userDelegationKey = userDelegationKey;
|
|
93210
|
+
this.key = Buffer.from(userDelegationKey.value, "base64");
|
|
93211
|
+
}
|
|
93212
|
+
/**
|
|
93213
|
+
* Generates a hash signature for an HTTP request or for a SAS.
|
|
93214
|
+
*
|
|
93215
|
+
* @param stringToSign -
|
|
93216
|
+
*/
|
|
93217
|
+
computeHMACSHA256(stringToSign) {
|
|
93218
|
+
// console.log(`stringToSign: ${JSON.stringify(stringToSign)}`);
|
|
93219
|
+
return (0, node_crypto_1.createHmac)("sha256", this.key).update(stringToSign, "utf8").digest("base64");
|
|
93220
|
+
}
|
|
93221
|
+
}
|
|
93222
|
+
exports.UserDelegationKeyCredential = UserDelegationKeyCredential;
|
|
93223
|
+
//# sourceMappingURL=UserDelegationKeyCredential.js.map
|
|
93224
|
+
|
|
93225
|
+
/***/ }),
|
|
93226
|
+
|
|
94427
93227
|
/***/ 51382:
|
|
94428
93228
|
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
|
94429
93229
|
|
|
@@ -94437,6 +93237,7 @@ const tslib_1 = __nccwpck_require__(61860);
|
|
|
94437
93237
|
tslib_1.__exportStar(__nccwpck_require__(86381), exports);
|
|
94438
93238
|
var cache_js_1 = __nccwpck_require__(68376);
|
|
94439
93239
|
Object.defineProperty(exports, "getCachedDefaultHttpClient", ({ enumerable: true, get: function () { return cache_js_1.getCachedDefaultHttpClient; } }));
|
|
93240
|
+
tslib_1.__exportStar(__nccwpck_require__(81420), exports);
|
|
94440
93241
|
tslib_1.__exportStar(__nccwpck_require__(4399), exports);
|
|
94441
93242
|
tslib_1.__exportStar(__nccwpck_require__(32159), exports);
|
|
94442
93243
|
tslib_1.__exportStar(__nccwpck_require__(450), exports);
|
|
@@ -94446,20 +93247,29 @@ var RequestPolicy_js_1 = __nccwpck_require__(40590);
|
|
|
94446
93247
|
Object.defineProperty(exports, "BaseRequestPolicy", ({ enumerable: true, get: function () { return RequestPolicy_js_1.BaseRequestPolicy; } }));
|
|
94447
93248
|
tslib_1.__exportStar(__nccwpck_require__(63611), exports);
|
|
94448
93249
|
tslib_1.__exportStar(__nccwpck_require__(74238), exports);
|
|
94449
|
-
tslib_1.__exportStar(__nccwpck_require__(22312), exports);
|
|
94450
93250
|
tslib_1.__exportStar(__nccwpck_require__(83100), exports);
|
|
94451
93251
|
tslib_1.__exportStar(__nccwpck_require__(92505), exports);
|
|
94452
|
-
tslib_1.__exportStar(__nccwpck_require__(38622), exports);
|
|
94453
|
-
tslib_1.__exportStar(__nccwpck_require__(27734), exports);
|
|
94454
93252
|
tslib_1.__exportStar(__nccwpck_require__(78178), exports);
|
|
94455
93253
|
tslib_1.__exportStar(__nccwpck_require__(35369), exports);
|
|
94456
93254
|
tslib_1.__exportStar(__nccwpck_require__(53233), exports);
|
|
94457
|
-
tslib_1.__exportStar(__nccwpck_require__(77321), exports);
|
|
94458
93255
|
tslib_1.__exportStar(__nccwpck_require__(24174), exports);
|
|
93256
|
+
tslib_1.__exportStar(__nccwpck_require__(3602), exports);
|
|
94459
93257
|
//# sourceMappingURL=index.js.map
|
|
94460
93258
|
|
|
94461
93259
|
/***/ }),
|
|
94462
93260
|
|
|
93261
|
+
/***/ 81420:
|
|
93262
|
+
/***/ ((__unused_webpack_module, exports) => {
|
|
93263
|
+
|
|
93264
|
+
"use strict";
|
|
93265
|
+
|
|
93266
|
+
// Copyright (c) Microsoft Corporation.
|
|
93267
|
+
// Licensed under the MIT License.
|
|
93268
|
+
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
93269
|
+
//# sourceMappingURL=interfaces.js.map
|
|
93270
|
+
|
|
93271
|
+
/***/ }),
|
|
93272
|
+
|
|
94463
93273
|
/***/ 32780:
|
|
94464
93274
|
/***/ ((__unused_webpack_module, exports, __nccwpck_require__) => {
|
|
94465
93275
|
|
|
@@ -95288,7 +94098,7 @@ class StorageSharedKeyCredentialPolicy extends CredentialPolicy_js_1.CredentialP
|
|
|
95288
94098
|
}
|
|
95289
94099
|
/**
|
|
95290
94100
|
* Retrieve header value according to shared key sign rules.
|
|
95291
|
-
* @see https://learn.microsoft.com/
|
|
94101
|
+
* @see https://learn.microsoft.com/rest/api/storageservices/authenticate-with-shared-key
|
|
95292
94102
|
*
|
|
95293
94103
|
* @param request -
|
|
95294
94104
|
* @param headerName -
|
|
@@ -95300,7 +94110,7 @@ class StorageSharedKeyCredentialPolicy extends CredentialPolicy_js_1.CredentialP
|
|
|
95300
94110
|
}
|
|
95301
94111
|
// When using version 2015-02-21 or later, if Content-Length is zero, then
|
|
95302
94112
|
// set the Content-Length part of the StringToSign to an empty string.
|
|
95303
|
-
// https://learn.microsoft.com/
|
|
94113
|
+
// https://learn.microsoft.com/rest/api/storageservices/authenticate-with-shared-key
|
|
95304
94114
|
if (headerName === constants_js_1.HeaderConstants.CONTENT_LENGTH && value === "0") {
|
|
95305
94115
|
return "";
|
|
95306
94116
|
}
|
|
@@ -95431,7 +94241,7 @@ function storageSharedKeyCredentialPolicy(options) {
|
|
|
95431
94241
|
}
|
|
95432
94242
|
/**
|
|
95433
94243
|
* Retrieve header value according to shared key sign rules.
|
|
95434
|
-
* @see https://learn.microsoft.com/
|
|
94244
|
+
* @see https://learn.microsoft.com/rest/api/storageservices/authenticate-with-shared-key
|
|
95435
94245
|
*/
|
|
95436
94246
|
function getHeaderValueToSign(request, headerName) {
|
|
95437
94247
|
const value = request.headers.get(headerName);
|
|
@@ -95440,7 +94250,7 @@ function storageSharedKeyCredentialPolicy(options) {
|
|
|
95440
94250
|
}
|
|
95441
94251
|
// When using version 2015-02-21 or later, if Content-Length is zero, then
|
|
95442
94252
|
// set the Content-Length part of the StringToSign to an empty string.
|
|
95443
|
-
// https://learn.microsoft.com/
|
|
94253
|
+
// https://learn.microsoft.com/rest/api/storageservices/authenticate-with-shared-key
|
|
95444
94254
|
if (headerName === constants_js_1.HeaderConstants.CONTENT_LENGTH && value === "0") {
|
|
95445
94255
|
return "";
|
|
95446
94256
|
}
|
|
@@ -95759,8 +94569,8 @@ const constants_js_1 = __nccwpck_require__(77925);
|
|
|
95759
94569
|
*
|
|
95760
94570
|
* We will apply strategy one, and call encodeURIComponent for these parameters like blobName. Because what customers passes in is a plain name instead of a URL.
|
|
95761
94571
|
*
|
|
95762
|
-
* @see https://learn.microsoft.com/
|
|
95763
|
-
* @see https://learn.microsoft.com/
|
|
94572
|
+
* @see https://learn.microsoft.com/rest/api/storageservices/naming-and-referencing-containers--blobs--and-metadata
|
|
94573
|
+
* @see https://learn.microsoft.com/rest/api/storageservices/naming-and-referencing-shares--directories--files--and-metadata
|
|
95764
94574
|
*
|
|
95765
94575
|
* @param url -
|
|
95766
94576
|
*/
|
|
@@ -95774,7 +94584,7 @@ function escapeURLPath(url) {
|
|
|
95774
94584
|
}
|
|
95775
94585
|
function getProxyUriFromDevConnString(connectionString) {
|
|
95776
94586
|
// Development Connection String
|
|
95777
|
-
// https://learn.microsoft.com/
|
|
94587
|
+
// https://learn.microsoft.com/azure/storage/common/storage-configure-connection-string#connect-to-the-emulator-account-using-the-well-known-account-name-and-key
|
|
95778
94588
|
let proxyUri = "";
|
|
95779
94589
|
if (connectionString.search("DevelopmentStorageProxyUri=") !== -1) {
|
|
95780
94590
|
// CONNECTION_STRING=UseDevelopmentStorage=true;DevelopmentStorageProxyUri=http://myProxyUri
|
|
@@ -96872,6 +95682,9 @@ function getRequestContentType(options = {}) {
|
|
|
96872
95682
|
* @returns returns the content-type
|
|
96873
95683
|
*/
|
|
96874
95684
|
function getContentType(body) {
|
|
95685
|
+
if (body === undefined) {
|
|
95686
|
+
return undefined;
|
|
95687
|
+
}
|
|
96875
95688
|
if (ArrayBuffer.isView(body)) {
|
|
96876
95689
|
return "application/octet-stream";
|
|
96877
95690
|
}
|
|
@@ -96891,12 +95704,10 @@ function getContentType(body) {
|
|
|
96891
95704
|
function buildPipelineRequest(method, url, options = {}) {
|
|
96892
95705
|
const requestContentType = getRequestContentType(options);
|
|
96893
95706
|
const { body, multipartBody } = getRequestBody(options.body, requestContentType);
|
|
96894
|
-
const hasContent = body !== undefined || multipartBody !== undefined;
|
|
96895
95707
|
const headers = (0, httpHeaders_js_1.createHttpHeaders)({
|
|
96896
95708
|
...(options.headers ? options.headers : {}),
|
|
96897
95709
|
accept: options.accept ?? options.headers?.accept ?? "application/json",
|
|
96898
|
-
...(
|
|
96899
|
-
requestContentType && {
|
|
95710
|
+
...(requestContentType && {
|
|
96900
95711
|
"content-type": requestContentType,
|
|
96901
95712
|
}),
|
|
96902
95713
|
});
|
|
@@ -97161,7 +95972,7 @@ function replaceAll(value, searchValue, replaceValue) {
|
|
|
97161
95972
|
// Licensed under the MIT License.
|
|
97162
95973
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
97163
95974
|
exports.DEFAULT_RETRY_POLICY_COUNT = exports.SDK_VERSION = void 0;
|
|
97164
|
-
exports.SDK_VERSION = "0.3.
|
|
95975
|
+
exports.SDK_VERSION = "0.3.3";
|
|
97165
95976
|
exports.DEFAULT_RETRY_POLICY_COUNT = 3;
|
|
97166
95977
|
//# sourceMappingURL=constants.js.map
|
|
97167
95978
|
|
|
@@ -100948,7 +99759,7 @@ module.exports = { ping }
|
|
|
100948
99759
|
/***/ 50591:
|
|
100949
99760
|
/***/ ((module) => {
|
|
100950
99761
|
|
|
100951
|
-
(()=>{"use strict";var t={d:(e,i)=>{for(var n in i)t.o(i,n)&&!t.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:i[n]})},o:(t,e)=>Object.prototype.hasOwnProperty.call(t,e),r:t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})}},e={};t.r(e),t.d(e,{XMLBuilder:()=>lt,XMLParser:()=>tt,XMLValidator:()=>pt});const i=":A-Za-z_\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD",n=new RegExp("^["+i+"]["+i+"\\-.\\d\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$");function s(t,e){const i=[];let n=e.exec(t);for(;n;){const s=[];s.startIndex=e.lastIndex-n[0].length;const r=n.length;for(let t=0;t<r;t++)s.push(n[t]);i.push(s),n=e.exec(t)}return i}const r=function(t){return!(null==n.exec(t))},o={allowBooleanAttributes:!1,unpairedTags:[]};function a(t,e){e=Object.assign({},o,e);const i=[];let n=!1,s=!1;"\ufeff"===t[0]&&(t=t.substr(1));for(let o=0;o<t.length;o++)if("<"===t[o]&&"?"===t[o+1]){if(o+=2,o=u(t,o),o.err)return o}else{if("<"!==t[o]){if(l(t[o]))continue;return x("InvalidChar","char '"+t[o]+"' is not expected.",b(t,o))}{let a=o;if(o++,"!"===t[o]){o=h(t,o);continue}{let d=!1;"/"===t[o]&&(d=!0,o++);let p="";for(;o<t.length&&">"!==t[o]&&" "!==t[o]&&"\t"!==t[o]&&"\n"!==t[o]&&"\r"!==t[o];o++)p+=t[o];if(p=p.trim(),"/"===p[p.length-1]&&(p=p.substring(0,p.length-1),o--),!r(p)){let e;return e=0===p.trim().length?"Invalid space after '<'.":"Tag '"+p+"' is an invalid name.",x("InvalidTag",e,b(t,o))}const c=f(t,o);if(!1===c)return x("InvalidAttr","Attributes for '"+p+"' have open quote.",b(t,o));let N=c.value;if(o=c.index,"/"===N[N.length-1]){const i=o-N.length;N=N.substring(0,N.length-1);const s=g(N,e);if(!0!==s)return x(s.err.code,s.err.msg,b(t,i+s.err.line));n=!0}else if(d){if(!c.tagClosed)return x("InvalidTag","Closing tag '"+p+"' doesn't have proper closing.",b(t,o));if(N.trim().length>0)return x("InvalidTag","Closing tag '"+p+"' can't have attributes or invalid starting.",b(t,a));if(0===i.length)return x("InvalidTag","Closing tag '"+p+"' has not been opened.",b(t,a));{const e=i.pop();if(p!==e.tagName){let i=b(t,e.tagStartPos);return x("InvalidTag","Expected closing tag '"+e.tagName+"' (opened in line "+i.line+", col "+i.col+") instead of closing tag '"+p+"'.",b(t,a))}0==i.length&&(s=!0)}}else{const r=g(N,e);if(!0!==r)return x(r.err.code,r.err.msg,b(t,o-N.length+r.err.line));if(!0===s)return x("InvalidXml","Multiple possible root nodes found.",b(t,o));-1!==e.unpairedTags.indexOf(p)||i.push({tagName:p,tagStartPos:a}),n=!0}for(o++;o<t.length;o++)if("<"===t[o]){if("!"===t[o+1]){o++,o=h(t,o);continue}if("?"!==t[o+1])break;if(o=u(t,++o),o.err)return o}else if("&"===t[o]){const e=m(t,o);if(-1==e)return x("InvalidChar","char '&' is not expected.",b(t,o));o=e}else if(!0===s&&!l(t[o]))return x("InvalidXml","Extra text at the end",b(t,o));"<"===t[o]&&o--}}}return n?1==i.length?x("InvalidTag","Unclosed tag '"+i[0].tagName+"'.",b(t,i[0].tagStartPos)):!(i.length>0)||x("InvalidXml","Invalid '"+JSON.stringify(i.map((t=>t.tagName)),null,4).replace(/\r?\n/g,"")+"' found.",{line:1,col:1}):x("InvalidXml","Start tag expected.",1)}function l(t){return" "===t||"\t"===t||"\n"===t||"\r"===t}function u(t,e){const i=e;for(;e<t.length;e++)if("?"!=t[e]&&" "!=t[e]);else{const n=t.substr(i,e-i);if(e>5&&"xml"===n)return x("InvalidXml","XML declaration allowed only at the start of the document.",b(t,e));if("?"==t[e]&&">"==t[e+1]){e++;break}}return e}function h(t,e){if(t.length>e+5&&"-"===t[e+1]&&"-"===t[e+2]){for(e+=3;e<t.length;e++)if("-"===t[e]&&"-"===t[e+1]&&">"===t[e+2]){e+=2;break}}else if(t.length>e+8&&"D"===t[e+1]&&"O"===t[e+2]&&"C"===t[e+3]&&"T"===t[e+4]&&"Y"===t[e+5]&&"P"===t[e+6]&&"E"===t[e+7]){let i=1;for(e+=8;e<t.length;e++)if("<"===t[e])i++;else if(">"===t[e]&&(i--,0===i))break}else if(t.length>e+9&&"["===t[e+1]&&"C"===t[e+2]&&"D"===t[e+3]&&"A"===t[e+4]&&"T"===t[e+5]&&"A"===t[e+6]&&"["===t[e+7])for(e+=8;e<t.length;e++)if("]"===t[e]&&"]"===t[e+1]&&">"===t[e+2]){e+=2;break}return e}const d='"',p="'";function f(t,e){let i="",n="",s=!1;for(;e<t.length;e++){if(t[e]===d||t[e]===p)""===n?n=t[e]:n!==t[e]||(n="");else if(">"===t[e]&&""===n){s=!0;break}i+=t[e]}return""===n&&{value:i,index:e,tagClosed:s}}const c=new RegExp("(\\s*)([^\\s=]+)(\\s*=)?(\\s*(['\"])(([\\s\\S])*?)\\5)?","g");function g(t,e){const i=s(t,c),n={};for(let t=0;t<i.length;t++){if(0===i[t][1].length)return x("InvalidAttr","Attribute '"+i[t][2]+"' has no space in starting.",E(i[t]));if(void 0!==i[t][3]&&void 0===i[t][4])return x("InvalidAttr","Attribute '"+i[t][2]+"' is without value.",E(i[t]));if(void 0===i[t][3]&&!e.allowBooleanAttributes)return x("InvalidAttr","boolean attribute '"+i[t][2]+"' is not allowed.",E(i[t]));const s=i[t][2];if(!N(s))return x("InvalidAttr","Attribute '"+s+"' is an invalid name.",E(i[t]));if(n.hasOwnProperty(s))return x("InvalidAttr","Attribute '"+s+"' is repeated.",E(i[t]));n[s]=1}return!0}function m(t,e){if(";"===t[++e])return-1;if("#"===t[e])return function(t,e){let i=/\d/;for("x"===t[e]&&(e++,i=/[\da-fA-F]/);e<t.length;e++){if(";"===t[e])return e;if(!t[e].match(i))break}return-1}(t,++e);let i=0;for(;e<t.length;e++,i++)if(!(t[e].match(/\w/)&&i<20)){if(";"===t[e])break;return-1}return e}function x(t,e,i){return{err:{code:t,msg:e,line:i.line||i,col:i.col}}}function N(t){return r(t)}function b(t,e){const i=t.substring(0,e).split(/\r?\n/);return{line:i.length,col:i[i.length-1].length+1}}function E(t){return t.startIndex+t[1].length}const v={preserveOrder:!1,attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,removeNSPrefix:!1,allowBooleanAttributes:!1,parseTagValue:!0,parseAttributeValue:!1,trimValues:!0,cdataPropName:!1,numberParseOptions:{hex:!0,leadingZeros:!0,eNotation:!0},tagValueProcessor:function(t,e){return e},attributeValueProcessor:function(t,e){return e},stopNodes:[],alwaysCreateTextNode:!1,isArray:()=>!1,commentPropName:!1,unpairedTags:[],processEntities:!0,htmlEntities:!1,ignoreDeclaration:!1,ignorePiTags:!1,transformTagName:!1,transformAttributeName:!1,updateTag:function(t,e,i){return t},captureMetaData:!1};let T;T="function"!=typeof Symbol?"@@xmlMetadata":Symbol("XML Node Metadata");class y{constructor(t){this.tagname=t,this.child=[],this[":@"]={}}add(t,e){"__proto__"===t&&(t="#__proto__"),this.child.push({[t]:e})}addChild(t,e){"__proto__"===t.tagname&&(t.tagname="#__proto__"),t[":@"]&&Object.keys(t[":@"]).length>0?this.child.push({[t.tagname]:t.child,":@":t[":@"]}):this.child.push({[t.tagname]:t.child}),void 0!==e&&(this.child[this.child.length-1][T]={startIndex:e})}static getMetaDataSymbol(){return T}}class w{constructor(t){this.suppressValidationErr=!t}readDocType(t,e){const i={};if("O"!==t[e+3]||"C"!==t[e+4]||"T"!==t[e+5]||"Y"!==t[e+6]||"P"!==t[e+7]||"E"!==t[e+8])throw new Error("Invalid Tag instead of DOCTYPE");{e+=9;let n=1,s=!1,r=!1,o="";for(;e<t.length;e++)if("<"!==t[e]||r)if(">"===t[e]){if(r?"-"===t[e-1]&&"-"===t[e-2]&&(r=!1,n--):n--,0===n)break}else"["===t[e]?s=!0:o+=t[e];else{if(s&&P(t,"!ENTITY",e)){let n,s;e+=7,[n,s,e]=this.readEntityExp(t,e+1,this.suppressValidationErr),-1===s.indexOf("&")&&(i[n]={regx:RegExp(`&${n};`,"g"),val:s})}else if(s&&P(t,"!ELEMENT",e)){e+=8;const{index:i}=this.readElementExp(t,e+1);e=i}else if(s&&P(t,"!ATTLIST",e))e+=8;else if(s&&P(t,"!NOTATION",e)){e+=9;const{index:i}=this.readNotationExp(t,e+1,this.suppressValidationErr);e=i}else{if(!P(t,"!--",e))throw new Error("Invalid DOCTYPE");r=!0}n++,o=""}if(0!==n)throw new Error("Unclosed DOCTYPE")}return{entities:i,i:e}}readEntityExp(t,e){e=I(t,e);let i="";for(;e<t.length&&!/\s/.test(t[e])&&'"'!==t[e]&&"'"!==t[e];)i+=t[e],e++;if(O(i),e=I(t,e),!this.suppressValidationErr){if("SYSTEM"===t.substring(e,e+6).toUpperCase())throw new Error("External entities are not supported");if("%"===t[e])throw new Error("Parameter entities are not supported")}let n="";return[e,n]=this.readIdentifierVal(t,e,"entity"),[i,n,--e]}readNotationExp(t,e){e=I(t,e);let i="";for(;e<t.length&&!/\s/.test(t[e]);)i+=t[e],e++;!this.suppressValidationErr&&O(i),e=I(t,e);const n=t.substring(e,e+6).toUpperCase();if(!this.suppressValidationErr&&"SYSTEM"!==n&&"PUBLIC"!==n)throw new Error(`Expected SYSTEM or PUBLIC, found "${n}"`);e+=n.length,e=I(t,e);let s=null,r=null;if("PUBLIC"===n)[e,s]=this.readIdentifierVal(t,e,"publicIdentifier"),'"'!==t[e=I(t,e)]&&"'"!==t[e]||([e,r]=this.readIdentifierVal(t,e,"systemIdentifier"));else if("SYSTEM"===n&&([e,r]=this.readIdentifierVal(t,e,"systemIdentifier"),!this.suppressValidationErr&&!r))throw new Error("Missing mandatory system identifier for SYSTEM notation");return{notationName:i,publicIdentifier:s,systemIdentifier:r,index:--e}}readIdentifierVal(t,e,i){let n="";const s=t[e];if('"'!==s&&"'"!==s)throw new Error(`Expected quoted string, found "${s}"`);for(e++;e<t.length&&t[e]!==s;)n+=t[e],e++;if(t[e]!==s)throw new Error(`Unterminated ${i} value`);return[++e,n]}readElementExp(t,e){e=I(t,e);let i="";for(;e<t.length&&!/\s/.test(t[e]);)i+=t[e],e++;if(!this.suppressValidationErr&&!r(i))throw new Error(`Invalid element name: "${i}"`);let n="";if("E"===t[e=I(t,e)]&&P(t,"MPTY",e))e+=4;else if("A"===t[e]&&P(t,"NY",e))e+=2;else if("("===t[e]){for(e++;e<t.length&&")"!==t[e];)n+=t[e],e++;if(")"!==t[e])throw new Error("Unterminated content model")}else if(!this.suppressValidationErr)throw new Error(`Invalid Element Expression, found "${t[e]}"`);return{elementName:i,contentModel:n.trim(),index:e}}readAttlistExp(t,e){e=I(t,e);let i="";for(;e<t.length&&!/\s/.test(t[e]);)i+=t[e],e++;O(i),e=I(t,e);let n="";for(;e<t.length&&!/\s/.test(t[e]);)n+=t[e],e++;if(!O(n))throw new Error(`Invalid attribute name: "${n}"`);e=I(t,e);let s="";if("NOTATION"===t.substring(e,e+8).toUpperCase()){if(s="NOTATION","("!==t[e=I(t,e+=8)])throw new Error(`Expected '(', found "${t[e]}"`);e++;let i=[];for(;e<t.length&&")"!==t[e];){let n="";for(;e<t.length&&"|"!==t[e]&&")"!==t[e];)n+=t[e],e++;if(n=n.trim(),!O(n))throw new Error(`Invalid notation name: "${n}"`);i.push(n),"|"===t[e]&&(e++,e=I(t,e))}if(")"!==t[e])throw new Error("Unterminated list of notations");e++,s+=" ("+i.join("|")+")"}else{for(;e<t.length&&!/\s/.test(t[e]);)s+=t[e],e++;const i=["CDATA","ID","IDREF","IDREFS","ENTITY","ENTITIES","NMTOKEN","NMTOKENS"];if(!this.suppressValidationErr&&!i.includes(s.toUpperCase()))throw new Error(`Invalid attribute type: "${s}"`)}e=I(t,e);let r="";return"#REQUIRED"===t.substring(e,e+8).toUpperCase()?(r="#REQUIRED",e+=8):"#IMPLIED"===t.substring(e,e+7).toUpperCase()?(r="#IMPLIED",e+=7):[e,r]=this.readIdentifierVal(t,e,"ATTLIST"),{elementName:i,attributeName:n,attributeType:s,defaultValue:r,index:e}}}const I=(t,e)=>{for(;e<t.length&&/\s/.test(t[e]);)e++;return e};function P(t,e,i){for(let n=0;n<e.length;n++)if(e[n]!==t[i+n+1])return!1;return!0}function O(t){if(r(t))return t;throw new Error(`Invalid entity name ${t}`)}const A=/^[-+]?0x[a-fA-F0-9]+$/,S=/^([\-\+])?(0*)([0-9]*(\.[0-9]*)?)$/,C={hex:!0,leadingZeros:!0,decimalPoint:".",eNotation:!0};const V=/^([-+])?(0*)(\d*(\.\d*)?[eE][-\+]?\d+)$/;function $(t){return"function"==typeof t?t:Array.isArray(t)?e=>{for(const i of t){if("string"==typeof i&&e===i)return!0;if(i instanceof RegExp&&i.test(e))return!0}}:()=>!1}class D{constructor(t){if(this.options=t,this.currentNode=null,this.tagsNodeStack=[],this.docTypeEntities={},this.lastEntities={apos:{regex:/&(apos|#39|#x27);/g,val:"'"},gt:{regex:/&(gt|#62|#x3E);/g,val:">"},lt:{regex:/&(lt|#60|#x3C);/g,val:"<"},quot:{regex:/&(quot|#34|#x22);/g,val:'"'}},this.ampEntity={regex:/&(amp|#38|#x26);/g,val:"&"},this.htmlEntities={space:{regex:/&(nbsp|#160);/g,val:" "},cent:{regex:/&(cent|#162);/g,val:"¢"},pound:{regex:/&(pound|#163);/g,val:"£"},yen:{regex:/&(yen|#165);/g,val:"¥"},euro:{regex:/&(euro|#8364);/g,val:"€"},copyright:{regex:/&(copy|#169);/g,val:"©"},reg:{regex:/&(reg|#174);/g,val:"®"},inr:{regex:/&(inr|#8377);/g,val:"₹"},num_dec:{regex:/&#([0-9]{1,7});/g,val:(t,e)=>String.fromCodePoint(Number.parseInt(e,10))},num_hex:{regex:/&#x([0-9a-fA-F]{1,6});/g,val:(t,e)=>String.fromCodePoint(Number.parseInt(e,16))}},this.addExternalEntities=j,this.parseXml=L,this.parseTextData=M,this.resolveNameSpace=F,this.buildAttributesMap=k,this.isItStopNode=Y,this.replaceEntitiesValue=B,this.readStopNodeData=W,this.saveTextToParentTag=R,this.addChild=U,this.ignoreAttributesFn=$(this.options.ignoreAttributes),this.options.stopNodes&&this.options.stopNodes.length>0){this.stopNodesExact=new Set,this.stopNodesWildcard=new Set;for(let t=0;t<this.options.stopNodes.length;t++){const e=this.options.stopNodes[t];"string"==typeof e&&(e.startsWith("*.")?this.stopNodesWildcard.add(e.substring(2)):this.stopNodesExact.add(e))}}}}function j(t){const e=Object.keys(t);for(let i=0;i<e.length;i++){const n=e[i];this.lastEntities[n]={regex:new RegExp("&"+n+";","g"),val:t[n]}}}function M(t,e,i,n,s,r,o){if(void 0!==t&&(this.options.trimValues&&!n&&(t=t.trim()),t.length>0)){o||(t=this.replaceEntitiesValue(t));const n=this.options.tagValueProcessor(e,t,i,s,r);return null==n?t:typeof n!=typeof t||n!==t?n:this.options.trimValues||t.trim()===t?q(t,this.options.parseTagValue,this.options.numberParseOptions):t}}function F(t){if(this.options.removeNSPrefix){const e=t.split(":"),i="/"===t.charAt(0)?"/":"";if("xmlns"===e[0])return"";2===e.length&&(t=i+e[1])}return t}const _=new RegExp("([^\\s=]+)\\s*(=\\s*(['\"])([\\s\\S]*?)\\3)?","gm");function k(t,e){if(!0!==this.options.ignoreAttributes&&"string"==typeof t){const i=s(t,_),n=i.length,r={};for(let t=0;t<n;t++){const n=this.resolveNameSpace(i[t][1]);if(this.ignoreAttributesFn(n,e))continue;let s=i[t][4],o=this.options.attributeNamePrefix+n;if(n.length)if(this.options.transformAttributeName&&(o=this.options.transformAttributeName(o)),"__proto__"===o&&(o="#__proto__"),void 0!==s){this.options.trimValues&&(s=s.trim()),s=this.replaceEntitiesValue(s);const t=this.options.attributeValueProcessor(n,s,e);r[o]=null==t?s:typeof t!=typeof s||t!==s?t:q(s,this.options.parseAttributeValue,this.options.numberParseOptions)}else this.options.allowBooleanAttributes&&(r[o]=!0)}if(!Object.keys(r).length)return;if(this.options.attributesGroupName){const t={};return t[this.options.attributesGroupName]=r,t}return r}}const L=function(t){t=t.replace(/\r\n?/g,"\n");const e=new y("!xml");let i=e,n="",s="";const r=new w(this.options.processEntities);for(let o=0;o<t.length;o++)if("<"===t[o])if("/"===t[o+1]){const e=G(t,">",o,"Closing Tag is not closed.");let r=t.substring(o+2,e).trim();if(this.options.removeNSPrefix){const t=r.indexOf(":");-1!==t&&(r=r.substr(t+1))}this.options.transformTagName&&(r=this.options.transformTagName(r)),i&&(n=this.saveTextToParentTag(n,i,s));const a=s.substring(s.lastIndexOf(".")+1);if(r&&-1!==this.options.unpairedTags.indexOf(r))throw new Error(`Unpaired tag can not be used as closing tag: </${r}>`);let l=0;a&&-1!==this.options.unpairedTags.indexOf(a)?(l=s.lastIndexOf(".",s.lastIndexOf(".")-1),this.tagsNodeStack.pop()):l=s.lastIndexOf("."),s=s.substring(0,l),i=this.tagsNodeStack.pop(),n="",o=e}else if("?"===t[o+1]){let e=X(t,o,!1,"?>");if(!e)throw new Error("Pi Tag is not closed.");if(n=this.saveTextToParentTag(n,i,s),this.options.ignoreDeclaration&&"?xml"===e.tagName||this.options.ignorePiTags);else{const t=new y(e.tagName);t.add(this.options.textNodeName,""),e.tagName!==e.tagExp&&e.attrExpPresent&&(t[":@"]=this.buildAttributesMap(e.tagExp,s)),this.addChild(i,t,s,o)}o=e.closeIndex+1}else if("!--"===t.substr(o+1,3)){const e=G(t,"--\x3e",o+4,"Comment is not closed.");if(this.options.commentPropName){const r=t.substring(o+4,e-2);n=this.saveTextToParentTag(n,i,s),i.add(this.options.commentPropName,[{[this.options.textNodeName]:r}])}o=e}else if("!D"===t.substr(o+1,2)){const e=r.readDocType(t,o);this.docTypeEntities=e.entities,o=e.i}else if("!["===t.substr(o+1,2)){const e=G(t,"]]>",o,"CDATA is not closed.")-2,r=t.substring(o+9,e);n=this.saveTextToParentTag(n,i,s);let a=this.parseTextData(r,i.tagname,s,!0,!1,!0,!0);null==a&&(a=""),this.options.cdataPropName?i.add(this.options.cdataPropName,[{[this.options.textNodeName]:r}]):i.add(this.options.textNodeName,a),o=e+2}else{let r=X(t,o,this.options.removeNSPrefix),a=r.tagName;const l=r.rawTagName;let u=r.tagExp,h=r.attrExpPresent,d=r.closeIndex;if(this.options.transformTagName){const t=this.options.transformTagName(a);u===a&&(u=t),a=t}i&&n&&"!xml"!==i.tagname&&(n=this.saveTextToParentTag(n,i,s,!1));const p=i;p&&-1!==this.options.unpairedTags.indexOf(p.tagname)&&(i=this.tagsNodeStack.pop(),s=s.substring(0,s.lastIndexOf("."))),a!==e.tagname&&(s+=s?"."+a:a);const f=o;if(this.isItStopNode(this.stopNodesExact,this.stopNodesWildcard,s,a)){let e="";if(u.length>0&&u.lastIndexOf("/")===u.length-1)"/"===a[a.length-1]?(a=a.substr(0,a.length-1),s=s.substr(0,s.length-1),u=a):u=u.substr(0,u.length-1),o=r.closeIndex;else if(-1!==this.options.unpairedTags.indexOf(a))o=r.closeIndex;else{const i=this.readStopNodeData(t,l,d+1);if(!i)throw new Error(`Unexpected end of ${l}`);o=i.i,e=i.tagContent}const n=new y(a);a!==u&&h&&(n[":@"]=this.buildAttributesMap(u,s)),e&&(e=this.parseTextData(e,a,s,!0,h,!0,!0)),s=s.substr(0,s.lastIndexOf(".")),n.add(this.options.textNodeName,e),this.addChild(i,n,s,f)}else{if(u.length>0&&u.lastIndexOf("/")===u.length-1){if("/"===a[a.length-1]?(a=a.substr(0,a.length-1),s=s.substr(0,s.length-1),u=a):u=u.substr(0,u.length-1),this.options.transformTagName){const t=this.options.transformTagName(a);u===a&&(u=t),a=t}const t=new y(a);a!==u&&h&&(t[":@"]=this.buildAttributesMap(u,s)),this.addChild(i,t,s,f),s=s.substr(0,s.lastIndexOf("."))}else{const t=new y(a);this.tagsNodeStack.push(i),a!==u&&h&&(t[":@"]=this.buildAttributesMap(u,s)),this.addChild(i,t,s,f),i=t}n="",o=d}}else n+=t[o];return e.child};function U(t,e,i,n){this.options.captureMetaData||(n=void 0);const s=this.options.updateTag(e.tagname,i,e[":@"]);!1===s||("string"==typeof s?(e.tagname=s,t.addChild(e,n)):t.addChild(e,n))}const B=function(t){if(this.options.processEntities){for(let e in this.docTypeEntities){const i=this.docTypeEntities[e];t=t.replace(i.regx,i.val)}for(let e in this.lastEntities){const i=this.lastEntities[e];t=t.replace(i.regex,i.val)}if(this.options.htmlEntities)for(let e in this.htmlEntities){const i=this.htmlEntities[e];t=t.replace(i.regex,i.val)}t=t.replace(this.ampEntity.regex,this.ampEntity.val)}return t};function R(t,e,i,n){return t&&(void 0===n&&(n=0===e.child.length),void 0!==(t=this.parseTextData(t,e.tagname,i,!1,!!e[":@"]&&0!==Object.keys(e[":@"]).length,n))&&""!==t&&e.add(this.options.textNodeName,t),t=""),t}function Y(t,e,i,n){return!(!e||!e.has(n))||!(!t||!t.has(i))}function G(t,e,i,n){const s=t.indexOf(e,i);if(-1===s)throw new Error(n);return s+e.length-1}function X(t,e,i,n=">"){const s=function(t,e,i=">"){let n,s="";for(let r=e;r<t.length;r++){let e=t[r];if(n)e===n&&(n="");else if('"'===e||"'"===e)n=e;else if(e===i[0]){if(!i[1])return{data:s,index:r};if(t[r+1]===i[1])return{data:s,index:r}}else"\t"===e&&(e=" ");s+=e}}(t,e+1,n);if(!s)return;let r=s.data;const o=s.index,a=r.search(/\s/);let l=r,u=!0;-1!==a&&(l=r.substring(0,a),r=r.substring(a+1).trimStart());const h=l;if(i){const t=l.indexOf(":");-1!==t&&(l=l.substr(t+1),u=l!==s.data.substr(t+1))}return{tagName:l,tagExp:r,closeIndex:o,attrExpPresent:u,rawTagName:h}}function W(t,e,i){const n=i;let s=1;for(;i<t.length;i++)if("<"===t[i])if("/"===t[i+1]){const r=G(t,">",i,`${e} is not closed`);if(t.substring(i+2,r).trim()===e&&(s--,0===s))return{tagContent:t.substring(n,i),i:r};i=r}else if("?"===t[i+1])i=G(t,"?>",i+1,"StopNode is not closed.");else if("!--"===t.substr(i+1,3))i=G(t,"--\x3e",i+3,"StopNode is not closed.");else if("!["===t.substr(i+1,2))i=G(t,"]]>",i,"StopNode is not closed.")-2;else{const n=X(t,i,">");n&&((n&&n.tagName)===e&&"/"!==n.tagExp[n.tagExp.length-1]&&s++,i=n.closeIndex)}}function q(t,e,i){if(e&&"string"==typeof t){const e=t.trim();return"true"===e||"false"!==e&&function(t,e={}){if(e=Object.assign({},C,e),!t||"string"!=typeof t)return t;let i=t.trim();if(void 0!==e.skipLike&&e.skipLike.test(i))return t;if("0"===t)return 0;if(e.hex&&A.test(i))return function(t){if(parseInt)return parseInt(t,16);if(Number.parseInt)return Number.parseInt(t,16);if(window&&window.parseInt)return window.parseInt(t,16);throw new Error("parseInt, Number.parseInt, window.parseInt are not supported")}(i);if(-1!==i.search(/.+[eE].+/))return function(t,e,i){if(!i.eNotation)return t;const n=e.match(V);if(n){let s=n[1]||"";const r=-1===n[3].indexOf("e")?"E":"e",o=n[2],a=s?t[o.length+1]===r:t[o.length]===r;return o.length>1&&a?t:1!==o.length||!n[3].startsWith(`.${r}`)&&n[3][0]!==r?i.leadingZeros&&!a?(e=(n[1]||"")+n[3],Number(e)):t:Number(e)}return t}(t,i,e);{const s=S.exec(i);if(s){const r=s[1]||"",o=s[2];let a=(n=s[3])&&-1!==n.indexOf(".")?("."===(n=n.replace(/0+$/,""))?n="0":"."===n[0]?n="0"+n:"."===n[n.length-1]&&(n=n.substring(0,n.length-1)),n):n;const l=r?"."===t[o.length+1]:"."===t[o.length];if(!e.leadingZeros&&(o.length>1||1===o.length&&!l))return t;{const n=Number(i),s=String(n);if(0===n||-0===n)return n;if(-1!==s.search(/[eE]/))return e.eNotation?n:t;if(-1!==i.indexOf("."))return"0"===s||s===a||s===`${r}${a}`?n:t;let l=o?a:i;return o?l===s||r+l===s?n:t:l===s||l===r+s?n:t}}return t}var n}(t,i)}return void 0!==t?t:""}const Z=y.getMetaDataSymbol();function K(t,e){return Q(t,e)}function Q(t,e,i){let n;const s={};for(let r=0;r<t.length;r++){const o=t[r],a=z(o);let l="";if(l=void 0===i?a:i+"."+a,a===e.textNodeName)void 0===n?n=o[a]:n+=""+o[a];else{if(void 0===a)continue;if(o[a]){let t=Q(o[a],e,l);const i=H(t,e);void 0!==o[Z]&&(t[Z]=o[Z]),o[":@"]?J(t,o[":@"],l,e):1!==Object.keys(t).length||void 0===t[e.textNodeName]||e.alwaysCreateTextNode?0===Object.keys(t).length&&(e.alwaysCreateTextNode?t[e.textNodeName]="":t=""):t=t[e.textNodeName],void 0!==s[a]&&s.hasOwnProperty(a)?(Array.isArray(s[a])||(s[a]=[s[a]]),s[a].push(t)):e.isArray(a,l,i)?s[a]=[t]:s[a]=t}}}return"string"==typeof n?n.length>0&&(s[e.textNodeName]=n):void 0!==n&&(s[e.textNodeName]=n),s}function z(t){const e=Object.keys(t);for(let t=0;t<e.length;t++){const i=e[t];if(":@"!==i)return i}}function J(t,e,i,n){if(e){const s=Object.keys(e),r=s.length;for(let o=0;o<r;o++){const r=s[o];n.isArray(r,i+"."+r,!0,!0)?t[r]=[e[r]]:t[r]=e[r]}}}function H(t,e){const{textNodeName:i}=e,n=Object.keys(t).length;return 0===n||!(1!==n||!t[i]&&"boolean"!=typeof t[i]&&0!==t[i])}class tt{constructor(t){this.externalEntities={},this.options=function(t){return Object.assign({},v,t)}(t)}parse(t,e){if("string"!=typeof t&&t.toString)t=t.toString();else if("string"!=typeof t)throw new Error("XML data is accepted in String or Bytes[] form.");if(e){!0===e&&(e={});const i=a(t,e);if(!0!==i)throw Error(`${i.err.msg}:${i.err.line}:${i.err.col}`)}const i=new D(this.options);i.addExternalEntities(this.externalEntities);const n=i.parseXml(t);return this.options.preserveOrder||void 0===n?n:K(n,this.options)}addEntity(t,e){if(-1!==e.indexOf("&"))throw new Error("Entity value can't have '&'");if(-1!==t.indexOf("&")||-1!==t.indexOf(";"))throw new Error("An entity must be set without '&' and ';'. Eg. use '#xD' for '
'");if("&"===e)throw new Error("An entity with value '&' is not permitted");this.externalEntities[t]=e}static getMetaDataSymbol(){return y.getMetaDataSymbol()}}function et(t,e){let i="";return e.format&&e.indentBy.length>0&&(i="\n"),it(t,e,"",i)}function it(t,e,i,n){let s="",r=!1;for(let o=0;o<t.length;o++){const a=t[o],l=nt(a);if(void 0===l)continue;let u="";if(u=0===i.length?l:`${i}.${l}`,l===e.textNodeName){let t=a[l];rt(u,e)||(t=e.tagValueProcessor(l,t),t=ot(t,e)),r&&(s+=n),s+=t,r=!1;continue}if(l===e.cdataPropName){r&&(s+=n),s+=`<![CDATA[${a[l][0][e.textNodeName]}]]>`,r=!1;continue}if(l===e.commentPropName){s+=n+`\x3c!--${a[l][0][e.textNodeName]}--\x3e`,r=!0;continue}if("?"===l[0]){const t=st(a[":@"],e),i="?xml"===l?"":n;let o=a[l][0][e.textNodeName];o=0!==o.length?" "+o:"",s+=i+`<${l}${o}${t}?>`,r=!0;continue}let h=n;""!==h&&(h+=e.indentBy);const d=n+`<${l}${st(a[":@"],e)}`,p=it(a[l],e,u,h);-1!==e.unpairedTags.indexOf(l)?e.suppressUnpairedNode?s+=d+">":s+=d+"/>":p&&0!==p.length||!e.suppressEmptyNode?p&&p.endsWith(">")?s+=d+`>${p}${n}</${l}>`:(s+=d+">",p&&""!==n&&(p.includes("/>")||p.includes("</"))?s+=n+e.indentBy+p+n:s+=p,s+=`</${l}>`):s+=d+"/>",r=!0}return s}function nt(t){const e=Object.keys(t);for(let i=0;i<e.length;i++){const n=e[i];if(t.hasOwnProperty(n)&&":@"!==n)return n}}function st(t,e){let i="";if(t&&!e.ignoreAttributes)for(let n in t){if(!t.hasOwnProperty(n))continue;let s=e.attributeValueProcessor(n,t[n]);s=ot(s,e),!0===s&&e.suppressBooleanAttributes?i+=` ${n.substr(e.attributeNamePrefix.length)}`:i+=` ${n.substr(e.attributeNamePrefix.length)}="${s}"`}return i}function rt(t,e){let i=(t=t.substr(0,t.length-e.textNodeName.length-1)).substr(t.lastIndexOf(".")+1);for(let n in e.stopNodes)if(e.stopNodes[n]===t||e.stopNodes[n]==="*."+i)return!0;return!1}function ot(t,e){if(t&&t.length>0&&e.processEntities)for(let i=0;i<e.entities.length;i++){const n=e.entities[i];t=t.replace(n.regex,n.val)}return t}const at={attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,cdataPropName:!1,format:!1,indentBy:" ",suppressEmptyNode:!1,suppressUnpairedNode:!0,suppressBooleanAttributes:!0,tagValueProcessor:function(t,e){return e},attributeValueProcessor:function(t,e){return e},preserveOrder:!1,commentPropName:!1,unpairedTags:[],entities:[{regex:new RegExp("&","g"),val:"&"},{regex:new RegExp(">","g"),val:">"},{regex:new RegExp("<","g"),val:"<"},{regex:new RegExp("'","g"),val:"'"},{regex:new RegExp('"',"g"),val:"""}],processEntities:!0,stopNodes:[],oneListGroup:!1};function lt(t){this.options=Object.assign({},at,t),!0===this.options.ignoreAttributes||this.options.attributesGroupName?this.isAttribute=function(){return!1}:(this.ignoreAttributesFn=$(this.options.ignoreAttributes),this.attrPrefixLen=this.options.attributeNamePrefix.length,this.isAttribute=dt),this.processTextOrObjNode=ut,this.options.format?(this.indentate=ht,this.tagEndChar=">\n",this.newLine="\n"):(this.indentate=function(){return""},this.tagEndChar=">",this.newLine="")}function ut(t,e,i,n){const s=this.j2x(t,i+1,n.concat(e));return void 0!==t[this.options.textNodeName]&&1===Object.keys(t).length?this.buildTextValNode(t[this.options.textNodeName],e,s.attrStr,i):this.buildObjectNode(s.val,e,s.attrStr,i)}function ht(t){return this.options.indentBy.repeat(t)}function dt(t){return!(!t.startsWith(this.options.attributeNamePrefix)||t===this.options.textNodeName)&&t.substr(this.attrPrefixLen)}lt.prototype.build=function(t){return this.options.preserveOrder?et(t,this.options):(Array.isArray(t)&&this.options.arrayNodeName&&this.options.arrayNodeName.length>1&&(t={[this.options.arrayNodeName]:t}),this.j2x(t,0,[]).val)},lt.prototype.j2x=function(t,e,i){let n="",s="";const r=i.join(".");for(let o in t)if(Object.prototype.hasOwnProperty.call(t,o))if(void 0===t[o])this.isAttribute(o)&&(s+="");else if(null===t[o])this.isAttribute(o)||o===this.options.cdataPropName?s+="":"?"===o[0]?s+=this.indentate(e)+"<"+o+"?"+this.tagEndChar:s+=this.indentate(e)+"<"+o+"/"+this.tagEndChar;else if(t[o]instanceof Date)s+=this.buildTextValNode(t[o],o,"",e);else if("object"!=typeof t[o]){const i=this.isAttribute(o);if(i&&!this.ignoreAttributesFn(i,r))n+=this.buildAttrPairStr(i,""+t[o]);else if(!i)if(o===this.options.textNodeName){let e=this.options.tagValueProcessor(o,""+t[o]);s+=this.replaceEntitiesValue(e)}else s+=this.buildTextValNode(t[o],o,"",e)}else if(Array.isArray(t[o])){const n=t[o].length;let r="",a="";for(let l=0;l<n;l++){const n=t[o][l];if(void 0===n);else if(null===n)"?"===o[0]?s+=this.indentate(e)+"<"+o+"?"+this.tagEndChar:s+=this.indentate(e)+"<"+o+"/"+this.tagEndChar;else if("object"==typeof n)if(this.options.oneListGroup){const t=this.j2x(n,e+1,i.concat(o));r+=t.val,this.options.attributesGroupName&&n.hasOwnProperty(this.options.attributesGroupName)&&(a+=t.attrStr)}else r+=this.processTextOrObjNode(n,o,e,i);else if(this.options.oneListGroup){let t=this.options.tagValueProcessor(o,n);t=this.replaceEntitiesValue(t),r+=t}else r+=this.buildTextValNode(n,o,"",e)}this.options.oneListGroup&&(r=this.buildObjectNode(r,o,a,e)),s+=r}else if(this.options.attributesGroupName&&o===this.options.attributesGroupName){const e=Object.keys(t[o]),i=e.length;for(let s=0;s<i;s++)n+=this.buildAttrPairStr(e[s],""+t[o][e[s]])}else s+=this.processTextOrObjNode(t[o],o,e,i);return{attrStr:n,val:s}},lt.prototype.buildAttrPairStr=function(t,e){return e=this.options.attributeValueProcessor(t,""+e),e=this.replaceEntitiesValue(e),this.options.suppressBooleanAttributes&&"true"===e?" "+t:" "+t+'="'+e+'"'},lt.prototype.buildObjectNode=function(t,e,i,n){if(""===t)return"?"===e[0]?this.indentate(n)+"<"+e+i+"?"+this.tagEndChar:this.indentate(n)+"<"+e+i+this.closeTag(e)+this.tagEndChar;{let s="</"+e+this.tagEndChar,r="";return"?"===e[0]&&(r="?",s=""),!i&&""!==i||-1!==t.indexOf("<")?!1!==this.options.commentPropName&&e===this.options.commentPropName&&0===r.length?this.indentate(n)+`\x3c!--${t}--\x3e`+this.newLine:this.indentate(n)+"<"+e+i+r+this.tagEndChar+t+this.indentate(n)+s:this.indentate(n)+"<"+e+i+r+">"+t+s}},lt.prototype.closeTag=function(t){let e="";return-1!==this.options.unpairedTags.indexOf(t)?this.options.suppressUnpairedNode||(e="/"):e=this.options.suppressEmptyNode?"/":`></${t}`,e},lt.prototype.buildTextValNode=function(t,e,i,n){if(!1!==this.options.cdataPropName&&e===this.options.cdataPropName)return this.indentate(n)+`<![CDATA[${t}]]>`+this.newLine;if(!1!==this.options.commentPropName&&e===this.options.commentPropName)return this.indentate(n)+`\x3c!--${t}--\x3e`+this.newLine;if("?"===e[0])return this.indentate(n)+"<"+e+i+"?"+this.tagEndChar;{let s=this.options.tagValueProcessor(e,t);return s=this.replaceEntitiesValue(s),""===s?this.indentate(n)+"<"+e+i+this.closeTag(e)+this.tagEndChar:this.indentate(n)+"<"+e+i+">"+s+"</"+e+this.tagEndChar}},lt.prototype.replaceEntitiesValue=function(t){if(t&&t.length>0&&this.options.processEntities)for(let e=0;e<this.options.entities.length;e++){const i=this.options.entities[e];t=t.replace(i.regex,i.val)}return t};const pt={validate:a};module.exports=e})();
|
|
99762
|
+
(()=>{"use strict";var t={d:(e,n)=>{for(var i in n)t.o(n,i)&&!t.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:n[i]})},o:(t,e)=>Object.prototype.hasOwnProperty.call(t,e),r:t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})}},e={};t.r(e),t.d(e,{XMLBuilder:()=>dt,XMLParser:()=>it,XMLValidator:()=>gt});const n=":A-Za-z_\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD",i=new RegExp("^["+n+"]["+n+"\\-.\\d\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$");function s(t,e){const n=[];let i=e.exec(t);for(;i;){const s=[];s.startIndex=e.lastIndex-i[0].length;const r=i.length;for(let t=0;t<r;t++)s.push(i[t]);n.push(s),i=e.exec(t)}return n}const r=function(t){return!(null==i.exec(t))},o={allowBooleanAttributes:!1,unpairedTags:[]};function a(t,e){e=Object.assign({},o,e);const n=[];let i=!1,s=!1;"\ufeff"===t[0]&&(t=t.substr(1));for(let o=0;o<t.length;o++)if("<"===t[o]&&"?"===t[o+1]){if(o+=2,o=u(t,o),o.err)return o}else{if("<"!==t[o]){if(l(t[o]))continue;return m("InvalidChar","char '"+t[o]+"' is not expected.",b(t,o))}{let a=o;if(o++,"!"===t[o]){o=h(t,o);continue}{let d=!1;"/"===t[o]&&(d=!0,o++);let p="";for(;o<t.length&&">"!==t[o]&&" "!==t[o]&&"\t"!==t[o]&&"\n"!==t[o]&&"\r"!==t[o];o++)p+=t[o];if(p=p.trim(),"/"===p[p.length-1]&&(p=p.substring(0,p.length-1),o--),!r(p)){let e;return e=0===p.trim().length?"Invalid space after '<'.":"Tag '"+p+"' is an invalid name.",m("InvalidTag",e,b(t,o))}const c=f(t,o);if(!1===c)return m("InvalidAttr","Attributes for '"+p+"' have open quote.",b(t,o));let E=c.value;if(o=c.index,"/"===E[E.length-1]){const n=o-E.length;E=E.substring(0,E.length-1);const s=g(E,e);if(!0!==s)return m(s.err.code,s.err.msg,b(t,n+s.err.line));i=!0}else if(d){if(!c.tagClosed)return m("InvalidTag","Closing tag '"+p+"' doesn't have proper closing.",b(t,o));if(E.trim().length>0)return m("InvalidTag","Closing tag '"+p+"' can't have attributes or invalid starting.",b(t,a));if(0===n.length)return m("InvalidTag","Closing tag '"+p+"' has not been opened.",b(t,a));{const e=n.pop();if(p!==e.tagName){let n=b(t,e.tagStartPos);return m("InvalidTag","Expected closing tag '"+e.tagName+"' (opened in line "+n.line+", col "+n.col+") instead of closing tag '"+p+"'.",b(t,a))}0==n.length&&(s=!0)}}else{const r=g(E,e);if(!0!==r)return m(r.err.code,r.err.msg,b(t,o-E.length+r.err.line));if(!0===s)return m("InvalidXml","Multiple possible root nodes found.",b(t,o));-1!==e.unpairedTags.indexOf(p)||n.push({tagName:p,tagStartPos:a}),i=!0}for(o++;o<t.length;o++)if("<"===t[o]){if("!"===t[o+1]){o++,o=h(t,o);continue}if("?"!==t[o+1])break;if(o=u(t,++o),o.err)return o}else if("&"===t[o]){const e=x(t,o);if(-1==e)return m("InvalidChar","char '&' is not expected.",b(t,o));o=e}else if(!0===s&&!l(t[o]))return m("InvalidXml","Extra text at the end",b(t,o));"<"===t[o]&&o--}}}return i?1==n.length?m("InvalidTag","Unclosed tag '"+n[0].tagName+"'.",b(t,n[0].tagStartPos)):!(n.length>0)||m("InvalidXml","Invalid '"+JSON.stringify(n.map((t=>t.tagName)),null,4).replace(/\r?\n/g,"")+"' found.",{line:1,col:1}):m("InvalidXml","Start tag expected.",1)}function l(t){return" "===t||"\t"===t||"\n"===t||"\r"===t}function u(t,e){const n=e;for(;e<t.length;e++)if("?"!=t[e]&&" "!=t[e]);else{const i=t.substr(n,e-n);if(e>5&&"xml"===i)return m("InvalidXml","XML declaration allowed only at the start of the document.",b(t,e));if("?"==t[e]&&">"==t[e+1]){e++;break}}return e}function h(t,e){if(t.length>e+5&&"-"===t[e+1]&&"-"===t[e+2]){for(e+=3;e<t.length;e++)if("-"===t[e]&&"-"===t[e+1]&&">"===t[e+2]){e+=2;break}}else if(t.length>e+8&&"D"===t[e+1]&&"O"===t[e+2]&&"C"===t[e+3]&&"T"===t[e+4]&&"Y"===t[e+5]&&"P"===t[e+6]&&"E"===t[e+7]){let n=1;for(e+=8;e<t.length;e++)if("<"===t[e])n++;else if(">"===t[e]&&(n--,0===n))break}else if(t.length>e+9&&"["===t[e+1]&&"C"===t[e+2]&&"D"===t[e+3]&&"A"===t[e+4]&&"T"===t[e+5]&&"A"===t[e+6]&&"["===t[e+7])for(e+=8;e<t.length;e++)if("]"===t[e]&&"]"===t[e+1]&&">"===t[e+2]){e+=2;break}return e}const d='"',p="'";function f(t,e){let n="",i="",s=!1;for(;e<t.length;e++){if(t[e]===d||t[e]===p)""===i?i=t[e]:i!==t[e]||(i="");else if(">"===t[e]&&""===i){s=!0;break}n+=t[e]}return""===i&&{value:n,index:e,tagClosed:s}}const c=new RegExp("(\\s*)([^\\s=]+)(\\s*=)?(\\s*(['\"])(([\\s\\S])*?)\\5)?","g");function g(t,e){const n=s(t,c),i={};for(let t=0;t<n.length;t++){if(0===n[t][1].length)return m("InvalidAttr","Attribute '"+n[t][2]+"' has no space in starting.",N(n[t]));if(void 0!==n[t][3]&&void 0===n[t][4])return m("InvalidAttr","Attribute '"+n[t][2]+"' is without value.",N(n[t]));if(void 0===n[t][3]&&!e.allowBooleanAttributes)return m("InvalidAttr","boolean attribute '"+n[t][2]+"' is not allowed.",N(n[t]));const s=n[t][2];if(!E(s))return m("InvalidAttr","Attribute '"+s+"' is an invalid name.",N(n[t]));if(i.hasOwnProperty(s))return m("InvalidAttr","Attribute '"+s+"' is repeated.",N(n[t]));i[s]=1}return!0}function x(t,e){if(";"===t[++e])return-1;if("#"===t[e])return function(t,e){let n=/\d/;for("x"===t[e]&&(e++,n=/[\da-fA-F]/);e<t.length;e++){if(";"===t[e])return e;if(!t[e].match(n))break}return-1}(t,++e);let n=0;for(;e<t.length;e++,n++)if(!(t[e].match(/\w/)&&n<20)){if(";"===t[e])break;return-1}return e}function m(t,e,n){return{err:{code:t,msg:e,line:n.line||n,col:n.col}}}function E(t){return r(t)}function b(t,e){const n=t.substring(0,e).split(/\r?\n/);return{line:n.length,col:n[n.length-1].length+1}}function N(t){return t.startIndex+t[1].length}const y={preserveOrder:!1,attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,removeNSPrefix:!1,allowBooleanAttributes:!1,parseTagValue:!0,parseAttributeValue:!1,trimValues:!0,cdataPropName:!1,numberParseOptions:{hex:!0,leadingZeros:!0,eNotation:!0},tagValueProcessor:function(t,e){return e},attributeValueProcessor:function(t,e){return e},stopNodes:[],alwaysCreateTextNode:!1,isArray:()=>!1,commentPropName:!1,unpairedTags:[],processEntities:!0,htmlEntities:!1,ignoreDeclaration:!1,ignorePiTags:!1,transformTagName:!1,transformAttributeName:!1,updateTag:function(t,e,n){return t},captureMetaData:!1};function T(t){return"boolean"==typeof t?{enabled:t,maxEntitySize:1e4,maxExpansionDepth:10,maxTotalExpansions:1e3,maxExpandedLength:1e5,allowedTags:null,tagFilter:null}:"object"==typeof t&&null!==t?{enabled:!1!==t.enabled,maxEntitySize:t.maxEntitySize??1e4,maxExpansionDepth:t.maxExpansionDepth??10,maxTotalExpansions:t.maxTotalExpansions??1e3,maxExpandedLength:t.maxExpandedLength??1e5,allowedTags:t.allowedTags??null,tagFilter:t.tagFilter??null}:T(!0)}const w=function(t){const e=Object.assign({},y,t);return e.processEntities=T(e.processEntities),e};let v;v="function"!=typeof Symbol?"@@xmlMetadata":Symbol("XML Node Metadata");class I{constructor(t){this.tagname=t,this.child=[],this[":@"]={}}add(t,e){"__proto__"===t&&(t="#__proto__"),this.child.push({[t]:e})}addChild(t,e){"__proto__"===t.tagname&&(t.tagname="#__proto__"),t[":@"]&&Object.keys(t[":@"]).length>0?this.child.push({[t.tagname]:t.child,":@":t[":@"]}):this.child.push({[t.tagname]:t.child}),void 0!==e&&(this.child[this.child.length-1][v]={startIndex:e})}static getMetaDataSymbol(){return v}}class O{constructor(t){this.suppressValidationErr=!t,this.options=t}readDocType(t,e){const n={};if("O"!==t[e+3]||"C"!==t[e+4]||"T"!==t[e+5]||"Y"!==t[e+6]||"P"!==t[e+7]||"E"!==t[e+8])throw new Error("Invalid Tag instead of DOCTYPE");{e+=9;let i=1,s=!1,r=!1,o="";for(;e<t.length;e++)if("<"!==t[e]||r)if(">"===t[e]){if(r?"-"===t[e-1]&&"-"===t[e-2]&&(r=!1,i--):i--,0===i)break}else"["===t[e]?s=!0:o+=t[e];else{if(s&&A(t,"!ENTITY",e)){let i,s;if(e+=7,[i,s,e]=this.readEntityExp(t,e+1,this.suppressValidationErr),-1===s.indexOf("&")){const t=i.replace(/[.\-+*:]/g,"\\.");n[i]={regx:RegExp(`&${t};`,"g"),val:s}}}else if(s&&A(t,"!ELEMENT",e)){e+=8;const{index:n}=this.readElementExp(t,e+1);e=n}else if(s&&A(t,"!ATTLIST",e))e+=8;else if(s&&A(t,"!NOTATION",e)){e+=9;const{index:n}=this.readNotationExp(t,e+1,this.suppressValidationErr);e=n}else{if(!A(t,"!--",e))throw new Error("Invalid DOCTYPE");r=!0}i++,o=""}if(0!==i)throw new Error("Unclosed DOCTYPE")}return{entities:n,i:e}}readEntityExp(t,e){e=P(t,e);let n="";for(;e<t.length&&!/\s/.test(t[e])&&'"'!==t[e]&&"'"!==t[e];)n+=t[e],e++;if(S(n),e=P(t,e),!this.suppressValidationErr){if("SYSTEM"===t.substring(e,e+6).toUpperCase())throw new Error("External entities are not supported");if("%"===t[e])throw new Error("Parameter entities are not supported")}let i="";if([e,i]=this.readIdentifierVal(t,e,"entity"),!1!==this.options.enabled&&this.options.maxEntitySize&&i.length>this.options.maxEntitySize)throw new Error(`Entity "${n}" size (${i.length}) exceeds maximum allowed size (${this.options.maxEntitySize})`);return[n,i,--e]}readNotationExp(t,e){e=P(t,e);let n="";for(;e<t.length&&!/\s/.test(t[e]);)n+=t[e],e++;!this.suppressValidationErr&&S(n),e=P(t,e);const i=t.substring(e,e+6).toUpperCase();if(!this.suppressValidationErr&&"SYSTEM"!==i&&"PUBLIC"!==i)throw new Error(`Expected SYSTEM or PUBLIC, found "${i}"`);e+=i.length,e=P(t,e);let s=null,r=null;if("PUBLIC"===i)[e,s]=this.readIdentifierVal(t,e,"publicIdentifier"),'"'!==t[e=P(t,e)]&&"'"!==t[e]||([e,r]=this.readIdentifierVal(t,e,"systemIdentifier"));else if("SYSTEM"===i&&([e,r]=this.readIdentifierVal(t,e,"systemIdentifier"),!this.suppressValidationErr&&!r))throw new Error("Missing mandatory system identifier for SYSTEM notation");return{notationName:n,publicIdentifier:s,systemIdentifier:r,index:--e}}readIdentifierVal(t,e,n){let i="";const s=t[e];if('"'!==s&&"'"!==s)throw new Error(`Expected quoted string, found "${s}"`);for(e++;e<t.length&&t[e]!==s;)i+=t[e],e++;if(t[e]!==s)throw new Error(`Unterminated ${n} value`);return[++e,i]}readElementExp(t,e){e=P(t,e);let n="";for(;e<t.length&&!/\s/.test(t[e]);)n+=t[e],e++;if(!this.suppressValidationErr&&!r(n))throw new Error(`Invalid element name: "${n}"`);let i="";if("E"===t[e=P(t,e)]&&A(t,"MPTY",e))e+=4;else if("A"===t[e]&&A(t,"NY",e))e+=2;else if("("===t[e]){for(e++;e<t.length&&")"!==t[e];)i+=t[e],e++;if(")"!==t[e])throw new Error("Unterminated content model")}else if(!this.suppressValidationErr)throw new Error(`Invalid Element Expression, found "${t[e]}"`);return{elementName:n,contentModel:i.trim(),index:e}}readAttlistExp(t,e){e=P(t,e);let n="";for(;e<t.length&&!/\s/.test(t[e]);)n+=t[e],e++;S(n),e=P(t,e);let i="";for(;e<t.length&&!/\s/.test(t[e]);)i+=t[e],e++;if(!S(i))throw new Error(`Invalid attribute name: "${i}"`);e=P(t,e);let s="";if("NOTATION"===t.substring(e,e+8).toUpperCase()){if(s="NOTATION","("!==t[e=P(t,e+=8)])throw new Error(`Expected '(', found "${t[e]}"`);e++;let n=[];for(;e<t.length&&")"!==t[e];){let i="";for(;e<t.length&&"|"!==t[e]&&")"!==t[e];)i+=t[e],e++;if(i=i.trim(),!S(i))throw new Error(`Invalid notation name: "${i}"`);n.push(i),"|"===t[e]&&(e++,e=P(t,e))}if(")"!==t[e])throw new Error("Unterminated list of notations");e++,s+=" ("+n.join("|")+")"}else{for(;e<t.length&&!/\s/.test(t[e]);)s+=t[e],e++;const n=["CDATA","ID","IDREF","IDREFS","ENTITY","ENTITIES","NMTOKEN","NMTOKENS"];if(!this.suppressValidationErr&&!n.includes(s.toUpperCase()))throw new Error(`Invalid attribute type: "${s}"`)}e=P(t,e);let r="";return"#REQUIRED"===t.substring(e,e+8).toUpperCase()?(r="#REQUIRED",e+=8):"#IMPLIED"===t.substring(e,e+7).toUpperCase()?(r="#IMPLIED",e+=7):[e,r]=this.readIdentifierVal(t,e,"ATTLIST"),{elementName:n,attributeName:i,attributeType:s,defaultValue:r,index:e}}}const P=(t,e)=>{for(;e<t.length&&/\s/.test(t[e]);)e++;return e};function A(t,e,n){for(let i=0;i<e.length;i++)if(e[i]!==t[n+i+1])return!1;return!0}function S(t){if(r(t))return t;throw new Error(`Invalid entity name ${t}`)}const C=/^[-+]?0x[a-fA-F0-9]+$/,$=/^([\-\+])?(0*)([0-9]*(\.[0-9]*)?)$/,V={hex:!0,leadingZeros:!0,decimalPoint:".",eNotation:!0};const D=/^([-+])?(0*)(\d*(\.\d*)?[eE][-\+]?\d+)$/;function L(t){return"function"==typeof t?t:Array.isArray(t)?e=>{for(const n of t){if("string"==typeof n&&e===n)return!0;if(n instanceof RegExp&&n.test(e))return!0}}:()=>!1}class F{constructor(t){if(this.options=t,this.currentNode=null,this.tagsNodeStack=[],this.docTypeEntities={},this.lastEntities={apos:{regex:/&(apos|#39|#x27);/g,val:"'"},gt:{regex:/&(gt|#62|#x3E);/g,val:">"},lt:{regex:/&(lt|#60|#x3C);/g,val:"<"},quot:{regex:/&(quot|#34|#x22);/g,val:'"'}},this.ampEntity={regex:/&(amp|#38|#x26);/g,val:"&"},this.htmlEntities={space:{regex:/&(nbsp|#160);/g,val:" "},cent:{regex:/&(cent|#162);/g,val:"¢"},pound:{regex:/&(pound|#163);/g,val:"£"},yen:{regex:/&(yen|#165);/g,val:"¥"},euro:{regex:/&(euro|#8364);/g,val:"€"},copyright:{regex:/&(copy|#169);/g,val:"©"},reg:{regex:/&(reg|#174);/g,val:"®"},inr:{regex:/&(inr|#8377);/g,val:"₹"},num_dec:{regex:/&#([0-9]{1,7});/g,val:(t,e)=>K(e,10,"&#")},num_hex:{regex:/&#x([0-9a-fA-F]{1,6});/g,val:(t,e)=>K(e,16,"&#x")}},this.addExternalEntities=j,this.parseXml=B,this.parseTextData=M,this.resolveNameSpace=_,this.buildAttributesMap=U,this.isItStopNode=X,this.replaceEntitiesValue=Y,this.readStopNodeData=q,this.saveTextToParentTag=G,this.addChild=R,this.ignoreAttributesFn=L(this.options.ignoreAttributes),this.entityExpansionCount=0,this.currentExpandedLength=0,this.options.stopNodes&&this.options.stopNodes.length>0){this.stopNodesExact=new Set,this.stopNodesWildcard=new Set;for(let t=0;t<this.options.stopNodes.length;t++){const e=this.options.stopNodes[t];"string"==typeof e&&(e.startsWith("*.")?this.stopNodesWildcard.add(e.substring(2)):this.stopNodesExact.add(e))}}}}function j(t){const e=Object.keys(t);for(let n=0;n<e.length;n++){const i=e[n],s=i.replace(/[.\-+*:]/g,"\\.");this.lastEntities[i]={regex:new RegExp("&"+s+";","g"),val:t[i]}}}function M(t,e,n,i,s,r,o){if(void 0!==t&&(this.options.trimValues&&!i&&(t=t.trim()),t.length>0)){o||(t=this.replaceEntitiesValue(t,e,n));const i=this.options.tagValueProcessor(e,t,n,s,r);return null==i?t:typeof i!=typeof t||i!==t?i:this.options.trimValues||t.trim()===t?Z(t,this.options.parseTagValue,this.options.numberParseOptions):t}}function _(t){if(this.options.removeNSPrefix){const e=t.split(":"),n="/"===t.charAt(0)?"/":"";if("xmlns"===e[0])return"";2===e.length&&(t=n+e[1])}return t}const k=new RegExp("([^\\s=]+)\\s*(=\\s*(['\"])([\\s\\S]*?)\\3)?","gm");function U(t,e,n){if(!0!==this.options.ignoreAttributes&&"string"==typeof t){const i=s(t,k),r=i.length,o={};for(let t=0;t<r;t++){const s=this.resolveNameSpace(i[t][1]);if(this.ignoreAttributesFn(s,e))continue;let r=i[t][4],a=this.options.attributeNamePrefix+s;if(s.length)if(this.options.transformAttributeName&&(a=this.options.transformAttributeName(a)),"__proto__"===a&&(a="#__proto__"),void 0!==r){this.options.trimValues&&(r=r.trim()),r=this.replaceEntitiesValue(r,n,e);const t=this.options.attributeValueProcessor(s,r,e);o[a]=null==t?r:typeof t!=typeof r||t!==r?t:Z(r,this.options.parseAttributeValue,this.options.numberParseOptions)}else this.options.allowBooleanAttributes&&(o[a]=!0)}if(!Object.keys(o).length)return;if(this.options.attributesGroupName){const t={};return t[this.options.attributesGroupName]=o,t}return o}}const B=function(t){t=t.replace(/\r\n?/g,"\n");const e=new I("!xml");let n=e,i="",s="";this.entityExpansionCount=0,this.currentExpandedLength=0;const r=new O(this.options.processEntities);for(let o=0;o<t.length;o++)if("<"===t[o])if("/"===t[o+1]){const e=z(t,">",o,"Closing Tag is not closed.");let r=t.substring(o+2,e).trim();if(this.options.removeNSPrefix){const t=r.indexOf(":");-1!==t&&(r=r.substr(t+1))}this.options.transformTagName&&(r=this.options.transformTagName(r)),n&&(i=this.saveTextToParentTag(i,n,s));const a=s.substring(s.lastIndexOf(".")+1);if(r&&-1!==this.options.unpairedTags.indexOf(r))throw new Error(`Unpaired tag can not be used as closing tag: </${r}>`);let l=0;a&&-1!==this.options.unpairedTags.indexOf(a)?(l=s.lastIndexOf(".",s.lastIndexOf(".")-1),this.tagsNodeStack.pop()):l=s.lastIndexOf("."),s=s.substring(0,l),n=this.tagsNodeStack.pop(),i="",o=e}else if("?"===t[o+1]){let e=W(t,o,!1,"?>");if(!e)throw new Error("Pi Tag is not closed.");if(i=this.saveTextToParentTag(i,n,s),this.options.ignoreDeclaration&&"?xml"===e.tagName||this.options.ignorePiTags);else{const t=new I(e.tagName);t.add(this.options.textNodeName,""),e.tagName!==e.tagExp&&e.attrExpPresent&&(t[":@"]=this.buildAttributesMap(e.tagExp,s,e.tagName)),this.addChild(n,t,s,o)}o=e.closeIndex+1}else if("!--"===t.substr(o+1,3)){const e=z(t,"--\x3e",o+4,"Comment is not closed.");if(this.options.commentPropName){const r=t.substring(o+4,e-2);i=this.saveTextToParentTag(i,n,s),n.add(this.options.commentPropName,[{[this.options.textNodeName]:r}])}o=e}else if("!D"===t.substr(o+1,2)){const e=r.readDocType(t,o);this.docTypeEntities=e.entities,o=e.i}else if("!["===t.substr(o+1,2)){const e=z(t,"]]>",o,"CDATA is not closed.")-2,r=t.substring(o+9,e);i=this.saveTextToParentTag(i,n,s);let a=this.parseTextData(r,n.tagname,s,!0,!1,!0,!0);null==a&&(a=""),this.options.cdataPropName?n.add(this.options.cdataPropName,[{[this.options.textNodeName]:r}]):n.add(this.options.textNodeName,a),o=e+2}else{let r=W(t,o,this.options.removeNSPrefix),a=r.tagName;const l=r.rawTagName;let u=r.tagExp,h=r.attrExpPresent,d=r.closeIndex;if(this.options.transformTagName){const t=this.options.transformTagName(a);u===a&&(u=t),a=t}n&&i&&"!xml"!==n.tagname&&(i=this.saveTextToParentTag(i,n,s,!1));const p=n;p&&-1!==this.options.unpairedTags.indexOf(p.tagname)&&(n=this.tagsNodeStack.pop(),s=s.substring(0,s.lastIndexOf("."))),a!==e.tagname&&(s+=s?"."+a:a);const f=o;if(this.isItStopNode(this.stopNodesExact,this.stopNodesWildcard,s,a)){let e="";if(u.length>0&&u.lastIndexOf("/")===u.length-1)"/"===a[a.length-1]?(a=a.substr(0,a.length-1),s=s.substr(0,s.length-1),u=a):u=u.substr(0,u.length-1),o=r.closeIndex;else if(-1!==this.options.unpairedTags.indexOf(a))o=r.closeIndex;else{const n=this.readStopNodeData(t,l,d+1);if(!n)throw new Error(`Unexpected end of ${l}`);o=n.i,e=n.tagContent}const i=new I(a);a!==u&&h&&(i[":@"]=this.buildAttributesMap(u,s,a)),e&&(e=this.parseTextData(e,a,s,!0,h,!0,!0)),s=s.substr(0,s.lastIndexOf(".")),i.add(this.options.textNodeName,e),this.addChild(n,i,s,f)}else{if(u.length>0&&u.lastIndexOf("/")===u.length-1){if("/"===a[a.length-1]?(a=a.substr(0,a.length-1),s=s.substr(0,s.length-1),u=a):u=u.substr(0,u.length-1),this.options.transformTagName){const t=this.options.transformTagName(a);u===a&&(u=t),a=t}const t=new I(a);a!==u&&h&&(t[":@"]=this.buildAttributesMap(u,s,a)),this.addChild(n,t,s,f),s=s.substr(0,s.lastIndexOf("."))}else{const t=new I(a);this.tagsNodeStack.push(n),a!==u&&h&&(t[":@"]=this.buildAttributesMap(u,s,a)),this.addChild(n,t,s,f),n=t}i="",o=d}}else i+=t[o];return e.child};function R(t,e,n,i){this.options.captureMetaData||(i=void 0);const s=this.options.updateTag(e.tagname,n,e[":@"]);!1===s||("string"==typeof s?(e.tagname=s,t.addChild(e,i)):t.addChild(e,i))}const Y=function(t,e,n){if(-1===t.indexOf("&"))return t;const i=this.options.processEntities;if(!i.enabled)return t;if(i.allowedTags&&!i.allowedTags.includes(e))return t;if(i.tagFilter&&!i.tagFilter(e,n))return t;for(let e in this.docTypeEntities){const n=this.docTypeEntities[e],s=t.match(n.regx);if(s){if(this.entityExpansionCount+=s.length,i.maxTotalExpansions&&this.entityExpansionCount>i.maxTotalExpansions)throw new Error(`Entity expansion limit exceeded: ${this.entityExpansionCount} > ${i.maxTotalExpansions}`);const e=t.length;if(t=t.replace(n.regx,n.val),i.maxExpandedLength&&(this.currentExpandedLength+=t.length-e,this.currentExpandedLength>i.maxExpandedLength))throw new Error(`Total expanded content size exceeded: ${this.currentExpandedLength} > ${i.maxExpandedLength}`)}}if(-1===t.indexOf("&"))return t;for(let e in this.lastEntities){const n=this.lastEntities[e];t=t.replace(n.regex,n.val)}if(-1===t.indexOf("&"))return t;if(this.options.htmlEntities)for(let e in this.htmlEntities){const n=this.htmlEntities[e];t=t.replace(n.regex,n.val)}return t.replace(this.ampEntity.regex,this.ampEntity.val)};function G(t,e,n,i){return t&&(void 0===i&&(i=0===e.child.length),void 0!==(t=this.parseTextData(t,e.tagname,n,!1,!!e[":@"]&&0!==Object.keys(e[":@"]).length,i))&&""!==t&&e.add(this.options.textNodeName,t),t=""),t}function X(t,e,n,i){return!(!e||!e.has(i))||!(!t||!t.has(n))}function z(t,e,n,i){const s=t.indexOf(e,n);if(-1===s)throw new Error(i);return s+e.length-1}function W(t,e,n,i=">"){const s=function(t,e,n=">"){let i,s="";for(let r=e;r<t.length;r++){let e=t[r];if(i)e===i&&(i="");else if('"'===e||"'"===e)i=e;else if(e===n[0]){if(!n[1])return{data:s,index:r};if(t[r+1]===n[1])return{data:s,index:r}}else"\t"===e&&(e=" ");s+=e}}(t,e+1,i);if(!s)return;let r=s.data;const o=s.index,a=r.search(/\s/);let l=r,u=!0;-1!==a&&(l=r.substring(0,a),r=r.substring(a+1).trimStart());const h=l;if(n){const t=l.indexOf(":");-1!==t&&(l=l.substr(t+1),u=l!==s.data.substr(t+1))}return{tagName:l,tagExp:r,closeIndex:o,attrExpPresent:u,rawTagName:h}}function q(t,e,n){const i=n;let s=1;for(;n<t.length;n++)if("<"===t[n])if("/"===t[n+1]){const r=z(t,">",n,`${e} is not closed`);if(t.substring(n+2,r).trim()===e&&(s--,0===s))return{tagContent:t.substring(i,n),i:r};n=r}else if("?"===t[n+1])n=z(t,"?>",n+1,"StopNode is not closed.");else if("!--"===t.substr(n+1,3))n=z(t,"--\x3e",n+3,"StopNode is not closed.");else if("!["===t.substr(n+1,2))n=z(t,"]]>",n,"StopNode is not closed.")-2;else{const i=W(t,n,">");i&&((i&&i.tagName)===e&&"/"!==i.tagExp[i.tagExp.length-1]&&s++,n=i.closeIndex)}}function Z(t,e,n){if(e&&"string"==typeof t){const e=t.trim();return"true"===e||"false"!==e&&function(t,e={}){if(e=Object.assign({},V,e),!t||"string"!=typeof t)return t;let n=t.trim();if(void 0!==e.skipLike&&e.skipLike.test(n))return t;if("0"===t)return 0;if(e.hex&&C.test(n))return function(t){if(parseInt)return parseInt(t,16);if(Number.parseInt)return Number.parseInt(t,16);if(window&&window.parseInt)return window.parseInt(t,16);throw new Error("parseInt, Number.parseInt, window.parseInt are not supported")}(n);if(-1!==n.search(/.+[eE].+/))return function(t,e,n){if(!n.eNotation)return t;const i=e.match(D);if(i){let s=i[1]||"";const r=-1===i[3].indexOf("e")?"E":"e",o=i[2],a=s?t[o.length+1]===r:t[o.length]===r;return o.length>1&&a?t:1!==o.length||!i[3].startsWith(`.${r}`)&&i[3][0]!==r?n.leadingZeros&&!a?(e=(i[1]||"")+i[3],Number(e)):t:Number(e)}return t}(t,n,e);{const s=$.exec(n);if(s){const r=s[1]||"",o=s[2];let a=(i=s[3])&&-1!==i.indexOf(".")?("."===(i=i.replace(/0+$/,""))?i="0":"."===i[0]?i="0"+i:"."===i[i.length-1]&&(i=i.substring(0,i.length-1)),i):i;const l=r?"."===t[o.length+1]:"."===t[o.length];if(!e.leadingZeros&&(o.length>1||1===o.length&&!l))return t;{const i=Number(n),s=String(i);if(0===i||-0===i)return i;if(-1!==s.search(/[eE]/))return e.eNotation?i:t;if(-1!==n.indexOf("."))return"0"===s||s===a||s===`${r}${a}`?i:t;let l=o?a:n;return o?l===s||r+l===s?i:t:l===s||l===r+s?i:t}}return t}var i}(t,n)}return void 0!==t?t:""}function K(t,e,n){const i=Number.parseInt(t,e);return i>=0&&i<=1114111?String.fromCodePoint(i):n+t+";"}const Q=I.getMetaDataSymbol();function J(t,e){return H(t,e)}function H(t,e,n){let i;const s={};for(let r=0;r<t.length;r++){const o=t[r],a=tt(o);let l="";if(l=void 0===n?a:n+"."+a,a===e.textNodeName)void 0===i?i=o[a]:i+=""+o[a];else{if(void 0===a)continue;if(o[a]){let t=H(o[a],e,l);const n=nt(t,e);void 0!==o[Q]&&(t[Q]=o[Q]),o[":@"]?et(t,o[":@"],l,e):1!==Object.keys(t).length||void 0===t[e.textNodeName]||e.alwaysCreateTextNode?0===Object.keys(t).length&&(e.alwaysCreateTextNode?t[e.textNodeName]="":t=""):t=t[e.textNodeName],void 0!==s[a]&&s.hasOwnProperty(a)?(Array.isArray(s[a])||(s[a]=[s[a]]),s[a].push(t)):e.isArray(a,l,n)?s[a]=[t]:s[a]=t}}}return"string"==typeof i?i.length>0&&(s[e.textNodeName]=i):void 0!==i&&(s[e.textNodeName]=i),s}function tt(t){const e=Object.keys(t);for(let t=0;t<e.length;t++){const n=e[t];if(":@"!==n)return n}}function et(t,e,n,i){if(e){const s=Object.keys(e),r=s.length;for(let o=0;o<r;o++){const r=s[o];i.isArray(r,n+"."+r,!0,!0)?t[r]=[e[r]]:t[r]=e[r]}}}function nt(t,e){const{textNodeName:n}=e,i=Object.keys(t).length;return 0===i||!(1!==i||!t[n]&&"boolean"!=typeof t[n]&&0!==t[n])}class it{constructor(t){this.externalEntities={},this.options=w(t)}parse(t,e){if("string"!=typeof t&&t.toString)t=t.toString();else if("string"!=typeof t)throw new Error("XML data is accepted in String or Bytes[] form.");if(e){!0===e&&(e={});const n=a(t,e);if(!0!==n)throw Error(`${n.err.msg}:${n.err.line}:${n.err.col}`)}const n=new F(this.options);n.addExternalEntities(this.externalEntities);const i=n.parseXml(t);return this.options.preserveOrder||void 0===i?i:J(i,this.options)}addEntity(t,e){if(-1!==e.indexOf("&"))throw new Error("Entity value can't have '&'");if(-1!==t.indexOf("&")||-1!==t.indexOf(";"))throw new Error("An entity must be set without '&' and ';'. Eg. use '#xD' for '
'");if("&"===e)throw new Error("An entity with value '&' is not permitted");this.externalEntities[t]=e}static getMetaDataSymbol(){return I.getMetaDataSymbol()}}function st(t,e){let n="";return e.format&&e.indentBy.length>0&&(n="\n"),rt(t,e,"",n)}function rt(t,e,n,i){let s="",r=!1;for(let o=0;o<t.length;o++){const a=t[o],l=ot(a);if(void 0===l)continue;let u="";if(u=0===n.length?l:`${n}.${l}`,l===e.textNodeName){let t=a[l];lt(u,e)||(t=e.tagValueProcessor(l,t),t=ut(t,e)),r&&(s+=i),s+=t,r=!1;continue}if(l===e.cdataPropName){r&&(s+=i),s+=`<![CDATA[${a[l][0][e.textNodeName]}]]>`,r=!1;continue}if(l===e.commentPropName){s+=i+`\x3c!--${a[l][0][e.textNodeName]}--\x3e`,r=!0;continue}if("?"===l[0]){const t=at(a[":@"],e),n="?xml"===l?"":i;let o=a[l][0][e.textNodeName];o=0!==o.length?" "+o:"",s+=n+`<${l}${o}${t}?>`,r=!0;continue}let h=i;""!==h&&(h+=e.indentBy);const d=i+`<${l}${at(a[":@"],e)}`,p=rt(a[l],e,u,h);-1!==e.unpairedTags.indexOf(l)?e.suppressUnpairedNode?s+=d+">":s+=d+"/>":p&&0!==p.length||!e.suppressEmptyNode?p&&p.endsWith(">")?s+=d+`>${p}${i}</${l}>`:(s+=d+">",p&&""!==i&&(p.includes("/>")||p.includes("</"))?s+=i+e.indentBy+p+i:s+=p,s+=`</${l}>`):s+=d+"/>",r=!0}return s}function ot(t){const e=Object.keys(t);for(let n=0;n<e.length;n++){const i=e[n];if(t.hasOwnProperty(i)&&":@"!==i)return i}}function at(t,e){let n="";if(t&&!e.ignoreAttributes)for(let i in t){if(!t.hasOwnProperty(i))continue;let s=e.attributeValueProcessor(i,t[i]);s=ut(s,e),!0===s&&e.suppressBooleanAttributes?n+=` ${i.substr(e.attributeNamePrefix.length)}`:n+=` ${i.substr(e.attributeNamePrefix.length)}="${s}"`}return n}function lt(t,e){let n=(t=t.substr(0,t.length-e.textNodeName.length-1)).substr(t.lastIndexOf(".")+1);for(let i in e.stopNodes)if(e.stopNodes[i]===t||e.stopNodes[i]==="*."+n)return!0;return!1}function ut(t,e){if(t&&t.length>0&&e.processEntities)for(let n=0;n<e.entities.length;n++){const i=e.entities[n];t=t.replace(i.regex,i.val)}return t}const ht={attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,cdataPropName:!1,format:!1,indentBy:" ",suppressEmptyNode:!1,suppressUnpairedNode:!0,suppressBooleanAttributes:!0,tagValueProcessor:function(t,e){return e},attributeValueProcessor:function(t,e){return e},preserveOrder:!1,commentPropName:!1,unpairedTags:[],entities:[{regex:new RegExp("&","g"),val:"&"},{regex:new RegExp(">","g"),val:">"},{regex:new RegExp("<","g"),val:"<"},{regex:new RegExp("'","g"),val:"'"},{regex:new RegExp('"',"g"),val:"""}],processEntities:!0,stopNodes:[],oneListGroup:!1};function dt(t){this.options=Object.assign({},ht,t),!0===this.options.ignoreAttributes||this.options.attributesGroupName?this.isAttribute=function(){return!1}:(this.ignoreAttributesFn=L(this.options.ignoreAttributes),this.attrPrefixLen=this.options.attributeNamePrefix.length,this.isAttribute=ct),this.processTextOrObjNode=pt,this.options.format?(this.indentate=ft,this.tagEndChar=">\n",this.newLine="\n"):(this.indentate=function(){return""},this.tagEndChar=">",this.newLine="")}function pt(t,e,n,i){const s=this.j2x(t,n+1,i.concat(e));return void 0!==t[this.options.textNodeName]&&1===Object.keys(t).length?this.buildTextValNode(t[this.options.textNodeName],e,s.attrStr,n):this.buildObjectNode(s.val,e,s.attrStr,n)}function ft(t){return this.options.indentBy.repeat(t)}function ct(t){return!(!t.startsWith(this.options.attributeNamePrefix)||t===this.options.textNodeName)&&t.substr(this.attrPrefixLen)}dt.prototype.build=function(t){return this.options.preserveOrder?st(t,this.options):(Array.isArray(t)&&this.options.arrayNodeName&&this.options.arrayNodeName.length>1&&(t={[this.options.arrayNodeName]:t}),this.j2x(t,0,[]).val)},dt.prototype.j2x=function(t,e,n){let i="",s="";const r=n.join(".");for(let o in t)if(Object.prototype.hasOwnProperty.call(t,o))if(void 0===t[o])this.isAttribute(o)&&(s+="");else if(null===t[o])this.isAttribute(o)||o===this.options.cdataPropName?s+="":"?"===o[0]?s+=this.indentate(e)+"<"+o+"?"+this.tagEndChar:s+=this.indentate(e)+"<"+o+"/"+this.tagEndChar;else if(t[o]instanceof Date)s+=this.buildTextValNode(t[o],o,"",e);else if("object"!=typeof t[o]){const n=this.isAttribute(o);if(n&&!this.ignoreAttributesFn(n,r))i+=this.buildAttrPairStr(n,""+t[o]);else if(!n)if(o===this.options.textNodeName){let e=this.options.tagValueProcessor(o,""+t[o]);s+=this.replaceEntitiesValue(e)}else s+=this.buildTextValNode(t[o],o,"",e)}else if(Array.isArray(t[o])){const i=t[o].length;let r="",a="";for(let l=0;l<i;l++){const i=t[o][l];if(void 0===i);else if(null===i)"?"===o[0]?s+=this.indentate(e)+"<"+o+"?"+this.tagEndChar:s+=this.indentate(e)+"<"+o+"/"+this.tagEndChar;else if("object"==typeof i)if(this.options.oneListGroup){const t=this.j2x(i,e+1,n.concat(o));r+=t.val,this.options.attributesGroupName&&i.hasOwnProperty(this.options.attributesGroupName)&&(a+=t.attrStr)}else r+=this.processTextOrObjNode(i,o,e,n);else if(this.options.oneListGroup){let t=this.options.tagValueProcessor(o,i);t=this.replaceEntitiesValue(t),r+=t}else r+=this.buildTextValNode(i,o,"",e)}this.options.oneListGroup&&(r=this.buildObjectNode(r,o,a,e)),s+=r}else if(this.options.attributesGroupName&&o===this.options.attributesGroupName){const e=Object.keys(t[o]),n=e.length;for(let s=0;s<n;s++)i+=this.buildAttrPairStr(e[s],""+t[o][e[s]])}else s+=this.processTextOrObjNode(t[o],o,e,n);return{attrStr:i,val:s}},dt.prototype.buildAttrPairStr=function(t,e){return e=this.options.attributeValueProcessor(t,""+e),e=this.replaceEntitiesValue(e),this.options.suppressBooleanAttributes&&"true"===e?" "+t:" "+t+'="'+e+'"'},dt.prototype.buildObjectNode=function(t,e,n,i){if(""===t)return"?"===e[0]?this.indentate(i)+"<"+e+n+"?"+this.tagEndChar:this.indentate(i)+"<"+e+n+this.closeTag(e)+this.tagEndChar;{let s="</"+e+this.tagEndChar,r="";return"?"===e[0]&&(r="?",s=""),!n&&""!==n||-1!==t.indexOf("<")?!1!==this.options.commentPropName&&e===this.options.commentPropName&&0===r.length?this.indentate(i)+`\x3c!--${t}--\x3e`+this.newLine:this.indentate(i)+"<"+e+n+r+this.tagEndChar+t+this.indentate(i)+s:this.indentate(i)+"<"+e+n+r+">"+t+s}},dt.prototype.closeTag=function(t){let e="";return-1!==this.options.unpairedTags.indexOf(t)?this.options.suppressUnpairedNode||(e="/"):e=this.options.suppressEmptyNode?"/":`></${t}`,e},dt.prototype.buildTextValNode=function(t,e,n,i){if(!1!==this.options.cdataPropName&&e===this.options.cdataPropName)return this.indentate(i)+`<![CDATA[${t}]]>`+this.newLine;if(!1!==this.options.commentPropName&&e===this.options.commentPropName)return this.indentate(i)+`\x3c!--${t}--\x3e`+this.newLine;if("?"===e[0])return this.indentate(i)+"<"+e+n+"?"+this.tagEndChar;{let s=this.options.tagValueProcessor(e,t);return s=this.replaceEntitiesValue(s),""===s?this.indentate(i)+"<"+e+n+this.closeTag(e)+this.tagEndChar:this.indentate(i)+"<"+e+n+">"+s+"</"+e+this.tagEndChar}},dt.prototype.replaceEntitiesValue=function(t){if(t&&t.length>0&&this.options.processEntities)for(let e=0;e<this.options.entities.length;e++){const n=this.options.entities[e];t=t.replace(n.regex,n.val)}return t};const gt={validate:a};module.exports=e})();
|
|
100952
99763
|
|
|
100953
99764
|
/***/ }),
|
|
100954
99765
|
|