@loaders.gl/crypto 4.0.0-beta.2 → 4.0.0-beta.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (101) hide show
  1. package/dist/crypto-worker-node.js +1 -1
  2. package/dist/crypto-worker-node.js.map +2 -2
  3. package/dist/crypto-worker.js +1 -1
  4. package/dist/crypto-worker.js.map +2 -2
  5. package/dist/dist.dev.js +846 -0
  6. package/dist/index.cjs +1341 -0
  7. package/dist/index.d.ts +1 -1
  8. package/dist/index.d.ts.map +1 -1
  9. package/dist/index.js +28 -0
  10. package/dist/index.js.map +1 -0
  11. package/dist/{esm/lib → lib}/algorithms/crc32.js +1 -2
  12. package/dist/lib/algorithms/crc32.js.map +1 -0
  13. package/dist/{esm/lib → lib}/algorithms/crc32c.js +2 -3
  14. package/dist/lib/algorithms/crc32c.js.map +1 -0
  15. package/dist/lib/algorithms/md5-wasm.js.map +1 -0
  16. package/dist/{esm/lib → lib}/crc32-hash.js +6 -7
  17. package/dist/lib/crc32-hash.js.map +1 -0
  18. package/dist/{esm/lib → lib}/crc32c-hash.js +6 -7
  19. package/dist/lib/crc32c-hash.js.map +1 -0
  20. package/dist/lib/crypto-hash.d.ts.map +1 -1
  21. package/dist/{esm/lib → lib}/crypto-hash.js +8 -9
  22. package/dist/lib/crypto-hash.js.map +1 -0
  23. package/dist/{esm/lib → lib}/hash.js +2 -3
  24. package/dist/lib/hash.js.map +1 -0
  25. package/dist/{esm/lib → lib}/md5-hash.js +5 -6
  26. package/dist/lib/md5-hash.js.map +1 -0
  27. package/dist/{esm/lib → lib}/sha256-hash.js +1 -1
  28. package/dist/lib/sha256-hash.js.map +1 -0
  29. package/dist/{esm/lib → lib}/utils/base64-utils.js +2 -2
  30. package/dist/lib/utils/base64-utils.js.map +1 -0
  31. package/dist/{esm/lib → lib}/utils/digest-utils.js +3 -3
  32. package/dist/lib/utils/digest-utils.js.map +1 -0
  33. package/dist/types.js.map +1 -0
  34. package/dist/{esm/workers → workers}/worker.js +4 -4
  35. package/dist/workers/worker.js.map +1 -0
  36. package/package.json +16 -8
  37. package/src/index.ts +4 -1
  38. package/src/lib/crypto-hash.ts +4 -8
  39. package/dist/bundle.d.ts +0 -2
  40. package/dist/bundle.d.ts.map +0 -1
  41. package/dist/dist.min.js +0 -2
  42. package/dist/dist.min.js.map +0 -7
  43. package/dist/es5/bundle.js +0 -6
  44. package/dist/es5/bundle.js.map +0 -1
  45. package/dist/es5/index.js +0 -102
  46. package/dist/es5/index.js.map +0 -1
  47. package/dist/es5/lib/algorithms/crc32.js +0 -41
  48. package/dist/es5/lib/algorithms/crc32.js.map +0 -1
  49. package/dist/es5/lib/algorithms/crc32c.js +0 -44
  50. package/dist/es5/lib/algorithms/crc32c.js.map +0 -1
  51. package/dist/es5/lib/algorithms/md5-wasm.js +0 -436
  52. package/dist/es5/lib/algorithms/md5-wasm.js.map +0 -1
  53. package/dist/es5/lib/crc32-hash.js +0 -148
  54. package/dist/es5/lib/crc32-hash.js.map +0 -1
  55. package/dist/es5/lib/crc32c-hash.js +0 -147
  56. package/dist/es5/lib/crc32c-hash.js.map +0 -1
  57. package/dist/es5/lib/crypto-hash.js +0 -189
  58. package/dist/es5/lib/crypto-hash.js.map +0 -1
  59. package/dist/es5/lib/hash.js +0 -150
  60. package/dist/es5/lib/hash.js.map +0 -1
  61. package/dist/es5/lib/md5-hash.js +0 -66
  62. package/dist/es5/lib/md5-hash.js.map +0 -1
  63. package/dist/es5/lib/node-hash.js +0 -155
  64. package/dist/es5/lib/node-hash.js.map +0 -1
  65. package/dist/es5/lib/sha256-hash.js +0 -33
  66. package/dist/es5/lib/sha256-hash.js.map +0 -1
  67. package/dist/es5/lib/utils/base64-utils.js +0 -94
  68. package/dist/es5/lib/utils/base64-utils.js.map +0 -1
  69. package/dist/es5/lib/utils/digest-utils.js +0 -61
  70. package/dist/es5/lib/utils/digest-utils.js.map +0 -1
  71. package/dist/es5/types.js +0 -2
  72. package/dist/es5/types.js.map +0 -1
  73. package/dist/es5/workers/worker.js +0 -67
  74. package/dist/es5/workers/worker.js.map +0 -1
  75. package/dist/esm/bundle.js +0 -4
  76. package/dist/esm/bundle.js.map +0 -1
  77. package/dist/esm/index.js +0 -28
  78. package/dist/esm/index.js.map +0 -1
  79. package/dist/esm/lib/algorithms/crc32.js.map +0 -1
  80. package/dist/esm/lib/algorithms/crc32c.js.map +0 -1
  81. package/dist/esm/lib/algorithms/md5-wasm.js.map +0 -1
  82. package/dist/esm/lib/crc32-hash.js.map +0 -1
  83. package/dist/esm/lib/crc32c-hash.js.map +0 -1
  84. package/dist/esm/lib/crypto-hash.js.map +0 -1
  85. package/dist/esm/lib/hash.js.map +0 -1
  86. package/dist/esm/lib/md5-hash.js.map +0 -1
  87. package/dist/esm/lib/node-hash.js +0 -52
  88. package/dist/esm/lib/node-hash.js.map +0 -1
  89. package/dist/esm/lib/sha256-hash.js.map +0 -1
  90. package/dist/esm/lib/utils/base64-utils.js.map +0 -1
  91. package/dist/esm/lib/utils/digest-utils.js.map +0 -1
  92. package/dist/esm/types.js.map +0 -1
  93. package/dist/esm/workers/cryptojs-worker.ts.disabled +0 -26
  94. package/dist/esm/workers/worker.js.map +0 -1
  95. package/dist/lib/node-hash.d.ts +0 -28
  96. package/dist/lib/node-hash.d.ts.map +0 -1
  97. package/src/bundle.ts +0 -4
  98. package/src/lib/node-hash.ts +0 -65
  99. /package/dist/{esm/lib → lib}/algorithms/md5-wasm.js +0 -0
  100. /package/dist/{esm/types.js → types.js} +0 -0
  101. /package/dist/{es5/workers → workers}/cryptojs-worker.ts.disabled +0 -0
package/package.json CHANGED
@@ -1,8 +1,9 @@
1
1
  {
2
2
  "name": "@loaders.gl/crypto",
3
- "version": "4.0.0-beta.2",
3
+ "version": "4.0.0-beta.4",
4
4
  "description": "Cryptographic/hashing plugins for loaders.gl",
5
5
  "license": "MIT",
6
+ "type": "module",
6
7
  "publishConfig": {
7
8
  "access": "public"
8
9
  },
@@ -18,8 +19,15 @@
18
19
  "point cloud"
19
20
  ],
20
21
  "types": "dist/index.d.ts",
21
- "main": "dist/es5/index.js",
22
- "module": "dist/esm/index.js",
22
+ "main": "dist/index.cjs",
23
+ "module": "dist/index.js",
24
+ "exports": {
25
+ ".": {
26
+ "import": "./dist/index.js",
27
+ "require": "./dist/index.cjs",
28
+ "types": "./dist/index.d.ts"
29
+ }
30
+ },
23
31
  "sideEffects": false,
24
32
  "files": [
25
33
  "src",
@@ -27,15 +35,15 @@
27
35
  "README.md"
28
36
  ],
29
37
  "scripts": {
30
- "pre-build": "npm run build-bundle && npm run build-worker && npm run build-worker-node",
31
- "build-bundle": "esbuild src/bundle.ts --outfile=dist/dist.min.js --bundle --minify --sourcemap",
38
+ "pre-build": "npm run build-bundle && npm run build-bundle -- --env=dev && npm run build-worker && npm run build-worker-node",
39
+ "build-bundle": "ocular-bundle ./src/index.ts",
32
40
  "build-worker": "esbuild src/workers/worker.ts --outfile=dist/crypto-worker.js --target=esnext --bundle --minify --sourcemap --define:__VERSION__=\\\"$npm_package_version\\\"",
33
41
  "build-worker-node": "esbuild src/workers/worker.ts --outfile=dist/crypto-worker-node.js --platform=node --target=esnext,node16 --bundle --minify --sourcemap --define:__VERSION__=\\\"$npm_package_version\\\""
34
42
  },
35
43
  "dependencies": {
36
44
  "@babel/runtime": "^7.3.1",
37
- "@loaders.gl/loader-utils": "4.0.0-beta.2",
38
- "@loaders.gl/worker-utils": "4.0.0-beta.2",
45
+ "@loaders.gl/loader-utils": "4.0.0-beta.4",
46
+ "@loaders.gl/worker-utils": "4.0.0-beta.4",
39
47
  "@types/crypto-js": "^4.0.2"
40
48
  },
41
49
  "devDependencies": {
@@ -45,5 +53,5 @@
45
53
  "crypto": false,
46
54
  "sse4_crc32": false
47
55
  },
48
- "gitHead": "79c2033f755e88e11bc30a04428e3666b177b8fc"
56
+ "gitHead": "848c20b474532d301f2c3f8d4e1fb9bf262b86d4"
49
57
  }
package/src/index.ts CHANGED
@@ -4,13 +4,16 @@
4
4
  // @ts-ignore TS2304: Cannot find name '__VERSION__'.
5
5
  const VERSION = typeof __VERSION__ !== 'undefined' ? __VERSION__ : 'latest';
6
6
 
7
+ export {Hash} from './lib/hash';
8
+
7
9
  export {CRC32Hash} from './lib/crc32-hash';
8
10
  export {CRC32CHash} from './lib/crc32c-hash';
9
11
  export {MD5Hash} from './lib/md5-hash';
10
12
  export {SHA256Hash} from './lib/sha256-hash';
11
13
 
12
14
  export {CryptoHash} from './lib/crypto-hash';
13
- export {NodeHash} from './lib/node-hash';
15
+ // TODO - moved to polyfills
16
+ // export {NodeHash} from './lib/node-hash';
14
17
 
15
18
  /**
16
19
  * Small, fast worker for CRC32, CRC32c and MD5 Hashes
@@ -1,5 +1,3 @@
1
- // This dependency is too big, application must provide it
2
- import type * as CryptoJSNamespace from 'crypto-js';
3
1
  import {Hash} from './hash';
4
2
 
5
3
  type CryptoHashOptions = {
@@ -10,7 +8,7 @@ type CryptoHashOptions = {
10
8
  };
11
9
  };
12
10
 
13
- let CryptoJS: typeof CryptoJSNamespace;
11
+ let CryptoJS: any;
14
12
 
15
13
  /**
16
14
  * A transform that calculates Cryptographic Hash using Crypto JS library
@@ -36,9 +34,9 @@ export class CryptoHash extends Hash {
36
34
  async preload(): Promise<void> {
37
35
  if (!CryptoJS) {
38
36
  CryptoJS = this.options?.modules?.CryptoJS;
39
- if (!CryptoJS) {
40
- throw new Error(this.name);
41
- }
37
+ }
38
+ if (!CryptoJS) {
39
+ throw new Error(this.name);
42
40
  }
43
41
  if (!this._hash) {
44
42
  const algo = CryptoJS.algo[this._algorithm];
@@ -57,7 +55,6 @@ export class CryptoHash extends Hash {
57
55
  await this.preload();
58
56
  // arrayBuffer is accepted, even though types and docs say no
59
57
  // https://stackoverflow.com/questions/25567468/how-to-decrypt-an-arraybuffer
60
- // @ts-expect-error
61
58
  const typedWordArray = CryptoJS.lib.WordArray.create(input);
62
59
  // Map our encoding constant to Crypto library
63
60
  const enc = encoding === 'base64' ? CryptoJS.enc.Base64 : CryptoJS.enc.Hex;
@@ -72,7 +69,6 @@ export class CryptoHash extends Hash {
72
69
  for await (const chunk of asyncIterator) {
73
70
  // arrayBuffer is accepted, even though types and docs say no
74
71
  // https://stackoverflow.com/questions/25567468/how-to-decrypt-an-arraybuffer
75
- // @ts-expect-error
76
72
  const typedWordArray = CryptoJS.lib.WordArray.create(chunk);
77
73
  this._hash.update(typedWordArray);
78
74
  yield chunk;
package/dist/bundle.d.ts DELETED
@@ -1,2 +0,0 @@
1
- declare const moduleExports: any;
2
- //# sourceMappingURL=bundle.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"bundle.d.ts","sourceRoot":"","sources":["../src/bundle.ts"],"names":[],"mappings":"AACA,QAAA,MAAM,aAAa,KAAqB,CAAC"}
package/dist/dist.min.js DELETED
@@ -1,2 +0,0 @@
1
- (()=>{var Ee=Object.defineProperty;var Ye=i=>Ee(i,"__esModule",{value:!0});var Q=(i,e)=>()=>(i&&(e=i(i=0)),e);var Ke=(i,e)=>()=>(e||i((e={exports:{}}).exports,e),e.exports),$e=(i,e)=>{Ye(i);for(var x in e)Ee(i,x,{get:e[x],enumerable:!0})};function Qe(...i){let e=i.map(l=>l instanceof ArrayBuffer?new Uint8Array(l):l),x=e.reduce((l,p)=>l+p.byteLength,0),A=new Uint8Array(x),h=0;for(let l of e)A.set(l,h),h+=l.byteLength;return A.buffer}var Ie=Q(()=>{});async function ne(i){let e=[];for await(let x of i)e.push(x);return Qe(...e)}var Me=Q(()=>{Ie()});var ve=Q(()=>{Me()});var D,X=Q(()=>{ve();D=class{constructor(e={}){this.hashBatches=this.hashBatches.bind(this)}async preload(){}async*hashBatches(e,x="base64"){let A=[];for await(let p of e)A.push(p),yield p;let h=await this.concatenate(A),l=await this.hash(h,x);this.options.crypto?.onEnd?.({hash:l})}async concatenate(e){return await ne(e)}}});function rr(){return er}var te,er,Ge=Q(()=>{te=class{constructor(){this.crc=~0}update(e){let x=rr(),A=new Uint8Array(e);for(let h=0;h<A.byteLength;h++)this.crc=this.crc>>>8^x[(this.crc^A[h])&255];return this}finalize(){return this.crc=Math.abs(this.crc^-1),this.crc}},er=Uint32Array.of(0,1996959894,3993919788,2567524794,124634137,1886057615,3915621685,2657392035,249268274,2044508324,3772115230,2547177864,162941995,2125561021,3887607047,2428444049,498536548,1789927666,4089016648,2227061214,450548861,1843258603,4107580753,2211677639,325883990,1684777152,4251122042,2321926636,335633487,1661365465,4195302755,2366115317,997073096,1281953886,3579855332,2724688242,1006888145,1258607687,3524101629,2768942443,901097722,1119000684,3686517206,2898065728,853044451,1172266101,3705015759,2882616665,651767980,1373503546,3369554304,3218104598,565507253,1454621731,3485111705,3099436303,671266974,1594198024,3322730930,2970347812,795835527,1483230225,3244367275,3060149565,1994146192,31158534,2563907772,4023717930,1907459465,112637215,2680153253,3904427059,2013776290,251722036,2517215374,3775830040,2137656763,141376813,2439277719,3865271297,1802195444,476864866,2238001368,4066508878,1812370925,453092731,2181625025,4111451223,1706088902,314042704,2344532202,4240017532,1658658271,366619977,2362670323,4224994405,1303535960,984961486,2747007092,3569037538,1256170817,1037604311,2765210733,3554079995,1131014506,879679996,2909243462,3663771856,1141124467,855842277,2852801631,3708648649,1342533948,654459306,3188396048,3373015174,1466479909,544179635,3110523913,3462522015,1591671054,702138776,2966460450,3352799412,1504918807,783551873,3082640443,3233442989,3988292384,2596254646,62317068,1957810842,3939845945,2647816111,81470997,1943803523,3814918930,2489596804,225274430,2053790376,3826175755,2466906013,167816743,2097651377,4027552580,2265490386,503444072,1762050814,4150417245,2154129355,426522225,1852507879,4275313526,2312317920,282753626,1742555852,4189708143,2394877945,397917763,1622183637,3604390888,2714866558,953729732,1340076626,3518719985,2797360999,1068828381,1219638859,3624741850,2936675148,906185462,1090812512,3747672003,2825379669,829329135,1181335161,3412177804,3160834842,628085408,1382605366,3423369109,3138078467,570562233,1426400815,3317316542,2998733608,733239954,1555261956,3268935591,3050360625,752459403,1541320221,2607071920,3965973030,1969922972,40735498,2617837225,3943577151,1913087877,83908371,2512341634,3803740692,2075208622,213261112,2463272603,3855990285,2094854071,198958881,2262029012,4057260610,1759359992,534414190,2176718541,4139329115,1873836001,414664567,2282248934,4279200368,1711684554,285281116,2405801727,4167216745,1634467795,376229701,2685067896,3608007406,1308918612,956543938,2808555105,3495958263,1231636301,1047427035,2932959818,3654703836,1088359270,936918e3,2847714899,3736837829,1202900863,817233897,3183342108,3401237130,1404277552,615818150,3134207493,3453421203,1423857449,601450431,3009837614,3294710456,1567103746,711928724,3020668471,3272380065,1510334235,755167117)});function ae(i){i=`${i}`;for(let x=0;x<i.length;x++)if(i.charCodeAt(x)>255)return null;let e="";for(let x=0;x<i.length;x+=3){let A=[void 0,void 0,void 0,void 0];A[0]=i.charCodeAt(x)>>2,A[1]=(i.charCodeAt(x)&3)<<4,i.length>x+1&&(A[1]|=i.charCodeAt(x+1)>>4,A[2]=(i.charCodeAt(x+1)&15)<<2),i.length>x+2&&(A[2]|=i.charCodeAt(x+2)>>6,A[3]=i.charCodeAt(x+2)&63);for(let h=0;h<A.length;h++)typeof A[h]=="undefined"?e+="=":e+=or(A[h])}return e}function oe(i){if(i=`${i}`,i=i.replace(/[ \t\n\f\r]/g,""),i.length%4==0&&(i=i.replace(/[=]=?$/,"")),i.length%4==1||/[^+/0-9A-Za-z]/.test(i))return"";let e="",x=0,A=0;for(let h=0;h<i.length;h++)x<<=6,x|=ar(i[h]),A+=6,A===24&&(e+=String.fromCharCode((x&16711680)>>16),e+=String.fromCharCode((x&65280)>>8),e+=String.fromCharCode(x&255),x=A=0);return A===12?(x>>=4,e+=String.fromCharCode(x)):A===18&&(x>>=2,e+=String.fromCharCode((x&65280)>>8),e+=String.fromCharCode(x&255)),e}function ar(i){let e=tr.indexOf(i);return e<0?void 0:e}function or(i){if(i<26)return String.fromCharCode(i+"A".charCodeAt(0));if(i<52)return String.fromCharCode(i-26+"a".charCodeAt(0));if(i<62)return String.fromCharCode(i-52+"0".charCodeAt(0));if(i===62)return"+";if(i===63)return"/"}var tr,ie=Q(()=>{tr="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"});function _(i,e){switch(e){case"hex":return Se(i);case"base64":return Te(Se(i));default:throw new Error(e)}}function se(i,e){switch(e){case"hex":return i;case"base64":return Te(i);default:throw new Error(e)}}function Fe(i,e){switch(e){case"hex":return sr(i);case"base64":return i;default:throw new Error(e)}}function Te(i){i.length%2!=0&&(i=`0${i}`);let x=(i.match(/\w{2}/g)||[]).map(A=>String.fromCharCode(parseInt(A,16))).join("");return ae(x)||""}function sr(i){return[...oe(i)].map(e=>e.charCodeAt(0).toString(16).padStart(2,"0")).join("")}function Se(i){let e=i.toString(16);return e==="0"?`0${e}`:e}var O=Q(()=>{ie()});var xe,We=Q(()=>{X();Ge();O();xe=class extends D{constructor(e={}){super();this.name="crc32";this.options={crypto:{},...e},this._hash=new te,this.hashBatches=this.hashBatches.bind(this)}async hash(e,x){return this.hashSync(e,x)}hashSync(e,x){this._hash.update(e);let A=this._hash.finalize();return _(A,x)}async*hashBatches(e,x="base64"){for await(let l of e)this._hash.update(l),yield l;let A=this._hash.finalize(),h=_(A,x);this.options.crypto?.onEnd?.({hash:h})}}});function fr(){return cr}var ce,cr,He=Q(()=>{ce=class{constructor(e={}){this.options=e,this.crc=~0}update(e){let x=new Uint8Array(e),A=fr();for(let h=0;h<x.length;h++)this.crc=A[(this.crc^x[h])&255]^this.crc>>>8;return this}finalize(){return this.crc=(this.crc^-1)>>>0,this.crc}},cr=Int32Array.of(0,4067132163,3778769143,324072436,3348797215,904991772,648144872,3570033899,2329499855,2024987596,1809983544,2575936315,1296289744,3207089363,2893594407,1578318884,274646895,3795141740,4049975192,51262619,3619967088,632279923,922689671,3298075524,2592579488,1760304291,2075979607,2312596564,1562183871,2943781820,3156637768,1313733451,549293790,3537243613,3246849577,871202090,3878099393,357341890,102525238,4101499445,2858735121,1477399826,1264559846,3107202533,1845379342,2677391885,2361733625,2125378298,820201905,3263744690,3520608582,598981189,4151959214,85089709,373468761,3827903834,3124367742,1213305469,1526817161,2842354314,2107672161,2412447074,2627466902,1861252501,1098587580,3004210879,2688576843,1378610760,2262928035,1955203488,1742404180,2511436119,3416409459,969524848,714683780,3639785095,205050476,4266873199,3976438427,526918040,1361435347,2739821008,2954799652,1114974503,2529119692,1691668175,2005155131,2247081528,3690758684,697762079,986182379,3366744552,476452099,3993867776,4250756596,255256311,1640403810,2477592673,2164122517,1922457750,2791048317,1412925310,1197962378,3037525897,3944729517,427051182,170179418,4165941337,746937522,3740196785,3451792453,1070968646,1905808397,2213795598,2426610938,1657317369,3053634322,1147748369,1463399397,2773627110,4215344322,153784257,444234805,3893493558,1021025245,3467647198,3722505002,797665321,2197175160,1889384571,1674398607,2443626636,1164749927,3070701412,2757221520,1446797203,137323447,4198817972,3910406976,461344835,3484808360,1037989803,781091935,3705997148,2460548119,1623424788,1939049696,2180517859,1429367560,2807687179,3020495871,1180866812,410100952,3927582683,4182430767,186734380,3756733383,763408580,1053836080,3434856499,2722870694,1344288421,1131464017,2971354706,1708204729,2545590714,2229949006,1988219213,680717673,3673779818,3383336350,1002577565,4010310262,493091189,238226049,4233660802,2987750089,1082061258,1395524158,2705686845,1972364758,2279892693,2494862625,1725896226,952904198,3399985413,3656866545,731699698,4283874585,222117402,510512622,3959836397,3280807620,837199303,582374963,3504198960,68661723,4135334616,3844915500,390545967,1230274059,3141532936,2825850620,1510247935,2395924756,2091215383,1878366691,2644384480,3553878443,565732008,854102364,3229815391,340358836,3861050807,4117890627,119113024,1493875044,2875275879,3090270611,1247431312,2660249211,1828433272,2141937292,2378227087,3811616794,291187481,34330861,4032846830,615137029,3603020806,3314634738,939183345,1776939221,2609017814,2295496738,2058945313,2926798794,1545135305,1330124605,3173225534,4084100981,17165430,307568514,3762199681,888469610,3332340585,3587147933,665062302,2042050490,2346497209,2559330125,1793573966,3190661285,1279665062,1595330642,2910671697)});var Ae,je=Q(()=>{X();He();O();Ae=class extends D{constructor(e={}){super();this.name="crc32c";this.options={crypto:{},...e},this._hash=new ce(e)}async hash(e,x){return this.hashSync(e,x)}hashSync(e,x){this._hash.update(e);let A=this._hash.finalize();return _(A,x)}async*hashBatches(e,x="base64"){for await(let l of e)this._hash.update(l),yield l;let A=this._hash.finalize(),h=_(A,x);this.options.crypto?.onEnd?.({hash:h})}}});function he(i){var e,x,A,h,l,p,v,G,H,k;let J=dr(),F=Ar(),T={},W=new Date().getTime();return T.then=function(y){return v=y,E(),T},T.catch=function(y){return G=y,T},i&&typeof i=="object"?typeof Buffer=="function"&&i.constructor===Buffer?p=i:i.constructor===Uint8Array||i.constructor===ArrayBuffer?p=i.constructor===ArrayBuffer?new Uint8Array(i):i:w(new TypeError(Re)):w(new TypeError(Re)),p&&(l=p.length,de&&l>ke?l>ir?w(new Error(xr)):(e=new WebAssembly.Memory({initial:l>32e6?l>64e6?l>128e6?4096:2048:1024:512}),x=new Uint32Array(e.buffer),h={mem:e,log:console.log},A={imports:h},WebAssembly.instantiate(de,A).then(m)):E(J(p))),T;function m(y){E(F(p,y.instance.exports,x))}function E(y){var j=Boolean(y)?y:H;Boolean(y)&&(k=new Date().getTime()),typeof v=="function"?Boolean(j)&&(v(j,k-W),v=G=null):Boolean(y)&&(H=y)}function w(y){typeof G=="function"&&G(y)}}function Ar(){var i,e,x,A,h,l,p,v,G,H,k,J,F,T=function(W){var m,E,w,y,j,N,Z,V,u,P,r,t,a,o,R,S,g,d,K,$,C,Br,gr=new Date().getTime(),ze=0,s=1732584193,c=-271733879,f=-1732584194,n=271733878,B=0,z=W.length*8,ee;for(ee=Oe(W,F),F[z>>>5]|=128<<z%32,F[(z+64>>>9<<4)+14]=z,ee=(z+64>>>9<<4)+15,C=F;B<ee;)ee>B+ke?(A(s),l(c),v(f),H(n),e(be),B=B+be*16,s=x(),c=h(),f=p(),n=G(),ze++):(g=s,d=c,K=f,$=n,m=C[B+0]>>>0,E=C[B+1]>>>0,w=C[B+2]>>>0,y=C[B+3]>>>0,j=C[B+4]>>>0,N=C[B+5]>>>0,Z=C[B+6]>>>0,V=C[B+7]>>>0,u=C[B+8]>>>0,P=C[B+9]>>>0,r=C[B+10]>>>0,t=C[B+11]>>>0,a=C[B+12]>>>0,o=C[B+13]>>>0,R=C[B+14]>>>0,S=C[B+15]>>>0,s=b(7,25,s+(c&f|~c&n)+m-680876936)+c,n=b(12,20,n+(s&c|~s&f)+E-389564586)+s,f=b(17,15,f+(n&s|~n&c)+w+606105819)+n,c=b(22,10,c+(f&n|~f&s)+y-1044525330)+f,s=b(7,25,s+(c&f|~c&n)+j-176418897)+c,n=b(12,20,n+(s&c|~s&f)+N+1200080426)+s,f=b(17,15,f+(n&s|~n&c)+Z-1473231341)+n,c=b(22,10,c+(f&n|~f&s)+V-45705983)+f,s=b(7,25,s+(c&f|~c&n)+u+1770035416)+c,n=b(12,20,n+(s&c|~s&f)+P-1958414417)+s,f=b(17,15,f+(n&s|~n&c)+r-42063)+n,c=b(22,10,c+(f&n|~f&s)+t-1990404162)+f,s=b(7,25,s+(c&f|~c&n)+a+1804603682)+c,n=b(12,20,n+(s&c|~s&f)+o-40341101)+s,f=b(17,15,f+(n&s|~n&c)+R-1502002290)+n,c=b(22,10,c+(f&n|~f&s)+S+1236535329)+f,s=b(5,27,s+(c&n|f&~n)+E-165796510)+c,n=b(9,23,n+(s&f|c&~f)+Z-1069501632)+s,f=b(14,18,f+(n&c|s&~c)+t+643717713)+n,c=b(20,12,c+(f&s|n&~s)+m-373897302)+f,s=b(5,27,s+(c&n|f&~n)+N-701558691)+c,n=b(9,23,n+(s&f|c&~f)+r+38016083)+s,f=b(14,18,f+(n&c|s&~c)+S-660478335)+n,c=b(20,12,c+(f&s|n&~s)+j-405537848)+f,s=b(5,27,s+(c&n|f&~n)+P+568446438)+c,n=b(9,23,n+(s&f|c&~f)+R-1019803690)+s,f=b(14,18,f+(n&c|s&~c)+y-187363961)+n,c=b(20,12,c+(f&s|n&~s)+u+1163531501)+f,s=b(5,27,s+(c&n|f&~n)+o-1444681467)+c,n=b(9,23,n+(s&f|c&~f)+w-51403784)+s,f=b(14,18,f+(n&c|s&~c)+V+1735328473)+n,c=b(20,12,c+(f&s|n&~s)+a-1926607734)+f,s=b(4,28,s+(c^f^n)+N-378558)+c,n=b(11,21,n+(s^c^f)+u-2022574463)+s,f=b(16,16,f+(n^s^c)+t+1839030562)+n,c=b(23,9,c+(f^n^s)+R-35309556)+f,s=b(4,28,s+(c^f^n)+E-1530992060)+c,n=b(11,21,n+(s^c^f)+j+1272893353)+s,f=b(16,16,f+(n^s^c)+V-155497632)+n,c=b(23,9,c+(f^n^s)+r-1094730640)+f,s=b(4,28,s+(c^f^n)+o+681279174)+c,n=b(11,21,n+(s^c^f)+m-358537222)+s,f=b(16,16,f+(n^s^c)+y-722521979)+n,c=b(23,9,c+(f^n^s)+Z+76029189)+f,s=b(4,28,s+(c^f^n)+P-640364487)+c,n=b(11,21,n+(s^c^f)+a-421815835)+s,f=b(16,16,f+(n^s^c)+S+530742520)+n,c=b(23,9,c+(f^n^s)+w-995338651)+f,s=b(6,26,s+(f^(c|~n))+m-198630844)+c,n=b(10,22,n+(c^(s|~f))+V+1126891415)+s,f=b(15,17,f+(s^(n|~c))+R-1416354905)+n,c=b(21,11,c+(n^(f|~s))+N-57434055)+f,s=b(6,26,s+(f^(c|~n))+a+1700485571)+c,n=b(10,22,n+(c^(s|~f))+y-1894986606)+s,f=b(15,17,f+(s^(n|~c))+r-1051523)+n,c=b(21,11,c+(n^(f|~s))+E-2054922799)+f,s=b(6,26,s+(f^(c|~n))+u+1873313359)+c,n=b(10,22,n+(c^(s|~f))+S-30611744)+s,f=b(15,17,f+(s^(n|~c))+Z-1560198380)+n,c=b(21,11,c+(n^(f|~s))+o+1309151649)+f,s=b(6,26,s+(f^(c|~n))+j-145523070)+c,n=b(10,22,n+(c^(s|~f))+t-1120210379)+s,f=b(15,17,f+(s^(n|~c))+w+718787259)+n,c=b(21,11,c+(n^(f|~s))+P-343485551)+f,B=B+16,s=s+g>>>0,c=c+d>>>0,f=f+K>>>0,n=n+$>>>0);return L.endian([s,c,f,n]);function b(I,re,q){return q<<I|q>>>re}function Oe(I,re){for(var q=-1,fe=Math.floor((I.length-1)/4),M=0,Be,ge,Ce,we;fe-8>q++;)M=q<<2,re[q]=I[M+0]|I[M+1]<<8|I[M+2]<<16|I[M+3]<<24;for(q--;fe>q++;)M=q<<2,Be=typeof I[M+0]=="undefined"?0:I[M+0],ge=typeof I[M+1]=="undefined"?0:I[M+1],Ce=typeof I[M+2]=="undefined"?0:I[M+2],we=typeof I[M+3]=="undefined"?0:I[M+3],re[q]=Be|ge<<8|Ce<<16|we<<24;return fe+1}};return function(W,m,E,w){var y;return e=m.loops,i=m.loop,x=m.getA,h=m.getB,p=m.getC,G=m.getD,k=m.getX,A=m.setA,l=m.setB,v=m.setC,H=m.setD,J=m.setX,F=E,y=L.wordsToBytes(T(W)),w&&w.asBytes?y:L.bytesconvertNumberToHex(y)}}function dr(){var i=function(e,x){var A,h,l,p,v,G,H,k,J,F,T,W,m,E,w,y,j,N,Z,V,u,P=new Date().getTime(),r=1732584193,t=-271733879,a=-1732584194,o=271733878,R=e.length*8;u=L.bytesToWords(e);for(var S=0;S<u.length;S++)u[S]=(u[S]<<8|u[S]>>>24)&16711935|(u[S]<<24|u[S]>>>8)&4278255360;u[R>>>5]|=128<<R%32,u[(R+64>>>9<<4)+14]=R;for(var g=0;g<u.length;g+=16)j=r,N=t,Z=a,V=o,A=u[g+0]>>>0,h=u[g+1]>>>0,l=u[g+2]>>>0,p=u[g+3]>>>0,v=u[g+4]>>>0,G=u[g+5]>>>0,H=u[g+6]>>>0,k=u[g+7]>>>0,J=u[g+8]>>>0,F=u[g+9]>>>0,T=u[g+10]>>>0,W=u[g+11]>>>0,m=u[g+12]>>>0,E=u[g+13]>>>0,w=u[g+14]>>>0,y=u[g+15]>>>0,r=d(7,25,r+(t&a|~t&o)+A-680876936)+t,o=d(12,20,o+(r&t|~r&a)+h-389564586)+r,a=d(17,15,a+(o&r|~o&t)+l+606105819)+o,t=d(22,10,t+(a&o|~a&r)+p-1044525330)+a,r=d(7,25,r+(t&a|~t&o)+v-176418897)+t,o=d(12,20,o+(r&t|~r&a)+G+1200080426)+r,a=d(17,15,a+(o&r|~o&t)+H-1473231341)+o,t=d(22,10,t+(a&o|~a&r)+k-45705983)+a,r=d(7,25,r+(t&a|~t&o)+J+1770035416)+t,o=d(12,20,o+(r&t|~r&a)+F-1958414417)+r,a=d(17,15,a+(o&r|~o&t)+T-42063)+o,t=d(22,10,t+(a&o|~a&r)+W-1990404162)+a,r=d(7,25,r+(t&a|~t&o)+m+1804603682)+t,o=d(12,20,o+(r&t|~r&a)+E-40341101)+r,a=d(17,15,a+(o&r|~o&t)+w-1502002290)+o,t=d(22,10,t+(a&o|~a&r)+y+1236535329)+a,r=d(5,27,r+(t&o|a&~o)+h-165796510)+t,o=d(9,23,o+(r&a|t&~a)+H-1069501632)+r,a=d(14,18,a+(o&t|r&~t)+W+643717713)+o,t=d(20,12,t+(a&r|o&~r)+A-373897302)+a,r=d(5,27,r+(t&o|a&~o)+G-701558691)+t,o=d(9,23,o+(r&a|t&~a)+T+38016083)+r,a=d(14,18,a+(o&t|r&~t)+y-660478335)+o,t=d(20,12,t+(a&r|o&~r)+v-405537848)+a,r=d(5,27,r+(t&o|a&~o)+F+568446438)+t,o=d(9,23,o+(r&a|t&~a)+w-1019803690)+r,a=d(14,18,a+(o&t|r&~t)+p-187363961)+o,t=d(20,12,t+(a&r|o&~r)+J+1163531501)+a,r=d(5,27,r+(t&o|a&~o)+E-1444681467)+t,o=d(9,23,o+(r&a|t&~a)+l-51403784)+r,a=d(14,18,a+(o&t|r&~t)+k+1735328473)+o,t=d(20,12,t+(a&r|o&~r)+m-1926607734)+a,r=d(4,28,r+(t^a^o)+G-378558)+t,o=d(11,21,o+(r^t^a)+J-2022574463)+r,a=d(16,16,a+(o^r^t)+W+1839030562)+o,t=d(23,9,t+(a^o^r)+w-35309556)+a,r=d(4,28,r+(t^a^o)+h-1530992060)+t,o=d(11,21,o+(r^t^a)+v+1272893353)+r,a=d(16,16,a+(o^r^t)+k-155497632)+o,t=d(23,9,t+(a^o^r)+T-1094730640)+a,r=d(4,28,r+(t^a^o)+E+681279174)+t,o=d(11,21,o+(r^t^a)+A-358537222)+r,a=d(16,16,a+(o^r^t)+p-722521979)+o,t=d(23,9,t+(a^o^r)+H+76029189)+a,r=d(4,28,r+(t^a^o)+F-640364487)+t,o=d(11,21,o+(r^t^a)+m-421815835)+r,a=d(16,16,a+(o^r^t)+y+530742520)+o,t=d(23,9,t+(a^o^r)+l-995338651)+a,r=d(6,26,r+(a^(t|~o))+A-198630844)+t,o=d(10,22,o+(t^(r|~a))+k+1126891415)+r,a=d(15,17,a+(r^(o|~t))+w-1416354905)+o,t=d(21,11,t+(o^(a|~r))+G-57434055)+a,r=d(6,26,r+(a^(t|~o))+m+1700485571)+t,o=d(10,22,o+(t^(r|~a))+p-1894986606)+r,a=d(15,17,a+(r^(o|~t))+T-1051523)+o,t=d(21,11,t+(o^(a|~r))+h-2054922799)+a,r=d(6,26,r+(a^(t|~o))+J+1873313359)+t,o=d(10,22,o+(t^(r|~a))+y-30611744)+r,a=d(15,17,a+(r^(o|~t))+H-1560198380)+o,t=d(21,11,t+(o^(a|~r))+E+1309151649)+a,r=d(6,26,r+(a^(t|~o))+v-145523070)+t,o=d(10,22,o+(t^(r|~a))+W-1120210379)+r,a=d(15,17,a+(r^(o|~t))+l+718787259)+o,t=d(21,11,t+(o^(a|~r))+F-343485551)+a,r=r+j>>>0,t=t+N>>>0,a=a+Z>>>0,o=o+V>>>0;return L.endian([r,t,a,o]);function d(K,$,C){return C<<K|C>>>$}};return function(e,x){var A=L.wordsToBytes(i(e,x)),h=x&&x.asBytes?A:L.bytesconvertNumberToHex(A);return h}}function br(i){var e,x,A,h=-1;for(e=i.length-1,x=new ArrayBuffer(i.length),A=new Uint8Array(x);e>h++;)A[h]=i.charCodeAt(h);return A}function hr(i){return Buffer.from(i,"base64").toString("binary")}function qe(i){return i}function lr(){var i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";return{rotl:function(e,x){return e<<x|e>>>32-x},endian:function(e){if(e.constructor==Number)return L.rotl(e,8)&16711935|L.rotl(e,24)&4278255360;for(var x=0;x<e.length;x++)e[x]=L.endian(e[x]);return e},bytesToWords:function(e){for(var x=[],A=0,h=0;A<e.length;A++,h+=8)x[h>>>5]|=e[A]<<24-h%32;return x},wordsToBytes:function(e){for(var x=[],A=0;A<e.length*32;A+=8)x.push(e[A>>>5]>>>24-A%32&255);return x},bytesconvertNumberToHex:function(e){for(var x=[],A=0;A<e.length;A++)x.push((e[A]>>>4).toString(16)),x.push((e[A]&15).toString(16));return x.join("")}}}var De,nr,de,L,be,ke,ir,Re,xr,Le=Q(()=>{De=typeof atob=="function"?atob:typeof Buffer=="function"?hr:qe,nr=De("AGFzbQEAAAABDANgAX8AYAAAYAABfwIeAgdpbXBvcnRzA2xvZwAAB2ltcG9ydHMDbWVtAgABAzIxAAEBAQEBAQEBAQEBAQEBAQEBAQEBAQEAAAAAAAAAAAAAAAAAAAAAAgICAgIAAAAAAAaYARt/AUGBxpS6Bgt/AUGJ17b+fgt/AUH+uevFeQt/AUH2qMmBAQt/AUEAC38BQQALfwFBAAt/AUEAC38BQQALfwFBAAt/AUEAC38BQQALfwFBAAt/AUEAC38BQQALfwFBAAt/AUEAC38BQQALfwFBAAt/AUEAC38BQQALfwFBAAt/AUEAC38BQQALfwFBAAt/AUEAC38BQQALB7oCJQhvbmVGdWxsQQAYCG9uZUZ1bGxCABkIb25lRnVsbEMAGghvbmVGdWxsRAAbBWxvb3BzAAEEbG9vcAACBXByaW1lAAMFbG9vcEEABAZsb29wQTEABQZsb29wQTIABgZsb29wQTMABwZsb29wQTQACAVsb29wQgAJBmxvb3BCMQAKBmxvb3BCMgALBmxvb3BCMwAMBmxvb3BCNAANBWxvb3BDAA4GbG9vcEMxAA8GbG9vc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iECAAABAW4iAgAAAQFuIwIAAAEBbiQCAAABAW4lAgAAAQFuJgIAAAEBbicCAAABAW4oACkAKgArACwALQEAAC4BAAAvAQAAMAEAADEBAAA="),de=WebAssembly&&De!==qe?br(nr).buffer:!1,L=lr(),be=240*16*16,ke=Math.floor(be*16*1.066666667),ir=268435456-65536,Re="Parameter must be Buffer, ArrayBuffer or Uint8Array",xr="Parameter exceeds max size of 255.9 Mbytes";de||console.log("WebAssembly not available or WASM module could not be decoded; md5WASM will fall back to JavaScript")});var le,Ue=Q(()=>{X();Le();O();le=class extends D{constructor(e={}){super();this.name="md5";this.options=e}async hash(e,x){let h=await new Promise((l,p)=>he(e).then(l).catch(p));return se(h,x)}}});var U,Y,ue=Q(()=>{X();Y=class extends D{constructor(e){super();if(this.options=e,this._algorithm=this.options?.crypto?.algorithm,!this._algorithm)throw new Error(this.name);this.name=this._algorithm.toLowerCase()}async preload(){if(!U&&(U=this.options?.modules?.CryptoJS,!U))throw new Error(this.name);if(!this._hash){let e=U.algo[this._algorithm];this._hash=e.create()}if(!this._hash)throw new Error(this.name)}async hash(e,x){await this.preload();let A=U.lib.WordArray.create(e),h=x==="base64"?U.enc.Base64:U.enc.Hex;return this._hash.update(A).finalize().toString(h)}async*hashBatches(e,x="base64"){await this.preload();for await(let l of e){let p=U.lib.WordArray.create(l);this._hash.update(p),yield l}let A=x==="base64"?U.enc.Base64:U.enc.Hex,h=this._hash.finalize().toString(A);this.options?.crypto?.onEnd?.({hash:h})}}});var ye,Je=Q(()=>{ue();ye=class extends Y{constructor(e){super({...e,crypto:{...e.crypto,algorithm:"SHA256"}})}}});var Ne=Q(()=>{});var me,Ze=Q(()=>{X();Ne();me=class extends D{constructor(e){super();this.name="crypto-node";if(this.options=e,!this.options?.crypto?.algorithm)throw new Error(this.name)}async hash(e,x){await this.preload();let A=this.options?.crypto?.algorithm?.toLowerCase();try{let h=(0,pe.createHash)(A),l=new Uint8Array(e);return h.update(l).digest("base64")}catch(h){throw Error(`${A} hash not available. ${h}`)}}async*hashBatches(e,x="base64"){await this.preload();let A=(0,pe.createHash)(this.options?.crypto?.algorithm?.toLowerCase());for await(let l of e){let p=new Uint8Array(l);A.update(p),yield l}let h=A.digest(x);this.options?.crypto?.onEnd?.({hash:h})}}});var _e={};$e(_e,{CRC32CHash:()=>Ae,CRC32Hash:()=>xe,CryptoHash:()=>Y,CryptoJSWorker:()=>yr,CryptoWorker:()=>ur,MD5Hash:()=>le,NodeHash:()=>me,SHA256Hash:()=>ye,asciiToBase64:()=>ae,base64ToAscii:()=>oe,encodeBase64:()=>Fe,encodeHex:()=>se,encodeNumber:()=>_});var Ve,ur,yr,Pe=Q(()=>{We();je();Ue();Je();ue();Ze();O();ie();Ve=typeof __VERSION__!="undefined"?__VERSION__:"latest",ur={id:"crypto",name:"CRC32, CRC32c and MD5 Hashes",module:"crypto",version:Ve,options:{crypto:{}}},yr={id:"cryptojs",name:"Cryptographic Hashes",module:"crypto",version:Ve,options:{cryptojs:{}}}});var mr=Ke((x0,Xe)=>{var pr=(Pe(),_e);globalThis.loaders=globalThis.loaders||{};Xe.exports=Object.assign(globalThis.loaders,pr)});mr();})();
2
- //# sourceMappingURL=dist.min.js.map
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../loader-utils/src/lib/binary-utils/array-buffer-utils.ts", "../../loader-utils/src/lib/iterators/async-iteration.ts", "../../loader-utils/src/index.ts", "../src/lib/hash.ts", "../src/lib/algorithms/crc32.ts", "../src/lib/utils/base64-utils.ts", "../src/lib/utils/digest-utils.ts", "../src/lib/crc32-hash.ts", "../src/lib/algorithms/crc32c.ts", "../src/lib/crc32c-hash.ts", "../src/lib/algorithms/md5-wasm.ts", "../src/lib/md5-hash.ts", "../src/lib/crypto-hash.ts", "../src/lib/sha256-hash.ts", "(disabled):crypto", "../src/lib/node-hash.ts", "../src/index.ts", "../src/bundle.ts"],
4
- "sourcesContent": ["import {TypedArray} from '../../types';\n\n/**\n * compare two binary arrays for equality\n * @param a\n * @param b\n * @param byteLength\n */\nexport function compareArrayBuffers(\n arrayBuffer1: ArrayBuffer,\n arrayBuffer2: ArrayBuffer,\n byteLength?: number\n): boolean {\n byteLength = byteLength || arrayBuffer1.byteLength;\n if (arrayBuffer1.byteLength < byteLength || arrayBuffer2.byteLength < byteLength) {\n return false;\n }\n const array1 = new Uint8Array(arrayBuffer1);\n const array2 = new Uint8Array(arrayBuffer2);\n for (let i = 0; i < array1.length; ++i) {\n if (array1[i] !== array2[i]) {\n return false;\n }\n }\n return true;\n}\n\n/**\n * Concatenate a sequence of ArrayBuffers\n * @return A concatenated ArrayBuffer\n */\nexport function concatenateArrayBuffers(...sources: (ArrayBuffer | Uint8Array)[]): ArrayBuffer {\n // Make sure all inputs are wrapped in typed arrays\n const sourceArrays = sources.map((source2) =>\n source2 instanceof ArrayBuffer ? new Uint8Array(source2) : source2\n );\n\n // Get length of all inputs\n const byteLength = sourceArrays.reduce((length, typedArray) => length + typedArray.byteLength, 0);\n\n // Allocate array with space for all inputs\n const result = new Uint8Array(byteLength);\n\n // Copy the subarrays\n let offset = 0;\n for (const sourceArray of sourceArrays) {\n result.set(sourceArray, offset);\n offset += sourceArray.byteLength;\n }\n\n // We work with ArrayBuffers, discard the typed array wrapper\n return result.buffer;\n}\n\n/**\n * Concatenate arbitrary count of typed arrays\n * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Typed_arrays\n * @param - list of arrays. All arrays should be the same type\n * @return A concatenated TypedArray\n */\nexport function concatenateTypedArrays<T>(...typedArrays: T[]): T {\n // @ts-ignore\n const arrays = typedArrays as TypedArray[];\n // @ts-ignore\n const TypedArrayConstructor = (arrays && arrays.length > 1 && arrays[0].constructor) || null;\n if (!TypedArrayConstructor) {\n throw new Error(\n '\"concatenateTypedArrays\" - incorrect quantity of arguments or arguments have incompatible data types'\n );\n }\n\n const sumLength = arrays.reduce((acc, value) => acc + value.length, 0);\n // @ts-ignore typescript does not like dynamic constructors\n const result = new TypedArrayConstructor(sumLength);\n let offset = 0;\n for (const array of arrays) {\n result.set(array, offset);\n offset += array.length;\n }\n return result;\n}\n\n/**\n * Copy a view of an ArrayBuffer into new ArrayBuffer with byteOffset = 0\n * @param arrayBuffer\n * @param byteOffset\n * @param byteLength\n */\nexport function sliceArrayBuffer(\n arrayBuffer: ArrayBuffer,\n byteOffset: number,\n byteLength?: number\n): ArrayBuffer {\n const subArray =\n byteLength !== undefined\n ? new Uint8Array(arrayBuffer).subarray(byteOffset, byteOffset + byteLength)\n : new Uint8Array(arrayBuffer).subarray(byteOffset);\n const arrayCopy = new Uint8Array(subArray);\n return arrayCopy.buffer;\n}\n", "import {concatenateArrayBuffers} from '../binary-utils/array-buffer-utils';\n\n// GENERAL UTILITIES\n\n/**\n * Iterate over async iterator, without resetting iterator if end is not reached\n * - forEach intentionally does not reset iterator if exiting loop prematurely\n * so that iteration can continue in a second loop\n * - It is recommended to use a standard for-await as last loop to ensure\n * iterator gets properly reset\n *\n * TODO - optimize using sync iteration if argument is an Iterable?\n *\n * @param iterator\n * @param visitor\n */\nexport async function forEach(iterator, visitor) {\n // eslint-disable-next-line\n while (true) {\n const {done, value} = await iterator.next();\n if (done) {\n iterator.return();\n return;\n }\n const cancel = visitor(value);\n if (cancel) {\n return;\n }\n }\n}\n\n// Breaking big data into iterable chunks, concatenating iterable chunks into big data objects\n\n/**\n * Concatenates all data chunks yielded by an (async) iterator\n * This function can e.g. be used to enable atomic parsers to work on (async) iterator inputs\n */\n\nexport async function concatenateArrayBuffersAsync(\n asyncIterator: AsyncIterable<ArrayBuffer> | Iterable<ArrayBuffer>\n): Promise<ArrayBuffer> {\n const arrayBuffers: ArrayBuffer[] = [];\n for await (const chunk of asyncIterator) {\n arrayBuffers.push(chunk);\n }\n return concatenateArrayBuffers(...arrayBuffers);\n}\n\nexport async function concatenateStringsAsync(\n asyncIterator: AsyncIterable<string> | Iterable<string>\n): Promise<string> {\n const strings: string[] = [];\n for await (const chunk of asyncIterator) {\n strings.push(chunk);\n }\n return strings.join('');\n}\n", "// loaders.gl, MIT license\n\n// TYPES\n\nexport type {\n // misc\n DataType,\n SyncDataType,\n BatchableDataType,\n // numeric array types\n TypedArray,\n BigTypedArray,\n TypedArrayConstructor,\n BigTypedArrayConstructor,\n NumberArray,\n NumericArray,\n // fetch\n FetchLike\n} from './types';\n\n// loaders\n\nexport type {\n Loader,\n LoaderWithParser,\n LoaderContext,\n LoaderOptions,\n LoaderOptionsType,\n LoaderReturnType,\n LoaderBatchType\n} from './loader-types';\n\nexport {parseFromContext, parseSyncFromContext, parseInBatchesFromContext} from './loader-types';\n\n// writers\n\nexport type {Writer, WriterOptions, WriterOptionsType} from './writer-types';\n\n// GENERAL UTILS\nexport {assert} from './lib/env-utils/assert';\nexport {\n isBrowser,\n isWorker,\n nodeVersion,\n self,\n window,\n global,\n document\n} from './lib/env-utils/globals';\n\nexport {mergeLoaderOptions} from './lib/option-utils/merge-loader-options';\n\n// LOADERS.GL-SPECIFIC WORKER UTILS\nexport {createLoaderWorker} from './lib/worker-loader-utils/create-loader-worker';\nexport {parseWithWorker, canParseWithWorker} from './lib/worker-loader-utils/parse-with-worker';\nexport {canEncodeWithWorker} from './lib/worker-loader-utils/encode-with-worker';\n\n// PARSER UTILS\nexport {parseJSON} from './lib/parser-utils/parse-json';\n\n// MEMORY COPY UTILS\nexport {\n sliceArrayBuffer,\n concatenateArrayBuffers,\n concatenateTypedArrays,\n compareArrayBuffers\n} from './lib/binary-utils/array-buffer-utils';\nexport {padToNBytes, copyToArray, copyArrayBuffer} from './lib/binary-utils/memory-copy-utils';\nexport {\n padStringToByteAlignment,\n copyStringToDataView,\n copyBinaryToDataView,\n copyPaddedArrayBufferToDataView,\n copyPaddedStringToDataView\n} from './lib/binary-utils/dataview-copy-utils';\nexport {getFirstCharacters, getMagicString} from './lib/binary-utils/get-first-characters';\n\n// ITERATOR UTILS\nexport {\n makeTextEncoderIterator,\n makeTextDecoderIterator,\n makeLineIterator,\n makeNumberedLineIterator\n} from './lib/iterators/text-iterators';\nexport {forEach, concatenateArrayBuffersAsync} from './lib/iterators/async-iteration';\n\n// REQUEST UTILS\nexport {default as RequestScheduler} from './lib/request-utils/request-scheduler';\n\n// PATH HELPERS\nexport {setPathPrefix, getPathPrefix, resolvePath} from './lib/path-utils/file-aliases';\nexport {addAliases as _addAliases} from './lib/path-utils/file-aliases';\n\n// MICRO LOADERS\nexport {JSONLoader} from './json-loader';\n\n// NODE support\n\n// Node.js emulation (can be used in browser)\n\n// Avoid direct use of `Buffer` which pulls in 50KB polyfill\nexport {isBuffer, toBuffer, toArrayBuffer} from './lib/binary-utils/memory-conversion-utils';\n\n// Note.js wrappers (can be safely imported, but not used in browser)\n\n// Use instead of importing 'util' to avoid node dependencies\nexport {promisify1, promisify2} from './lib/node/promisify';\n\n// `path` replacement (avoids bundling big path polyfill)\nimport * as path from './lib/path-utils/path';\nexport {path};\n\n// Use instead of importing 'fs' to avoid node dependencies`\nimport * as fs from './lib/node/fs';\nexport {fs};\n\n// Use instead of importing 'stream' to avoid node dependencies`\nimport * as stream from './lib/node/stream';\nexport {stream};\n\n// EXPERIMENTAL: FILE SYSTEMS\n\nexport type {FileSystem, RandomAccessReadFileSystem} from './lib/filesystems/filesystem';\nexport {NodeFileSystem as _NodeFileSystem} from './lib/filesystems/node-filesystem';\n\nexport type {FileProvider} from './lib/file-provider/file-provider';\nexport {isFileProvider} from './lib/file-provider/file-provider';\n\nexport {FileHandle} from './lib/file-provider/file-handle';\nexport {FileHandleFile} from './lib/file-provider/file-handle-file';\nexport {DataViewFile} from './lib/file-provider/data-view-file';\n\nexport type {ReadableFile} from './lib/filesystems/readable-file';\nexport {makeReadableFile} from './lib/filesystems/readable-file';\n\nexport type {WritableFile} from './lib/filesystems/writable-file';\nexport {makeWritableFile} from './lib/filesystems/writable-file';\n\n// EXPERIMENTAL: DATA SOURCES\nexport type {Service} from './service-types';\n\nexport type {DataSourceProps} from './lib/sources/data-source';\nexport {DataSource} from './lib/sources/data-source';\n\nexport type {ImageType} from './lib/sources/utils/image-type';\nexport type {ImageSourceProps, ImageSourceMetadata} from './lib/sources/image-source';\nexport type {GetImageParameters} from './lib/sources/image-source';\nexport {ImageSource} from './lib/sources/image-source';\n\nexport type {\n TileSourceProps,\n TileSourceMetadata,\n GetTileParameters\n} from './lib/sources/tile-source';\nexport type {TileSource} from './lib/sources/tile-source';\n\nexport type {ImageTileSource} from './lib/sources/image-tile-source';\n\nexport type {VectorTileSource} from './lib/sources/vector-tile-source';\n", "// Hash\nimport {concatenateArrayBuffersAsync} from '@loaders.gl/loader-utils';\n\ntype HashOptions = {\n modules?: {[moduleName: string]: any};\n crypto?: {\n onEnd?: (result: {hash: string}) => any;\n };\n};\n\n/** Abstract hash base class */\nexport abstract class Hash {\n abstract readonly name: string;\n abstract readonly options: HashOptions;\n\n constructor(options: HashOptions = {}) {\n this.hashBatches = this.hashBatches.bind(this);\n }\n\n async preload(): Promise<void> {\n return;\n }\n\n abstract hash(arrayBuffer: ArrayBuffer, encoding: 'hex' | 'base64'): Promise<string>;\n\n async *hashBatches(\n asyncIterator: AsyncIterable<ArrayBuffer> | Iterable<ArrayBuffer>,\n encoding: 'hex' | 'base64' = 'base64'\n ): AsyncIterable<ArrayBuffer> {\n const arrayBuffers: ArrayBuffer[] = [];\n for await (const arrayBuffer of asyncIterator) {\n arrayBuffers.push(arrayBuffer);\n yield arrayBuffer;\n }\n const output = await this.concatenate(arrayBuffers);\n const hash = await this.hash(output, encoding);\n this.options.crypto?.onEnd?.({hash});\n }\n\n // HELPERS\n\n protected async concatenate(asyncIterator): Promise<ArrayBuffer> {\n return await concatenateArrayBuffersAsync(asyncIterator);\n }\n}\n", "// Inspired by https://gist.github.com/wqli78/1330293/6d85cc967f32cccfcbad94ae7d088a3dcfc14bd9\n\n/**\n * Calculates the CRC32 checksum of a string.\n */\nexport default class CRC32 {\n crc: number;\n\n constructor() {\n this.crc = ~0;\n }\n\n update(arrayBuffer) {\n const CRC32_TABLE = getCRC32Table();\n const byteArray = new Uint8Array(arrayBuffer);\n for (let i = 0; i < byteArray.byteLength; i++) {\n this.crc = (this.crc >>> 8) ^ CRC32_TABLE[(this.crc ^ byteArray[i]) & 0xff];\n // strings: crc = (crc >>> 8) ^ CRC32TAB[(crc ^ str.charCodeAt(i)) & 0xff];\n }\n return this;\n }\n\n finalize() {\n this.crc = Math.abs(this.crc ^ -1);\n return this.crc;\n }\n}\n\n// Note: Using a typed array here doubles the speed of the cipher\nconst CRC32TAB = Uint32Array.of(\n 0x00000000,\n 0x77073096,\n 0xee0e612c,\n 0x990951ba,\n 0x076dc419,\n 0x706af48f,\n 0xe963a535,\n 0x9e6495a3,\n 0x0edb8832,\n 0x79dcb8a4,\n 0xe0d5e91e,\n 0x97d2d988,\n 0x09b64c2b,\n 0x7eb17cbd,\n 0xe7b82d07,\n 0x90bf1d91,\n 0x1db71064,\n 0x6ab020f2,\n 0xf3b97148,\n 0x84be41de,\n 0x1adad47d,\n 0x6ddde4eb,\n 0xf4d4b551,\n 0x83d385c7,\n 0x136c9856,\n 0x646ba8c0,\n 0xfd62f97a,\n 0x8a65c9ec,\n 0x14015c4f,\n 0x63066cd9,\n 0xfa0f3d63,\n 0x8d080df5,\n 0x3b6e20c8,\n 0x4c69105e,\n 0xd56041e4,\n 0xa2677172,\n 0x3c03e4d1,\n 0x4b04d447,\n 0xd20d85fd,\n 0xa50ab56b,\n 0x35b5a8fa,\n 0x42b2986c,\n 0xdbbbc9d6,\n 0xacbcf940,\n 0x32d86ce3,\n 0x45df5c75,\n 0xdcd60dcf,\n 0xabd13d59,\n 0x26d930ac,\n 0x51de003a,\n 0xc8d75180,\n 0xbfd06116,\n 0x21b4f4b5,\n 0x56b3c423,\n 0xcfba9599,\n 0xb8bda50f,\n 0x2802b89e,\n 0x5f058808,\n 0xc60cd9b2,\n 0xb10be924,\n 0x2f6f7c87,\n 0x58684c11,\n 0xc1611dab,\n 0xb6662d3d,\n 0x76dc4190,\n 0x01db7106,\n 0x98d220bc,\n 0xefd5102a,\n 0x71b18589,\n 0x06b6b51f,\n 0x9fbfe4a5,\n 0xe8b8d433,\n 0x7807c9a2,\n 0x0f00f934,\n 0x9609a88e,\n 0xe10e9818,\n 0x7f6a0dbb,\n 0x086d3d2d,\n 0x91646c97,\n 0xe6635c01,\n 0x6b6b51f4,\n 0x1c6c6162,\n 0x856530d8,\n 0xf262004e,\n 0x6c0695ed,\n 0x1b01a57b,\n 0x8208f4c1,\n 0xf50fc457,\n 0x65b0d9c6,\n 0x12b7e950,\n 0x8bbeb8ea,\n 0xfcb9887c,\n 0x62dd1ddf,\n 0x15da2d49,\n 0x8cd37cf3,\n 0xfbd44c65,\n 0x4db26158,\n 0x3ab551ce,\n 0xa3bc0074,\n 0xd4bb30e2,\n 0x4adfa541,\n 0x3dd895d7,\n 0xa4d1c46d,\n 0xd3d6f4fb,\n 0x4369e96a,\n 0x346ed9fc,\n 0xad678846,\n 0xda60b8d0,\n 0x44042d73,\n 0x33031de5,\n 0xaa0a4c5f,\n 0xdd0d7cc9,\n 0x5005713c,\n 0x270241aa,\n 0xbe0b1010,\n 0xc90c2086,\n 0x5768b525,\n 0x206f85b3,\n 0xb966d409,\n 0xce61e49f,\n 0x5edef90e,\n 0x29d9c998,\n 0xb0d09822,\n 0xc7d7a8b4,\n 0x59b33d17,\n 0x2eb40d81,\n 0xb7bd5c3b,\n 0xc0ba6cad,\n 0xedb88320,\n 0x9abfb3b6,\n 0x03b6e20c,\n 0x74b1d29a,\n 0xead54739,\n 0x9dd277af,\n 0x04db2615,\n 0x73dc1683,\n 0xe3630b12,\n 0x94643b84,\n 0x0d6d6a3e,\n 0x7a6a5aa8,\n 0xe40ecf0b,\n 0x9309ff9d,\n 0x0a00ae27,\n 0x7d079eb1,\n 0xf00f9344,\n 0x8708a3d2,\n 0x1e01f268,\n 0x6906c2fe,\n 0xf762575d,\n 0x806567cb,\n 0x196c3671,\n 0x6e6b06e7,\n 0xfed41b76,\n 0x89d32be0,\n 0x10da7a5a,\n 0x67dd4acc,\n 0xf9b9df6f,\n 0x8ebeeff9,\n 0x17b7be43,\n 0x60b08ed5,\n 0xd6d6a3e8,\n 0xa1d1937e,\n 0x38d8c2c4,\n 0x4fdff252,\n 0xd1bb67f1,\n 0xa6bc5767,\n 0x3fb506dd,\n 0x48b2364b,\n 0xd80d2bda,\n 0xaf0a1b4c,\n 0x36034af6,\n 0x41047a60,\n 0xdf60efc3,\n 0xa867df55,\n 0x316e8eef,\n 0x4669be79,\n 0xcb61b38c,\n 0xbc66831a,\n 0x256fd2a0,\n 0x5268e236,\n 0xcc0c7795,\n 0xbb0b4703,\n 0x220216b9,\n 0x5505262f,\n 0xc5ba3bbe,\n 0xb2bd0b28,\n 0x2bb45a92,\n 0x5cb36a04,\n 0xc2d7ffa7,\n 0xb5d0cf31,\n 0x2cd99e8b,\n 0x5bdeae1d,\n 0x9b64c2b0,\n 0xec63f226,\n 0x756aa39c,\n 0x026d930a,\n 0x9c0906a9,\n 0xeb0e363f,\n 0x72076785,\n 0x05005713,\n 0x95bf4a82,\n 0xe2b87a14,\n 0x7bb12bae,\n 0x0cb61b38,\n 0x92d28e9b,\n 0xe5d5be0d,\n 0x7cdcefb7,\n 0x0bdbdf21,\n 0x86d3d2d4,\n 0xf1d4e242,\n 0x68ddb3f8,\n 0x1fda836e,\n 0x81be16cd,\n 0xf6b9265b,\n 0x6fb077e1,\n 0x18b74777,\n 0x88085ae6,\n 0xff0f6a70,\n 0x66063bca,\n 0x11010b5c,\n 0x8f659eff,\n 0xf862ae69,\n 0x616bffd3,\n 0x166ccf45,\n 0xa00ae278,\n 0xd70dd2ee,\n 0x4e048354,\n 0x3903b3c2,\n 0xa7672661,\n 0xd06016f7,\n 0x4969474d,\n 0x3e6e77db,\n 0xaed16a4a,\n 0xd9d65adc,\n 0x40df0b66,\n 0x37d83bf0,\n 0xa9bcae53,\n 0xdebb9ec5,\n 0x47b2cf7f,\n 0x30b5ffe9,\n 0xbdbdf21c,\n 0xcabac28a,\n 0x53b39330,\n 0x24b4a3a6,\n 0xbad03605,\n 0xcdd70693,\n 0x54de5729,\n 0x23d967bf,\n 0xb3667a2e,\n 0xc4614ab8,\n 0x5d681b02,\n 0x2a6f2b94,\n 0xb40bbe37,\n 0xc30c8ea1,\n 0x5a05df1b,\n 0x2d02ef8d\n);\n\nfunction getCRC32Table() {\n return CRC32TAB;\n}\n", "/**\n * `btoa()` polyfill as defined by the HTML and Infra specs, which mostly just references\n * RFC 4648.\n */\nexport function asciiToBase64(string: string): string | null {\n // String conversion as required by Web IDL.\n string = `${string}`;\n // \"The btoa() method must throw an \"InvalidCharacterError\" DOMException if\n // data contains any character whose code point is greater than U+00FF.\"\n for (let i = 0; i < string.length; i++) {\n if (string.charCodeAt(i) > 255) {\n return null;\n }\n }\n let out = '';\n for (let i = 0; i < string.length; i += 3) {\n /** @type {Array[4]} */\n const groupsOfSix: (number | undefined)[] = [undefined, undefined, undefined, undefined];\n groupsOfSix[0] = string.charCodeAt(i) >> 2;\n groupsOfSix[1] = (string.charCodeAt(i) & 0x03) << 4;\n if (string.length > i + 1) {\n groupsOfSix[1] |= string.charCodeAt(i + 1) >> 4;\n groupsOfSix[2] = (string.charCodeAt(i + 1) & 0x0f) << 2;\n }\n if (string.length > i + 2) {\n // @ts-expect-error\n groupsOfSix[2] |= string.charCodeAt(i + 2) >> 6;\n groupsOfSix[3] = string.charCodeAt(i + 2) & 0x3f;\n }\n for (let j = 0; j < groupsOfSix.length; j++) {\n if (typeof groupsOfSix[j] === 'undefined') {\n out += '=';\n } else {\n out += btoaLookup(groupsOfSix[j]);\n }\n }\n }\n return out;\n}\n\n/**\n * Implementation of atob() according to the HTML and Infra specs, except that\n * instead of throwing INVALID_CHARACTER_ERR we return null.\n *\n * @note Forked from https://github.com/jsdom/abab under BSD 3 clause license\n */\nexport function base64ToAscii(data: string): string {\n // Web IDL requires DOMStrings to just be converted using ECMAScript\n // ToString, which in our case amounts to using a template literal.\n data = `${data}`;\n // \"Remove all ASCII whitespace from data.\"\n data = data.replace(/[ \\t\\n\\f\\r]/g, '');\n // \"If data's code point length divides by 4 leaving no remainder, then: if data ends\n // with one or two U+003D (=) code points, then remove them from data.\"\n if (data.length % 4 === 0) {\n data = data.replace(/[=]=?$/, '');\n }\n // \"If data's code point length divides by 4 leaving a remainder of 1, then return\n // failure.\"\n //\n // \"If data contains a code point that is not one of\n //\n // U+002B (+)\n // U+002F (/)\n // ASCII alphanumeric\n //\n // then return failure.\"\n if (data.length % 4 === 1 || /[^+/0-9A-Za-z]/.test(data)) {\n return '';\n }\n // \"Let output be an empty byte sequence.\"\n let output = '';\n // \"Let buffer be an empty buffer that can have bits appended to it.\"\n //\n // We append bits via left-shift and or. accumulatedBits is used to track\n // when we've gotten to 24 bits.\n let buffer = 0;\n let accumulatedBits = 0;\n // \"Let position be a position variable for data, initially pointing at the\n // start of data.\"\n //\n // \"While position does not point past the end of data:\"\n for (let i = 0; i < data.length; i++) {\n // \"Find the code point pointed to by position in the second column of\n // Table 1: The Base 64 Alphabet of RFC 4648. Let n be the number given in\n // the first cell of the same row.\n //\n // \"Append to buffer the six bits corresponding to n, most significant bit\n // first.\"\n //\n // atobLookup() implements the table from RFC 4648.\n buffer <<= 6;\n // @ts-expect-error\n buffer |= atobLookup(data[i]);\n accumulatedBits += 6;\n // \"If buffer has accumulated 24 bits, interpret them as three 8-bit\n // big-endian numbers. Append three bytes with values equal to those\n // numbers to output, in the same order, and then empty buffer.\"\n if (accumulatedBits === 24) {\n output += String.fromCharCode((buffer & 0xff0000) >> 16);\n output += String.fromCharCode((buffer & 0xff00) >> 8);\n output += String.fromCharCode(buffer & 0xff);\n buffer = accumulatedBits = 0;\n }\n // \"Advance position by 1.\"\n }\n // \"If buffer is not empty, it contains either 12 or 18 bits. If it contains\n // 12 bits, then discard the last four and interpret the remaining eight as\n // an 8-bit big-endian number. If it contains 18 bits, then discard the last\n // two and interpret the remaining 16 as two 8-bit big-endian numbers. Append\n // the one or two bytes with values equal to those one or two numbers to\n // output, in the same order.\"\n if (accumulatedBits === 12) {\n buffer >>= 4;\n output += String.fromCharCode(buffer);\n } else if (accumulatedBits === 18) {\n buffer >>= 2;\n output += String.fromCharCode((buffer & 0xff00) >> 8);\n output += String.fromCharCode(buffer & 0xff);\n }\n // \"Return output.\"\n return output;\n}\n/**\n * A lookup table for atob(), which converts an ASCII character to the\n * corresponding six-bit number.\n */\n\nconst keystr = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/';\n\nfunction atobLookup(chr: string): number | undefined {\n const index = keystr.indexOf(chr);\n // Throw exception if character is not in the lookup string; should not be hit in tests\n return index < 0 ? undefined : index;\n}\n\n/**\n * Lookup table for btoa(), which converts a six-bit number into the\n * corresponding ASCII character.\n */\nfunction btoaLookup(idx) {\n if (idx < 26) {\n return String.fromCharCode(idx + 'A'.charCodeAt(0));\n }\n if (idx < 52) {\n return String.fromCharCode(idx - 26 + 'a'.charCodeAt(0));\n }\n if (idx < 62) {\n return String.fromCharCode(idx - 52 + '0'.charCodeAt(0));\n }\n if (idx === 62) {\n return '+';\n }\n if (idx === 63) {\n return '/';\n }\n // Throw INVALID_CHARACTER_ERR exception here -- won't be hit in the teststring.\n return undefined;\n}\n", "// loaders.gl, MIT license\n\nimport {asciiToBase64, base64ToAscii} from './base64-utils';\n\n/**\n * Encode a number (usually a digest from a hash function / cipher) as either hex or base64\n * Suitable for hashes like CRC32 where the number of required bits fit withing a JavaScript number.\n */\nexport function encodeNumber(number: number, encoding: 'hex' | 'base64'): string {\n switch (encoding) {\n case 'hex':\n return convertNumberToHex(number);\n case 'base64':\n return convertHexToBase64(convertNumberToHex(number));\n default:\n throw new Error(encoding);\n }\n}\n\n/** Encode a hex string, aeither return hex or re-encode as base64 */\nexport function encodeHex(hex: string, encoding: 'hex' | 'base64'): string {\n switch (encoding) {\n case 'hex':\n return hex;\n case 'base64':\n return convertHexToBase64(hex);\n default:\n throw new Error(encoding);\n }\n}\n\nexport function encodeBase64(base64: string, encoding: 'hex' | 'base64'): string {\n switch (encoding) {\n case 'hex':\n return convertBase64ToHex(base64);\n case 'base64':\n return base64;\n default:\n throw new Error(encoding);\n }\n}\n\n/**\n * Convert a hexadecimal string to base64 encoded string representation\n */\nfunction convertHexToBase64(hexstring: string): string {\n // Add leading zero to keep even count of digits\n // eg. f85d741 => 0f85d741\n if (hexstring.length % 2 !== 0) {\n hexstring = `0${hexstring}`;\n }\n const matches = hexstring.match(/\\w{2}/g) || [];\n const string = matches.map((a) => String.fromCharCode(parseInt(a, 16))).join('');\n // TODO - define how to handle failures\n return asciiToBase64(string) || '';\n}\n\n/**\n * Convert a base64 encoded string to hexadecimal encoded string representation\n */\nfunction convertBase64ToHex(base64String: string): string {\n return [...base64ToAscii(base64String)]\n .map((c) => c.charCodeAt(0).toString(16).padStart(2, '0'))\n .join('');\n}\n\n/**\n * Converts a number to hex\n */\nfunction convertNumberToHex(cipher: number): string {\n const hexString = cipher.toString(16);\n return hexString === '0' ? `0${hexString}` : hexString;\n}\n", "// CRC32\nimport {Hash} from './hash';\nimport CRC32 from './algorithms/crc32';\nimport {encodeNumber} from './utils/digest-utils';\n\n/**\n * Calculates CRC32 Cryptographic Hash\n */\nexport class CRC32Hash extends Hash {\n readonly name = 'crc32';\n\n options;\n private _hash: CRC32;\n\n constructor(options = {}) {\n super();\n this.options = {crypto: {}, ...options};\n this._hash = new CRC32();\n this.hashBatches = this.hashBatches.bind(this);\n }\n\n /**\n * Atomic hash calculation\n * @returns base64 encoded hash\n */\n async hash(input: ArrayBuffer, encoding: 'hex' | 'base64'): Promise<string> {\n return this.hashSync(input, encoding);\n }\n\n hashSync(input: ArrayBuffer, encoding: 'hex' | 'base64'): string {\n this._hash.update(input);\n const digest = this._hash.finalize();\n return encodeNumber(digest, encoding);\n }\n\n async *hashBatches(\n asyncIterator: AsyncIterable<ArrayBuffer> | Iterable<ArrayBuffer>,\n encoding: 'hex' | 'base64' = 'base64'\n ): AsyncIterable<ArrayBuffer> {\n for await (const chunk of asyncIterator) {\n this._hash.update(chunk);\n yield chunk;\n }\n const digest = this._hash.finalize();\n const hash = encodeNumber(digest, encoding);\n this.options.crypto?.onEnd?.({hash});\n }\n}\n", "// From: https://gist.github.com/wqli78/1330293/6d85cc967f32cccfcbad94ae7d088a3dcfc14bd9\n// CRC32 doesn't appear to be supported natively by crypto-js\n\n// import {toBuffer} from '@loaders.gl/loader-utils';\n// import {calculate as sse4calculate} from 'sse4_crc32';\n\n/**\n * Calculates the CRC32C checksum of a string.\n */\nexport default class CRC32C {\n options;\n crc: number;\n\n constructor(options = {}) {\n this.options = options;\n this.crc = ~0;\n }\n\n update(arrayBuffer) {\n const byteArray = new Uint8Array(arrayBuffer);\n const CRC32_TABLE = getCRC32Table();\n for (let i = 0; i < byteArray.length; i++) {\n this.crc = CRC32_TABLE[(this.crc ^ byteArray[i]) & 0xff] ^ (this.crc >>> 8);\n }\n return this;\n }\n\n finalize() {\n this.crc = (this.crc ^ -1) >>> 0;\n return this.crc;\n }\n}\n\n/**\n * This code is a manual javascript translation of c code generated by\n * pycrc 0.7.1 (http://www.tty1.net/pycrc/). Command line used:\n * './pycrc.py --model=crc-32c --generate c --algorithm=table-driven'\n */\n\n// Note: Using a typed array here doubles the speed of the cipher\nconst CRC32C_TABLE = Int32Array.of(\n 0x00000000,\n 0xf26b8303,\n 0xe13b70f7,\n 0x1350f3f4,\n 0xc79a971f,\n 0x35f1141c,\n 0x26a1e7e8,\n 0xd4ca64eb,\n 0x8ad958cf,\n 0x78b2dbcc,\n 0x6be22838,\n 0x9989ab3b,\n 0x4d43cfd0,\n 0xbf284cd3,\n 0xac78bf27,\n 0x5e133c24,\n 0x105ec76f,\n 0xe235446c,\n 0xf165b798,\n 0x030e349b,\n 0xd7c45070,\n 0x25afd373,\n 0x36ff2087,\n 0xc494a384,\n 0x9a879fa0,\n 0x68ec1ca3,\n 0x7bbcef57,\n 0x89d76c54,\n 0x5d1d08bf,\n 0xaf768bbc,\n 0xbc267848,\n 0x4e4dfb4b,\n 0x20bd8ede,\n 0xd2d60ddd,\n 0xc186fe29,\n 0x33ed7d2a,\n 0xe72719c1,\n 0x154c9ac2,\n 0x061c6936,\n 0xf477ea35,\n 0xaa64d611,\n 0x580f5512,\n 0x4b5fa6e6,\n 0xb93425e5,\n 0x6dfe410e,\n 0x9f95c20d,\n 0x8cc531f9,\n 0x7eaeb2fa,\n 0x30e349b1,\n 0xc288cab2,\n 0xd1d83946,\n 0x23b3ba45,\n 0xf779deae,\n 0x05125dad,\n 0x1642ae59,\n 0xe4292d5a,\n 0xba3a117e,\n 0x4851927d,\n 0x5b016189,\n 0xa96ae28a,\n 0x7da08661,\n 0x8fcb0562,\n 0x9c9bf696,\n 0x6ef07595,\n 0x417b1dbc,\n 0xb3109ebf,\n 0xa0406d4b,\n 0x522bee48,\n 0x86e18aa3,\n 0x748a09a0,\n 0x67dafa54,\n 0x95b17957,\n 0xcba24573,\n 0x39c9c670,\n 0x2a993584,\n 0xd8f2b687,\n 0x0c38d26c,\n 0xfe53516f,\n 0xed03a29b,\n 0x1f682198,\n 0x5125dad3,\n 0xa34e59d0,\n 0xb01eaa24,\n 0x42752927,\n 0x96bf4dcc,\n 0x64d4cecf,\n 0x77843d3b,\n 0x85efbe38,\n 0xdbfc821c,\n 0x2997011f,\n 0x3ac7f2eb,\n 0xc8ac71e8,\n 0x1c661503,\n 0xee0d9600,\n 0xfd5d65f4,\n 0x0f36e6f7,\n 0x61c69362,\n 0x93ad1061,\n 0x80fde395,\n 0x72966096,\n 0xa65c047d,\n 0x5437877e,\n 0x4767748a,\n 0xb50cf789,\n 0xeb1fcbad,\n 0x197448ae,\n 0x0a24bb5a,\n 0xf84f3859,\n 0x2c855cb2,\n 0xdeeedfb1,\n 0xcdbe2c45,\n 0x3fd5af46,\n 0x7198540d,\n 0x83f3d70e,\n 0x90a324fa,\n 0x62c8a7f9,\n 0xb602c312,\n 0x44694011,\n 0x5739b3e5,\n 0xa55230e6,\n 0xfb410cc2,\n 0x092a8fc1,\n 0x1a7a7c35,\n 0xe811ff36,\n 0x3cdb9bdd,\n 0xceb018de,\n 0xdde0eb2a,\n 0x2f8b6829,\n 0x82f63b78,\n 0x709db87b,\n 0x63cd4b8f,\n 0x91a6c88c,\n 0x456cac67,\n 0xb7072f64,\n 0xa457dc90,\n 0x563c5f93,\n 0x082f63b7,\n 0xfa44e0b4,\n 0xe9141340,\n 0x1b7f9043,\n 0xcfb5f4a8,\n 0x3dde77ab,\n 0x2e8e845f,\n 0xdce5075c,\n 0x92a8fc17,\n 0x60c37f14,\n 0x73938ce0,\n 0x81f80fe3,\n 0x55326b08,\n 0xa759e80b,\n 0xb4091bff,\n 0x466298fc,\n 0x1871a4d8,\n 0xea1a27db,\n 0xf94ad42f,\n 0x0b21572c,\n 0xdfeb33c7,\n 0x2d80b0c4,\n 0x3ed04330,\n 0xccbbc033,\n 0xa24bb5a6,\n 0x502036a5,\n 0x4370c551,\n 0xb11b4652,\n 0x65d122b9,\n 0x97baa1ba,\n 0x84ea524e,\n 0x7681d14d,\n 0x2892ed69,\n 0xdaf96e6a,\n 0xc9a99d9e,\n 0x3bc21e9d,\n 0xef087a76,\n 0x1d63f975,\n 0x0e330a81,\n 0xfc588982,\n 0xb21572c9,\n 0x407ef1ca,\n 0x532e023e,\n 0xa145813d,\n 0x758fe5d6,\n 0x87e466d5,\n 0x94b49521,\n 0x66df1622,\n 0x38cc2a06,\n 0xcaa7a905,\n 0xd9f75af1,\n 0x2b9cd9f2,\n 0xff56bd19,\n 0x0d3d3e1a,\n 0x1e6dcdee,\n 0xec064eed,\n 0xc38d26c4,\n 0x31e6a5c7,\n 0x22b65633,\n 0xd0ddd530,\n 0x0417b1db,\n 0xf67c32d8,\n 0xe52cc12c,\n 0x1747422f,\n 0x49547e0b,\n 0xbb3ffd08,\n 0xa86f0efc,\n 0x5a048dff,\n 0x8ecee914,\n 0x7ca56a17,\n 0x6ff599e3,\n 0x9d9e1ae0,\n 0xd3d3e1ab,\n 0x21b862a8,\n 0x32e8915c,\n 0xc083125f,\n 0x144976b4,\n 0xe622f5b7,\n 0xf5720643,\n 0x07198540,\n 0x590ab964,\n 0xab613a67,\n 0xb831c993,\n 0x4a5a4a90,\n 0x9e902e7b,\n 0x6cfbad78,\n 0x7fab5e8c,\n 0x8dc0dd8f,\n 0xe330a81a,\n 0x115b2b19,\n 0x020bd8ed,\n 0xf0605bee,\n 0x24aa3f05,\n 0xd6c1bc06,\n 0xc5914ff2,\n 0x37faccf1,\n 0x69e9f0d5,\n 0x9b8273d6,\n 0x88d28022,\n 0x7ab90321,\n 0xae7367ca,\n 0x5c18e4c9,\n 0x4f48173d,\n 0xbd23943e,\n 0xf36e6f75,\n 0x0105ec76,\n 0x12551f82,\n 0xe03e9c81,\n 0x34f4f86a,\n 0xc69f7b69,\n 0xd5cf889d,\n 0x27a40b9e,\n 0x79b737ba,\n 0x8bdcb4b9,\n 0x988c474d,\n 0x6ae7c44e,\n 0xbe2da0a5,\n 0x4c4623a6,\n 0x5f16d052,\n 0xad7d5351\n);\n\nfunction getCRC32Table() {\n return CRC32C_TABLE;\n}\n", "// CRC32c\nimport {Hash} from './hash';\nimport CRC32C from './algorithms/crc32c';\nimport {encodeNumber} from './utils/digest-utils';\n\n/**\n * A transform that calculates CRC32c Hash\n */\nexport class CRC32CHash extends Hash {\n readonly name = 'crc32c';\n\n options;\n private _hash: CRC32C;\n\n /**\n * Atomic hash calculation\n * @returns base64 encoded hash\n */\n constructor(options = {}) {\n super();\n this.options = {crypto: {}, ...options};\n this._hash = new CRC32C(options);\n }\n\n /**\n * Atomic hash calculation\n * @returns base64 encoded hash\n */\n async hash(input: ArrayBuffer, encoding: 'hex' | 'base64'): Promise<string> {\n return this.hashSync(input, encoding);\n }\n\n hashSync(input: ArrayBuffer, encoding: 'hex' | 'base64'): string {\n this._hash.update(input);\n const digest = this._hash.finalize();\n return encodeNumber(digest, encoding);\n }\n\n // runInBatches inherited\n\n async *hashBatches(\n asyncIterator: AsyncIterable<ArrayBuffer> | Iterable<ArrayBuffer>,\n encoding: 'hex' | 'base64' = 'base64'\n ): AsyncIterable<ArrayBuffer> {\n for await (const chunk of asyncIterator) {\n this._hash.update(chunk);\n yield chunk;\n }\n const digest = this._hash.finalize();\n const hash = encodeNumber(digest, encoding);\n this.options.crypto?.onEnd?.({hash});\n }\n}\n", "/* eslint-disable */\n// @ts-nocheck\n/* !\n * MD5 WebAssembly\n * https://github.com/briantbutton/md5-wasm\n * (c) 2020 Brian Todd Button\n * Released under the MIT license\n */\n\n// *-*=* *=*-* *-*=* *=*-* *-*=* *=*-* *-*=* *=*-* *-*=* *=*-* *-*=* *=*-*\n// This contains two functions designed to achieve the same thing\n// -> A WebAssembly function for larger files\n// -> A JavaScript function for the others\n//\nconst atb = typeof atob === 'function' ? atob : typeof Buffer === 'function' ? nodeATOB : identity,\n wasmB64 = atb(\n 'AGFzbQEAAAABDANgAX8AYAAAYAABfwIeAgdpbXBvcnRzA2xvZwAAB2ltcG9ydHMDbWVtAgABAzIxAAEBAQEBAQEBAQEBAQEBAQEBAQEBAQEAAAAAAAAAAAAAAAAAAAAAAgICAgIAAAAAAAaYARt/AUGBxpS6Bgt/AUGJ17b+fgt/AUH+uevFeQt/AUH2qMmBAQt/AUEAC38BQQALfwFBAAt/AUEAC38BQQALfwFBAAt/AUEAC38BQQALfwFBAAt/AUEAC38BQQALfwFBAAt/AUEAC38BQQALfwFBAAt/AUEAC38BQQALfwFBAAt/AUEAC38BQQALfwFBAAt/AUEAC38BQQALB7oCJQhvbmVGdWxsQQAYCG9uZUZ1bGxCABkIb25lRnVsbEMAGghvbmVGdWxsRAAbBWxvb3BzAAEEbG9vcAACBXByaW1lAAMFbG9vcEEABAZsb29wQTEABQZsb29wQTIABgZsb29wQTMABwZsb29wQTQACAVsb29wQgAJBmxvb3BCMQAKBmxvb3BCMgALBmxvb3BCMwAMBmxvb3BCNAANBWxvb3BDAA4GbG9vcEMxAA8GbG9vcEMyABAGbG9vcEMzABEGbG9vcEM0ABIFbG9vcEQAEwZsb29wRDEAFAZsb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icCAAABAW4oACkAKgArACwALQEAAC4BAAAvAQAAMAEAADEBAAA='\n ),\n wasm = WebAssembly && atb !== identity ? str2AB(wasmB64).buffer : false,\n crypt = makeCrypt(),\n biteSize = 240 * 16 * 16,\n bounder = Math.floor(biteSize * 16 * 1.066666667),\n upperLimit = 268435456 - 65536,\n parmTypeErrStr = 'Parameter must be Buffer, ArrayBuffer or Uint8Array',\n tooBigErrStr = 'Parameter exceeds max size of 255.9 Mbytes';\n\nif (!wasm) {\n console.log(\n 'WebAssembly not available or WASM module could not be decoded; md5WASM will fall back to JavaScript'\n );\n}\n\n// - - - - - - - - - - - - - - - - - - - - - - - - - - -\n// This returns a Promise-like object (I was farting around, so sue me)\n// which supports '.catch' and '.then'\nexport default function md5WASM(data) {\n var mem, memView, importObj, imports, len, buff, thenFun, catchFun, result, endTime;\n const md5JS = makeMD5JS(),\n md5WA = makeMD5WA(),\n returnObj = {},\n startTime = new Date().getTime();\n\n returnObj['then'] = function (fun) {\n thenFun = fun;\n getThen();\n return returnObj;\n };\n returnObj['catch'] = function (fun) {\n catchFun = fun;\n return returnObj;\n };\n\n // Sift the incoming parameter and the environment\n // If we are good, set buff\n if (true) {\n if (data && typeof data === 'object') {\n if (typeof Buffer === 'function' && data.constructor === Buffer) {\n buff = data;\n } else {\n if (data.constructor === Uint8Array || data.constructor === ArrayBuffer) {\n buff = data.constructor === ArrayBuffer ? new Uint8Array(data) : data;\n } else {\n getCatch(new TypeError(parmTypeErrStr));\n }\n }\n } else {\n getCatch(new TypeError(parmTypeErrStr));\n }\n }\n\n // - - - - - - - - - - - - - - - - - - - - - - - - - -\n // Make some choices based on the size of the incoming data\n // ~ Use WebAssembly or just JavaScript\n // ~ If Webassemly, allocate appropriate memory\n //\n if (buff) {\n len = buff.length;\n if (wasm && len > bounder) {\n if (len > upperLimit) {\n getCatch(new Error(tooBigErrStr));\n } else {\n mem = new WebAssembly.Memory({\n initial: len > 32000000 ? (len > 64000000 ? (len > 128000000 ? 4096 : 2048) : 1024) : 512\n });\n memView = new Uint32Array(mem.buffer);\n imports = {mem: mem, log: console.log};\n importObj = {imports};\n WebAssembly.instantiate(wasm, importObj).then(giterdone);\n }\n } else {\n getThen(md5JS(buff));\n }\n }\n return returnObj;\n\n function giterdone(obj) {\n getThen(md5WA(buff, obj.instance.exports, memView));\n }\n function getThen(r) {\n var res = Boolean(r) ? r : result;\n if (Boolean(r)) {\n endTime = new Date().getTime();\n }\n if (typeof thenFun === 'function') {\n if (Boolean(res)) {\n thenFun(res, endTime - startTime);\n thenFun = catchFun = null;\n }\n } else {\n if (Boolean(r)) {\n result = r;\n }\n }\n }\n function getCatch(err) {\n if (typeof catchFun === 'function') {\n catchFun(err);\n }\n }\n}\n\nfunction makeMD5WA() {\n var loop, loops;\n var getA, setA, getB, setB, getC, setC, getD, setD, getX, setX, memView;\n\n var md5WA = function (message) {\n var m00,\n m01,\n m02,\n m03,\n m04,\n m05,\n m06,\n m07,\n m08,\n m09,\n m10,\n m11,\n m12,\n m13,\n m14,\n m15,\n aa,\n bb,\n cc,\n dd,\n m,\n k;\n var qwerty = new Date().getTime();\n var md5Used = 0;\n\n var a = 1732584193,\n b = -271733879,\n c = -1732584194,\n d = 271733878,\n i = 0,\n l = message.length * 8,\n len;\n\n len = bytesToWordsNewer(message, memView);\n memView[l >>> 5] |= 0x80 << l % 32;\n memView[(((l + 64) >>> 9) << 4) + 14] = l;\n len = (((l + 64) >>> 9) << 4) + 15;\n m = memView;\n\n // console.log(\"first loop took \"+((new Date().getTime())-qwerty)+\"ms\");\n\n while (i < len) {\n if (len > i + bounder) {\n setA(a);\n setB(b);\n setC(c);\n setD(d);\n loops(biteSize);\n i = i + biteSize * 16;\n a = getA();\n b = getB();\n c = getC();\n d = getD();\n md5Used++;\n } else {\n aa = a;\n bb = b;\n cc = c;\n dd = d;\n m00 = m[i + 0] >>> 0;\n m01 = m[i + 1] >>> 0;\n m02 = m[i + 2] >>> 0;\n m03 = m[i + 3] >>> 0;\n m04 = m[i + 4] >>> 0;\n m05 = m[i + 5] >>> 0;\n m06 = m[i + 6] >>> 0;\n m07 = m[i + 7] >>> 0;\n m08 = m[i + 8] >>> 0;\n m09 = m[i + 9] >>> 0;\n m10 = m[i + 10] >>> 0;\n m11 = m[i + 11] >>> 0;\n m12 = m[i + 12] >>> 0;\n m13 = m[i + 13] >>> 0;\n m14 = m[i + 14] >>> 0;\n m15 = m[i + 15] >>> 0;\n\n a = ____(7, 25, a + ((b & c) | (~b & d)) + m00 - 680876936) + b;\n d = ____(12, 20, d + ((a & b) | (~a & c)) + m01 - 389564586) + a;\n c = ____(17, 15, c + ((d & a) | (~d & b)) + m02 + 606105819) + d;\n b = ____(22, 10, b + ((c & d) | (~c & a)) + m03 - 1044525330) + c;\n a = ____(7, 25, a + ((b & c) | (~b & d)) + m04 - 176418897) + b;\n d = ____(12, 20, d + ((a & b) | (~a & c)) + m05 + 1200080426) + a;\n c = ____(17, 15, c + ((d & a) | (~d & b)) + m06 - 1473231341) + d;\n b = ____(22, 10, b + ((c & d) | (~c & a)) + m07 - 45705983) + c;\n a = ____(7, 25, a + ((b & c) | (~b & d)) + m08 + 1770035416) + b;\n d = ____(12, 20, d + ((a & b) | (~a & c)) + m09 - 1958414417) + a;\n c = ____(17, 15, c + ((d & a) | (~d & b)) + m10 - 42063) + d;\n b = ____(22, 10, b + ((c & d) | (~c & a)) + m11 - 1990404162) + c;\n a = ____(7, 25, a + ((b & c) | (~b & d)) + m12 + 1804603682) + b;\n d = ____(12, 20, d + ((a & b) | (~a & c)) + m13 - 40341101) + a;\n c = ____(17, 15, c + ((d & a) | (~d & b)) + m14 - 1502002290) + d;\n b = ____(22, 10, b + ((c & d) | (~c & a)) + m15 + 1236535329) + c;\n\n a = ____(5, 27, a + ((b & d) | (c & ~d)) + m01 - 165796510) + b;\n d = ____(9, 23, d + ((a & c) | (b & ~c)) + m06 - 1069501632) + a;\n c = ____(14, 18, c + ((d & b) | (a & ~b)) + m11 + 643717713) + d;\n b = ____(20, 12, b + ((c & a) | (d & ~a)) + m00 - 373897302) + c;\n a = ____(5, 27, a + ((b & d) | (c & ~d)) + m05 - 701558691) + b;\n d = ____(9, 23, d + ((a & c) | (b & ~c)) + m10 + 38016083) + a;\n c = ____(14, 18, c + ((d & b) | (a & ~b)) + m15 - 660478335) + d;\n b = ____(20, 12, b + ((c & a) | (d & ~a)) + m04 - 405537848) + c;\n a = ____(5, 27, a + ((b & d) | (c & ~d)) + m09 + 568446438) + b;\n d = ____(9, 23, d + ((a & c) | (b & ~c)) + m14 - 1019803690) + a;\n c = ____(14, 18, c + ((d & b) | (a & ~b)) + m03 - 187363961) + d;\n b = ____(20, 12, b + ((c & a) | (d & ~a)) + m08 + 1163531501) + c;\n a = ____(5, 27, a + ((b & d) | (c & ~d)) + m13 - 1444681467) + b;\n d = ____(9, 23, d + ((a & c) | (b & ~c)) + m02 - 51403784) + a;\n c = ____(14, 18, c + ((d & b) | (a & ~b)) + m07 + 1735328473) + d;\n b = ____(20, 12, b + ((c & a) | (d & ~a)) + m12 - 1926607734) + c;\n\n a = ____(4, 28, a + (b ^ c ^ d) + m05 - 378558) + b;\n d = ____(11, 21, d + (a ^ b ^ c) + m08 - 2022574463) + a;\n c = ____(16, 16, c + (d ^ a ^ b) + m11 + 1839030562) + d;\n b = ____(23, 9, b + (c ^ d ^ a) + m14 - 35309556) + c;\n a = ____(4, 28, a + (b ^ c ^ d) + m01 - 1530992060) + b;\n d = ____(11, 21, d + (a ^ b ^ c) + m04 + 1272893353) + a;\n c = ____(16, 16, c + (d ^ a ^ b) + m07 - 155497632) + d;\n b = ____(23, 9, b + (c ^ d ^ a) + m10 - 1094730640) + c;\n a = ____(4, 28, a + (b ^ c ^ d) + m13 + 681279174) + b;\n d = ____(11, 21, d + (a ^ b ^ c) + m00 - 358537222) + a;\n c = ____(16, 16, c + (d ^ a ^ b) + m03 - 722521979) + d;\n b = ____(23, 9, b + (c ^ d ^ a) + m06 + 76029189) + c;\n a = ____(4, 28, a + (b ^ c ^ d) + m09 - 640364487) + b;\n d = ____(11, 21, d + (a ^ b ^ c) + m12 - 421815835) + a;\n c = ____(16, 16, c + (d ^ a ^ b) + m15 + 530742520) + d;\n b = ____(23, 9, b + (c ^ d ^ a) + m02 - 995338651) + c;\n\n a = ____(6, 26, a + (c ^ (b | ~d)) + m00 - 198630844) + b;\n d = ____(10, 22, d + (b ^ (a | ~c)) + m07 + 1126891415) + a;\n c = ____(15, 17, c + (a ^ (d | ~b)) + m14 - 1416354905) + d;\n b = ____(21, 11, b + (d ^ (c | ~a)) + m05 - 57434055) + c;\n a = ____(6, 26, a + (c ^ (b | ~d)) + m12 + 1700485571) + b;\n d = ____(10, 22, d + (b ^ (a | ~c)) + m03 - 1894986606) + a;\n c = ____(15, 17, c + (a ^ (d | ~b)) + m10 - 1051523) + d;\n b = ____(21, 11, b + (d ^ (c | ~a)) + m01 - 2054922799) + c;\n a = ____(6, 26, a + (c ^ (b | ~d)) + m08 + 1873313359) + b;\n d = ____(10, 22, d + (b ^ (a | ~c)) + m15 - 30611744) + a;\n c = ____(15, 17, c + (a ^ (d | ~b)) + m06 - 1560198380) + d;\n b = ____(21, 11, b + (d ^ (c | ~a)) + m13 + 1309151649) + c;\n a = ____(6, 26, a + (c ^ (b | ~d)) + m04 - 145523070) + b;\n d = ____(10, 22, d + (b ^ (a | ~c)) + m11 - 1120210379) + a;\n c = ____(15, 17, c + (a ^ (d | ~b)) + m02 + 718787259) + d;\n b = ____(21, 11, b + (d ^ (c | ~a)) + m09 - 343485551) + c;\n\n i = i + 16;\n a = (a + aa) >>> 0;\n b = (b + bb) >>> 0;\n c = (c + cc) >>> 0;\n d = (d + dd) >>> 0;\n }\n }\n\n // console.log(\"md5WA, elapsed=\"+((new Date().getTime())-qwerty)+(md5Used?\", WebAssembly called \"+md5Used+\" times\":\", WebAssembly not called\"));\n\n return crypt.endian([a, b, c, d]);\n\n function ____(s, t, n) {\n return (n << s) | (n >>> t);\n }\n\n // Convert a byte array to big-endian 32-bit words\n function bytesToWordsNewer(bytes, words) {\n var i = -1,\n l = Math.floor((bytes.length - 1) / 4),\n j = 0,\n b0,\n b1,\n b2,\n b3;\n while (l - 8 > i++) {\n j = i << 2;\n words[i] = bytes[j + 0] | (bytes[j + 1] << 8) | (bytes[j + 2] << 16) | (bytes[j + 3] << 24);\n }\n i--;\n while (l > i++) {\n j = i << 2;\n b0 = typeof bytes[j + 0] === 'undefined' ? 0 : bytes[j + 0];\n b1 = typeof bytes[j + 1] === 'undefined' ? 0 : bytes[j + 1];\n b2 = typeof bytes[j + 2] === 'undefined' ? 0 : bytes[j + 2];\n b3 = typeof bytes[j + 3] === 'undefined' ? 0 : bytes[j + 3];\n words[i] = b0 | (b1 << 8) | (b2 << 16) | (b3 << 24);\n }\n return l + 1;\n }\n };\n\n return function (message, exports, mView, options) {\n var digestbytes;\n loops = exports.loops;\n loop = exports.loop;\n getA = exports.getA;\n getB = exports.getB;\n getC = exports.getC;\n getD = exports.getD;\n getX = exports.getX;\n setA = exports.setA;\n setB = exports.setB;\n setC = exports.setC;\n setD = exports.setD;\n setX = exports.setX;\n memView = mView;\n digestbytes = crypt.wordsToBytes(md5WA(message));\n return options && options.asBytes ? digestbytes : crypt.bytesconvertNumberToHex(digestbytes);\n };\n}\n\nfunction makeMD5JS() {\n var md5JS = function (message, options) {\n var m00,\n m01,\n m02,\n m03,\n m04,\n m05,\n m06,\n m07,\n m08,\n m09,\n m10,\n m11,\n m12,\n m13,\n m14,\n m15,\n aa,\n bb,\n cc,\n dd,\n m;\n var qwerty = new Date().getTime();\n\n // console.log(\"md5 start\");\n\n var a = 1732584193,\n b = -271733879,\n c = -1732584194,\n d = 271733878,\n l = message.length * 8;\n\n m = crypt.bytesToWords(message);\n\n // Swap endian\n for (var j = 0; j < m.length; j++) {\n m[j] =\n (((m[j] << 8) | (m[j] >>> 24)) & 0x00ff00ff) | (((m[j] << 24) | (m[j] >>> 8)) & 0xff00ff00);\n }\n\n // Padding\n m[l >>> 5] |= 0x80 << l % 32;\n m[(((l + 64) >>> 9) << 4) + 14] = l;\n\n for (var i = 0; i < m.length; i += 16) {\n aa = a;\n bb = b;\n cc = c;\n dd = d;\n m00 = m[i + 0] >>> 0;\n m01 = m[i + 1] >>> 0;\n m02 = m[i + 2] >>> 0;\n m03 = m[i + 3] >>> 0;\n m04 = m[i + 4] >>> 0;\n m05 = m[i + 5] >>> 0;\n m06 = m[i + 6] >>> 0;\n m07 = m[i + 7] >>> 0;\n m08 = m[i + 8] >>> 0;\n m09 = m[i + 9] >>> 0;\n m10 = m[i + 10] >>> 0;\n m11 = m[i + 11] >>> 0;\n m12 = m[i + 12] >>> 0;\n m13 = m[i + 13] >>> 0;\n m14 = m[i + 14] >>> 0;\n m15 = m[i + 15] >>> 0;\n\n a = ____(7, 25, a + ((b & c) | (~b & d)) + m00 - 680876936) + b;\n d = ____(12, 20, d + ((a & b) | (~a & c)) + m01 - 389564586) + a;\n c = ____(17, 15, c + ((d & a) | (~d & b)) + m02 + 606105819) + d;\n b = ____(22, 10, b + ((c & d) | (~c & a)) + m03 - 1044525330) + c;\n a = ____(7, 25, a + ((b & c) | (~b & d)) + m04 - 176418897) + b;\n d = ____(12, 20, d + ((a & b) | (~a & c)) + m05 + 1200080426) + a;\n c = ____(17, 15, c + ((d & a) | (~d & b)) + m06 - 1473231341) + d;\n b = ____(22, 10, b + ((c & d) | (~c & a)) + m07 - 45705983) + c;\n a = ____(7, 25, a + ((b & c) | (~b & d)) + m08 + 1770035416) + b;\n d = ____(12, 20, d + ((a & b) | (~a & c)) + m09 - 1958414417) + a;\n c = ____(17, 15, c + ((d & a) | (~d & b)) + m10 - 42063) + d;\n b = ____(22, 10, b + ((c & d) | (~c & a)) + m11 - 1990404162) + c;\n a = ____(7, 25, a + ((b & c) | (~b & d)) + m12 + 1804603682) + b;\n d = ____(12, 20, d + ((a & b) | (~a & c)) + m13 - 40341101) + a;\n c = ____(17, 15, c + ((d & a) | (~d & b)) + m14 - 1502002290) + d;\n b = ____(22, 10, b + ((c & d) | (~c & a)) + m15 + 1236535329) + c;\n\n a = ____(5, 27, a + ((b & d) | (c & ~d)) + m01 - 165796510) + b;\n d = ____(9, 23, d + ((a & c) | (b & ~c)) + m06 - 1069501632) + a;\n c = ____(14, 18, c + ((d & b) | (a & ~b)) + m11 + 643717713) + d;\n b = ____(20, 12, b + ((c & a) | (d & ~a)) + m00 - 373897302) + c;\n a = ____(5, 27, a + ((b & d) | (c & ~d)) + m05 - 701558691) + b;\n d = ____(9, 23, d + ((a & c) | (b & ~c)) + m10 + 38016083) + a;\n c = ____(14, 18, c + ((d & b) | (a & ~b)) + m15 - 660478335) + d;\n b = ____(20, 12, b + ((c & a) | (d & ~a)) + m04 - 405537848) + c;\n a = ____(5, 27, a + ((b & d) | (c & ~d)) + m09 + 568446438) + b;\n d = ____(9, 23, d + ((a & c) | (b & ~c)) + m14 - 1019803690) + a;\n c = ____(14, 18, c + ((d & b) | (a & ~b)) + m03 - 187363961) + d;\n b = ____(20, 12, b + ((c & a) | (d & ~a)) + m08 + 1163531501) + c;\n a = ____(5, 27, a + ((b & d) | (c & ~d)) + m13 - 1444681467) + b;\n d = ____(9, 23, d + ((a & c) | (b & ~c)) + m02 - 51403784) + a;\n c = ____(14, 18, c + ((d & b) | (a & ~b)) + m07 + 1735328473) + d;\n b = ____(20, 12, b + ((c & a) | (d & ~a)) + m12 - 1926607734) + c;\n\n a = ____(4, 28, a + (b ^ c ^ d) + m05 - 378558) + b;\n d = ____(11, 21, d + (a ^ b ^ c) + m08 - 2022574463) + a;\n c = ____(16, 16, c + (d ^ a ^ b) + m11 + 1839030562) + d;\n b = ____(23, 9, b + (c ^ d ^ a) + m14 - 35309556) + c;\n a = ____(4, 28, a + (b ^ c ^ d) + m01 - 1530992060) + b;\n d = ____(11, 21, d + (a ^ b ^ c) + m04 + 1272893353) + a;\n c = ____(16, 16, c + (d ^ a ^ b) + m07 - 155497632) + d;\n b = ____(23, 9, b + (c ^ d ^ a) + m10 - 1094730640) + c;\n a = ____(4, 28, a + (b ^ c ^ d) + m13 + 681279174) + b;\n d = ____(11, 21, d + (a ^ b ^ c) + m00 - 358537222) + a;\n c = ____(16, 16, c + (d ^ a ^ b) + m03 - 722521979) + d;\n b = ____(23, 9, b + (c ^ d ^ a) + m06 + 76029189) + c;\n a = ____(4, 28, a + (b ^ c ^ d) + m09 - 640364487) + b;\n d = ____(11, 21, d + (a ^ b ^ c) + m12 - 421815835) + a;\n c = ____(16, 16, c + (d ^ a ^ b) + m15 + 530742520) + d;\n b = ____(23, 9, b + (c ^ d ^ a) + m02 - 995338651) + c;\n\n a = ____(6, 26, a + (c ^ (b | ~d)) + m00 - 198630844) + b;\n d = ____(10, 22, d + (b ^ (a | ~c)) + m07 + 1126891415) + a;\n c = ____(15, 17, c + (a ^ (d | ~b)) + m14 - 1416354905) + d;\n b = ____(21, 11, b + (d ^ (c | ~a)) + m05 - 57434055) + c;\n a = ____(6, 26, a + (c ^ (b | ~d)) + m12 + 1700485571) + b;\n d = ____(10, 22, d + (b ^ (a | ~c)) + m03 - 1894986606) + a;\n c = ____(15, 17, c + (a ^ (d | ~b)) + m10 - 1051523) + d;\n b = ____(21, 11, b + (d ^ (c | ~a)) + m01 - 2054922799) + c;\n a = ____(6, 26, a + (c ^ (b | ~d)) + m08 + 1873313359) + b;\n d = ____(10, 22, d + (b ^ (a | ~c)) + m15 - 30611744) + a;\n c = ____(15, 17, c + (a ^ (d | ~b)) + m06 - 1560198380) + d;\n b = ____(21, 11, b + (d ^ (c | ~a)) + m13 + 1309151649) + c;\n a = ____(6, 26, a + (c ^ (b | ~d)) + m04 - 145523070) + b;\n d = ____(10, 22, d + (b ^ (a | ~c)) + m11 - 1120210379) + a;\n c = ____(15, 17, c + (a ^ (d | ~b)) + m02 + 718787259) + d;\n b = ____(21, 11, b + (d ^ (c | ~a)) + m09 - 343485551) + c;\n\n a = (a + aa) >>> 0;\n b = (b + bb) >>> 0;\n c = (c + cc) >>> 0;\n d = (d + dd) >>> 0;\n }\n\n // console.log(\"md5JS, elapsed=\"+((new Date().getTime())-qwerty));\n\n return crypt.endian([a, b, c, d]);\n\n function ____(s, t, n) {\n return (n << s) | (n >>> t);\n }\n };\n\n return function (message, options) {\n var digestbytes = crypt.wordsToBytes(md5JS(message, options)),\n result =\n options && options.asBytes ? digestbytes : crypt.bytesconvertNumberToHex(digestbytes);\n return result;\n };\n}\nfunction str2AB(str) {\n var l,\n buff,\n buffView,\n i = -1;\n l = str.length - 1;\n buff = new ArrayBuffer(str.length);\n buffView = new Uint8Array(buff);\n while (l > i++) {\n buffView[i] = str.charCodeAt(i);\n }\n return buffView;\n}\nfunction nodeATOB(str) {\n return Buffer.from(str, 'base64').toString('binary');\n}\nfunction identity(x) {\n return x;\n}\n\nfunction makeCrypt() {\n var base64map = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/';\n\n return {\n rotl: function (n, b) {\n return (n << b) | (n >>> (32 - b));\n },\n\n endian: function (n) {\n if (n.constructor == Number) {\n return (crypt.rotl(n, 8) & 0x00ff00ff) | (crypt.rotl(n, 24) & 0xff00ff00);\n }\n for (var i = 0; i < n.length; i++) n[i] = crypt.endian(n[i]);\n return n;\n },\n\n bytesToWords: function (bytes) {\n for (var words = [], i = 0, b = 0; i < bytes.length; i++, b += 8)\n words[b >>> 5] |= bytes[i] << (24 - (b % 32));\n return words;\n },\n\n wordsToBytes: function (words) {\n for (var bytes = [], b = 0; b < words.length * 32; b += 8)\n bytes.push((words[b >>> 5] >>> (24 - (b % 32))) & 0xff);\n return bytes;\n },\n\n bytesconvertNumberToHex: function (bytes) {\n for (var hex = [], i = 0; i < bytes.length; i++) {\n hex.push((bytes[i] >>> 4).toString(16));\n hex.push((bytes[i] & 0xf).toString(16));\n }\n return hex.join('');\n }\n };\n}\n", "// Fork of https://github.com/briantbutton/md5-wasm under MIT license\nimport {Hash} from './hash';\nimport md5WASM from './algorithms/md5-wasm';\nimport {encodeHex} from './utils/digest-utils';\n\n/**\n * A transform that calculates MD5 hashes, passing data through\n */\nexport class MD5Hash extends Hash {\n readonly name = 'md5';\n readonly options;\n\n constructor(options = {}) {\n super();\n this.options = options;\n }\n\n /**\n * Atomic hash calculation\n * @returns base64 encoded hash\n */\n async hash(input: ArrayBuffer, encoding: 'hex' | 'base64'): Promise<string> {\n const md5Promise = new Promise<string>((resolve, reject) =>\n // @ts-expect-error\n md5WASM(input).then(resolve).catch(reject)\n );\n const hex = await md5Promise;\n return encodeHex(hex, encoding);\n }\n}\n", "// This dependency is too big, application must provide it\nimport type * as CryptoJSNamespace from 'crypto-js';\nimport {Hash} from './hash';\n\ntype CryptoHashOptions = {\n modules: {[moduleName: string]: any};\n crypto: {\n algorithm: string;\n onEnd?: (result: {hash: string}) => any;\n };\n};\n\nlet CryptoJS: typeof CryptoJSNamespace;\n\n/**\n * A transform that calculates Cryptographic Hash using Crypto JS library\n * @deprecated Warning, experimental class\n */\nexport class CryptoHash extends Hash {\n readonly name;\n\n options: CryptoHashOptions;\n private _algorithm;\n private _hash;\n\n constructor(options: CryptoHashOptions) {\n super();\n this.options = options;\n this._algorithm = this.options?.crypto?.algorithm;\n if (!this._algorithm) {\n throw new Error(this.name);\n }\n this.name = this._algorithm.toLowerCase();\n }\n\n async preload(): Promise<void> {\n if (!CryptoJS) {\n CryptoJS = this.options?.modules?.CryptoJS;\n if (!CryptoJS) {\n throw new Error(this.name);\n }\n }\n if (!this._hash) {\n const algo = CryptoJS.algo[this._algorithm];\n this._hash = algo.create();\n }\n if (!this._hash) {\n throw new Error(this.name);\n }\n }\n\n /**\n * Atomic hash calculation\n * @returns base64 encoded hash\n */\n async hash(input: ArrayBuffer, encoding: 'hex' | 'base64'): Promise<string> {\n await this.preload();\n // arrayBuffer is accepted, even though types and docs say no\n // https://stackoverflow.com/questions/25567468/how-to-decrypt-an-arraybuffer\n // @ts-expect-error\n const typedWordArray = CryptoJS.lib.WordArray.create(input);\n // Map our encoding constant to Crypto library\n const enc = encoding === 'base64' ? CryptoJS.enc.Base64 : CryptoJS.enc.Hex;\n return this._hash.update(typedWordArray).finalize().toString(enc);\n }\n\n async *hashBatches(\n asyncIterator: AsyncIterable<ArrayBuffer> | Iterable<ArrayBuffer>,\n encoding: 'hex' | 'base64' = 'base64'\n ): AsyncIterable<ArrayBuffer> {\n await this.preload();\n for await (const chunk of asyncIterator) {\n // arrayBuffer is accepted, even though types and docs say no\n // https://stackoverflow.com/questions/25567468/how-to-decrypt-an-arraybuffer\n // @ts-expect-error\n const typedWordArray = CryptoJS.lib.WordArray.create(chunk);\n this._hash.update(typedWordArray);\n yield chunk;\n }\n // Map our encoding constant to Crypto library\n const enc = encoding === 'base64' ? CryptoJS.enc.Base64 : CryptoJS.enc.Hex;\n const digest = this._hash.finalize().toString(enc);\n this.options?.crypto?.onEnd?.({hash: digest});\n }\n}\n", "//\nimport {CryptoHash} from './crypto-hash';\n\ntype CryptoHashOptions = {\n modules: {[moduleName: string]: any};\n crypto?: {\n onEnd?: (result: {hash: string}) => any;\n };\n};\n\n/**\n * A transform that calculates Cryptographic Hash\n */\nexport class SHA256Hash extends CryptoHash {\n constructor(options: CryptoHashOptions) {\n super({...options, crypto: {...options.crypto, algorithm: 'SHA256'}});\n }\n}\n", "", "// This dependency is too big, application must provide it\nimport {Hash} from './hash';\nimport {createHash} from 'crypto'; // Node.js builtin\n\ntype CryptoHashOptions = {\n crypto: {\n algorithm: string;\n onEnd?: (result: {hash: string}) => any;\n };\n};\n\n/**\n * Calculates Cryptographic Hash using Node.js crypto library\n * @deprecated Warning, experimental class\n */\nexport class NodeHash extends Hash {\n readonly name = 'crypto-node';\n\n options: CryptoHashOptions;\n // @ts-ignore\n private _algorithm;\n // @ts-ignore\n private _hash;\n\n constructor(options: CryptoHashOptions) {\n super();\n this.options = options;\n if (!this.options?.crypto?.algorithm) {\n throw new Error(this.name);\n }\n }\n\n /**\n * Atomic hash calculation\n * @returns base64 encoded hash\n */\n async hash(input: ArrayBuffer, encoding: 'hex' | 'base64'): Promise<string> {\n await this.preload();\n const algorithm = this.options?.crypto?.algorithm?.toLowerCase();\n try {\n const hash = createHash(algorithm);\n const inputArray = new Uint8Array(input);\n return hash.update(inputArray).digest('base64');\n } catch (error) {\n throw Error(`${algorithm} hash not available. ${error}`);\n }\n }\n\n async *hashBatches(\n asyncIterator: AsyncIterable<ArrayBuffer> | Iterable<ArrayBuffer>,\n encoding: 'hex' | 'base64' = 'base64'\n ): AsyncIterable<ArrayBuffer> {\n await this.preload();\n const hash = createHash(this.options?.crypto?.algorithm?.toLowerCase());\n for await (const chunk of asyncIterator) {\n // https://stackoverflow.com/questions/25567468/how-to-decrypt-an-arraybuffer\n const inputArray = new Uint8Array(chunk);\n hash.update(inputArray);\n yield chunk;\n }\n // We can pass our encoding constant directly to Node.js digest as it already supports `hex` and `base64`\n const digest = hash.digest(encoding);\n this.options?.crypto?.onEnd?.({hash: digest});\n }\n}\n", "// loaders.gl, MIT license\n\n// __VERSION__ is injected by babel-plugin-version-inline\n// @ts-ignore TS2304: Cannot find name '__VERSION__'.\nconst VERSION = typeof __VERSION__ !== 'undefined' ? __VERSION__ : 'latest';\n\nexport {CRC32Hash} from './lib/crc32-hash';\nexport {CRC32CHash} from './lib/crc32c-hash';\nexport {MD5Hash} from './lib/md5-hash';\nexport {SHA256Hash} from './lib/sha256-hash';\n\nexport {CryptoHash} from './lib/crypto-hash';\nexport {NodeHash} from './lib/node-hash';\n\n/**\n * Small, fast worker for CRC32, CRC32c and MD5 Hashes\n */\nexport const CryptoWorker = {\n id: 'crypto',\n name: 'CRC32, CRC32c and MD5 Hashes',\n module: 'crypto',\n version: VERSION,\n options: {\n crypto: {}\n }\n};\n\n/**\n * Large worker for full complement of Cryptographic Hashes\n * bundles the full crypto.js library\n */\nexport const CryptoJSWorker = {\n id: 'cryptojs',\n name: 'Cryptographic Hashes',\n module: 'crypto',\n version: VERSION,\n options: {\n cryptojs: {}\n }\n};\n\n// EXPERIMENTAL\n\nexport {encodeNumber, encodeHex, encodeBase64} from './lib/utils/digest-utils';\nexport {asciiToBase64, base64ToAscii} from './lib/utils/base64-utils';\n", "// @ts-nocheck\nconst moduleExports = require('./index');\nglobalThis.loaders = globalThis.loaders || {};\nmodule.exports = Object.assign(globalThis.loaders, moduleExports);\n"],
5
- "mappings": "+OA+BO,eAAoC,EAAoD,CAE7F,GAAM,GAAe,EAAQ,IAAI,AAAC,GAChC,YAAmB,aAAc,GAAI,YAAW,GAAW,GAIvD,EAAa,EAAa,OAAO,CAAC,EAAQ,IAAe,EAAS,EAAW,WAAY,GAGzF,EAAS,GAAI,YAAW,GAG1B,EAAS,EACb,OAAW,KAAe,GACxB,EAAO,IAAI,EAAa,GACxB,GAAU,EAAY,WAIxB,MAAO,GAAO,OAnDhB,iBCsCA,kBACE,EACsB,CACtB,GAAM,GAA8B,GACpC,aAAiB,KAAS,GACxB,EAAa,KAAK,GAEpB,MAAO,IAAwB,GAAG,GA7CpC,qBCAA,cAoFA,OCpFA,GAWO,GAXP,SACA,KAUO,OAAoB,CAIzB,YAAY,EAAuB,GAAI,CACrC,KAAK,YAAc,KAAK,YAAY,KAAK,WAGrC,UAAyB,QAMxB,YACL,EACA,EAA6B,SACD,CAC5B,GAAM,GAA8B,GACpC,aAAiB,KAAe,GAC9B,EAAa,KAAK,GAClB,KAAM,GAER,GAAM,GAAS,KAAM,MAAK,YAAY,GAChC,EAAO,KAAM,MAAK,KAAK,EAAQ,GACrC,KAAK,QAAQ,QAAQ,QAAQ,CAAC,cAKhB,aAAY,EAAqC,CAC/D,MAAO,MAAM,IAA6B,OCsP9C,aAAyB,CACvB,MAAO,IAjST,GAKA,IAwBM,GA7BN,UAKA,QAA2B,CAGzB,aAAc,CACZ,KAAK,IAAM,CAAC,EAGd,OAAO,EAAa,CAClB,GAAM,GAAc,KACd,EAAY,GAAI,YAAW,GACjC,OAAS,GAAI,EAAG,EAAI,EAAU,WAAY,IACxC,KAAK,IAAO,KAAK,MAAQ,EAAK,EAAa,MAAK,IAAM,EAAU,IAAM,KAGxE,MAAO,MAGT,UAAW,CACT,YAAK,IAAM,KAAK,IAAI,KAAK,IAAM,IACxB,KAAK,MAKV,GAAW,YAAY,GAC3B,EACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,WACA,SACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,WACA,SACA,WACA,WACA,WACA,SACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,WACA,SACA,WACA,WACA,WACA,SACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,SACA,W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ACA,WACA,WACA,WACA,WACA,WACA,UACA,WACA,WACA,UACA,WACA,SACA,UACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,UACA,UACA,WACA,UACA,WACA,WACA,UACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,UACA,UACA,WACA,UACA,WACA,WACA,UACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,UACA,UACA,WACA,UACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,UACA,UACA,WACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,UACA,WACA,WACA,UACA,WACA,WACA,UACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,UACA,WACA,WACA,UACA,WACA,UACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,UACA,WACA,WACA,WACA,WACA,UACA,UACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,UACA,WACA,WACA,UACA,WACA,UACA,UACA,WACA,WACA,UACA,UACA,WACA,SACA,WACA,WACA,UACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,UACA,UACA,WACA,UACA,WACA,WACA,UACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,UACA,SACA,WACA,UACA,WACA,WACA,UACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,SACA,UACA,WACA,UACA,WACA,WACA,UACA,WACA,WACA,WACA,WACA,WACA,WACA,WACA,cCxSF,GAQO,IARP,UACA,IACA,KACA,IAKO,gBAAyB,EAAK,CAUnC,YAAY,EAAU,GAAI,CACxB,QAVO,UAAO,SAWd,KAAK,QAAU,CAAC,OAAQ,MAAO,GAC/B,KAAK,MAAQ,GAAI,IAAO,QAOpB,MAAK,EAAoB,EAA6C,CAC1E,MAAO,M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ACN,OAAQ,SACR,QAAS,GACT,QAAS,CACP,OAAQ,KAQC,GAAiB,CAC5B,GAAI,WACJ,KAAM,uBACN,OAAQ,SACR,QAAS,GACT,QAAS,CACP,SAAU,OCrCd,oBACA,GAAM,IAAgB,UACtB,WAAW,QAAU,WAAW,SAAW,GAC3C,GAAO,QAAU,OAAO,OAAO,WAAW,QAAS",
6
- "names": []
7
- }
@@ -1,6 +0,0 @@
1
- "use strict";
2
-
3
- var moduleExports = require('./index');
4
- globalThis.loaders = globalThis.loaders || {};
5
- module.exports = Object.assign(globalThis.loaders, moduleExports);
6
- //# sourceMappingURL=bundle.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"bundle.js","names":["moduleExports","require","globalThis","loaders","module","exports","Object","assign"],"sources":["../../src/bundle.ts"],"sourcesContent":["// @ts-nocheck\nconst moduleExports = require('./index');\nglobalThis.loaders = globalThis.loaders || {};\nmodule.exports = Object.assign(globalThis.loaders, moduleExports);\n"],"mappings":";;AACA,IAAMA,aAAa,GAAGC,OAAO,CAAC,SAAS,CAAC;AACxCC,UAAU,CAACC,OAAO,GAAGD,UAAU,CAACC,OAAO,IAAI,CAAC,CAAC;AAC7CC,MAAM,CAACC,OAAO,GAAGC,MAAM,CAACC,MAAM,CAACL,UAAU,CAACC,OAAO,EAAEH,aAAa,CAAC"}
package/dist/es5/index.js DELETED
@@ -1,102 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- Object.defineProperty(exports, "CRC32CHash", {
7
- enumerable: true,
8
- get: function get() {
9
- return _crc32cHash.CRC32CHash;
10
- }
11
- });
12
- Object.defineProperty(exports, "CRC32Hash", {
13
- enumerable: true,
14
- get: function get() {
15
- return _crc32Hash.CRC32Hash;
16
- }
17
- });
18
- Object.defineProperty(exports, "CryptoHash", {
19
- enumerable: true,
20
- get: function get() {
21
- return _cryptoHash.CryptoHash;
22
- }
23
- });
24
- exports.CryptoWorker = exports.CryptoJSWorker = void 0;
25
- Object.defineProperty(exports, "MD5Hash", {
26
- enumerable: true,
27
- get: function get() {
28
- return _md5Hash.MD5Hash;
29
- }
30
- });
31
- Object.defineProperty(exports, "NodeHash", {
32
- enumerable: true,
33
- get: function get() {
34
- return _nodeHash.NodeHash;
35
- }
36
- });
37
- Object.defineProperty(exports, "SHA256Hash", {
38
- enumerable: true,
39
- get: function get() {
40
- return _sha256Hash.SHA256Hash;
41
- }
42
- });
43
- Object.defineProperty(exports, "asciiToBase64", {
44
- enumerable: true,
45
- get: function get() {
46
- return _base64Utils.asciiToBase64;
47
- }
48
- });
49
- Object.defineProperty(exports, "base64ToAscii", {
50
- enumerable: true,
51
- get: function get() {
52
- return _base64Utils.base64ToAscii;
53
- }
54
- });
55
- Object.defineProperty(exports, "encodeBase64", {
56
- enumerable: true,
57
- get: function get() {
58
- return _digestUtils.encodeBase64;
59
- }
60
- });
61
- Object.defineProperty(exports, "encodeHex", {
62
- enumerable: true,
63
- get: function get() {
64
- return _digestUtils.encodeHex;
65
- }
66
- });
67
- Object.defineProperty(exports, "encodeNumber", {
68
- enumerable: true,
69
- get: function get() {
70
- return _digestUtils.encodeNumber;
71
- }
72
- });
73
- var _crc32Hash = require("./lib/crc32-hash");
74
- var _crc32cHash = require("./lib/crc32c-hash");
75
- var _md5Hash = require("./lib/md5-hash");
76
- var _sha256Hash = require("./lib/sha256-hash");
77
- var _cryptoHash = require("./lib/crypto-hash");
78
- var _nodeHash = require("./lib/node-hash");
79
- var _digestUtils = require("./lib/utils/digest-utils");
80
- var _base64Utils = require("./lib/utils/base64-utils");
81
- var VERSION = typeof "4.0.0-beta.2" !== 'undefined' ? "4.0.0-beta.2" : 'latest';
82
- var CryptoWorker = {
83
- id: 'crypto',
84
- name: 'CRC32, CRC32c and MD5 Hashes',
85
- module: 'crypto',
86
- version: VERSION,
87
- options: {
88
- crypto: {}
89
- }
90
- };
91
- exports.CryptoWorker = CryptoWorker;
92
- var CryptoJSWorker = {
93
- id: 'cryptojs',
94
- name: 'Cryptographic Hashes',
95
- module: 'crypto',
96
- version: VERSION,
97
- options: {
98
- cryptojs: {}
99
- }
100
- };
101
- exports.CryptoJSWorker = CryptoJSWorker;
102
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","names":["_crc32Hash","require","_crc32cHash","_md5Hash","_sha256Hash","_cryptoHash","_nodeHash","_digestUtils","_base64Utils","VERSION","CryptoWorker","id","name","module","version","options","crypto","exports","CryptoJSWorker","cryptojs"],"sources":["../../src/index.ts"],"sourcesContent":["// loaders.gl, MIT license\n\n// __VERSION__ is injected by babel-plugin-version-inline\n// @ts-ignore TS2304: Cannot find name '__VERSION__'.\nconst VERSION = typeof __VERSION__ !== 'undefined' ? __VERSION__ : 'latest';\n\nexport {CRC32Hash} from './lib/crc32-hash';\nexport {CRC32CHash} from './lib/crc32c-hash';\nexport {MD5Hash} from './lib/md5-hash';\nexport {SHA256Hash} from './lib/sha256-hash';\n\nexport {CryptoHash} from './lib/crypto-hash';\nexport {NodeHash} from './lib/node-hash';\n\n/**\n * Small, fast worker for CRC32, CRC32c and MD5 Hashes\n */\nexport const CryptoWorker = {\n id: 'crypto',\n name: 'CRC32, CRC32c and MD5 Hashes',\n module: 'crypto',\n version: VERSION,\n options: {\n crypto: {}\n }\n};\n\n/**\n * Large worker for full complement of Cryptographic Hashes\n * bundles the full crypto.js library\n */\nexport const CryptoJSWorker = {\n id: 'cryptojs',\n name: 'Cryptographic Hashes',\n module: 'crypto',\n version: VERSION,\n options: {\n cryptojs: {}\n }\n};\n\n// EXPERIMENTAL\n\nexport {encodeNumber, encodeHex, encodeBase64} from './lib/utils/digest-utils';\nexport {asciiToBase64, base64ToAscii} from './lib/utils/base64-utils';\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAMA,IAAAA,UAAA,GAAAC,OAAA;AACA,IAAAC,WAAA,GAAAD,OAAA;AACA,IAAAE,QAAA,GAAAF,OAAA;AACA,IAAAG,WAAA,GAAAH,OAAA;AAEA,IAAAI,WAAA,GAAAJ,OAAA;AACA,IAAAK,SAAA,GAAAL,OAAA;AA+BA,IAAAM,YAAA,GAAAN,OAAA;AACA,IAAAO,YAAA,GAAAP,OAAA;AAxCA,IAAMQ,OAAO,GAAG,qBAAkB,KAAK,WAAW,oBAAiB,QAAQ;AAapE,IAAMC,YAAY,GAAG;EAC1BC,EAAE,EAAE,QAAQ;EACZC,IAAI,EAAE,8BAA8B;EACpCC,MAAM,EAAE,QAAQ;EAChBC,OAAO,EAAEL,OAAO;EAChBM,OAAO,EAAE;IACPC,MAAM,EAAE,CAAC;EACX;AACF,CAAC;AAACC,OAAA,CAAAP,YAAA,GAAAA,YAAA;AAMK,IAAMQ,cAAc,GAAG;EAC5BP,EAAE,EAAE,UAAU;EACdC,IAAI,EAAE,sBAAsB;EAC5BC,MAAM,EAAE,QAAQ;EAChBC,OAAO,EAAEL,OAAO;EAChBM,OAAO,EAAE;IACPI,QAAQ,EAAE,CAAC;EACb;AACF,CAAC;AAACF,OAAA,CAAAC,cAAA,GAAAA,cAAA"}
@@ -1,41 +0,0 @@
1
- "use strict";
2
-
3
- var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
4
- Object.defineProperty(exports, "__esModule", {
5
- value: true
6
- });
7
- exports.default = void 0;
8
- var _classCallCheck2 = _interopRequireDefault(require("@babel/runtime/helpers/classCallCheck"));
9
- var _createClass2 = _interopRequireDefault(require("@babel/runtime/helpers/createClass"));
10
- var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
11
- var CRC32 = function () {
12
- function CRC32() {
13
- (0, _classCallCheck2.default)(this, CRC32);
14
- (0, _defineProperty2.default)(this, "crc", void 0);
15
- this.crc = ~0;
16
- }
17
- (0, _createClass2.default)(CRC32, [{
18
- key: "update",
19
- value: function update(arrayBuffer) {
20
- var CRC32_TABLE = getCRC32Table();
21
- var byteArray = new Uint8Array(arrayBuffer);
22
- for (var i = 0; i < byteArray.byteLength; i++) {
23
- this.crc = this.crc >>> 8 ^ CRC32_TABLE[(this.crc ^ byteArray[i]) & 0xff];
24
- }
25
- return this;
26
- }
27
- }, {
28
- key: "finalize",
29
- value: function finalize() {
30
- this.crc = Math.abs(this.crc ^ -1);
31
- return this.crc;
32
- }
33
- }]);
34
- return CRC32;
35
- }();
36
- exports.default = CRC32;
37
- var CRC32TAB = Uint32Array.of(0x00000000, 0x77073096, 0xee0e612c, 0x990951ba, 0x076dc419, 0x706af48f, 0xe963a535, 0x9e6495a3, 0x0edb8832, 0x79dcb8a4, 0xe0d5e91e, 0x97d2d988, 0x09b64c2b, 0x7eb17cbd, 0xe7b82d07, 0x90bf1d91, 0x1db71064, 0x6ab020f2, 0xf3b97148, 0x84be41de, 0x1adad47d, 0x6ddde4eb, 0xf4d4b551, 0x83d385c7, 0x136c9856, 0x646ba8c0, 0xfd62f97a, 0x8a65c9ec, 0x14015c4f, 0x63066cd9, 0xfa0f3d63, 0x8d080df5, 0x3b6e20c8, 0x4c69105e, 0xd56041e4, 0xa2677172, 0x3c03e4d1, 0x4b04d447, 0xd20d85fd, 0xa50ab56b, 0x35b5a8fa, 0x42b2986c, 0xdbbbc9d6, 0xacbcf940, 0x32d86ce3, 0x45df5c75, 0xdcd60dcf, 0xabd13d59, 0x26d930ac, 0x51de003a, 0xc8d75180, 0xbfd06116, 0x21b4f4b5, 0x56b3c423, 0xcfba9599, 0xb8bda50f, 0x2802b89e, 0x5f058808, 0xc60cd9b2, 0xb10be924, 0x2f6f7c87, 0x58684c11, 0xc1611dab, 0xb6662d3d, 0x76dc4190, 0x01db7106, 0x98d220bc, 0xefd5102a, 0x71b18589, 0x06b6b51f, 0x9fbfe4a5, 0xe8b8d433, 0x7807c9a2, 0x0f00f934, 0x9609a88e, 0xe10e9818, 0x7f6a0dbb, 0x086d3d2d, 0x91646c97, 0xe6635c01, 0x6b6b51f4, 0x1c6c6162, 0x856530d8, 0xf262004e, 0x6c0695ed, 0x1b01a57b, 0x8208f4c1, 0xf50fc457, 0x65b0d9c6, 0x12b7e950, 0x8bbeb8ea, 0xfcb9887c, 0x62dd1ddf, 0x15da2d49, 0x8cd37cf3, 0xfbd44c65, 0x4db26158, 0x3ab551ce, 0xa3bc0074, 0xd4bb30e2, 0x4adfa541, 0x3dd895d7, 0xa4d1c46d, 0xd3d6f4fb, 0x4369e96a, 0x346ed9fc, 0xad678846, 0xda60b8d0, 0x44042d73, 0x33031de5, 0xaa0a4c5f, 0xdd0d7cc9, 0x5005713c, 0x270241aa, 0xbe0b1010, 0xc90c2086, 0x5768b525, 0x206f85b3, 0xb966d409, 0xce61e49f, 0x5edef90e, 0x29d9c998, 0xb0d09822, 0xc7d7a8b4, 0x59b33d17, 0x2eb40d81, 0xb7bd5c3b, 0xc0ba6cad, 0xedb88320, 0x9abfb3b6, 0x03b6e20c, 0x74b1d29a, 0xead54739, 0x9dd277af, 0x04db2615, 0x73dc1683, 0xe3630b12, 0x94643b84, 0x0d6d6a3e, 0x7a6a5aa8, 0xe40ecf0b, 0x9309ff9d, 0x0a00ae27, 0x7d079eb1, 0xf00f9344, 0x8708a3d2, 0x1e01f268, 0x6906c2fe, 0xf762575d, 0x806567cb, 0x196c3671, 0x6e6b06e7, 0xfed41b76, 0x89d32be0, 0x10da7a5a, 0x67dd4acc, 0xf9b9df6f, 0x8ebeeff9, 0x17b7be43, 0x60b08ed5, 0xd6d6a3e8, 0xa1d1937e, 0x38d8c2c4, 0x4fdff252, 0xd1bb67f1, 0xa6bc5767, 0x3fb506dd, 0x48b2364b, 0xd80d2bda, 0xaf0a1b4c, 0x36034af6, 0x41047a60, 0xdf60efc3, 0xa867df55, 0x316e8eef, 0x4669be79, 0xcb61b38c, 0xbc66831a, 0x256fd2a0, 0x5268e236, 0xcc0c7795, 0xbb0b4703, 0x220216b9, 0x5505262f, 0xc5ba3bbe, 0xb2bd0b28, 0x2bb45a92, 0x5cb36a04, 0xc2d7ffa7, 0xb5d0cf31, 0x2cd99e8b, 0x5bdeae1d, 0x9b64c2b0, 0xec63f226, 0x756aa39c, 0x026d930a, 0x9c0906a9, 0xeb0e363f, 0x72076785, 0x05005713, 0x95bf4a82, 0xe2b87a14, 0x7bb12bae, 0x0cb61b38, 0x92d28e9b, 0xe5d5be0d, 0x7cdcefb7, 0x0bdbdf21, 0x86d3d2d4, 0xf1d4e242, 0x68ddb3f8, 0x1fda836e, 0x81be16cd, 0xf6b9265b, 0x6fb077e1, 0x18b74777, 0x88085ae6, 0xff0f6a70, 0x66063bca, 0x11010b5c, 0x8f659eff, 0xf862ae69, 0x616bffd3, 0x166ccf45, 0xa00ae278, 0xd70dd2ee, 0x4e048354, 0x3903b3c2, 0xa7672661, 0xd06016f7, 0x4969474d, 0x3e6e77db, 0xaed16a4a, 0xd9d65adc, 0x40df0b66, 0x37d83bf0, 0xa9bcae53, 0xdebb9ec5, 0x47b2cf7f, 0x30b5ffe9, 0xbdbdf21c, 0xcabac28a, 0x53b39330, 0x24b4a3a6, 0xbad03605, 0xcdd70693, 0x54de5729, 0x23d967bf, 0xb3667a2e, 0xc4614ab8, 0x5d681b02, 0x2a6f2b94, 0xb40bbe37, 0xc30c8ea1, 0x5a05df1b, 0x2d02ef8d);
38
- function getCRC32Table() {
39
- return CRC32TAB;
40
- }
41
- //# sourceMappingURL=crc32.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"crc32.js","names":["CRC32","_classCallCheck2","default","_defineProperty2","crc","_createClass2","key","value","update","arrayBuffer","CRC32_TABLE","getCRC32Table","byteArray","Uint8Array","i","byteLength","finalize","Math","abs","exports","CRC32TAB","Uint32Array","of"],"sources":["../../../../src/lib/algorithms/crc32.ts"],"sourcesContent":["// Inspired by https://gist.github.com/wqli78/1330293/6d85cc967f32cccfcbad94ae7d088a3dcfc14bd9\n\n/**\n * Calculates the CRC32 checksum of a string.\n */\nexport default class CRC32 {\n crc: number;\n\n constructor() {\n this.crc = ~0;\n }\n\n update(arrayBuffer) {\n const CRC32_TABLE = getCRC32Table();\n const byteArray = new Uint8Array(arrayBuffer);\n for (let i = 0; i < byteArray.byteLength; i++) {\n this.crc = (this.crc >>> 8) ^ CRC32_TABLE[(this.crc ^ byteArray[i]) & 0xff];\n // strings: crc = (crc >>> 8) ^ CRC32TAB[(crc ^ str.charCodeAt(i)) & 0xff];\n }\n return this;\n }\n\n finalize() {\n this.crc = Math.abs(this.crc ^ -1);\n return this.crc;\n }\n}\n\n// Note: Using a typed array here doubles the speed of the cipher\nconst CRC32TAB = Uint32Array.of(\n 0x00000000,\n 0x77073096,\n 0xee0e612c,\n 0x990951ba,\n 0x076dc419,\n 0x706af48f,\n 0xe963a535,\n 0x9e6495a3,\n 0x0edb8832,\n 0x79dcb8a4,\n 0xe0d5e91e,\n 0x97d2d988,\n 0x09b64c2b,\n 0x7eb17cbd,\n 0xe7b82d07,\n 0x90bf1d91,\n 0x1db71064,\n 0x6ab020f2,\n 0xf3b97148,\n 0x84be41de,\n 0x1adad47d,\n 0x6ddde4eb,\n 0xf4d4b551,\n 0x83d385c7,\n 0x136c9856,\n 0x646ba8c0,\n 0xfd62f97a,\n 0x8a65c9ec,\n 0x14015c4f,\n 0x63066cd9,\n 0xfa0f3d63,\n 0x8d080df5,\n 0x3b6e20c8,\n 0x4c69105e,\n 0xd56041e4,\n 0xa2677172,\n 0x3c03e4d1,\n 0x4b04d447,\n 0xd20d85fd,\n 0xa50ab56b,\n 0x35b5a8fa,\n 0x42b2986c,\n 0xdbbbc9d6,\n 0xacbcf940,\n 0x32d86ce3,\n 0x45df5c75,\n 0xdcd60dcf,\n 0xabd13d59,\n 0x26d930ac,\n 0x51de003a,\n 0xc8d75180,\n 0xbfd06116,\n 0x21b4f4b5,\n 0x56b3c423,\n 0xcfba9599,\n 0xb8bda50f,\n 0x2802b89e,\n 0x5f058808,\n 0xc60cd9b2,\n 0xb10be924,\n 0x2f6f7c87,\n 0x58684c11,\n 0xc1611dab,\n 0xb6662d3d,\n 0x76dc4190,\n 0x01db7106,\n 0x98d220bc,\n 0xefd5102a,\n 0x71b18589,\n 0x06b6b51f,\n 0x9fbfe4a5,\n 0xe8b8d433,\n 0x7807c9a2,\n 0x0f00f934,\n 0x9609a88e,\n 0xe10e9818,\n 0x7f6a0dbb,\n 0x086d3d2d,\n 0x91646c97,\n 0xe6635c01,\n 0x6b6b51f4,\n 0x1c6c6162,\n 0x856530d8,\n 0xf262004e,\n 0x6c0695ed,\n 0x1b01a57b,\n 0x8208f4c1,\n 0xf50fc457,\n 0x65b0d9c6,\n 0x12b7e950,\n 0x8bbeb8ea,\n 0xfcb9887c,\n 0x62dd1ddf,\n 0x15da2d49,\n 0x8cd37cf3,\n 0xfbd44c65,\n 0x4db26158,\n 0x3ab551ce,\n 0xa3bc0074,\n 0xd4bb30e2,\n 0x4adfa541,\n 0x3dd895d7,\n 0xa4d1c46d,\n 0xd3d6f4fb,\n 0x4369e96a,\n 0x346ed9fc,\n 0xad678846,\n 0xda60b8d0,\n 0x44042d73,\n 0x33031de5,\n 0xaa0a4c5f,\n 0xdd0d7cc9,\n 0x5005713c,\n 0x270241aa,\n 0xbe0b1010,\n 0xc90c2086,\n 0x5768b525,\n 0x206f85b3,\n 0xb966d409,\n 0xce61e49f,\n 0x5edef90e,\n 0x29d9c998,\n 0xb0d09822,\n 0xc7d7a8b4,\n 0x59b33d17,\n 0x2eb40d81,\n 0xb7bd5c3b,\n 0xc0ba6cad,\n 0xedb88320,\n 0x9abfb3b6,\n 0x03b6e20c,\n 0x74b1d29a,\n 0xead54739,\n 0x9dd277af,\n 0x04db2615,\n 0x73dc1683,\n 0xe3630b12,\n 0x94643b84,\n 0x0d6d6a3e,\n 0x7a6a5aa8,\n 0xe40ecf0b,\n 0x9309ff9d,\n 0x0a00ae27,\n 0x7d079eb1,\n 0xf00f9344,\n 0x8708a3d2,\n 0x1e01f268,\n 0x6906c2fe,\n 0xf762575d,\n 0x806567cb,\n 0x196c3671,\n 0x6e6b06e7,\n 0xfed41b76,\n 0x89d32be0,\n 0x10da7a5a,\n 0x67dd4acc,\n 0xf9b9df6f,\n 0x8ebeeff9,\n 0x17b7be43,\n 0x60b08ed5,\n 0xd6d6a3e8,\n 0xa1d1937e,\n 0x38d8c2c4,\n 0x4fdff252,\n 0xd1bb67f1,\n 0xa6bc5767,\n 0x3fb506dd,\n 0x48b2364b,\n 0xd80d2bda,\n 0xaf0a1b4c,\n 0x36034af6,\n 0x41047a60,\n 0xdf60efc3,\n 0xa867df55,\n 0x316e8eef,\n 0x4669be79,\n 0xcb61b38c,\n 0xbc66831a,\n 0x256fd2a0,\n 0x5268e236,\n 0xcc0c7795,\n 0xbb0b4703,\n 0x220216b9,\n 0x5505262f,\n 0xc5ba3bbe,\n 0xb2bd0b28,\n 0x2bb45a92,\n 0x5cb36a04,\n 0xc2d7ffa7,\n 0xb5d0cf31,\n 0x2cd99e8b,\n 0x5bdeae1d,\n 0x9b64c2b0,\n 0xec63f226,\n 0x756aa39c,\n 0x026d930a,\n 0x9c0906a9,\n 0xeb0e363f,\n 0x72076785,\n 0x05005713,\n 0x95bf4a82,\n 0xe2b87a14,\n 0x7bb12bae,\n 0x0cb61b38,\n 0x92d28e9b,\n 0xe5d5be0d,\n 0x7cdcefb7,\n 0x0bdbdf21,\n 0x86d3d2d4,\n 0xf1d4e242,\n 0x68ddb3f8,\n 0x1fda836e,\n 0x81be16cd,\n 0xf6b9265b,\n 0x6fb077e1,\n 0x18b74777,\n 0x88085ae6,\n 0xff0f6a70,\n 0x66063bca,\n 0x11010b5c,\n 0x8f659eff,\n 0xf862ae69,\n 0x616bffd3,\n 0x166ccf45,\n 0xa00ae278,\n 0xd70dd2ee,\n 0x4e048354,\n 0x3903b3c2,\n 0xa7672661,\n 0xd06016f7,\n 0x4969474d,\n 0x3e6e77db,\n 0xaed16a4a,\n 0xd9d65adc,\n 0x40df0b66,\n 0x37d83bf0,\n 0xa9bcae53,\n 0xdebb9ec5,\n 0x47b2cf7f,\n 0x30b5ffe9,\n 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GC,WAAW,CAACC,EAAE,CAC7B,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UAAU,EACV,UACF,CAAC;AAED,SAASX,aAAaA,CAAA,EAAG;EACvB,OAAOS,QAAQ;AACjB"}