@usearazzo/runner 1.0.1-alpha.12 → 1.0.1-alpha.13

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.
@@ -11191,16 +11191,18 @@ __webpack_require__.r(__webpack_exports__);
11191
11191
  /* harmony import */ var _speclynx_apidom_datamodel__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(62823);
11192
11192
  /* harmony import */ var _speclynx_apidom_reference_configuration_empty__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(30698);
11193
11193
  /* harmony import */ var _speclynx_apidom_ns_openapi_2__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(29716);
11194
- /* harmony import */ var _swaggerexpert_media_types__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(93504);
11195
- /* harmony import */ var ramda_adjunct__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(34606);
11196
- /* harmony import */ var _vendor_swagger_client_mjs__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(96777);
11197
- /* harmony import */ var _client_ParameterDelivery_ts__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(55995);
11198
- /* harmony import */ var _client_HTTPClientFetch_ts__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(55549);
11199
- /* harmony import */ var _client_OpenAPIOperationResponseNormalizer_ts__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(63439);
11200
- /* harmony import */ var _extractor_OpenAPIOperationExtractor_ts__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(57658);
11201
- /* harmony import */ var _normalizer_OpenAPIOperationNormalizer_ts__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(87864);
11202
- /* harmony import */ var _assembler_OpenAPIDocumentAssembler_ts__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(6898);
11203
- /* harmony import */ var _errors_ClientError_ts__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(81763);
11194
+ /* harmony import */ var _swaggerexpert_cookie__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(36258);
11195
+ /* harmony import */ var _swaggerexpert_media_types__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(93504);
11196
+ /* harmony import */ var ramda_adjunct__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(34606);
11197
+ /* harmony import */ var _vendor_swagger_client_mjs__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(96777);
11198
+ /* harmony import */ var _client_ParameterDelivery_ts__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(55995);
11199
+ /* harmony import */ var _client_HTTPClientFetch_ts__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(55549);
11200
+ /* harmony import */ var _client_OpenAPIOperationResponseNormalizer_ts__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(63439);
11201
+ /* harmony import */ var _extractor_OpenAPIOperationExtractor_ts__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(57658);
11202
+ /* harmony import */ var _normalizer_OpenAPIOperationNormalizer_ts__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(87864);
11203
+ /* harmony import */ var _assembler_OpenAPIDocumentAssembler_ts__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(6898);
11204
+ /* harmony import */ var _errors_ClientError_ts__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(81763);
11205
+
11204
11206
 
11205
11207
 
11206
11208
 
@@ -11227,6 +11229,21 @@ __webpack_require__.r(__webpack_exports__);
11227
11229
  * @public
11228
11230
  */
11229
11231
 
11232
+ /**
11233
+ * The plain-JSON shape of the assembled document, as far as declaring a
11234
+ * parameter on its one operation needs it.
11235
+ */
11236
+
11237
+ /**
11238
+ * A caller-supplied parameter the operation does not declare, in a location
11239
+ * it can still be delivered to.
11240
+ */
11241
+
11242
+ const UNDECLARED_LOCATIONS = new Set(['header', 'query', 'cookie', 'path']);
11243
+
11244
+ // the header parameters OpenAPI 3 says SHALL be ignored, which buildRequest drops
11245
+ const IGNORED_HEADERS = new Set(['accept', 'authorization', 'content-type']);
11246
+
11230
11247
  /**
11231
11248
  * Options for executing an OpenAPI operation.
11232
11249
  *
@@ -11303,12 +11320,12 @@ class OpenAPIOperationExecutor {
11303
11320
  #operationNormalizer;
11304
11321
  #documentAssembler;
11305
11322
  constructor(options = {}) {
11306
- this.#httpClient = options.httpClient ?? _client_HTTPClientFetch_ts__WEBPACK_IMPORTED_MODULE_8__["default"];
11323
+ this.#httpClient = options.httpClient ?? _client_HTTPClientFetch_ts__WEBPACK_IMPORTED_MODULE_9__["default"];
11307
11324
  this.#requestInterceptor = options.requestInterceptor;
11308
- this.#responseNormalizer = options.responseNormalizer ?? new _client_OpenAPIOperationResponseNormalizer_ts__WEBPACK_IMPORTED_MODULE_9__["default"]();
11309
- this.#operationExtractor = options.operationExtractor ?? new _extractor_OpenAPIOperationExtractor_ts__WEBPACK_IMPORTED_MODULE_10__["default"]();
11310
- this.#operationNormalizer = options.operationNormalizer ?? new _normalizer_OpenAPIOperationNormalizer_ts__WEBPACK_IMPORTED_MODULE_11__["default"]();
11311
- this.#documentAssembler = options.documentAssembler ?? new _assembler_OpenAPIDocumentAssembler_ts__WEBPACK_IMPORTED_MODULE_12__["default"]();
11325
+ this.#responseNormalizer = options.responseNormalizer ?? new _client_OpenAPIOperationResponseNormalizer_ts__WEBPACK_IMPORTED_MODULE_10__["default"]();
11326
+ this.#operationExtractor = options.operationExtractor ?? new _extractor_OpenAPIOperationExtractor_ts__WEBPACK_IMPORTED_MODULE_11__["default"]();
11327
+ this.#operationNormalizer = options.operationNormalizer ?? new _normalizer_OpenAPIOperationNormalizer_ts__WEBPACK_IMPORTED_MODULE_12__["default"]();
11328
+ this.#documentAssembler = options.documentAssembler ?? new _assembler_OpenAPIDocumentAssembler_ts__WEBPACK_IMPORTED_MODULE_13__["default"]();
11312
11329
  }
11313
11330
 
11314
11331
  /**
@@ -11328,7 +11345,7 @@ class OpenAPIOperationExecutor {
11328
11345
  const operation = this.#operationExtractor.extractByPointer(locator.document, locator.jsonPointer);
11329
11346
  // the legacy id (`{method}-{path}`) matches regardless of an explicit
11330
11347
  // `operationId` in the assembled document
11331
- const operationId = (0,_vendor_swagger_client_mjs__WEBPACK_IMPORTED_MODULE_6__.idFromPathMethodLegacy)((0,_speclynx_apidom_core__WEBPACK_IMPORTED_MODULE_0__["default"])(operation.meta.get('path')), (0,_speclynx_apidom_core__WEBPACK_IMPORTED_MODULE_0__["default"])(operation.meta.get('http-method')));
11348
+ const operationId = (0,_vendor_swagger_client_mjs__WEBPACK_IMPORTED_MODULE_7__.idFromPathMethodLegacy)((0,_speclynx_apidom_core__WEBPACK_IMPORTED_MODULE_0__["default"])(operation.meta.get('path')), (0,_speclynx_apidom_core__WEBPACK_IMPORTED_MODULE_0__["default"])(operation.meta.get('http-method')));
11332
11349
  const normalizedOperation = await this.#operationNormalizer.normalize(operation, locator.document);
11333
11350
  const assembled = this.#documentAssembler.assemble(normalizedOperation, locator.document);
11334
11351
 
@@ -11345,16 +11362,18 @@ class OpenAPIOperationExecutor {
11345
11362
  const withServer = this.#applyServerOptions(rest, normalizedOperation, locator.document);
11346
11363
  const withBody = this.#adaptRequestBody(withServer, normalizedOperation, locator.document, locator.jsonPointer);
11347
11364
  const buildOptions = this.#adaptRequestContentType(withBody, normalizedOperation, locator.document, locator.jsonPointer);
11365
+ const undeclared = this.#undeclaredParameters(buildOptions.parameters, normalizedOperation);
11366
+ const spec = assembled.toJSON();
11367
+ this.#declareQueryAndPathParameters(spec, undeclared, (0,_speclynx_apidom_core__WEBPACK_IMPORTED_MODULE_0__["default"])(operation.meta.get('path')), (0,_speclynx_apidom_core__WEBPACK_IMPORTED_MODULE_0__["default"])(operation.meta.get('http-method')), locator);
11348
11368
  let request;
11349
11369
  try {
11350
- const spec = assembled.toJSON();
11351
- request = (0,_vendor_swagger_client_mjs__WEBPACK_IMPORTED_MODULE_6__.buildRequest)({
11370
+ request = (0,_vendor_swagger_client_mjs__WEBPACK_IMPORTED_MODULE_7__.buildRequest)({
11352
11371
  ...buildOptions,
11353
11372
  spec,
11354
11373
  operationId
11355
11374
  });
11356
11375
  } catch (error) {
11357
- throw new _errors_ClientError_ts__WEBPACK_IMPORTED_MODULE_13__["default"]('Failed to build request for OpenAPI operation', {
11376
+ throw new _errors_ClientError_ts__WEBPACK_IMPORTED_MODULE_14__["default"]('Failed to build request for OpenAPI operation', {
11358
11377
  operationPath: locator.jsonPointer,
11359
11378
  cause: error
11360
11379
  });
@@ -11367,6 +11386,7 @@ class OpenAPIOperationExecutor {
11367
11386
  if (typeof authoredContentType === 'string' && buildOptions.requestContentType !== authoredContentType) {
11368
11387
  request.headers['Content-Type'] = authoredContentType;
11369
11388
  }
11389
+ this.#deliverHeadersAndCookies(request, undeclared);
11370
11390
  request = await this.#finalizeRequest(request, requestInterceptor);
11371
11391
 
11372
11392
  // capture the request as sent, so `$url` / `$method` / `$request.*` can be
@@ -11384,7 +11404,7 @@ class OpenAPIOperationExecutor {
11384
11404
  try {
11385
11405
  rawResponse = await this.#httpClient(request);
11386
11406
  } catch (error) {
11387
- throw new _errors_ClientError_ts__WEBPACK_IMPORTED_MODULE_13__["default"]('OpenAPI operation request failed', {
11407
+ throw new _errors_ClientError_ts__WEBPACK_IMPORTED_MODULE_14__["default"]('OpenAPI operation request failed', {
11388
11408
  operationPath: locator.jsonPointer,
11389
11409
  cause: error
11390
11410
  });
@@ -11392,6 +11412,130 @@ class OpenAPIOperationExecutor {
11392
11412
  return this.#responseNormalizer.normalize(rawResponse, requestInfo);
11393
11413
  }
11394
11414
 
11415
+ /**
11416
+ * The `{in}.{name}`-keyed parameters (see {@link ParameterDelivery}) in a
11417
+ * header, query, cookie or path location that the operation does not
11418
+ * declare. `buildRequest` delivers only what the operation declares, yet a
11419
+ * step's parameters are what its author asked to send — an `Authorization`
11420
+ * header carrying a token from an earlier step most of all, which OpenAPI 3
11421
+ * cannot even declare. A declared `Accept`, `Authorization` or
11422
+ * `Content-Type` header parameter counts as undeclared too: `buildRequest`
11423
+ * drops it for OpenAPI 3, as that specification requires, and for 2.0
11424
+ * delivering it here sends the same value. Bare keys are left to
11425
+ * `buildRequest`: they name no location to deliver to.
11426
+ */
11427
+ #undeclaredParameters(parameters, operation) {
11428
+ if (!(0,ramda_adjunct__WEBPACK_IMPORTED_MODULE_6__["default"])(parameters)) return [];
11429
+ const declared = new Set(((0,_speclynx_apidom_datamodel__WEBPACK_IMPORTED_MODULE_1__.isArrayElement)(operation.parameters) ? [...operation.parameters] : []).filter(_speclynx_apidom_datamodel__WEBPACK_IMPORTED_MODULE_1__.isObjectElement).map(parameter => `${(0,_speclynx_apidom_core__WEBPACK_IMPORTED_MODULE_0__["default"])(parameter.get('in'))}.${(0,_speclynx_apidom_core__WEBPACK_IMPORTED_MODULE_0__["default"])(parameter.get('name'))}`));
11430
+ return Object.entries(parameters).flatMap(([key, value]) => {
11431
+ const separator = key.indexOf('.');
11432
+ const location = key.slice(0, separator);
11433
+ const name = key.slice(separator + 1);
11434
+ // an unresolved expression or a null delivers nothing, as buildRequest
11435
+ // does for a declared parameter
11436
+ if (separator === -1 || !UNDECLARED_LOCATIONS.has(location) || value === undefined || value === null) {
11437
+ return [];
11438
+ }
11439
+ const ignored = location === 'header' && IGNORED_HEADERS.has(name.toLowerCase());
11440
+ return declared.has(key) && !ignored ? [] : [{
11441
+ location,
11442
+ name,
11443
+ value
11444
+ }];
11445
+ });
11446
+ }
11447
+
11448
+ /**
11449
+ * Declares the undeclared query and path parameters on the assembled
11450
+ * operation, so `buildRequest` serializes and encodes them as it does
11451
+ * declared ones. A path parameter is declared only when the path has its
11452
+ * `{name}` template expression; otherwise there is nowhere to put it, and
11453
+ * that authoring error throws {@link ClientError} rather than sending a
11454
+ * request without it.
11455
+ */
11456
+ #declareQueryAndPathParameters(spec, undeclared, path, method, locator) {
11457
+ const operation = spec.paths[path][method];
11458
+ const isSwagger = (0,_speclynx_apidom_ns_openapi_2__WEBPACK_IMPORTED_MODULE_3__.isSwaggerElement)(locator.document.parseResult.api);
11459
+ for (const {
11460
+ location,
11461
+ name
11462
+ } of undeclared) {
11463
+ if (location !== 'query' && location !== 'path') continue;
11464
+ if (location === 'path' && !path.includes(`{${name}}`)) {
11465
+ throw new _errors_ClientError_ts__WEBPACK_IMPORTED_MODULE_14__["default"](`Path parameter "${name}" is not declared by the operation and its path "${path}" ` + `has no "{${name}}" to substitute it into`, {
11466
+ operationPath: locator.jsonPointer
11467
+ });
11468
+ }
11469
+ const required = location === 'path';
11470
+ (operation.parameters ??= []).push(isSwagger ? {
11471
+ name,
11472
+ in: location,
11473
+ required,
11474
+ type: 'string'
11475
+ } : {
11476
+ name,
11477
+ in: location,
11478
+ required,
11479
+ schema: {}
11480
+ });
11481
+ }
11482
+ }
11483
+
11484
+ /**
11485
+ * Sets the undeclared header parameters on the built request and appends the
11486
+ * undeclared cookie parameters to its `Cookie` header. A header replaces any
11487
+ * value the build gave it under any spelling — the default `Accept`, say —
11488
+ * since the step naming it is the more specific intent. OpenAPI 2.0 has no
11489
+ * cookie location, so its cookies always go this way.
11490
+ */
11491
+ #deliverHeadersAndCookies(request, undeclared) {
11492
+ const present = name => Object.keys(request.headers).find(header => header.toLowerCase() === name.toLowerCase());
11493
+ for (const {
11494
+ location,
11495
+ name,
11496
+ value
11497
+ } of undeclared) {
11498
+ if (location !== 'header') continue;
11499
+ const built = present(name);
11500
+ if (built !== undefined) delete request.headers[built];
11501
+ request.headers[name] = this.#stringify(value);
11502
+ }
11503
+ const cookies = undeclared.filter(({
11504
+ location
11505
+ }) => location === 'cookie').map(({
11506
+ name,
11507
+ value
11508
+ }) => [name, this.#stringify(value)]);
11509
+ if (cookies.length === 0) return;
11510
+ // serialized as buildRequest serializes a declared cookie, so a `;` in the
11511
+ // value is percent-encoded rather than splitting it into further cookies
11512
+ const serialized = (0,_swaggerexpert_cookie__WEBPACK_IMPORTED_MODULE_4__.serializeCookie)(cookies, {
11513
+ encoders: {
11514
+ value: _swaggerexpert_cookie__WEBPACK_IMPORTED_MODULE_4__.cookieValueStrictPercentEncoder
11515
+ },
11516
+ validators: {
11517
+ name: _swaggerexpert_cookie__WEBPACK_IMPORTED_MODULE_4__.cookieNameLenientValidator
11518
+ }
11519
+ });
11520
+ const cookieHeader = present('Cookie') ?? 'Cookie';
11521
+ const existing = request.headers[cookieHeader];
11522
+ request.headers[cookieHeader] = existing ? `${existing}; ${serialized}` : serialized;
11523
+ }
11524
+
11525
+ /**
11526
+ * A header or cookie value with no schema to serialize it by, the way
11527
+ * OpenAPI's default for those locations (`simple` and `form`, not exploded)
11528
+ * serializes a declared one: an array as `a,b`, an object as `k,v,k2,v2`,
11529
+ * anything else via `String()`.
11530
+ */
11531
+ #stringify(value) {
11532
+ if (Array.isArray(value)) return value.map(String).join(',');
11533
+ if (typeof value === 'object' && value !== null) {
11534
+ return Object.entries(value).flat().map(String).join(',');
11535
+ }
11536
+ return String(value);
11537
+ }
11538
+
11395
11539
  /**
11396
11540
  * Derives where the request is sent, returning the options to build with.
11397
11541
  *
@@ -11474,7 +11618,7 @@ class OpenAPIOperationExecutor {
11474
11618
  const requestBody = operation.get('requestBody');
11475
11619
  const content = (0,_speclynx_apidom_datamodel__WEBPACK_IMPORTED_MODULE_1__.isObjectElement)(requestBody) ? requestBody.get('content') : undefined;
11476
11620
  if (!(0,_speclynx_apidom_datamodel__WEBPACK_IMPORTED_MODULE_1__.isObjectElement)(content)) {
11477
- throw new _errors_ClientError_ts__WEBPACK_IMPORTED_MODULE_13__["default"](`Request body media type "${requested}" cannot be sent: the operation declares ` + 'no request body content. Omit the content type to send the payload as-is', {
11621
+ throw new _errors_ClientError_ts__WEBPACK_IMPORTED_MODULE_14__["default"](`Request body media type "${requested}" cannot be sent: the operation declares ` + 'no request body content. Omit the content type to send the payload as-is', {
11478
11622
  operationPath: jsonPointer
11479
11623
  });
11480
11624
  }
@@ -11482,8 +11626,8 @@ class OpenAPIOperationExecutor {
11482
11626
  if (declared.includes(requested)) return buildOptions;
11483
11627
 
11484
11628
  // a range or a malformed value names no concrete media type to send
11485
- if ((0,_swaggerexpert_media_types__WEBPACK_IMPORTED_MODULE_4__.identify)(requested) !== 'media-type') {
11486
- throw new _errors_ClientError_ts__WEBPACK_IMPORTED_MODULE_13__["default"](`Request body media type "${requested}" is not a valid media type`, {
11629
+ if ((0,_swaggerexpert_media_types__WEBPACK_IMPORTED_MODULE_5__.identify)(requested) !== 'media-type') {
11630
+ throw new _errors_ClientError_ts__WEBPACK_IMPORTED_MODULE_14__["default"](`Request body media type "${requested}" is not a valid media type`, {
11487
11631
  operationPath: jsonPointer
11488
11632
  });
11489
11633
  }
@@ -11491,18 +11635,18 @@ class OpenAPIOperationExecutor {
11491
11635
  // a form media type decides how the body is encoded, and buildRequest applies
11492
11636
  // that encoding only for an exactly declared type. matching one against a
11493
11637
  // range would put a JSON body behind a form Content-Type
11494
- const isFormEncoded = (0,_swaggerexpert_media_types__WEBPACK_IMPORTED_MODULE_4__.matches)('application/x-www-form-urlencoded', requested) || (0,_swaggerexpert_media_types__WEBPACK_IMPORTED_MODULE_4__.matches)('multipart/form-data', requested);
11638
+ const isFormEncoded = (0,_swaggerexpert_media_types__WEBPACK_IMPORTED_MODULE_5__.matches)('application/x-www-form-urlencoded', requested) || (0,_swaggerexpert_media_types__WEBPACK_IMPORTED_MODULE_5__.matches)('multipart/form-data', requested);
11495
11639
 
11496
11640
  // otherwise a declared range covers a concrete type, so `*/*` (what several
11497
11641
  // generators emit by default) accepts anything; the most specific wins.
11498
11642
  // parameters on one side only (a declared `charset=utf-8`) describe the
11499
11643
  // content rather than constrain it, while conflicting ones never match
11500
- const candidates = isFormEncoded ? declared.filter(mediaType => (0,_swaggerexpert_media_types__WEBPACK_IMPORTED_MODULE_4__.identify)(mediaType) === 'media-type') : declared;
11501
- const match = (0,_swaggerexpert_media_types__WEBPACK_IMPORTED_MODULE_4__.selectBestMatch)(candidates, requested, {
11644
+ const candidates = isFormEncoded ? declared.filter(mediaType => (0,_swaggerexpert_media_types__WEBPACK_IMPORTED_MODULE_5__.identify)(mediaType) === 'media-type') : declared;
11645
+ const match = (0,_swaggerexpert_media_types__WEBPACK_IMPORTED_MODULE_5__.selectBestMatch)(candidates, requested, {
11502
11646
  parameterMatching: 'compatible'
11503
11647
  });
11504
11648
  if (match === null) {
11505
- throw new _errors_ClientError_ts__WEBPACK_IMPORTED_MODULE_13__["default"](isFormEncoded ? `Request body media type "${requested}" must be declared by the operation exactly, ` + `since it decides how the body is encoded (declared: [${declared.join(', ')}])` : `Request body media type "${requested}" is not declared by the operation ` + `(declared: [${declared.join(', ')}])`, {
11649
+ throw new _errors_ClientError_ts__WEBPACK_IMPORTED_MODULE_14__["default"](isFormEncoded ? `Request body media type "${requested}" must be declared by the operation exactly, ` + `since it decides how the body is encoded (declared: [${declared.join(', ')}])` : `Request body media type "${requested}" is not declared by the operation ` + `(declared: [${declared.join(', ')}])`, {
11506
11650
  operationPath: jsonPointer
11507
11651
  });
11508
11652
  }
@@ -11564,7 +11708,7 @@ class OpenAPIOperationExecutor {
11564
11708
  ...rest,
11565
11709
  parameters: {
11566
11710
  ...callerParameters,
11567
- [_client_ParameterDelivery_ts__WEBPACK_IMPORTED_MODULE_7__["default"].keyFor('body', name)]: requestBody
11711
+ [_client_ParameterDelivery_ts__WEBPACK_IMPORTED_MODULE_8__["default"].keyFor('body', name)]: requestBody
11568
11712
  }
11569
11713
  };
11570
11714
  }
@@ -11573,8 +11717,8 @@ class OpenAPIOperationExecutor {
11573
11717
  // are the parameter names; buildRequest reports any that do not match
11574
11718
  const hasForm = parameters.some(parameter => (0,_speclynx_apidom_core__WEBPACK_IMPORTED_MODULE_0__["default"])(parameter.in) === 'formData');
11575
11719
  if (hasForm) {
11576
- if (!(0,ramda_adjunct__WEBPACK_IMPORTED_MODULE_5__["default"])(requestBody)) {
11577
- throw new _errors_ClientError_ts__WEBPACK_IMPORTED_MODULE_13__["default"]('Request body cannot be sent: the OpenAPI 2.0 operation carries it in "formData" ' + 'parameters, so the payload must be an object keyed by their names', {
11720
+ if (!(0,ramda_adjunct__WEBPACK_IMPORTED_MODULE_6__["default"])(requestBody)) {
11721
+ throw new _errors_ClientError_ts__WEBPACK_IMPORTED_MODULE_14__["default"]('Request body cannot be sent: the OpenAPI 2.0 operation carries it in "formData" ' + 'parameters, so the payload must be an object keyed by their names', {
11578
11722
  operationPath: jsonPointer
11579
11723
  });
11580
11724
  }
@@ -11584,14 +11728,14 @@ class OpenAPIOperationExecutor {
11584
11728
  ...callerParameters
11585
11729
  };
11586
11730
  for (const [field, value] of Object.entries(payload)) {
11587
- merged[_client_ParameterDelivery_ts__WEBPACK_IMPORTED_MODULE_7__["default"].keyFor('formData', field)] = value;
11731
+ merged[_client_ParameterDelivery_ts__WEBPACK_IMPORTED_MODULE_8__["default"].keyFor('formData', field)] = value;
11588
11732
  }
11589
11733
  return {
11590
11734
  ...rest,
11591
11735
  parameters: merged
11592
11736
  };
11593
11737
  }
11594
- throw new _errors_ClientError_ts__WEBPACK_IMPORTED_MODULE_13__["default"]('Request body cannot be sent: the OpenAPI 2.0 operation declares no "body" or ' + '"formData" parameter to carry it', {
11738
+ throw new _errors_ClientError_ts__WEBPACK_IMPORTED_MODULE_14__["default"]('Request body cannot be sent: the OpenAPI 2.0 operation declares no "body" or ' + '"formData" parameter to carry it', {
11595
11739
  operationPath: jsonPointer
11596
11740
  });
11597
11741
  }
@@ -11606,7 +11750,7 @@ class OpenAPIOperationExecutor {
11606
11750
  if (callerParameters === undefined) return;
11607
11751
  const conflicts = payloadNames.filter(name => Object.hasOwn(callerParameters, name));
11608
11752
  if (conflicts.length === 0) return;
11609
- throw new _errors_ClientError_ts__WEBPACK_IMPORTED_MODULE_13__["default"](`Request body cannot be sent: bare parameter ${conflicts.length === 1 ? 'entry' : 'entries'} ` + `[${conflicts.join(', ')}] would displace the payload at delivery. Supply the ` + `parameter under its "{in}.{name}" key, or drop the duplicate`, {
11753
+ throw new _errors_ClientError_ts__WEBPACK_IMPORTED_MODULE_14__["default"](`Request body cannot be sent: bare parameter ${conflicts.length === 1 ? 'entry' : 'entries'} ` + `[${conflicts.join(', ')}] would displace the payload at delivery. Supply the ` + `parameter under its "{in}.{name}" key, or drop the duplicate`, {
11610
11754
  operationPath: jsonPointer
11611
11755
  });
11612
11756
  }
@@ -11625,7 +11769,7 @@ class OpenAPIOperationExecutor {
11625
11769
 
11626
11770
  // JSON-encode plain-object and array bodies, exactly as swagger-client's
11627
11771
  // execute() does before handing the request to its transport
11628
- if (finalized.body && ((0,ramda_adjunct__WEBPACK_IMPORTED_MODULE_5__["default"])(finalized.body) || Array.isArray(finalized.body))) {
11772
+ if (finalized.body && ((0,ramda_adjunct__WEBPACK_IMPORTED_MODULE_6__["default"])(finalized.body) || Array.isArray(finalized.body))) {
11629
11773
  finalized.body = JSON.stringify(finalized.body);
11630
11774
  }
11631
11775
 
@@ -71764,6 +71908,1742 @@ const test = runtimeExpression => {
71764
71908
  /* harmony export */ ]);
71765
71909
 
71766
71910
 
71911
+ /***/ },
71912
+
71913
+ /***/ 95878
71914
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
71915
+
71916
+ "use strict";
71917
+ __webpack_require__.r(__webpack_exports__);
71918
+ /* harmony import */ var apg_lite__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(51751);
71919
+
71920
+ const cookieName = (state, chars, phraseIndex, phraseLength, data) => {
71921
+ if (state === apg_lite__WEBPACK_IMPORTED_MODULE_0__.identifiers.SEM_PRE) {
71922
+ data.push(['cookie-name', apg_lite__WEBPACK_IMPORTED_MODULE_0__.utilities.charsToString(chars, phraseIndex, phraseLength)]);
71923
+ } else if (state === apg_lite__WEBPACK_IMPORTED_MODULE_0__.identifiers.SEM_POST) {
71924
+ /* not used in this example */
71925
+ }
71926
+ return apg_lite__WEBPACK_IMPORTED_MODULE_0__.identifiers.SEM_OK;
71927
+ };
71928
+ /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (cookieName);
71929
+ /* harmony export */ __webpack_require__.d(__webpack_exports__, [
71930
+ /* harmony export */ "default", 0, __WEBPACK_DEFAULT_EXPORT__
71931
+ /* harmony export */ ]);
71932
+
71933
+
71934
+ /***/ },
71935
+
71936
+ /***/ 19511
71937
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
71938
+
71939
+ "use strict";
71940
+ __webpack_require__.r(__webpack_exports__);
71941
+ /* harmony import */ var apg_lite__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(51751);
71942
+
71943
+ const cookiePair = (state, chars, phraseIndex, phraseLength, data) => {
71944
+ if (state === apg_lite__WEBPACK_IMPORTED_MODULE_0__.identifiers.SEM_PRE) {
71945
+ data.push(['cookie-pair', apg_lite__WEBPACK_IMPORTED_MODULE_0__.utilities.charsToString(chars, phraseIndex, phraseLength)]);
71946
+ } else if (state === apg_lite__WEBPACK_IMPORTED_MODULE_0__.identifiers.SEM_POST) {
71947
+ /* not used in this example */
71948
+ }
71949
+ return apg_lite__WEBPACK_IMPORTED_MODULE_0__.identifiers.SEM_OK;
71950
+ };
71951
+ /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (cookiePair);
71952
+ /* harmony export */ __webpack_require__.d(__webpack_exports__, [
71953
+ /* harmony export */ "default", 0, __WEBPACK_DEFAULT_EXPORT__
71954
+ /* harmony export */ ]);
71955
+
71956
+
71957
+ /***/ },
71958
+
71959
+ /***/ 12556
71960
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
71961
+
71962
+ "use strict";
71963
+ __webpack_require__.r(__webpack_exports__);
71964
+ /* harmony import */ var apg_lite__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(51751);
71965
+
71966
+ const cookieString = (state, chars, phraseIndex, phraseLength, data) => {
71967
+ if (state === apg_lite__WEBPACK_IMPORTED_MODULE_0__.identifiers.SEM_PRE) {
71968
+ if (Array.isArray(data) === false) {
71969
+ throw new Error("parser's user data must be an array");
71970
+ }
71971
+ data.push(['cookie-string', apg_lite__WEBPACK_IMPORTED_MODULE_0__.utilities.charsToString(chars, phraseIndex, phraseLength)]);
71972
+ }
71973
+ return apg_lite__WEBPACK_IMPORTED_MODULE_0__.identifiers.SEM_OK;
71974
+ };
71975
+ /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (cookieString);
71976
+ /* harmony export */ __webpack_require__.d(__webpack_exports__, [
71977
+ /* harmony export */ "default", 0, __WEBPACK_DEFAULT_EXPORT__
71978
+ /* harmony export */ ]);
71979
+
71980
+
71981
+ /***/ },
71982
+
71983
+ /***/ 18494
71984
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
71985
+
71986
+ "use strict";
71987
+ __webpack_require__.r(__webpack_exports__);
71988
+ /* harmony import */ var apg_lite__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(51751);
71989
+
71990
+ const cookieValue = (state, chars, phraseIndex, phraseLength, data) => {
71991
+ if (state === apg_lite__WEBPACK_IMPORTED_MODULE_0__.identifiers.SEM_PRE) {
71992
+ data.push(['cookie-value', apg_lite__WEBPACK_IMPORTED_MODULE_0__.utilities.charsToString(chars, phraseIndex, phraseLength)]);
71993
+ } else if (state === apg_lite__WEBPACK_IMPORTED_MODULE_0__.identifiers.SEM_POST) {
71994
+ /* not used in this example */
71995
+ }
71996
+ return apg_lite__WEBPACK_IMPORTED_MODULE_0__.identifiers.SEM_OK;
71997
+ };
71998
+ /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (cookieValue);
71999
+ /* harmony export */ __webpack_require__.d(__webpack_exports__, [
72000
+ /* harmony export */ "default", 0, __WEBPACK_DEFAULT_EXPORT__
72001
+ /* harmony export */ ]);
72002
+
72003
+
72004
+ /***/ },
72005
+
72006
+ /***/ 5789
72007
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
72008
+
72009
+ "use strict";
72010
+ __webpack_require__.r(__webpack_exports__);
72011
+ /* harmony import */ var apg_lite__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(51751);
72012
+ /* harmony import */ var _grammar_mjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(67789);
72013
+ /* harmony import */ var _callbacks_cookie_string_mjs__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(12556);
72014
+ /* harmony import */ var _callbacks_cookie_pair_mjs__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(19511);
72015
+ /* harmony import */ var _callbacks_cookie_name_mjs__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(95878);
72016
+ /* harmony import */ var _callbacks_cookie_value_mjs__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(18494);
72017
+
72018
+
72019
+
72020
+
72021
+
72022
+
72023
+ const grammar = new _grammar_mjs__WEBPACK_IMPORTED_MODULE_1__["default"]();
72024
+ const parse = (cookieString, {
72025
+ strict = true
72026
+ } = {}) => {
72027
+ const parser = new apg_lite__WEBPACK_IMPORTED_MODULE_0__.Parser();
72028
+ parser.ast = new apg_lite__WEBPACK_IMPORTED_MODULE_0__.Ast();
72029
+ if (strict) {
72030
+ parser.ast.callbacks['cookie-string'] = _callbacks_cookie_string_mjs__WEBPACK_IMPORTED_MODULE_2__["default"];
72031
+ parser.ast.callbacks['cookie-pair'] = _callbacks_cookie_pair_mjs__WEBPACK_IMPORTED_MODULE_3__["default"];
72032
+ parser.ast.callbacks['cookie-name'] = _callbacks_cookie_name_mjs__WEBPACK_IMPORTED_MODULE_4__["default"];
72033
+ parser.ast.callbacks['cookie-value'] = _callbacks_cookie_value_mjs__WEBPACK_IMPORTED_MODULE_5__["default"];
72034
+ } else {
72035
+ parser.ast.callbacks['lenient-cookie-string'] = _callbacks_cookie_string_mjs__WEBPACK_IMPORTED_MODULE_2__["default"];
72036
+ parser.ast.callbacks['lenient-cookie-pair'] = _callbacks_cookie_pair_mjs__WEBPACK_IMPORTED_MODULE_3__["default"];
72037
+ parser.ast.callbacks['lenient-cookie-name'] = _callbacks_cookie_name_mjs__WEBPACK_IMPORTED_MODULE_4__["default"];
72038
+ parser.ast.callbacks['lenient-cookie-value'] = _callbacks_cookie_value_mjs__WEBPACK_IMPORTED_MODULE_5__["default"];
72039
+ }
72040
+ const startRule = strict ? 'cookie-string' : 'lenient-cookie-string';
72041
+ const result = parser.parse(grammar, startRule, cookieString);
72042
+ return {
72043
+ result,
72044
+ ast: parser.ast
72045
+ };
72046
+ };
72047
+ /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (parse);
72048
+ /* harmony export */ __webpack_require__.d(__webpack_exports__, [
72049
+ /* harmony export */ "default", 0, __WEBPACK_DEFAULT_EXPORT__
72050
+ /* harmony export */ ]);
72051
+
72052
+
72053
+ /***/ },
72054
+
72055
+ /***/ 70074
72056
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
72057
+
72058
+ "use strict";
72059
+ __webpack_require__.r(__webpack_exports__);
72060
+ /* harmony import */ var _set_cookie_serialize_index_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(51575);
72061
+
72062
+ const serialize = (cookiePairs, options = {}) => {
72063
+ const cookiePairEntries = Array.isArray(cookiePairs) ? cookiePairs : typeof cookiePairs === 'object' && cookiePairs !== null ? Object.entries(cookiePairs) : [];
72064
+ return cookiePairEntries.map(([name, value]) => (0,_set_cookie_serialize_index_mjs__WEBPACK_IMPORTED_MODULE_0__["default"])(name, value, options)).join('; ');
72065
+ };
72066
+ /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (serialize);
72067
+ /* harmony export */ __webpack_require__.d(__webpack_exports__, [
72068
+ /* harmony export */ "default", 0, __WEBPACK_DEFAULT_EXPORT__
72069
+ /* harmony export */ ]);
72070
+
72071
+
72072
+ /***/ },
72073
+
72074
+ /***/ 16552
72075
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
72076
+
72077
+ "use strict";
72078
+ __webpack_require__.r(__webpack_exports__);
72079
+ /* harmony import */ var apg_lite__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(51751);
72080
+ /* harmony import */ var _grammar_mjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(67789);
72081
+
72082
+
72083
+ const parser = new apg_lite__WEBPACK_IMPORTED_MODULE_0__.Parser();
72084
+ const grammar = new _grammar_mjs__WEBPACK_IMPORTED_MODULE_1__["default"]();
72085
+ const testCookieName = (cookieName, {
72086
+ strict = true
72087
+ } = {}) => {
72088
+ try {
72089
+ const startRule = strict ? 'cookie-name' : 'lenient-cookie-name';
72090
+ return parser.parse(grammar, startRule, cookieName).success;
72091
+ } catch {
72092
+ return false;
72093
+ }
72094
+ };
72095
+ /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (testCookieName);
72096
+ /* harmony export */ __webpack_require__.d(__webpack_exports__, [
72097
+ /* harmony export */ "default", 0, __WEBPACK_DEFAULT_EXPORT__
72098
+ /* harmony export */ ]);
72099
+
72100
+
72101
+ /***/ },
72102
+
72103
+ /***/ 23396
72104
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
72105
+
72106
+ "use strict";
72107
+ __webpack_require__.r(__webpack_exports__);
72108
+ /* harmony import */ var apg_lite__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(51751);
72109
+ /* harmony import */ var _grammar_mjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(67789);
72110
+ /* harmony import */ var _utils_mjs__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(93913);
72111
+
72112
+
72113
+
72114
+ const parser = new apg_lite__WEBPACK_IMPORTED_MODULE_0__.Parser();
72115
+ const grammar = new _grammar_mjs__WEBPACK_IMPORTED_MODULE_1__["default"]();
72116
+ const testCookieValue = (cookieValue, {
72117
+ strict = true,
72118
+ quoted = null
72119
+ } = {}) => {
72120
+ try {
72121
+ const startRule = strict ? 'cookie-value' : 'lenient-cookie-value';
72122
+ const result = parser.parse(grammar, startRule, cookieValue);
72123
+ if (typeof quoted === 'boolean') {
72124
+ return result.success && quoted === (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_2__.isQuoted)(cookieValue);
72125
+ }
72126
+ return result.success;
72127
+ } catch {
72128
+ return false;
72129
+ }
72130
+ };
72131
+ /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (testCookieValue);
72132
+ /* harmony export */ __webpack_require__.d(__webpack_exports__, [
72133
+ /* harmony export */ "default", 0, __WEBPACK_DEFAULT_EXPORT__
72134
+ /* harmony export */ ]);
72135
+
72136
+
72137
+ /***/ },
72138
+
72139
+ /***/ 67789
72140
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
72141
+
72142
+ "use strict";
72143
+ __webpack_require__.r(__webpack_exports__);
72144
+ /* harmony export */ __webpack_require__.d(__webpack_exports__, {
72145
+ /* harmony export */ "default": () => (/* binding */ grammar)
72146
+ /* harmony export */ });
72147
+ // copyright: Copyright (c) 2024 Lowell D. Thomas, all rights reserved<br>
72148
+ // license: BSD-2-Clause (https://opensource.org/licenses/BSD-2-Clause)<br>
72149
+ //
72150
+ // Generated by apg-js, Version 4.4.0 [apg-js](https://github.com/ldthomas/apg-js)
72151
+ function grammar() {
72152
+ // ```
72153
+ // SUMMARY
72154
+ // rules = 30
72155
+ // udts = 0
72156
+ // opcodes = 139
72157
+ // --- ABNF original opcodes
72158
+ // ALT = 12
72159
+ // CAT = 12
72160
+ // REP = 13
72161
+ // RNM = 41
72162
+ // TLS = 35
72163
+ // TBS = 10
72164
+ // TRG = 16
72165
+ // --- SABNF superset opcodes
72166
+ // UDT = 0
72167
+ // AND = 0
72168
+ // NOT = 0
72169
+ // characters = [0 - 127]
72170
+ // ```
72171
+ /* OBJECT IDENTIFIER (for internal parser use) */
72172
+ this.grammarObject = 'grammarObject';
72173
+
72174
+ /* RULES */
72175
+ this.rules = [];
72176
+ this.rules[0] = {
72177
+ name: 'lenient-cookie-string',
72178
+ lower: 'lenient-cookie-string',
72179
+ index: 0,
72180
+ isBkr: false
72181
+ };
72182
+ this.rules[1] = {
72183
+ name: 'lenient-cookie-entry',
72184
+ lower: 'lenient-cookie-entry',
72185
+ index: 1,
72186
+ isBkr: false
72187
+ };
72188
+ this.rules[2] = {
72189
+ name: 'lenient-cookie-pair',
72190
+ lower: 'lenient-cookie-pair',
72191
+ index: 2,
72192
+ isBkr: false
72193
+ };
72194
+ this.rules[3] = {
72195
+ name: 'lenient-cookie-pair-invalid',
72196
+ lower: 'lenient-cookie-pair-invalid',
72197
+ index: 3,
72198
+ isBkr: false
72199
+ };
72200
+ this.rules[4] = {
72201
+ name: 'lenient-cookie-name',
72202
+ lower: 'lenient-cookie-name',
72203
+ index: 4,
72204
+ isBkr: false
72205
+ };
72206
+ this.rules[5] = {
72207
+ name: 'lenient-cookie-value',
72208
+ lower: 'lenient-cookie-value',
72209
+ index: 5,
72210
+ isBkr: false
72211
+ };
72212
+ this.rules[6] = {
72213
+ name: 'lenient-quoted-value',
72214
+ lower: 'lenient-quoted-value',
72215
+ index: 6,
72216
+ isBkr: false
72217
+ };
72218
+ this.rules[7] = {
72219
+ name: 'lenient-quoted-char',
72220
+ lower: 'lenient-quoted-char',
72221
+ index: 7,
72222
+ isBkr: false
72223
+ };
72224
+ this.rules[8] = {
72225
+ name: 'lenient-cookie-octet',
72226
+ lower: 'lenient-cookie-octet',
72227
+ index: 8,
72228
+ isBkr: false
72229
+ };
72230
+ this.rules[9] = {
72231
+ name: 'cookie-string',
72232
+ lower: 'cookie-string',
72233
+ index: 9,
72234
+ isBkr: false
72235
+ };
72236
+ this.rules[10] = {
72237
+ name: 'cookie-pair',
72238
+ lower: 'cookie-pair',
72239
+ index: 10,
72240
+ isBkr: false
72241
+ };
72242
+ this.rules[11] = {
72243
+ name: 'cookie-name',
72244
+ lower: 'cookie-name',
72245
+ index: 11,
72246
+ isBkr: false
72247
+ };
72248
+ this.rules[12] = {
72249
+ name: 'cookie-value',
72250
+ lower: 'cookie-value',
72251
+ index: 12,
72252
+ isBkr: false
72253
+ };
72254
+ this.rules[13] = {
72255
+ name: 'cookie-octet',
72256
+ lower: 'cookie-octet',
72257
+ index: 13,
72258
+ isBkr: false
72259
+ };
72260
+ this.rules[14] = {
72261
+ name: 'OWS',
72262
+ lower: 'ows',
72263
+ index: 14,
72264
+ isBkr: false
72265
+ };
72266
+ this.rules[15] = {
72267
+ name: 'token',
72268
+ lower: 'token',
72269
+ index: 15,
72270
+ isBkr: false
72271
+ };
72272
+ this.rules[16] = {
72273
+ name: 'tchar',
72274
+ lower: 'tchar',
72275
+ index: 16,
72276
+ isBkr: false
72277
+ };
72278
+ this.rules[17] = {
72279
+ name: 'CHAR',
72280
+ lower: 'char',
72281
+ index: 17,
72282
+ isBkr: false
72283
+ };
72284
+ this.rules[18] = {
72285
+ name: 'CTL',
72286
+ lower: 'ctl',
72287
+ index: 18,
72288
+ isBkr: false
72289
+ };
72290
+ this.rules[19] = {
72291
+ name: 'separators',
72292
+ lower: 'separators',
72293
+ index: 19,
72294
+ isBkr: false
72295
+ };
72296
+ this.rules[20] = {
72297
+ name: 'SP',
72298
+ lower: 'sp',
72299
+ index: 20,
72300
+ isBkr: false
72301
+ };
72302
+ this.rules[21] = {
72303
+ name: 'HT',
72304
+ lower: 'ht',
72305
+ index: 21,
72306
+ isBkr: false
72307
+ };
72308
+ this.rules[22] = {
72309
+ name: 'ALPHA',
72310
+ lower: 'alpha',
72311
+ index: 22,
72312
+ isBkr: false
72313
+ };
72314
+ this.rules[23] = {
72315
+ name: 'DIGIT',
72316
+ lower: 'digit',
72317
+ index: 23,
72318
+ isBkr: false
72319
+ };
72320
+ this.rules[24] = {
72321
+ name: 'DQUOTE',
72322
+ lower: 'dquote',
72323
+ index: 24,
72324
+ isBkr: false
72325
+ };
72326
+ this.rules[25] = {
72327
+ name: 'WSP',
72328
+ lower: 'wsp',
72329
+ index: 25,
72330
+ isBkr: false
72331
+ };
72332
+ this.rules[26] = {
72333
+ name: 'HTAB',
72334
+ lower: 'htab',
72335
+ index: 26,
72336
+ isBkr: false
72337
+ };
72338
+ this.rules[27] = {
72339
+ name: 'CRLF',
72340
+ lower: 'crlf',
72341
+ index: 27,
72342
+ isBkr: false
72343
+ };
72344
+ this.rules[28] = {
72345
+ name: 'CR',
72346
+ lower: 'cr',
72347
+ index: 28,
72348
+ isBkr: false
72349
+ };
72350
+ this.rules[29] = {
72351
+ name: 'LF',
72352
+ lower: 'lf',
72353
+ index: 29,
72354
+ isBkr: false
72355
+ };
72356
+
72357
+ /* UDTS */
72358
+ this.udts = [];
72359
+
72360
+ /* OPCODES */
72361
+ /* lenient-cookie-string */
72362
+ this.rules[0].opcodes = [];
72363
+ this.rules[0].opcodes[0] = {
72364
+ type: 2,
72365
+ children: [1, 2]
72366
+ }; // CAT
72367
+ this.rules[0].opcodes[1] = {
72368
+ type: 4,
72369
+ index: 1
72370
+ }; // RNM(lenient-cookie-entry)
72371
+ this.rules[0].opcodes[2] = {
72372
+ type: 3,
72373
+ min: 0,
72374
+ max: Infinity
72375
+ }; // REP
72376
+ this.rules[0].opcodes[3] = {
72377
+ type: 2,
72378
+ children: [4, 5, 6]
72379
+ }; // CAT
72380
+ this.rules[0].opcodes[4] = {
72381
+ type: 7,
72382
+ string: [59]
72383
+ }; // TLS
72384
+ this.rules[0].opcodes[5] = {
72385
+ type: 4,
72386
+ index: 14
72387
+ }; // RNM(OWS)
72388
+ this.rules[0].opcodes[6] = {
72389
+ type: 4,
72390
+ index: 1
72391
+ }; // RNM(lenient-cookie-entry)
72392
+
72393
+ /* lenient-cookie-entry */
72394
+ this.rules[1].opcodes = [];
72395
+ this.rules[1].opcodes[0] = {
72396
+ type: 1,
72397
+ children: [1, 2]
72398
+ }; // ALT
72399
+ this.rules[1].opcodes[1] = {
72400
+ type: 4,
72401
+ index: 2
72402
+ }; // RNM(lenient-cookie-pair)
72403
+ this.rules[1].opcodes[2] = {
72404
+ type: 4,
72405
+ index: 3
72406
+ }; // RNM(lenient-cookie-pair-invalid)
72407
+
72408
+ /* lenient-cookie-pair */
72409
+ this.rules[2].opcodes = [];
72410
+ this.rules[2].opcodes[0] = {
72411
+ type: 2,
72412
+ children: [1, 2, 3, 4, 5, 6, 7]
72413
+ }; // CAT
72414
+ this.rules[2].opcodes[1] = {
72415
+ type: 4,
72416
+ index: 14
72417
+ }; // RNM(OWS)
72418
+ this.rules[2].opcodes[2] = {
72419
+ type: 4,
72420
+ index: 4
72421
+ }; // RNM(lenient-cookie-name)
72422
+ this.rules[2].opcodes[3] = {
72423
+ type: 4,
72424
+ index: 14
72425
+ }; // RNM(OWS)
72426
+ this.rules[2].opcodes[4] = {
72427
+ type: 7,
72428
+ string: [61]
72429
+ }; // TLS
72430
+ this.rules[2].opcodes[5] = {
72431
+ type: 4,
72432
+ index: 14
72433
+ }; // RNM(OWS)
72434
+ this.rules[2].opcodes[6] = {
72435
+ type: 4,
72436
+ index: 5
72437
+ }; // RNM(lenient-cookie-value)
72438
+ this.rules[2].opcodes[7] = {
72439
+ type: 4,
72440
+ index: 14
72441
+ }; // RNM(OWS)
72442
+
72443
+ /* lenient-cookie-pair-invalid */
72444
+ this.rules[3].opcodes = [];
72445
+ this.rules[3].opcodes[0] = {
72446
+ type: 2,
72447
+ children: [1, 2, 4]
72448
+ }; // CAT
72449
+ this.rules[3].opcodes[1] = {
72450
+ type: 4,
72451
+ index: 14
72452
+ }; // RNM(OWS)
72453
+ this.rules[3].opcodes[2] = {
72454
+ type: 3,
72455
+ min: 1,
72456
+ max: Infinity
72457
+ }; // REP
72458
+ this.rules[3].opcodes[3] = {
72459
+ type: 4,
72460
+ index: 16
72461
+ }; // RNM(tchar)
72462
+ this.rules[3].opcodes[4] = {
72463
+ type: 4,
72464
+ index: 14
72465
+ }; // RNM(OWS)
72466
+
72467
+ /* lenient-cookie-name */
72468
+ this.rules[4].opcodes = [];
72469
+ this.rules[4].opcodes[0] = {
72470
+ type: 3,
72471
+ min: 1,
72472
+ max: Infinity
72473
+ }; // REP
72474
+ this.rules[4].opcodes[1] = {
72475
+ type: 1,
72476
+ children: [2, 3, 4]
72477
+ }; // ALT
72478
+ this.rules[4].opcodes[2] = {
72479
+ type: 5,
72480
+ min: 33,
72481
+ max: 58
72482
+ }; // TRG
72483
+ this.rules[4].opcodes[3] = {
72484
+ type: 6,
72485
+ string: [60]
72486
+ }; // TBS
72487
+ this.rules[4].opcodes[4] = {
72488
+ type: 5,
72489
+ min: 62,
72490
+ max: 126
72491
+ }; // TRG
72492
+
72493
+ /* lenient-cookie-value */
72494
+ this.rules[5].opcodes = [];
72495
+ this.rules[5].opcodes[0] = {
72496
+ type: 1,
72497
+ children: [1, 6]
72498
+ }; // ALT
72499
+ this.rules[5].opcodes[1] = {
72500
+ type: 2,
72501
+ children: [2, 3]
72502
+ }; // CAT
72503
+ this.rules[5].opcodes[2] = {
72504
+ type: 4,
72505
+ index: 6
72506
+ }; // RNM(lenient-quoted-value)
72507
+ this.rules[5].opcodes[3] = {
72508
+ type: 3,
72509
+ min: 0,
72510
+ max: 1
72511
+ }; // REP
72512
+ this.rules[5].opcodes[4] = {
72513
+ type: 3,
72514
+ min: 0,
72515
+ max: Infinity
72516
+ }; // REP
72517
+ this.rules[5].opcodes[5] = {
72518
+ type: 4,
72519
+ index: 8
72520
+ }; // RNM(lenient-cookie-octet)
72521
+ this.rules[5].opcodes[6] = {
72522
+ type: 3,
72523
+ min: 0,
72524
+ max: Infinity
72525
+ }; // REP
72526
+ this.rules[5].opcodes[7] = {
72527
+ type: 4,
72528
+ index: 8
72529
+ }; // RNM(lenient-cookie-octet)
72530
+
72531
+ /* lenient-quoted-value */
72532
+ this.rules[6].opcodes = [];
72533
+ this.rules[6].opcodes[0] = {
72534
+ type: 2,
72535
+ children: [1, 2, 4]
72536
+ }; // CAT
72537
+ this.rules[6].opcodes[1] = {
72538
+ type: 4,
72539
+ index: 24
72540
+ }; // RNM(DQUOTE)
72541
+ this.rules[6].opcodes[2] = {
72542
+ type: 3,
72543
+ min: 0,
72544
+ max: Infinity
72545
+ }; // REP
72546
+ this.rules[6].opcodes[3] = {
72547
+ type: 4,
72548
+ index: 7
72549
+ }; // RNM(lenient-quoted-char)
72550
+ this.rules[6].opcodes[4] = {
72551
+ type: 4,
72552
+ index: 24
72553
+ }; // RNM(DQUOTE)
72554
+
72555
+ /* lenient-quoted-char */
72556
+ this.rules[7].opcodes = [];
72557
+ this.rules[7].opcodes[0] = {
72558
+ type: 1,
72559
+ children: [1, 2]
72560
+ }; // ALT
72561
+ this.rules[7].opcodes[1] = {
72562
+ type: 5,
72563
+ min: 32,
72564
+ max: 33
72565
+ }; // TRG
72566
+ this.rules[7].opcodes[2] = {
72567
+ type: 5,
72568
+ min: 35,
72569
+ max: 126
72570
+ }; // TRG
72571
+
72572
+ /* lenient-cookie-octet */
72573
+ this.rules[8].opcodes = [];
72574
+ this.rules[8].opcodes[0] = {
72575
+ type: 1,
72576
+ children: [1, 2, 3]
72577
+ }; // ALT
72578
+ this.rules[8].opcodes[1] = {
72579
+ type: 5,
72580
+ min: 33,
72581
+ max: 43
72582
+ }; // TRG
72583
+ this.rules[8].opcodes[2] = {
72584
+ type: 5,
72585
+ min: 45,
72586
+ max: 58
72587
+ }; // TRG
72588
+ this.rules[8].opcodes[3] = {
72589
+ type: 5,
72590
+ min: 60,
72591
+ max: 126
72592
+ }; // TRG
72593
+
72594
+ /* cookie-string */
72595
+ this.rules[9].opcodes = [];
72596
+ this.rules[9].opcodes[0] = {
72597
+ type: 2,
72598
+ children: [1, 2]
72599
+ }; // CAT
72600
+ this.rules[9].opcodes[1] = {
72601
+ type: 4,
72602
+ index: 10
72603
+ }; // RNM(cookie-pair)
72604
+ this.rules[9].opcodes[2] = {
72605
+ type: 3,
72606
+ min: 0,
72607
+ max: Infinity
72608
+ }; // REP
72609
+ this.rules[9].opcodes[3] = {
72610
+ type: 2,
72611
+ children: [4, 5, 6]
72612
+ }; // CAT
72613
+ this.rules[9].opcodes[4] = {
72614
+ type: 7,
72615
+ string: [59]
72616
+ }; // TLS
72617
+ this.rules[9].opcodes[5] = {
72618
+ type: 4,
72619
+ index: 20
72620
+ }; // RNM(SP)
72621
+ this.rules[9].opcodes[6] = {
72622
+ type: 4,
72623
+ index: 10
72624
+ }; // RNM(cookie-pair)
72625
+
72626
+ /* cookie-pair */
72627
+ this.rules[10].opcodes = [];
72628
+ this.rules[10].opcodes[0] = {
72629
+ type: 2,
72630
+ children: [1, 2, 3]
72631
+ }; // CAT
72632
+ this.rules[10].opcodes[1] = {
72633
+ type: 4,
72634
+ index: 11
72635
+ }; // RNM(cookie-name)
72636
+ this.rules[10].opcodes[2] = {
72637
+ type: 7,
72638
+ string: [61]
72639
+ }; // TLS
72640
+ this.rules[10].opcodes[3] = {
72641
+ type: 4,
72642
+ index: 12
72643
+ }; // RNM(cookie-value)
72644
+
72645
+ /* cookie-name */
72646
+ this.rules[11].opcodes = [];
72647
+ this.rules[11].opcodes[0] = {
72648
+ type: 4,
72649
+ index: 15
72650
+ }; // RNM(token)
72651
+
72652
+ /* cookie-value */
72653
+ this.rules[12].opcodes = [];
72654
+ this.rules[12].opcodes[0] = {
72655
+ type: 1,
72656
+ children: [1, 6]
72657
+ }; // ALT
72658
+ this.rules[12].opcodes[1] = {
72659
+ type: 2,
72660
+ children: [2, 3, 5]
72661
+ }; // CAT
72662
+ this.rules[12].opcodes[2] = {
72663
+ type: 4,
72664
+ index: 24
72665
+ }; // RNM(DQUOTE)
72666
+ this.rules[12].opcodes[3] = {
72667
+ type: 3,
72668
+ min: 0,
72669
+ max: Infinity
72670
+ }; // REP
72671
+ this.rules[12].opcodes[4] = {
72672
+ type: 4,
72673
+ index: 13
72674
+ }; // RNM(cookie-octet)
72675
+ this.rules[12].opcodes[5] = {
72676
+ type: 4,
72677
+ index: 24
72678
+ }; // RNM(DQUOTE)
72679
+ this.rules[12].opcodes[6] = {
72680
+ type: 3,
72681
+ min: 0,
72682
+ max: Infinity
72683
+ }; // REP
72684
+ this.rules[12].opcodes[7] = {
72685
+ type: 4,
72686
+ index: 13
72687
+ }; // RNM(cookie-octet)
72688
+
72689
+ /* cookie-octet */
72690
+ this.rules[13].opcodes = [];
72691
+ this.rules[13].opcodes[0] = {
72692
+ type: 1,
72693
+ children: [1, 2, 3, 4, 5]
72694
+ }; // ALT
72695
+ this.rules[13].opcodes[1] = {
72696
+ type: 6,
72697
+ string: [33]
72698
+ }; // TBS
72699
+ this.rules[13].opcodes[2] = {
72700
+ type: 5,
72701
+ min: 35,
72702
+ max: 43
72703
+ }; // TRG
72704
+ this.rules[13].opcodes[3] = {
72705
+ type: 5,
72706
+ min: 45,
72707
+ max: 58
72708
+ }; // TRG
72709
+ this.rules[13].opcodes[4] = {
72710
+ type: 5,
72711
+ min: 60,
72712
+ max: 91
72713
+ }; // TRG
72714
+ this.rules[13].opcodes[5] = {
72715
+ type: 5,
72716
+ min: 93,
72717
+ max: 126
72718
+ }; // TRG
72719
+
72720
+ /* OWS */
72721
+ this.rules[14].opcodes = [];
72722
+ this.rules[14].opcodes[0] = {
72723
+ type: 3,
72724
+ min: 0,
72725
+ max: Infinity
72726
+ }; // REP
72727
+ this.rules[14].opcodes[1] = {
72728
+ type: 2,
72729
+ children: [2, 4]
72730
+ }; // CAT
72731
+ this.rules[14].opcodes[2] = {
72732
+ type: 3,
72733
+ min: 0,
72734
+ max: 1
72735
+ }; // REP
72736
+ this.rules[14].opcodes[3] = {
72737
+ type: 4,
72738
+ index: 27
72739
+ }; // RNM(CRLF)
72740
+ this.rules[14].opcodes[4] = {
72741
+ type: 4,
72742
+ index: 25
72743
+ }; // RNM(WSP)
72744
+
72745
+ /* token */
72746
+ this.rules[15].opcodes = [];
72747
+ this.rules[15].opcodes[0] = {
72748
+ type: 3,
72749
+ min: 1,
72750
+ max: Infinity
72751
+ }; // REP
72752
+ this.rules[15].opcodes[1] = {
72753
+ type: 4,
72754
+ index: 16
72755
+ }; // RNM(tchar)
72756
+
72757
+ /* tchar */
72758
+ this.rules[16].opcodes = [];
72759
+ this.rules[16].opcodes[0] = {
72760
+ type: 1,
72761
+ children: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17]
72762
+ }; // ALT
72763
+ this.rules[16].opcodes[1] = {
72764
+ type: 7,
72765
+ string: [33]
72766
+ }; // TLS
72767
+ this.rules[16].opcodes[2] = {
72768
+ type: 7,
72769
+ string: [35]
72770
+ }; // TLS
72771
+ this.rules[16].opcodes[3] = {
72772
+ type: 7,
72773
+ string: [36]
72774
+ }; // TLS
72775
+ this.rules[16].opcodes[4] = {
72776
+ type: 7,
72777
+ string: [37]
72778
+ }; // TLS
72779
+ this.rules[16].opcodes[5] = {
72780
+ type: 7,
72781
+ string: [38]
72782
+ }; // TLS
72783
+ this.rules[16].opcodes[6] = {
72784
+ type: 7,
72785
+ string: [39]
72786
+ }; // TLS
72787
+ this.rules[16].opcodes[7] = {
72788
+ type: 7,
72789
+ string: [42]
72790
+ }; // TLS
72791
+ this.rules[16].opcodes[8] = {
72792
+ type: 7,
72793
+ string: [43]
72794
+ }; // TLS
72795
+ this.rules[16].opcodes[9] = {
72796
+ type: 7,
72797
+ string: [45]
72798
+ }; // TLS
72799
+ this.rules[16].opcodes[10] = {
72800
+ type: 7,
72801
+ string: [46]
72802
+ }; // TLS
72803
+ this.rules[16].opcodes[11] = {
72804
+ type: 7,
72805
+ string: [94]
72806
+ }; // TLS
72807
+ this.rules[16].opcodes[12] = {
72808
+ type: 7,
72809
+ string: [95]
72810
+ }; // TLS
72811
+ this.rules[16].opcodes[13] = {
72812
+ type: 7,
72813
+ string: [96]
72814
+ }; // TLS
72815
+ this.rules[16].opcodes[14] = {
72816
+ type: 7,
72817
+ string: [124]
72818
+ }; // TLS
72819
+ this.rules[16].opcodes[15] = {
72820
+ type: 7,
72821
+ string: [126]
72822
+ }; // TLS
72823
+ this.rules[16].opcodes[16] = {
72824
+ type: 4,
72825
+ index: 23
72826
+ }; // RNM(DIGIT)
72827
+ this.rules[16].opcodes[17] = {
72828
+ type: 4,
72829
+ index: 22
72830
+ }; // RNM(ALPHA)
72831
+
72832
+ /* CHAR */
72833
+ this.rules[17].opcodes = [];
72834
+ this.rules[17].opcodes[0] = {
72835
+ type: 5,
72836
+ min: 1,
72837
+ max: 127
72838
+ }; // TRG
72839
+
72840
+ /* CTL */
72841
+ this.rules[18].opcodes = [];
72842
+ this.rules[18].opcodes[0] = {
72843
+ type: 1,
72844
+ children: [1, 2]
72845
+ }; // ALT
72846
+ this.rules[18].opcodes[1] = {
72847
+ type: 5,
72848
+ min: 0,
72849
+ max: 31
72850
+ }; // TRG
72851
+ this.rules[18].opcodes[2] = {
72852
+ type: 6,
72853
+ string: [127]
72854
+ }; // TBS
72855
+
72856
+ /* separators */
72857
+ this.rules[19].opcodes = [];
72858
+ this.rules[19].opcodes[0] = {
72859
+ type: 1,
72860
+ children: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19]
72861
+ }; // ALT
72862
+ this.rules[19].opcodes[1] = {
72863
+ type: 7,
72864
+ string: [40]
72865
+ }; // TLS
72866
+ this.rules[19].opcodes[2] = {
72867
+ type: 7,
72868
+ string: [41]
72869
+ }; // TLS
72870
+ this.rules[19].opcodes[3] = {
72871
+ type: 7,
72872
+ string: [60]
72873
+ }; // TLS
72874
+ this.rules[19].opcodes[4] = {
72875
+ type: 7,
72876
+ string: [62]
72877
+ }; // TLS
72878
+ this.rules[19].opcodes[5] = {
72879
+ type: 7,
72880
+ string: [64]
72881
+ }; // TLS
72882
+ this.rules[19].opcodes[6] = {
72883
+ type: 7,
72884
+ string: [44]
72885
+ }; // TLS
72886
+ this.rules[19].opcodes[7] = {
72887
+ type: 7,
72888
+ string: [59]
72889
+ }; // TLS
72890
+ this.rules[19].opcodes[8] = {
72891
+ type: 7,
72892
+ string: [58]
72893
+ }; // TLS
72894
+ this.rules[19].opcodes[9] = {
72895
+ type: 7,
72896
+ string: [92]
72897
+ }; // TLS
72898
+ this.rules[19].opcodes[10] = {
72899
+ type: 6,
72900
+ string: [34]
72901
+ }; // TBS
72902
+ this.rules[19].opcodes[11] = {
72903
+ type: 7,
72904
+ string: [47]
72905
+ }; // TLS
72906
+ this.rules[19].opcodes[12] = {
72907
+ type: 7,
72908
+ string: [91]
72909
+ }; // TLS
72910
+ this.rules[19].opcodes[13] = {
72911
+ type: 7,
72912
+ string: [93]
72913
+ }; // TLS
72914
+ this.rules[19].opcodes[14] = {
72915
+ type: 7,
72916
+ string: [63]
72917
+ }; // TLS
72918
+ this.rules[19].opcodes[15] = {
72919
+ type: 7,
72920
+ string: [61]
72921
+ }; // TLS
72922
+ this.rules[19].opcodes[16] = {
72923
+ type: 7,
72924
+ string: [123]
72925
+ }; // TLS
72926
+ this.rules[19].opcodes[17] = {
72927
+ type: 7,
72928
+ string: [125]
72929
+ }; // TLS
72930
+ this.rules[19].opcodes[18] = {
72931
+ type: 4,
72932
+ index: 20
72933
+ }; // RNM(SP)
72934
+ this.rules[19].opcodes[19] = {
72935
+ type: 4,
72936
+ index: 21
72937
+ }; // RNM(HT)
72938
+
72939
+ /* SP */
72940
+ this.rules[20].opcodes = [];
72941
+ this.rules[20].opcodes[0] = {
72942
+ type: 6,
72943
+ string: [32]
72944
+ }; // TBS
72945
+
72946
+ /* HT */
72947
+ this.rules[21].opcodes = [];
72948
+ this.rules[21].opcodes[0] = {
72949
+ type: 6,
72950
+ string: [9]
72951
+ }; // TBS
72952
+
72953
+ /* ALPHA */
72954
+ this.rules[22].opcodes = [];
72955
+ this.rules[22].opcodes[0] = {
72956
+ type: 1,
72957
+ children: [1, 2]
72958
+ }; // ALT
72959
+ this.rules[22].opcodes[1] = {
72960
+ type: 5,
72961
+ min: 65,
72962
+ max: 90
72963
+ }; // TRG
72964
+ this.rules[22].opcodes[2] = {
72965
+ type: 5,
72966
+ min: 97,
72967
+ max: 122
72968
+ }; // TRG
72969
+
72970
+ /* DIGIT */
72971
+ this.rules[23].opcodes = [];
72972
+ this.rules[23].opcodes[0] = {
72973
+ type: 5,
72974
+ min: 48,
72975
+ max: 57
72976
+ }; // TRG
72977
+
72978
+ /* DQUOTE */
72979
+ this.rules[24].opcodes = [];
72980
+ this.rules[24].opcodes[0] = {
72981
+ type: 6,
72982
+ string: [34]
72983
+ }; // TBS
72984
+
72985
+ /* WSP */
72986
+ this.rules[25].opcodes = [];
72987
+ this.rules[25].opcodes[0] = {
72988
+ type: 1,
72989
+ children: [1, 2]
72990
+ }; // ALT
72991
+ this.rules[25].opcodes[1] = {
72992
+ type: 4,
72993
+ index: 20
72994
+ }; // RNM(SP)
72995
+ this.rules[25].opcodes[2] = {
72996
+ type: 4,
72997
+ index: 26
72998
+ }; // RNM(HTAB)
72999
+
73000
+ /* HTAB */
73001
+ this.rules[26].opcodes = [];
73002
+ this.rules[26].opcodes[0] = {
73003
+ type: 6,
73004
+ string: [9]
73005
+ }; // TBS
73006
+
73007
+ /* CRLF */
73008
+ this.rules[27].opcodes = [];
73009
+ this.rules[27].opcodes[0] = {
73010
+ type: 2,
73011
+ children: [1, 2]
73012
+ }; // CAT
73013
+ this.rules[27].opcodes[1] = {
73014
+ type: 4,
73015
+ index: 28
73016
+ }; // RNM(CR)
73017
+ this.rules[27].opcodes[2] = {
73018
+ type: 4,
73019
+ index: 29
73020
+ }; // RNM(LF)
73021
+
73022
+ /* CR */
73023
+ this.rules[28].opcodes = [];
73024
+ this.rules[28].opcodes[0] = {
73025
+ type: 6,
73026
+ string: [13]
73027
+ }; // TBS
73028
+
73029
+ /* LF */
73030
+ this.rules[29].opcodes = [];
73031
+ this.rules[29].opcodes[0] = {
73032
+ type: 6,
73033
+ string: [10]
73034
+ }; // TBS
73035
+
73036
+ // The `toString()` function will display the original grammar file(s) that produced these opcodes.
73037
+ this.toString = function toString() {
73038
+ let str = "";
73039
+ str += "; Lenient version of https://datatracker.ietf.org/doc/html/rfc6265#section-4.2.1\n";
73040
+ str += "lenient-cookie-string = lenient-cookie-entry *( \";\" OWS lenient-cookie-entry )\n";
73041
+ str += "lenient-cookie-entry = lenient-cookie-pair / lenient-cookie-pair-invalid\n";
73042
+ str += "lenient-cookie-pair = OWS lenient-cookie-name OWS \"=\" OWS lenient-cookie-value OWS\n";
73043
+ str += "lenient-cookie-pair-invalid = OWS 1*tchar OWS ; Allow for standalone entries like \"fizz\" to be ignored\n";
73044
+ str += "lenient-cookie-name = 1*( %x21-3A / %x3C / %x3E-7E ) ; Allow all printable US-ASCII except \"=\"\n";
73045
+ str += "lenient-cookie-value = lenient-quoted-value [ *lenient-cookie-octet ] / *lenient-cookie-octet\n";
73046
+ str += "lenient-quoted-value = DQUOTE *( lenient-quoted-char ) DQUOTE\n";
73047
+ str += "lenient-quoted-char = %x20-21 / %x23-7E ; Allow all printable US-ASCII except DQUOTE\n";
73048
+ str += "lenient-cookie-octet = %x21-2B / %x2D-3A / %x3C-7E\n";
73049
+ str += " ; Allow all printable characters except CTLs, semicolon and SP\n";
73050
+ str += "\n";
73051
+ str += "; https://datatracker.ietf.org/doc/html/rfc6265#section-4.2.1\n";
73052
+ str += "cookie-string = cookie-pair *( \";\" SP cookie-pair )\n";
73053
+ str += "\n";
73054
+ str += "; https://datatracker.ietf.org/doc/html/rfc6265#section-4.1.1\n";
73055
+ str += "; https://www.rfc-editor.org/errata/eid5518\n";
73056
+ str += "cookie-pair = cookie-name \"=\" cookie-value\n";
73057
+ str += "cookie-name = token\n";
73058
+ str += "cookie-value = ( DQUOTE *cookie-octet DQUOTE ) / *cookie-octet\n";
73059
+ str += " ; https://www.rfc-editor.org/errata/eid8242\n";
73060
+ str += "cookie-octet = %x21 / %x23-2B / %x2D-3A / %x3C-5B / %x5D-7E\n";
73061
+ str += " ; US-ASCII characters excluding CTLs,\n";
73062
+ str += " ; whitespace, DQUOTE, comma, semicolon,\n";
73063
+ str += " ; and backslash\n";
73064
+ str += "\n";
73065
+ str += "; https://datatracker.ietf.org/doc/html/rfc6265#section-2.2\n";
73066
+ str += "OWS = *( [ CRLF ] WSP ) ; \"optional\" whitespace\n";
73067
+ str += "\n";
73068
+ str += "; https://datatracker.ietf.org/doc/html/rfc9110#section-5.6.2\n";
73069
+ str += "token = 1*(tchar)\n";
73070
+ str += "tchar = \"!\" / \"#\" / \"$\" / \"%\" / \"&\" / \"'\" / \"*\"\n";
73071
+ str += " / \"+\" / \"-\" / \".\" / \"^\" / \"_\" / \"`\" / \"|\" / \"~\"\n";
73072
+ str += " / DIGIT / ALPHA\n";
73073
+ str += " ; any VCHAR, except delimiters\n";
73074
+ str += "\n";
73075
+ str += "; https://datatracker.ietf.org/doc/html/rfc2616#section-2.2\n";
73076
+ str += "CHAR = %x01-7F ; any US-ASCII character (octets 0 - 127)\n";
73077
+ str += "CTL = %x00-1F / %x7F ; any US-ASCII control character\n";
73078
+ str += "separators = \"(\" / \")\" / \"<\" / \">\" / \"@\" / \",\" / \";\" / \":\" / \"\\\" / %x22 / \"/\" / \"[\" / \"]\" / \"?\" / \"=\" / \"{\" / \"}\" / SP / HT\n";
73079
+ str += "SP = %x20 ; US-ASCII SP, space (32)\n";
73080
+ str += "HT = %x09 ; US-ASCII HT, horizontal-tab (9)\n";
73081
+ str += "\n";
73082
+ str += "; https://datatracker.ietf.org/doc/html/rfc5234#appendix-B.1\n";
73083
+ str += "ALPHA = %x41-5A / %x61-7A ; A-Z / a-z\n";
73084
+ str += "DIGIT = %x30-39 ; 0-9\n";
73085
+ str += "DQUOTE = %x22 ; \" (Double Quote)\n";
73086
+ str += "WSP = SP / HTAB ; white space\n";
73087
+ str += "HTAB = %x09 ; horizontal tab\n";
73088
+ str += "CRLF = CR LF ; Internet standard newline\n";
73089
+ str += "CR = %x0D ; carriage return\n";
73090
+ str += "LF = %x0A ; linefeed\n";
73091
+ return str;
73092
+ };
73093
+ }
73094
+
73095
+ /***/ },
73096
+
73097
+ /***/ 36258
73098
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
73099
+
73100
+ "use strict";
73101
+ __webpack_require__.r(__webpack_exports__);
73102
+ /* harmony export */ __webpack_require__.d(__webpack_exports__, {
73103
+ /* harmony export */ Grammar: () => (/* reexport safe */ _grammar_mjs__WEBPACK_IMPORTED_MODULE_0__["default"]),
73104
+ /* harmony export */ base64Encoder: () => (/* reexport safe */ _set_cookie_serialize_encoders_base64_node_mjs__WEBPACK_IMPORTED_MODULE_3__["default"]),
73105
+ /* harmony export */ base64urlEncoder: () => (/* reexport safe */ _set_cookie_serialize_encoders_base64url_node_mjs__WEBPACK_IMPORTED_MODULE_4__["default"]),
73106
+ /* harmony export */ cookieNameLenientPercentEncoder: () => (/* reexport safe */ _set_cookie_serialize_encoders_cookie_name_lenient_percent_mjs__WEBPACK_IMPORTED_MODULE_6__["default"]),
73107
+ /* harmony export */ cookieNameLenientValidator: () => (/* reexport safe */ _set_cookie_serialize_validators_cookie_name_lenient_mjs__WEBPACK_IMPORTED_MODULE_14__["default"]),
73108
+ /* harmony export */ cookieNameStrictPercentEncoder: () => (/* reexport safe */ _set_cookie_serialize_encoders_cookie_name_strict_percent_mjs__WEBPACK_IMPORTED_MODULE_5__["default"]),
73109
+ /* harmony export */ cookieNameStrictValidator: () => (/* reexport safe */ _set_cookie_serialize_validators_cookie_name_strict_mjs__WEBPACK_IMPORTED_MODULE_13__["default"]),
73110
+ /* harmony export */ cookieValueLenientBase64Encoder: () => (/* reexport safe */ _set_cookie_serialize_encoders_cookie_value_lenient_base64_mjs__WEBPACK_IMPORTED_MODULE_11__["default"]),
73111
+ /* harmony export */ cookieValueLenientBase64urlEncoder: () => (/* reexport safe */ _set_cookie_serialize_encoders_cookie_value_lenient_base64url_mjs__WEBPACK_IMPORTED_MODULE_12__["default"]),
73112
+ /* harmony export */ cookieValueLenientPercentEncoder: () => (/* reexport safe */ _set_cookie_serialize_encoders_cookie_value_lenient_percent_mjs__WEBPACK_IMPORTED_MODULE_10__["default"]),
73113
+ /* harmony export */ cookieValueLenientValidator: () => (/* reexport safe */ _set_cookie_serialize_validators_cookie_value_lenient_mjs__WEBPACK_IMPORTED_MODULE_16__["default"]),
73114
+ /* harmony export */ cookieValueStrictBase64Encoder: () => (/* reexport safe */ _set_cookie_serialize_encoders_cookie_value_strict_base64_mjs__WEBPACK_IMPORTED_MODULE_8__["default"]),
73115
+ /* harmony export */ cookieValueStrictBase64urlEncoder: () => (/* reexport safe */ _set_cookie_serialize_encoders_cookie_value_strict_base64url_mjs__WEBPACK_IMPORTED_MODULE_9__["default"]),
73116
+ /* harmony export */ cookieValueStrictPercentEncoder: () => (/* reexport safe */ _set_cookie_serialize_encoders_cookie_value_strict_percent_mjs__WEBPACK_IMPORTED_MODULE_7__["default"]),
73117
+ /* harmony export */ cookieValueStrictValidator: () => (/* reexport safe */ _set_cookie_serialize_validators_cookie_value_strict_mjs__WEBPACK_IMPORTED_MODULE_15__["default"]),
73118
+ /* harmony export */ identity: () => (/* reexport safe */ _utils_mjs__WEBPACK_IMPORTED_MODULE_17__.identity),
73119
+ /* harmony export */ noop: () => (/* reexport safe */ _utils_mjs__WEBPACK_IMPORTED_MODULE_17__.noop),
73120
+ /* harmony export */ parseCookie: () => (/* reexport safe */ _cookie_parse_index_mjs__WEBPACK_IMPORTED_MODULE_1__["default"]),
73121
+ /* harmony export */ serializeCookie: () => (/* reexport safe */ _cookie_serialize_index_mjs__WEBPACK_IMPORTED_MODULE_2__["default"])
73122
+ /* harmony export */ });
73123
+ /* harmony import */ var _grammar_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(67789);
73124
+ /* harmony import */ var _cookie_parse_index_mjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(5789);
73125
+ /* harmony import */ var _cookie_serialize_index_mjs__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(70074);
73126
+ /* harmony import */ var _set_cookie_serialize_encoders_base64_node_mjs__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(99710);
73127
+ /* harmony import */ var _set_cookie_serialize_encoders_base64url_node_mjs__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(5221);
73128
+ /* harmony import */ var _set_cookie_serialize_encoders_cookie_name_strict_percent_mjs__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(25753);
73129
+ /* harmony import */ var _set_cookie_serialize_encoders_cookie_name_lenient_percent_mjs__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(64871);
73130
+ /* harmony import */ var _set_cookie_serialize_encoders_cookie_value_strict_percent_mjs__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(8655);
73131
+ /* harmony import */ var _set_cookie_serialize_encoders_cookie_value_strict_base64_mjs__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(29057);
73132
+ /* harmony import */ var _set_cookie_serialize_encoders_cookie_value_strict_base64url_mjs__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(1428);
73133
+ /* harmony import */ var _set_cookie_serialize_encoders_cookie_value_lenient_percent_mjs__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(20541);
73134
+ /* harmony import */ var _set_cookie_serialize_encoders_cookie_value_lenient_base64_mjs__WEBPACK_IMPORTED_MODULE_11__ = __webpack_require__(93083);
73135
+ /* harmony import */ var _set_cookie_serialize_encoders_cookie_value_lenient_base64url_mjs__WEBPACK_IMPORTED_MODULE_12__ = __webpack_require__(34822);
73136
+ /* harmony import */ var _set_cookie_serialize_validators_cookie_name_strict_mjs__WEBPACK_IMPORTED_MODULE_13__ = __webpack_require__(46319);
73137
+ /* harmony import */ var _set_cookie_serialize_validators_cookie_name_lenient_mjs__WEBPACK_IMPORTED_MODULE_14__ = __webpack_require__(74297);
73138
+ /* harmony import */ var _set_cookie_serialize_validators_cookie_value_strict_mjs__WEBPACK_IMPORTED_MODULE_15__ = __webpack_require__(77901);
73139
+ /* harmony import */ var _set_cookie_serialize_validators_cookie_value_lenient_mjs__WEBPACK_IMPORTED_MODULE_16__ = __webpack_require__(55959);
73140
+ /* harmony import */ var _utils_mjs__WEBPACK_IMPORTED_MODULE_17__ = __webpack_require__(93913);
73141
+
73142
+
73143
+
73144
+ /**
73145
+ * Encoders
73146
+ */
73147
+
73148
+
73149
+
73150
+
73151
+
73152
+
73153
+
73154
+
73155
+
73156
+
73157
+ /**
73158
+ * Validators
73159
+ */
73160
+
73161
+
73162
+
73163
+
73164
+ /**
73165
+ * Utils
73166
+ */
73167
+
73168
+
73169
+ /***/ },
73170
+
73171
+ /***/ 99710
73172
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
73173
+
73174
+ "use strict";
73175
+ __webpack_require__.r(__webpack_exports__);
73176
+ const base64Encoder = input => {
73177
+ const bytes = new TextEncoder().encode(input);
73178
+ const binaryString = bytes.reduce((acc, byte) => acc + String.fromCharCode(byte), '');
73179
+ return btoa(binaryString);
73180
+ };
73181
+ /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (base64Encoder);
73182
+ /* harmony export */ __webpack_require__.d(__webpack_exports__, [
73183
+ /* harmony export */ "default", 0, __WEBPACK_DEFAULT_EXPORT__
73184
+ /* harmony export */ ]);
73185
+
73186
+
73187
+ /***/ },
73188
+
73189
+ /***/ 5221
73190
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
73191
+
73192
+ "use strict";
73193
+ __webpack_require__.r(__webpack_exports__);
73194
+ /* harmony import */ var _utils_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(93913);
73195
+ /* harmony import */ var _base64_browser_mjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(99710);
73196
+
73197
+
73198
+ const base64urlEncoder = input => {
73199
+ return (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_0__.toBase64url)((0,_base64_browser_mjs__WEBPACK_IMPORTED_MODULE_1__["default"])(input));
73200
+ };
73201
+ /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (base64urlEncoder);
73202
+ /* harmony export */ __webpack_require__.d(__webpack_exports__, [
73203
+ /* harmony export */ "default", 0, __WEBPACK_DEFAULT_EXPORT__
73204
+ /* harmony export */ ]);
73205
+
73206
+
73207
+ /***/ },
73208
+
73209
+ /***/ 64871
73210
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
73211
+
73212
+ "use strict";
73213
+ __webpack_require__.r(__webpack_exports__);
73214
+ /* harmony import */ var _cookie_test_cookie_name_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(16552);
73215
+ /* harmony import */ var _utils_mjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(93913);
73216
+
73217
+
73218
+ const cookieNameLenientPercentEncoder = cookieName => {
73219
+ const value = String(cookieName);
73220
+ let result = '';
73221
+ for (const char of value) {
73222
+ result += (0,_cookie_test_cookie_name_mjs__WEBPACK_IMPORTED_MODULE_0__["default"])(char, {
73223
+ strict: false
73224
+ }) ? char : (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.percentEncodeChar)(char);
73225
+ }
73226
+ return result;
73227
+ };
73228
+ /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (cookieNameLenientPercentEncoder);
73229
+ /* harmony export */ __webpack_require__.d(__webpack_exports__, [
73230
+ /* harmony export */ "default", 0, __WEBPACK_DEFAULT_EXPORT__
73231
+ /* harmony export */ ]);
73232
+
73233
+
73234
+ /***/ },
73235
+
73236
+ /***/ 25753
73237
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
73238
+
73239
+ "use strict";
73240
+ __webpack_require__.r(__webpack_exports__);
73241
+ /* harmony import */ var _cookie_test_cookie_name_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(16552);
73242
+ /* harmony import */ var _utils_mjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(93913);
73243
+
73244
+
73245
+ const cookieNameStrictPercentEncoder = cookieName => {
73246
+ const value = String(cookieName);
73247
+ let result = '';
73248
+ for (const char of value) {
73249
+ result += (0,_cookie_test_cookie_name_mjs__WEBPACK_IMPORTED_MODULE_0__["default"])(char) ? char : (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_1__.percentEncodeChar)(char);
73250
+ }
73251
+ return result;
73252
+ };
73253
+ /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (cookieNameStrictPercentEncoder);
73254
+ /* harmony export */ __webpack_require__.d(__webpack_exports__, [
73255
+ /* harmony export */ "default", 0, __WEBPACK_DEFAULT_EXPORT__
73256
+ /* harmony export */ ]);
73257
+
73258
+
73259
+ /***/ },
73260
+
73261
+ /***/ 93083
73262
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
73263
+
73264
+ "use strict";
73265
+ __webpack_require__.r(__webpack_exports__);
73266
+ /* harmony import */ var _cookie_test_cookie_value_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23396);
73267
+ /* harmony import */ var _base64_node_mjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(99710);
73268
+ /* harmony import */ var _utils_mjs__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(93913);
73269
+
73270
+
73271
+
73272
+ const cookieValueLenientBase64Encoder = (cookieValue, encoder = _base64_node_mjs__WEBPACK_IMPORTED_MODULE_1__["default"]) => {
73273
+ const value = String(cookieValue);
73274
+
73275
+ // return early if the value is already valid
73276
+ if ((0,_cookie_test_cookie_value_mjs__WEBPACK_IMPORTED_MODULE_0__["default"])(value, {
73277
+ strict: false
73278
+ })) return value;
73279
+
73280
+ // detect if the value is quoted
73281
+ const isQuoted = (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_2__.isQuoted)(value);
73282
+
73283
+ // remove quotes if present for processing
73284
+ const valueToEncode = isQuoted ? (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_2__.unquote)(value) : value;
73285
+
73286
+ // encode the value
73287
+ const result = encoder(valueToEncode);
73288
+
73289
+ // return quoted if input was quoted, unquoted otherwise
73290
+ return isQuoted ? (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_2__.quote)(result) : result;
73291
+ };
73292
+ /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (cookieValueLenientBase64Encoder);
73293
+ /* harmony export */ __webpack_require__.d(__webpack_exports__, [
73294
+ /* harmony export */ "default", 0, __WEBPACK_DEFAULT_EXPORT__
73295
+ /* harmony export */ ]);
73296
+
73297
+
73298
+ /***/ },
73299
+
73300
+ /***/ 34822
73301
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
73302
+
73303
+ "use strict";
73304
+ __webpack_require__.r(__webpack_exports__);
73305
+ /* harmony import */ var _cookie_value_lenient_base64_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(93083);
73306
+ /* harmony import */ var _base64url_node_mjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(5221);
73307
+
73308
+
73309
+ const cookieValueLenientBase64urlEncoder = cookieValue => {
73310
+ return (0,_cookie_value_lenient_base64_mjs__WEBPACK_IMPORTED_MODULE_0__["default"])(cookieValue, _base64url_node_mjs__WEBPACK_IMPORTED_MODULE_1__["default"]);
73311
+ };
73312
+ /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (cookieValueLenientBase64urlEncoder);
73313
+ /* harmony export */ __webpack_require__.d(__webpack_exports__, [
73314
+ /* harmony export */ "default", 0, __WEBPACK_DEFAULT_EXPORT__
73315
+ /* harmony export */ ]);
73316
+
73317
+
73318
+ /***/ },
73319
+
73320
+ /***/ 20541
73321
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
73322
+
73323
+ "use strict";
73324
+ __webpack_require__.r(__webpack_exports__);
73325
+ /* harmony import */ var apg_lite__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(51751);
73326
+ /* harmony import */ var _grammar_mjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(67789);
73327
+ /* harmony import */ var _utils_mjs__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(93913);
73328
+ /* harmony import */ var _cookie_test_cookie_value_mjs__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(23396);
73329
+
73330
+
73331
+
73332
+
73333
+ const parser = new apg_lite__WEBPACK_IMPORTED_MODULE_0__.Parser();
73334
+ const grammar = new _grammar_mjs__WEBPACK_IMPORTED_MODULE_1__["default"]();
73335
+ const cookieValueLenientPercentEncoder = cookieValue => {
73336
+ const value = String(cookieValue);
73337
+
73338
+ // return early if the value is already valid
73339
+ if ((0,_cookie_test_cookie_value_mjs__WEBPACK_IMPORTED_MODULE_3__["default"])(value, {
73340
+ strict: false
73341
+ })) return value;
73342
+
73343
+ // detect if the value is quoted
73344
+ const isQuoted = (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_2__.isQuoted)(value);
73345
+
73346
+ // remove quotes if present for processing
73347
+ const valueToEncode = isQuoted ? (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_2__.unquote)(value) : value;
73348
+ const startRule = isQuoted ? 'lenient-quoted-char' : 'lenient-cookie-octet';
73349
+ let result = '';
73350
+ for (const char of valueToEncode) {
73351
+ result += parser.parse(grammar, startRule, char).success ? char : (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_2__.percentEncodeChar)(char);
73352
+ }
73353
+
73354
+ // return quoted if input was quoted, unquoted otherwise
73355
+ return isQuoted ? (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_2__.quote)(result) : result;
73356
+ };
73357
+ /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (cookieValueLenientPercentEncoder);
73358
+ /* harmony export */ __webpack_require__.d(__webpack_exports__, [
73359
+ /* harmony export */ "default", 0, __WEBPACK_DEFAULT_EXPORT__
73360
+ /* harmony export */ ]);
73361
+
73362
+
73363
+ /***/ },
73364
+
73365
+ /***/ 29057
73366
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
73367
+
73368
+ "use strict";
73369
+ __webpack_require__.r(__webpack_exports__);
73370
+ /* harmony import */ var _cookie_test_cookie_value_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23396);
73371
+ /* harmony import */ var _base64_node_mjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(99710);
73372
+ /* harmony import */ var _utils_mjs__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(93913);
73373
+
73374
+
73375
+
73376
+ const cookieValueStrictBase64Encoder = (cookieValue, encoder = _base64_node_mjs__WEBPACK_IMPORTED_MODULE_1__["default"]) => {
73377
+ const value = String(cookieValue);
73378
+
73379
+ // return early if the value is already valid
73380
+ if ((0,_cookie_test_cookie_value_mjs__WEBPACK_IMPORTED_MODULE_0__["default"])(value)) return value;
73381
+
73382
+ // detect if the value is quoted
73383
+ const isQuoted = (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_2__.isQuoted)(value);
73384
+
73385
+ // remove quotes if present for processing
73386
+ const valueToEncode = isQuoted ? (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_2__.unquote)(value) : value;
73387
+
73388
+ // base64 encode the value
73389
+ const base64EncodedValue = encoder(valueToEncode);
73390
+
73391
+ // return quoted if input was quoted, unquoted otherwise
73392
+ return isQuoted ? (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_2__.quote)(base64EncodedValue) : base64EncodedValue;
73393
+ };
73394
+ /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (cookieValueStrictBase64Encoder);
73395
+ /* harmony export */ __webpack_require__.d(__webpack_exports__, [
73396
+ /* harmony export */ "default", 0, __WEBPACK_DEFAULT_EXPORT__
73397
+ /* harmony export */ ]);
73398
+
73399
+
73400
+ /***/ },
73401
+
73402
+ /***/ 1428
73403
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
73404
+
73405
+ "use strict";
73406
+ __webpack_require__.r(__webpack_exports__);
73407
+ /* harmony import */ var _cookie_value_strict_base64_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(29057);
73408
+ /* harmony import */ var _base64url_node_mjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(5221);
73409
+
73410
+
73411
+ const cookieValueStrictBase64urlEncoder = cookieValue => {
73412
+ return (0,_cookie_value_strict_base64_mjs__WEBPACK_IMPORTED_MODULE_0__["default"])(cookieValue, _base64url_node_mjs__WEBPACK_IMPORTED_MODULE_1__["default"]);
73413
+ };
73414
+ /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (cookieValueStrictBase64urlEncoder);
73415
+ /* harmony export */ __webpack_require__.d(__webpack_exports__, [
73416
+ /* harmony export */ "default", 0, __WEBPACK_DEFAULT_EXPORT__
73417
+ /* harmony export */ ]);
73418
+
73419
+
73420
+ /***/ },
73421
+
73422
+ /***/ 8655
73423
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
73424
+
73425
+ "use strict";
73426
+ __webpack_require__.r(__webpack_exports__);
73427
+ /* harmony import */ var apg_lite__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(51751);
73428
+ /* harmony import */ var _grammar_mjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(67789);
73429
+ /* harmony import */ var _utils_mjs__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(93913);
73430
+ /* harmony import */ var _cookie_test_cookie_value_mjs__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(23396);
73431
+
73432
+
73433
+
73434
+
73435
+ const parser = new apg_lite__WEBPACK_IMPORTED_MODULE_0__.Parser();
73436
+ const grammar = new _grammar_mjs__WEBPACK_IMPORTED_MODULE_1__["default"]();
73437
+ const cookieValueStrictPercentEncoder = cookieValue => {
73438
+ const value = String(cookieValue);
73439
+
73440
+ // return early if the value is already valid
73441
+ if ((0,_cookie_test_cookie_value_mjs__WEBPACK_IMPORTED_MODULE_3__["default"])(value)) return value;
73442
+
73443
+ // detect if the value is quoted
73444
+ const isQuoted = (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_2__.isQuoted)(value);
73445
+
73446
+ // remove quotes if present for processing
73447
+ const valueToEncode = isQuoted ? (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_2__.unquote)(value) : value;
73448
+ let result = '';
73449
+ for (const char of valueToEncode) {
73450
+ result += parser.parse(grammar, 'cookie-octet', char).success ? char : (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_2__.percentEncodeChar)(char);
73451
+ }
73452
+
73453
+ // return quoted if input was quoted, unquoted otherwise
73454
+ return isQuoted ? (0,_utils_mjs__WEBPACK_IMPORTED_MODULE_2__.quote)(result) : result;
73455
+ };
73456
+ /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (cookieValueStrictPercentEncoder);
73457
+ /* harmony export */ __webpack_require__.d(__webpack_exports__, [
73458
+ /* harmony export */ "default", 0, __WEBPACK_DEFAULT_EXPORT__
73459
+ /* harmony export */ ]);
73460
+
73461
+
73462
+ /***/ },
73463
+
73464
+ /***/ 51575
73465
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
73466
+
73467
+ "use strict";
73468
+ __webpack_require__.r(__webpack_exports__);
73469
+ /* harmony import */ var _encoders_cookie_value_strict_base64url_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1428);
73470
+ /* harmony import */ var _validators_cookie_name_strict_mjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(46319);
73471
+ /* harmony import */ var _validators_cookie_value_strict_mjs__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(77901);
73472
+ /* harmony import */ var _utils_mjs__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(93913);
73473
+
73474
+
73475
+
73476
+
73477
+ const defaultOptions = {
73478
+ encoders: {
73479
+ name: _utils_mjs__WEBPACK_IMPORTED_MODULE_3__.identity,
73480
+ value: _encoders_cookie_value_strict_base64url_mjs__WEBPACK_IMPORTED_MODULE_0__["default"]
73481
+ },
73482
+ validators: {
73483
+ name: _validators_cookie_name_strict_mjs__WEBPACK_IMPORTED_MODULE_1__["default"],
73484
+ value: _validators_cookie_value_strict_mjs__WEBPACK_IMPORTED_MODULE_2__["default"]
73485
+ }
73486
+ };
73487
+ const serialize = (name, value, options = {}) => {
73488
+ const mergedOptions = {
73489
+ ...defaultOptions,
73490
+ ...options,
73491
+ encoders: {
73492
+ ...defaultOptions.encoders,
73493
+ ...options.encoders
73494
+ },
73495
+ validators: {
73496
+ ...defaultOptions.validators,
73497
+ ...options.validators
73498
+ }
73499
+ };
73500
+ const encodedName = mergedOptions.encoders.name(name);
73501
+ const encodedValue = mergedOptions.encoders.value(value);
73502
+ mergedOptions.validators.name(encodedName);
73503
+ mergedOptions.validators.value(encodedValue);
73504
+ return `${encodedName}=${encodedValue}`;
73505
+ };
73506
+ /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (serialize);
73507
+ /* harmony export */ __webpack_require__.d(__webpack_exports__, [
73508
+ /* harmony export */ "default", 0, __WEBPACK_DEFAULT_EXPORT__
73509
+ /* harmony export */ ]);
73510
+
73511
+
73512
+ /***/ },
73513
+
73514
+ /***/ 74297
73515
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
73516
+
73517
+ "use strict";
73518
+ __webpack_require__.r(__webpack_exports__);
73519
+ /* harmony import */ var _cookie_test_cookie_name_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(16552);
73520
+
73521
+ const cookieNameLenientValidator = cookieName => {
73522
+ if (!(0,_cookie_test_cookie_name_mjs__WEBPACK_IMPORTED_MODULE_0__["default"])(cookieName, {
73523
+ strict: false
73524
+ })) {
73525
+ throw new TypeError(`Invalid cookie name: ${cookieName}`);
73526
+ }
73527
+ };
73528
+ /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (cookieNameLenientValidator);
73529
+ /* harmony export */ __webpack_require__.d(__webpack_exports__, [
73530
+ /* harmony export */ "default", 0, __WEBPACK_DEFAULT_EXPORT__
73531
+ /* harmony export */ ]);
73532
+
73533
+
73534
+ /***/ },
73535
+
73536
+ /***/ 46319
73537
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
73538
+
73539
+ "use strict";
73540
+ __webpack_require__.r(__webpack_exports__);
73541
+ /* harmony import */ var _cookie_test_cookie_name_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(16552);
73542
+
73543
+ const cookieNameStrictValidator = cookieName => {
73544
+ if (!(0,_cookie_test_cookie_name_mjs__WEBPACK_IMPORTED_MODULE_0__["default"])(cookieName)) {
73545
+ throw new TypeError(`Invalid cookie name: ${cookieName}`);
73546
+ }
73547
+ };
73548
+ /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (cookieNameStrictValidator);
73549
+ /* harmony export */ __webpack_require__.d(__webpack_exports__, [
73550
+ /* harmony export */ "default", 0, __WEBPACK_DEFAULT_EXPORT__
73551
+ /* harmony export */ ]);
73552
+
73553
+
73554
+ /***/ },
73555
+
73556
+ /***/ 55959
73557
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
73558
+
73559
+ "use strict";
73560
+ __webpack_require__.r(__webpack_exports__);
73561
+ /* harmony import */ var _cookie_test_cookie_value_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23396);
73562
+
73563
+ const cookieValueLenientValidator = cookieValue => {
73564
+ if (!(0,_cookie_test_cookie_value_mjs__WEBPACK_IMPORTED_MODULE_0__["default"])(cookieValue, {
73565
+ strict: false
73566
+ })) {
73567
+ throw new TypeError(`Invalid cookie value: ${cookieValue}`);
73568
+ }
73569
+ };
73570
+ /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (cookieValueLenientValidator);
73571
+ /* harmony export */ __webpack_require__.d(__webpack_exports__, [
73572
+ /* harmony export */ "default", 0, __WEBPACK_DEFAULT_EXPORT__
73573
+ /* harmony export */ ]);
73574
+
73575
+
73576
+ /***/ },
73577
+
73578
+ /***/ 77901
73579
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
73580
+
73581
+ "use strict";
73582
+ __webpack_require__.r(__webpack_exports__);
73583
+ /* harmony import */ var _cookie_test_cookie_value_mjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(23396);
73584
+
73585
+ const cookieValueStrictValidator = cookieValue => {
73586
+ if (!(0,_cookie_test_cookie_value_mjs__WEBPACK_IMPORTED_MODULE_0__["default"])(cookieValue)) {
73587
+ throw new TypeError(`Invalid cookie value: ${cookieValue}`);
73588
+ }
73589
+ };
73590
+ /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (cookieValueStrictValidator);
73591
+ /* harmony export */ __webpack_require__.d(__webpack_exports__, [
73592
+ /* harmony export */ "default", 0, __WEBPACK_DEFAULT_EXPORT__
73593
+ /* harmony export */ ]);
73594
+
73595
+
73596
+ /***/ },
73597
+
73598
+ /***/ 93913
73599
+ (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
73600
+
73601
+ "use strict";
73602
+ __webpack_require__.r(__webpack_exports__);
73603
+ const percentEncodeChar = char => {
73604
+ if (typeof char !== 'string' || [...char].length !== 1) {
73605
+ throw new TypeError('Input must be a single character string.');
73606
+ }
73607
+ const codePoint = char.codePointAt(0);
73608
+ if (codePoint <= 0x7f) {
73609
+ // ASCII range: Encode as %XX
73610
+ return `%${codePoint.toString(16).toUpperCase().padStart(2, '0')}`;
73611
+ } else {
73612
+ // Non-ASCII range: Use encodeURIComponent to handle UTF-8 encoding
73613
+ return encodeURIComponent(char);
73614
+ }
73615
+ };
73616
+ const toBase64url = base64 => {
73617
+ return base64.replace(/\+/g, '-').replace(/\//g, '_').replace(/=+$/g, '');
73618
+ };
73619
+ const toBase64 = base64url => {
73620
+ const base64 = base64url.replace(/-/g, '+').replace(/_/g, '/');
73621
+ const padding = '='.repeat((4 - base64.length % 4) % 4);
73622
+ return `${base64}${padding}`;
73623
+ };
73624
+ const isQuoted = value => {
73625
+ return value.length >= 2 && value.startsWith('"') && value.endsWith('"');
73626
+ };
73627
+ const unquote = value => {
73628
+ return isQuoted(value) ? value.slice(1, -1) : value;
73629
+ };
73630
+ const quote = value => {
73631
+ return `"${value}"`;
73632
+ };
73633
+ const identity = a => a;
73634
+ const noop = () => {};
73635
+ /* harmony export */ __webpack_require__.d(__webpack_exports__, [
73636
+ /* harmony export */ "identity", 0, /* binding */ identity,
73637
+ /* harmony export */ "isQuoted", 0, /* binding */ isQuoted,
73638
+ /* harmony export */ "noop", 0, /* binding */ noop,
73639
+ /* harmony export */ "percentEncodeChar", 0, /* binding */ percentEncodeChar,
73640
+ /* harmony export */ "quote", 0, /* binding */ quote,
73641
+ /* harmony export */ "toBase64", 0, /* binding */ toBase64,
73642
+ /* harmony export */ "toBase64url", 0, /* binding */ toBase64url,
73643
+ /* harmony export */ "unquote", 0, /* binding */ unquote
73644
+ /* harmony export */ ]);
73645
+
73646
+
71767
73647
  /***/ },
71768
73648
 
71769
73649
  /***/ 96901