@zip.js/zip.js 2.8.44 → 2.8.46
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +28 -2
- package/deno.json +32 -2
- package/dist/zip-core-external.js +199 -149
- package/dist/zip-core-external.min.js +1 -1
- package/dist/zip-core.js +196 -120
- package/dist/zip-core.min.js +1 -1
- package/dist/zip-fs-core-external.js +251 -157
- package/dist/zip-fs-core-external.min.js +1 -1
- package/dist/zip-fs-core.js +227 -126
- package/dist/zip-fs-core.min.js +1 -1
- package/dist/zip-fs-external.js +272 -1751
- package/dist/zip-fs-external.min.js +1 -1
- package/dist/zip-fs-native.js +273 -1726
- package/dist/zip-fs-native.min.js +1 -1
- package/dist/zip-fs.js +273 -1726
- package/dist/zip-fs.min.js +1 -1
- package/dist/zip-legacy.js +198 -122
- package/dist/zip-legacy.min.js +1 -1
- package/dist/zip-native.js +200 -124
- package/dist/zip-native.min.js +1 -1
- package/dist/zip-web-worker-native.js +1 -1
- package/dist/zip-web-worker.js +1 -1
- package/dist/zip.js +200 -124
- package/dist/zip.min.js +1 -1
- package/eslint.config.mjs +31 -2
- package/index-native.cjs +273 -1726
- package/index-native.min.js +1 -1
- package/index.cjs +273 -1726
- package/index.d.cts +140 -2
- package/index.d.ts +140 -2
- package/index.min.js +1 -1
- package/lib/core/codec-pool.js +3 -2
- package/lib/core/codec-worker.js +30 -14
- package/lib/core/configuration.js +20 -2
- package/lib/core/constants.js +4 -0
- package/lib/core/options.js +2 -0
- package/lib/core/streams/aes-crypto-stream.js +15 -18
- package/lib/core/streams/codec-stream.js +2 -2
- package/lib/core/streams/zip-entry-stream.js +13 -18
- package/lib/core/util/mime-type-data.js +3 -0
- package/lib/core/util/mime-type.js +23 -1596
- package/lib/core/web-worker-base.js +29 -2
- package/lib/core/web-worker-inline-native.js +1 -1
- package/lib/core/web-worker-inline-wasm.js +1 -1
- package/lib/core/web-worker-native.js +7 -9
- package/lib/core/web-worker-wasm.js +9 -12
- package/lib/core/zip-entry.js +8 -1
- package/lib/core/zip-fs.js +62 -5
- package/lib/core/zip-reader.js +45 -17
- package/lib/core/zip-writer.js +58 -44
- package/lib/{core/web-worker-inline-template.js → zip-core-custom.js} +13 -20
- package/lib/zip-core-external.js +2 -0
- package/lib/zip-fs-core-external.js +2 -0
- package/lib/zip-fs-external.js +2 -0
- package/lib/zip-mime-types.js +2 -0
- package/lib/zip-module-native.js +3 -3
- package/lib/zip-module-wasm-base.js +3 -3
- package/package.json +28 -4
- package/worker-message-property-names.js +1 -1
- package/lib/core/web-worker-inline-template-native.js +0 -48
- package/lib/core/zlib-streams-inline-template.js +0 -45
package/dist/zip-fs.js
CHANGED
|
@@ -71,6 +71,8 @@
|
|
|
71
71
|
const EXTRAFIELD_TYPE_USDZ = 0x1986;
|
|
72
72
|
const EXTRAFIELD_TYPE_INFOZIP = 0x7875;
|
|
73
73
|
const EXTRAFIELD_TYPE_UNIX = 0x7855;
|
|
74
|
+
const EXTRAFIELD_TYPE_UNIX_TYPE1 = 0x5855;
|
|
75
|
+
const EXTRAFIELD_TYPE_PKWARE_UNIX = 0x000d;
|
|
74
76
|
|
|
75
77
|
const BITFLAG_ENCRYPTED = 0b1;
|
|
76
78
|
const BITFLAG_LEVEL = 0b0110;
|
|
@@ -174,6 +176,7 @@
|
|
|
174
176
|
"baseURI",
|
|
175
177
|
"wasmURI",
|
|
176
178
|
"workerURI",
|
|
179
|
+
"createWorker",
|
|
177
180
|
"chunkSize",
|
|
178
181
|
"maxWorkers",
|
|
179
182
|
"terminateWorkerTimeout",
|
|
@@ -184,8 +187,8 @@
|
|
|
184
187
|
"transferStreams",
|
|
185
188
|
"CompressionStream",
|
|
186
189
|
"DecompressionStream",
|
|
187
|
-
"
|
|
188
|
-
"
|
|
190
|
+
"CompressionStreamFallback",
|
|
191
|
+
"DecompressionStreamFallback"
|
|
189
192
|
];
|
|
190
193
|
|
|
191
194
|
const config = { ...DEFAULT_CONFIGURATION };
|
|
@@ -199,6 +202,7 @@
|
|
|
199
202
|
}
|
|
200
203
|
|
|
201
204
|
function configure(configuration) {
|
|
205
|
+
configuration = normalizeConfiguration(configuration);
|
|
202
206
|
for (const propertyName of CONFIGURABLE_PROPERTY_NAMES) {
|
|
203
207
|
const propertyValue = configuration[propertyName];
|
|
204
208
|
if (propertyValue !== UNDEFINED_VALUE) {
|
|
@@ -207,7 +211,23 @@
|
|
|
207
211
|
}
|
|
208
212
|
}
|
|
209
213
|
|
|
214
|
+
function normalizeConfiguration(configuration) {
|
|
215
|
+
const { CompressionStreamZlib, DecompressionStreamZlib } = configuration;
|
|
216
|
+
if (CompressionStreamZlib === UNDEFINED_VALUE && DecompressionStreamZlib === UNDEFINED_VALUE) {
|
|
217
|
+
return configuration;
|
|
218
|
+
}
|
|
219
|
+
const normalizedConfiguration = Object.assign({}, configuration);
|
|
220
|
+
if (normalizedConfiguration.CompressionStreamFallback === UNDEFINED_VALUE) {
|
|
221
|
+
normalizedConfiguration.CompressionStreamFallback = CompressionStreamZlib;
|
|
222
|
+
}
|
|
223
|
+
if (normalizedConfiguration.DecompressionStreamFallback === UNDEFINED_VALUE) {
|
|
224
|
+
normalizedConfiguration.DecompressionStreamFallback = DecompressionStreamZlib;
|
|
225
|
+
}
|
|
226
|
+
return normalizedConfiguration;
|
|
227
|
+
}
|
|
228
|
+
|
|
210
229
|
function setDefaultConfiguration(configuration) {
|
|
230
|
+
configuration = normalizeConfiguration(configuration);
|
|
211
231
|
for (const propertyName of CONFIGURABLE_PROPERTY_NAMES) {
|
|
212
232
|
const propertyValue = configuration[propertyName];
|
|
213
233
|
if (propertyValue !== UNDEFINED_VALUE) {
|
|
@@ -224,7 +244,7 @@
|
|
|
224
244
|
Object.assign(config, DEFAULT_CONFIGURATION);
|
|
225
245
|
}
|
|
226
246
|
|
|
227
|
-
function t$1(t){const e='(t=>{"function"==typeof define&&define.amd?define(t):t()})(function(){"use strict";const{Array:t,Object:e,Number:n,Math:s,Error:r,Uint8Array:o,Uint16Array:c,Uint32Array:i,Int32Array:a,Map:f,DataView:l,Promise:u,TextEncoder:w,crypto:h,postMessage:p,TransformStream:d,ReadableStream:y,WritableStream:m,CompressionStream:g,DecompressionStream:S}=self,v=void 0,b="undefined",k="function",z=new o,C=[[],[],[],[],[],[],[],[]];for(let t=0;256>t;t++){let e=t;for(let t=0;8>t;t++)e=1&e?e>>>1^3988292384:e>>>1;C[0][t]=e}for(let t=0;256>t;t++)for(let e=1;8>e;e++){const n=C[e-1][t];C[e][t]=n>>>8^C[0][255&n]}const[A,I,x,M,P,B,D,R]=C;class U{constructor(t){this.o=t||-1}append(t){let e=0|this.o;const n=0|t.length;let s=0;if(n>=8&&t.buffer){const r=new l(t.buffer,t.byteOffset,n),o=n-8;for(;o>=s;s+=8){const t=e^r.getInt32(s,!0),n=r.getInt32(s+4,!0);e=R[255&t]^D[t>>>8&255]^B[t>>>16&255]^P[t>>>24&255]^M[255&n]^x[n>>>8&255]^I[n>>>16&255]^A[n>>>24&255]}}for(;n>s;s++)e=e>>>8^A[255&(e^t[s])];this.o=e}get(){return~this.o}}class W extends d{constructor(){let t;const e=new U;super({transform(t,n){e.append(t),n.enqueue(t)},flush(){const n=new o(4);new l(n.buffer).setUint32(0,e.get()),t.value=n}}),t=this}}function _(t,e){const n=new o(t.length+e.length);return n.set(t),n.set(e,t.length),n}function T(t){return new l(t.buffer,t.byteOffset,t.byteLength)}const V={concat(t,e){if(0===t.length||0===e.length)return t.concat(e);const n=t[t.length-1],s=V.l(n);return 32===s?t.concat(e):V.h(e,s,0|n,t.slice(0,t.length-1))},m(t){const e=t.length;if(0===e)return 0;const n=t[e-1];return 32*(e-1)+V.l(n)},S(t,e){if(32*t.length<e)return t;const n=(t=t.slice(0,s.ceil(e/32))).length;return e&=31,n>0&&e&&(t[n-1]=V.v(e,t[n-1]&2147483648>>e-1,1)),t},v:(t,e,n)=>32===t?e:(n?0|e:e<<32-t)+1099511627776*t,l:t=>s.round(t/1099511627776)||32,h(t,e,n,s){for(void 0===s&&(s=[]);e>=32;e-=32)s.push(n),n=0;if(0===e)return s.concat(t);for(let r=0;r<t.length;r++)s.push(n|t[r]>>>e),n=t[r]<<32-e;const r=t.length?t[t.length-1]:0,o=V.l(r);return s.push(V.v(e+o&31,e+o>32?n:s.pop(),1)),s}},K={bytes:{C(t){const e=V.m(t)/8,n=new o(e);let s;for(let r=0;e>r;r++)3&r||(s=t[r/4]),n[r]=s>>>24,s<<=8;return n},A(t){const e=[];let n,s=0;for(n=0;n<t.length;n++)s=s<<8|t[n],3&~n||(e.push(s),s=0);return 3&n&&e.push(V.v(8*(3&n),s)),e}}},E=class{constructor(t){const e=this;e.blockSize=512,e.I=[1732584193,4023233417,2562383102,271733878,3285377520],e.M=[1518500249,1859775393,2400959708,3395469782],t?(e.P=t.P.slice(0),e.B=t.B.slice(0),e.D=t.D):e.reset()}reset(){const t=this;return t.P=t.I.slice(0),t.B=[],t.D=0,t}update(t){const e=this;"string"==typeof t&&(t=K.R.A(t));const n=e.B=V.concat(e.B,t),s=e.D,o=e.D=s+V.m(t);if(o>9007199254740991)throw new r("Cannot hash more than 2^53 - 1 bits");const c=new i(n);let a=0;for(let t=e.blockSize+s-(e.blockSize+s&e.blockSize-1);o>=t;t+=e.blockSize)e.U(c.subarray(16*a,16*(a+1))),a+=1;return n.splice(0,16*a),e}W(){const t=this;let e=t.B;const n=t.P;e=V.concat(e,[V.v(1,1)]);for(let t=e.length+2;15&t;t++)e.push(0);for(e.push(s.floor(t.D/4294967296)),e.push(0|t.D);e.length;)t.U(e.splice(0,16));return t.reset(),n}_(t,e,n,s){return t>19?t>39?t>59?t>79?void 0:e^n^s:e&n|e&s|n&s:e^n^s:e&n|~e&s}T(t,e){return e<<t|e>>>32-t}U(e){const n=this,r=n.P,o=t(80);for(let t=0;16>t;t++)o[t]=e[t];let c=r[0],i=r[1],a=r[2],f=r[3],l=r[4];for(let t=0;79>=t;t++){16>t||(o[t]=n.T(1,o[t-3]^o[t-8]^o[t-14]^o[t-16]));const e=n.T(5,c)+n._(t,i,a,f)+l+o[t]+n.M[s.floor(t/20)]|0;l=f,f=a,a=n.T(30,i),i=c,c=e}r[0]=r[0]+c|0,r[1]=r[1]+i|0,r[2]=r[2]+a|0,r[3]=r[3]+f|0,r[4]=r[4]+l|0}},F={importKey:t=>new F.V(K.bytes.A(t)),K(t,e,n,s){if(n=n||1e4,0>s||0>n)throw new r("invalid params to pbkdf2");const o=1+(s>>5)<<2;let c,i,a,f,u;const w=new ArrayBuffer(o),h=new l(w);let p=0;const d=V;for(e=K.bytes.A(e),u=1;(o||1)>p;u++){for(c=i=t.encrypt(d.concat(e,[u])),a=1;n>a;a++)for(i=t.encrypt(i),f=0;f<i.length;f++)c[f]^=i[f];for(a=0;(o||1)>p&&a<c.length;a++)h.setInt32(p,c[a]),p+=4}return w.slice(0,s/8)},V:class{constructor(t){const e=this,n=e.F=E,s=[[],[]];e.L=[new n,new n];const r=e.L[0].blockSize/32;t.length>r&&(t=(new n).update(t).W());for(let e=0;r>e;e++)s[0][e]=909522486^t[e],s[1][e]=1549556828^t[e];e.L[0].update(s[0]),e.L[1].update(s[1]),e.O=new n(e.L[0])}reset(){const t=this;t.O=new t.F(t.L[0]),t.j=!1}update(t){this.j=!0,this.O.update(t)}digest(){const t=this,e=t.O.W(),n=new t.F(t.L[1]).update(e).W();return t.reset(),n}encrypt(t){if(this.j)throw new r("encrypt on already updated hmac called!");return this.update(t),this.digest(t)}}},L=typeof h!=b&&typeof h.getRandomValues==k,O="Invalid password",j="Invalid signature",H=j,Z="zipjs-abort-check-password";function N(t){if(L)return h.getRandomValues(t);throw new r("Crypto API not supported")}const q=16,G={name:"PBKDF2"},J=e.assign({hash:{name:"HMAC"}},G),Q=e.assign({iterations:1e3,hash:{name:"SHA-1"}},G),X=["deriveBits"],Y=[8,12,16],$=[16,24,32],tt=10,et=[0,0,0,0],nt=typeof h!=b,st=nt&&h.subtle,rt=nt&&typeof st!=b,ot=K.bytes,ct=class{constructor(t){const e=this;e.H=[[[],[],[],[],[]],[[],[],[],[],[]]],e.H[0][0][0]||e.Z();const n=e.H[0][4],s=e.H[1],o=t.length;let c,i,a,f=1;if(4!==o&&6!==o&&8!==o)throw new r("invalid aes key size");for(e.M=[i=t.slice(0),a=[]],c=o;4*o+28>c;c++){let t=i[c-1];(c%o===0||8===o&&c%o===4)&&(t=n[t>>>24]<<24^n[t>>16&255]<<16^n[t>>8&255]<<8^n[255&t],c%o===0&&(t=t<<8^t>>>24^f<<24,f=f<<1^283*(f>>7))),i[c]=i[c-o]^t}for(let t=0;c;t++,c--){const e=i[3&t?c:c-4];a[t]=4>=c||4>t?e:s[0][n[e>>>24]]^s[1][n[e>>16&255]]^s[2][n[e>>8&255]]^s[3][n[255&e]]}}encrypt(t){return this.N(t,0)}decrypt(t){return this.N(t,1)}Z(){const t=this.H[0],e=this.H[1],n=t[4],s=e[4],r=[],o=[];let c,i,a,f;for(let t=0;256>t;t++)o[(r[t]=t<<1^283*(t>>7))^t]=t;for(let l=c=0;!n[l];l^=i||1,c=o[c]||1){let o=c^c<<1^c<<2^c<<3^c<<4;o=o>>8^255&o^99,n[l]=o,s[o]=l,f=r[a=r[i=r[l]]];let u=16843009*f^65537*a^257*i^16843008*l,w=257*r[o]^16843008*o;for(let n=0;4>n;n++)t[n][l]=w=w<<24^w>>>8,e[n][o]=u=u<<24^u>>>8}for(let n=0;5>n;n++)t[n]=t[n].slice(0),e[n]=e[n].slice(0)}N(t,e){if(4!==t.length)throw new r("invalid aes block size");const n=this.M[e],s=n.length/4-2,o=[0,0,0,0],c=this.H[e],i=c[0],a=c[1],f=c[2],l=c[3],u=c[4];let w,h,p,d=t[0]^n[0],y=t[e?3:1]^n[1],m=t[2]^n[2],g=t[e?1:3]^n[3],S=4;for(let t=0;s>t;t++)w=i[d>>>24]^a[y>>16&255]^f[m>>8&255]^l[255&g]^n[S],h=i[y>>>24]^a[m>>16&255]^f[g>>8&255]^l[255&d]^n[S+1],p=i[m>>>24]^a[g>>16&255]^f[d>>8&255]^l[255&y]^n[S+2],g=i[g>>>24]^a[d>>16&255]^f[y>>8&255]^l[255&m]^n[S+3],S+=4,d=w,y=h,m=p;for(let t=0;4>t;t++)o[e?3&-t:t]=u[d>>>24]<<24^u[y>>16&255]<<16^u[m>>8&255]<<8^u[255&g]^n[S++],w=d,d=y,y=m,m=g,g=w;return o}},it=class{constructor(t,e){this.G=t,this.J=e,this.X=e}reset(){this.X=this.J}update(t){return this.Y(this.G,t,this.X)}$(t){if(255&~(t>>24))t+=1<<24;else{let e=t>>16&255,n=t>>8&255,s=255&t;255===e?(e=0,255===n?(n=0,255===s?s=0:++s):++n):++e,t=0,t+=e<<16,t+=n<<8,t+=s}return t}et(t){0===(t[0]=this.$(t[0]))&&(t[1]=this.$(t[1]))}Y(t,e,n){let s;if(!(s=e.length))return[];const r=V.m(e);for(let r=0;s>r;r+=4){this.et(n);const s=t.encrypt(n);e[r]^=s[0],e[r+1]^=s[1],e[r+2]^=s[2],e[r+3]^=s[3]}return V.S(e,r)}},at=F.V;let ft=nt&&rt&&typeof st.importKey==k,lt=nt&&rt&&typeof st.deriveBits==k;class ut extends d{constructor({password:t,rawPassword:e,encryptionStrength:n,checkPasswordOnly:s,checkAuthenticationCode:c=!0}){super({start(){ht(this,t,e,n)},async transform(t,e){const n=this,{password:c,strength:i,nt:a,ready:f}=n;c?(await(async(t,e,n,s)=>{const o=await dt(t,e,n,mt(s,0,Y[e])),c=mt(s,Y[e]);if(o[0]!=c[0]||o[1]!=c[1])throw new r(O)})(n,i,c,mt(t,0,Y[i]+2)),t=mt(t,Y[i]+2),s?e.error(new r(Z)):a()):await f;const l=new o(t.length-tt-(t.length-tt)%q);e.enqueue(pt(n,t,l,0,tt,!0))},async flush(t){const{st:e,ot:n,pending:s,ready:o}=this;if(n&&e){await o;const i=mt(s,0,s.length-tt),a=mt(s,s.length-tt);let f=z;if(i.length){const t=St(ot,i);n.update(t);const s=e.update(t);f=gt(ot,s)}const l=mt(gt(ot,n.digest()),0,tt);let u=s.length<tt?1:0;for(let t=0;tt>t;t++)u|=l[t]^a[t];if(u&&c)throw new r(H);t.enqueue(f)}}})}}class wt extends d{constructor({password:t,rawPassword:e,encryptionStrength:n}){let s;super({start(){ht(this,t,e,n)},async transform(t,e){const n=this,{password:s,strength:r,nt:c,ready:i}=n;let a=z;s?(a=await(async(t,e,n)=>{const s=N(new o(Y[e]));return _(s,await dt(t,e,n,s))})(n,r,s),c()):await i;const f=new o(a.length+t.length-t.length%q);f.set(a,0),e.enqueue(pt(n,t,f,a.length,0))},async flush(t){const{st:e,ot:n,pending:r,ready:o}=this;if(n&&e){await o;let c=z;if(r.length){const t=e.update(St(ot,r));n.update(t),c=gt(ot,t)}s.signature=gt(ot,n.digest()).slice(0,tt),t.enqueue(_(c,s.signature))}}}),s=this}}function ht(t,n,s,r){e.assign(t,{ready:new u(e=>t.nt=e),password:yt(n,s),strength:r-1,pending:z})}function pt(t,e,n,s,r,c){const{st:i,ot:a,pending:f}=t;f.length&&(e=_(f,e));const l=e.length-r;let u;for(n=((t,e)=>{if(e&&e>t.length){const n=t;(t=new o(e)).set(n,0)}return t})(n,s+(l-l%q)),u=0;l-q>=u;u+=q){const t=St(ot,mt(e,u,u+q));c&&a.update(t);const r=i.update(t);c||a.update(r),n.set(gt(ot,r),u+s)}return t.pending=mt(e,u),n}async function dt(n,s,r,c){n.password=null;const i=await(async(t,e,n,s,r)=>{if(!ft)return F.importKey(e);try{return await st.importKey("raw",e,n,!1,r)}catch{return ft=!1,F.importKey(e)}})(0,r,J,0,X),a=await(async(t,e,n)=>{if(!lt)return F.K(e,t.salt,Q.iterations,n);try{return await st.deriveBits(t,e,n)}catch{return lt=!1,F.K(e,t.salt,Q.iterations,n)}})(e.assign({salt:c},Q),i,8*(2*$[s]+2)),f=new o(a),l=St(ot,mt(f,0,$[s])),u=St(ot,mt(f,$[s],2*$[s])),w=mt(f,2*$[s]);return e.assign(n,{keys:{key:l,ct:u,passwordVerification:w},st:new it(new ct(l),t.from(et)),ot:new at(u)}),w}function yt(t,e){return e===v?(t=>{if(typeof w==b){const e=new o((t=unescape(encodeURIComponent(t))).length);for(let n=0;n<e.length;n++)e[n]=t.charCodeAt(n);return e}return(new w).encode(t)})(t):e}function mt(t,e,n){return t.subarray(e,n)}function gt(t,e){return t.C(e)}function St(t,e){return t.A(e)}class vt extends d{constructor({password:t,rawPassword:e,passwordVerification:n,checkPasswordOnly:s}){super({start(){kt(this,t,e,n)},transform(t,e){const n=this;if(n.password||n.rawPassword){const e=zt(n,t.subarray(0,12));if(n.password=n.rawPassword=null,0!=(e[11]^n.passwordVerification))throw new r(O);t=t.subarray(12)}s?e.error(new r(Z)):e.enqueue(zt(n,t))}})}}class bt extends d{constructor({password:t,rawPassword:e,passwordVerification:n}){super({start(){kt(this,t,e,n)},transform(t,e){const n=this;let s,r;if(n.password||n.rawPassword){n.password=n.rawPassword=null;const e=N(new o(12));e[11]=n.passwordVerification,s=new o(t.length+e.length),s.set(Ct(n,e),0),r=12}else s=new o(t.length),r=0;s.set(Ct(n,t),r),e.enqueue(s)}})}}function kt(t,n,s,r){e.assign(t,{password:n,rawPassword:s,passwordVerification:r}),((t,n,s)=>{const r=[305419896,591751049,878082192];if(e.assign(t,{keys:r,it:new U(r[0]),ft:new U(r[2])}),s)for(let e=0;e<s.length;e++)At(t,s[e]);else for(let e=0;e<n.length;e++)At(t,n.charCodeAt(e))})(t,n,s)}function zt(t,e){const n=new o(e.length);for(let s=0;s<e.length;s++)n[s]=It(t)^e[s],At(t,n[s]);return n}function Ct(t,e){const n=new o(e.length);for(let s=0;s<e.length;s++)n[s]=It(t)^e[s],At(t,e[s]);return n}function At(t,e){let[,n]=t.keys;t.it.append([e]);const r=~t.it.get();n=Mt(s.imul(Mt(n+xt(r)),134775813)+1),t.ft.append([n>>>24]);const o=~t.ft.get();t.keys=[r,n,o]}function It(t){const e=2|t.keys[2];return xt(s.imul(e,1^e)>>>8)}function xt(t){return 255&t}function Mt(t){return 4294967295&t}const Pt=new f;function Bt(t){return Pt.get(t)}const Dt="Invalid uncompressed size",Rt=j,Ut="deflate-raw",Wt="gzip",_t=[31,139,8];class Tt extends d{constructor(t,{chunkSize:e,CompressionStreamZlib:n,CompressionStream:s}){super({});const{compressed:r,encrypted:o,useCompressionStream:c,zipCrypto:i,computeCrc32:a,level:f,deflate64:u,format:w,compressionMethod:h}=t,p=this;let d,y,m,g=super.readable;const S=w&&Bt(w),v=a&&r&&!u&&!S&&(!o||i)&&!(!c||!s);if(o&&!i||!a||v||(d=new W,g=jt(g,d)),r)if(S)g=Ht(g,Lt(S.CompressionStream,w,{level:f,chunkSize:e,compressionMethod:h}));else if(v)m=new Vt,g=Ht(g,new s(Wt)),g=jt(g,m);else try{g=Ot(g,c,{level:f,chunkSize:e},s,n)}catch(t){let e;try{e=new s(Wt)}catch{throw t}g=Ht(g,e),g=jt(g,new Vt)}o&&(i?g=jt(g,new bt(t)):(y=new wt(t),g=jt(g,y))),Ft(p,g,()=>{let t;o&&!i&&(t=y.signature),o&&!i||!a||(t=v?m.signature:new l(d.value.buffer).getUint32(0)),p.signature=t})}}class Vt extends d{constructor(){let t,e=10,n=new o(0);super({transform(t,r){if(e){const n=s.min(e,t.length);if(e-=n,!(t=t.subarray(n)).length)return}const o=n.length+t.length;if(8>=o)return void(n=_(n,t));const c=o-8,i=s.min(c,n.length);r.enqueue(_(n.subarray(0,i),t.subarray(0,c-i))),n=_(n.subarray(i),t.subarray(c-i))},flush(){const e=T(n);t.signature=e.getUint32(0,!0),t.uncompressedSize=e.getUint32(4,!0)}}),t=this}}class Kt extends d{constructor(t,{chunkSize:e,DecompressionStreamZlib:n,DecompressionStream:s}){super({});const{zipCrypto:c,encrypted:i,checkCrc32:a,signature:f,compressed:w,useCompressionStream:h,deflate64:p,format:m,compressionMethod:g,rawBitFlag:S,outputSize:b}=t;let k,z,C=super.readable;if(i&&(c?C=jt(C,new vt(t)):(z=new ut(t),C=jt(C,z))),w){const t=m&&Bt(m);if(t)C=Ht(C,Lt(t.DecompressionStream,m,{chunkSize:e,compressionMethod:g,rawBitFlag:S,uncompressedSize:b}));else try{C=Ot(C,h,{chunkSize:e,deflate64:p},s,n)}catch(t){if(p||b===v)throw t;let e;try{e=new s(Wt)}catch{throw t}C=((t,e,n)=>{const s=new U;let c,i,a,f=0,l=!1;const w=new u((t,e)=>{i=t,a=e});w.catch(()=>{}),n||i();const h=new d({start(t){const e=new o(10);e.set(_t),t.enqueue(e)},transform(t,e){e.enqueue(t)},async flush(t){l=!0,y();try{await w}finally{m()}const e=new o(8),r=T(e);r.setUint32(0,s.get(),!0),r.setUint32(4,n,!0),t.enqueue(e)},cancel(t){a(t)}}),p=new d({transform(t,e){s.append(t),f+=t.length,n>f?l&&y():i(),e.enqueue(t)},cancel(t){a(t)}});return t=jt(t,h),jt(t=Ht(t,e),p);function y(){m(),c=setTimeout(()=>a(new r(Dt)),5e3)}function m(){clearTimeout(c)}})(C,e,b)}C=(t=>{const e=t.getReader();return new y({async pull(t){let n;try{n=await e.read()}catch(t){if(t&&t.message)throw t;const e=new r("Invalid compressed data");throw e.cause=t,e}const{value:s,done:o}=n;o?t.close():t.enqueue(s)},cancel:t=>e.cancel(t)})})(C)}a&&(k=new W,C=jt(C,k)),Ft(this,C,()=>{if(a){const t=new l(k.value.buffer);if(f!=t.getUint32(0,!1))throw new r(Rt)}})}}const Et=new f;function Ft(t,n,s){n=jt(n,new d({flush:s})),e.defineProperty(t,"readable",{get:()=>n})}function Lt(t,e,n){if(!t)throw new r("Compression method not supported");return new t(e,n)}function Ot(t,e,n,s,r){const o=e&&s?s:r||s,c=n.deflate64?"deflate64-raw":Ut;let i;try{i=new o(c,n)}catch(t){if(!e||!r||o==r)throw t;i=new r(c,n)}return Ht(t,i)}function jt(t,e){return(t=>{if(t instanceof y)return t;const e=t.getReader();return new y({async pull(t){const{value:n,done:s}=await e.read();s?t.close():t.enqueue(n)},cancel:t=>e.cancel(t)})})(t).pipeThrough(e)}function Ht(t,e){const n=e.writable.getWriter(),s=t.getReader();return(async()=>{try{for(;;){await n.ready;const t=await s.read();if(t.done){await n.close();break}await n.write(t.value)}}catch(t){await(async(t,e)=>{try{await t.abort(e)}catch{}})(n,t),await(async(t,e)=>{try{await t.cancel(e)}catch{}})(s,t)}})(),e.readable}const Zt="data",Nt="close",qt="deflate";class Gt extends d{constructor(t,n){super({});const s=this,{codecType:o}=t;let c;o.startsWith(qt)?c=Tt:o.startsWith("inflate")&&(c=Kt),s.outputSize=0;let i=0;const a=new c(t,n),f=super.readable,l=new d({transform(t,e){t&&t.length&&(i+=t.length,e.enqueue(t))},flush(){e.assign(s,{inputSize:i})}}),u=new d({transform(e,n){if(e&&e.length&&(n.enqueue(e),s.outputSize+=e.length,t.outputSize!==v&&s.outputSize>t.outputSize))throw new r(Dt)},flush(){const{signature:t}=a;e.assign(s,{signature:t,inputSize:i})}});e.defineProperty(s,"readable",{get:()=>f.pipeThrough(l).pipeThrough(a).pipeThrough(u)})}}class Jt extends d{constructor(t){const e=[];let s=0;function r(){const n=new o(t);let r=0;for(;t>r;){const s=e[0],o=t-r;s.length>o?(n.set(s.subarray(0,o),r),e[0]=s.subarray(o),r+=o):(n.set(s,r),r+=s.length,e.shift())}return s-=t,n}n.isFinite(t)&&t>=1||(t=65536),super({transform(n,o){for(e.push(n),s+=n.length;s>t;)o.enqueue(r())},flush(t){s&&t.enqueue(((t,e)=>{const n=new o(e);let s=0;for(const e of t)n.set(e,s),s+=e.length;return n})(e,s))}})}}let Qt=2;try{typeof navigator!=b&&navigator.hardwareConcurrency&&(Qt=navigator.hardwareConcurrency)}catch{}const Xt=new f,Yt=new f;let $t,te,ee,ne,se,re,oe=0;async function ce(t){let e,o;try{const{options:c,config:i}=t;if(c.format&&await(async(t,e)=>{!Pt.has(t)&&e&&((t,e)=>{const{CompressionStream:n,DecompressionStream:s}=e;if(typeof n!=k&&typeof s!=k)throw new r("Invalid codec module");Pt.set(t,{CompressionStream:n,DecompressionStream:s})})(t,await(import(e)))})(c.format,c.codecURI),i.CompressionStream=self.CompressionStream,i.DecompressionStream=self.DecompressionStream,c.compressed&&!c.format)if(c.useCompressionStream){if(!((t,e)=>{if(!t)return!1;let n=Et.get(t);n||(n=new f,Et.set(t,n));let s=n.get(e);if(s===v){try{new t(e),s=!0}catch{s=!1}n.set(e,s)}return s})(c.codecType.startsWith(qt)?i.CompressionStream:i.DecompressionStream,Ut))try{await self.initModule(t.config)}catch{}}else try{await self.initModule(t.config)}catch{c.useCompressionStream=!0}const a={highWaterMark:1},l=t.readable||new y({async pull(t){const e=new u(t=>Xt.set(oe,t));ie({type:"pull",messageId:oe}),oe=(oe+1)%n.MAX_SAFE_INTEGER;const{value:s,done:r}=await e;t.enqueue(s),r&&t.close()}},a);o=t.writable||new m({async write(t){let e;const s=new u(t=>e=t);Yt.set(oe,e),ie({type:Zt,value:t,messageId:oe}),oe=(oe+1)%n.MAX_SAFE_INTEGER,await s}},a),e=new Gt(c,i),$t=new AbortController;const{signal:w}=$t;await l.pipeThrough(e).pipeThrough(new Jt((t=>s.max(t.chunkSize,64))(i))).pipeTo(o,{signal:w,preventClose:!0,preventAbort:!0}),await o.getWriter().close();const{signature:h,inputSize:p,outputSize:d}=e;ie({type:Nt,result:{signature:h,inputSize:p,outputSize:d}})}catch(t){if(t.outputSize=e?e.outputSize:0,o&&!o.locked)try{await o.getWriter().close()}catch{}ae(t)}}function ie(t){const{value:e}=t;if(e)if(e.length)try{t.value=(n=e,n.byteOffset||n.byteLength!=n.buffer.byteLength?new o(n):n).buffer,p(t,[t.value])}catch{p(t)}else p(t);else p(t);var n}function ae(t=new r("Unknown error")){const{message:e,stack:n,code:s,name:o,outputSize:c,cause:i}=t,a={message:e,stack:n,code:s,name:o,outputSize:c};i&&(a.cause={name:i.name,message:i.message}),p({error:a})}function fe(t,e,n={}){if(!te){const t=new r("WASM module not loaded");throw t.cause=re,t}const c="number"==typeof n.level?n.level:-1,i="number"==typeof n.outBuffer?n.outBuffer:65536,a="number"==typeof n.inBufferSize?n.inBufferSize:65536;return new d({start(){try{let n;if(this.lt=ee(i),this.in=ee(a),this.inBufferSize=a,!this.lt||!this.in)throw new r("allocation failed");if(this.ut=new o(i),t?(this.wt=te.deflate_process,this.ht=te.deflate_last_consumed,this.yt=te.deflate_end,this.gt=te.deflate_new(),n="gzip"===e?te.deflate_init_gzip(this.gt,c):"deflate-raw"===e?te.deflate_init_raw(this.gt,c):te.deflate_init(this.gt,c)):"deflate64-raw"===e?(this.wt=te.inflate9_process,this.ht=te.inflate9_last_consumed,this.yt=te.inflate9_end,this.gt=te.inflate9_new(),n=te.inflate9_init_raw(this.gt)):(this.wt=te.inflate_process,this.ht=te.inflate_last_consumed,this.yt=te.inflate_end,this.gt=te.inflate_new(),n="deflate-raw"===e?te.inflate_init_raw(this.gt):"gzip"===e?te.inflate_init_gzip(this.gt):te.inflate_init(this.gt)),0!==n)throw new r("init failed:"+n)}catch(t){throw f(this),t}},transform(e,n){try{const c=e,a=new o(se.buffer),f=this.wt,l=this.ht,u=this.lt,w=this.ut;let h=0;for(;h<c.length;){const e=s.min(c.length-h,32768);if((!this.in||this.inBufferSize<e)&&(this.in&&ne&&(ne(this.in),this.in=0),this.in=ee(e),this.inBufferSize=e,!this.in))throw new r("allocation failed");a.set(c.subarray(h,h+e),this.in);const o=f(this.gt,this.in,e,u,i,0),p=16777215&o;if(p&&(w.set(a.subarray(u,u+p),0),n.enqueue(w.slice(0,p))),!t){const t=o>>24&255,e=128&t?t-256:t;if(0>e)throw new r("process error:"+e)}const d=l(this.gt);if(0===d)break;h+=d}}catch(t){f(this),n.error(t)}},flush(e){try{const n=new o(se.buffer),s=this.wt,c=this.lt,a=this.ut;for(;;){const o=s(this.gt,0,0,c,i,4),f=16777215&o,l=o>>24&255;if(!t){const t=128&l?l-256:l;if(0>t)throw new r("process error:"+t)}if(f&&(a.set(n.subarray(c,c+f),0),e.enqueue(a.slice(0,f))),1===l||0===f)break}}catch(t){e.error(t)}finally{const t=f(this);0!==t&&e.error(new r("end error:"+t))}},cancel(){f(this)}});function f(t){let e=0;return t.gt&&t.yt&&(e=t.yt(t.gt)),t.gt=0,t.in&&ne&&ne(t.in),t.in=0,t.lt&&ne&&ne(t.lt),t.lt=0,e}}addEventListener("message",({data:t})=>{const{type:e,messageId:n,value:s,done:r}=t;try{if("start"==e&&ce(t),e==Zt){const t=Xt.get(n);Xt.delete(n),t({value:s||new o,done:r})}if("ack"==e){const t=Yt.get(n);Yt.delete(n),t()}e==Nt&&$t.abort()}catch(t){ae(t)}}),p({type:"ready"});class le{constructor(t="deflate",e){return fe(!0,t,e)}}class ue{constructor(t="deflate",e){return fe(!1,t,e)}}le.St=!0,ue.St=!0;let we=!1;self.initModule=async t=>{const e=await(async(t,{baseURI:e})=>{if(!we)try{await(async(t,e)=>{let n,s;try{try{s=new URL(t,e)}catch{}const r=await fetch(s);n=await r.arrayBuffer()}catch(e){if(!t.startsWith("data:application/wasm;base64,"))throw e;n=(t=>{const e=t.split(",")[1],n=atob(e),s=n.length,r=new o(s);for(let t=0;s>t;++t)r[t]=n.charCodeAt(t);return r.buffer})(t)}(t=>{if(te=t,({malloc:ee,free:ne,memory:se}=te),"function"!=typeof ee||"function"!=typeof ne||!se)throw te=ee=ne=se=null,new r("Invalid WASM module")})((await WebAssembly.instantiate(n)).instance.exports)})(t,e),we=!0}catch(t){throw(t=>{re=t})(t),t}})(t.wasmURI,t);return t.CompressionStreamZlib=le,t.DecompressionStreamZlib=ue,e}});\n';t({workerURI:t=>{const n="text/javascript";if(t){const t=new Blob([e],{type:n});return URL.createObjectURL(t)}return "data:"+n+","+encodeURIComponent(e)}});}
|
|
247
|
+
const t$1=new Uint8Array(288);t$1.fill(8,0,144),t$1.fill(9,144,256),t$1.fill(7,256,280),t$1.fill(8,280,288),new Uint8Array(30).fill(5);const e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",n$1=t=>t({workerURI:t=>{const n="text/javascript";let s='(t=>{"function"==typeof define&&define.amd?define(t):t()})(function(){"use strict";const{Array:t,Object:e,Number:n,Math:s,Error:r,Uint8Array:o,Uint16Array:c,Uint32Array:i,Int32Array:a,Map:f,DataView:l,Promise:w,TextEncoder:u,crypto:h,postMessage:p,TransformStream:d,ReadableStream:y,WritableStream:m,CompressionStream:S,DecompressionStream:g}=self,v=void 0,b="undefined",k="function",z=new o,C=[[],[],[],[],[],[],[],[]];for(let t=0;256>t;t++){let e=t;for(let t=0;8>t;t++)e=1&e?e>>>1^3988292384:e>>>1;C[0][t]=e}for(let t=0;256>t;t++)for(let e=1;8>e;e++){const n=C[e-1][t];C[e][t]=n>>>8^C[0][255&n]}const[A,I,x,M,P,D,B,F]=C;class R{constructor(t){this.o=t||-1}append(t){let e=0|this.o;const n=0|t.length;let s=0;if(n>=8&&t.buffer){const r=new l(t.buffer,t.byteOffset,n),o=n-8;for(;o>=s;s+=8){const t=e^r.getInt32(s,!0),n=r.getInt32(s+4,!0);e=F[255&t]^B[t>>>8&255]^D[t>>>16&255]^P[t>>>24&255]^M[255&n]^x[n>>>8&255]^I[n>>>16&255]^A[n>>>24&255]}}for(;n>s;s++)e=e>>>8^A[255&(e^t[s])];this.o=e}get(){return~this.o}}class U extends d{constructor(){let t;const e=new R;super({transform(t,n){e.append(t),n.enqueue(t)},flush(){const n=new o(4);new l(n.buffer).setUint32(0,e.get()),t.value=n}}),t=this}}function W(t,e){const n=new o(t.length+e.length);return n.set(t),n.set(e,t.length),n}function _(t){return new l(t.buffer,t.byteOffset,t.byteLength)}const T={concat(t,e){if(0===t.length||0===e.length)return t.concat(e);const n=t[t.length-1],s=T.l(n);return 32===s?t.concat(e):T.h(e,s,0|n,t.slice(0,t.length-1))},m(t){const e=t.length;if(0===e)return 0;const n=t[e-1];return 32*(e-1)+T.l(n)},S(t,e){if(32*t.length<e)return t;const n=(t=t.slice(0,s.ceil(e/32))).length;return e&=31,n>0&&e&&(t[n-1]=T.v(e,t[n-1]&2147483648>>e-1,1)),t},v:(t,e,n)=>32===t?e:(n?0|e:e<<32-t)+1099511627776*t,l:t=>s.round(t/1099511627776)||32,h(t,e,n,s){for(void 0===s&&(s=[]);e>=32;e-=32)s.push(n),n=0;if(0===e)return s.concat(t);for(let r=0;r<t.length;r++)s.push(n|t[r]>>>e),n=t[r]<<32-e;const r=t.length?t[t.length-1]:0,o=T.l(r);return s.push(T.v(e+o&31,e+o>32?n:s.pop(),1)),s}},V={bytes:{C(t){const e=T.m(t)/8,n=new o(e);let s;for(let r=0;e>r;r++)3&r||(s=t[r/4]),n[r]=s>>>24,s<<=8;return n},A(t){const e=[];let n,s=0;for(n=0;n<t.length;n++)s=s<<8|t[n],3&~n||(e.push(s),s=0);return 3&n&&e.push(T.v(8*(3&n),s)),e}}},K=class{constructor(t){const e=this;e.blockSize=512,e.I=[1732584193,4023233417,2562383102,271733878,3285377520],e.M=[1518500249,1859775393,2400959708,3395469782],t?(e.P=t.P.slice(0),e.D=t.D.slice(0),e.B=t.B):e.reset()}reset(){const t=this;return t.P=t.I.slice(0),t.D=[],t.B=0,t}update(t){const e=this;"string"==typeof t&&(t=V.F.A(t));const n=e.D=T.concat(e.D,t),s=e.B,o=e.B=s+T.m(t);if(o>9007199254740991)throw new r("Cannot hash more than 2^53 - 1 bits");const c=new i(n);let a=0;for(let t=e.blockSize+s-(e.blockSize+s&e.blockSize-1);o>=t;t+=e.blockSize)e.R(c.subarray(16*a,16*(a+1))),a+=1;return n.splice(0,16*a),e}U(){const t=this;let e=t.D;const n=t.P;e=T.concat(e,[T.v(1,1)]);for(let t=e.length+2;15&t;t++)e.push(0);for(e.push(s.floor(t.B/4294967296)),e.push(0|t.B);e.length;)t.R(e.splice(0,16));return t.reset(),n}W(t,e,n,s){return t>19?t>39?t>59?t>79?void 0:e^n^s:e&n|e&s|n&s:e^n^s:e&n|~e&s}_(t,e){return e<<t|e>>>32-t}R(e){const n=this,r=n.P,o=t(80);for(let t=0;16>t;t++)o[t]=e[t];let c=r[0],i=r[1],a=r[2],f=r[3],l=r[4];for(let t=0;79>=t;t++){16>t||(o[t]=n._(1,o[t-3]^o[t-8]^o[t-14]^o[t-16]));const e=n._(5,c)+n.W(t,i,a,f)+l+o[t]+n.M[s.floor(t/20)]|0;l=f,f=a,a=n._(30,i),i=c,c=e}r[0]=r[0]+c|0,r[1]=r[1]+i|0,r[2]=r[2]+a|0,r[3]=r[3]+f|0,r[4]=r[4]+l|0}},E={importKey:t=>new E.T(V.bytes.A(t)),V(t,e,n,s){if(n=n||1e4,0>s||0>n)throw new r("invalid params to pbkdf2");const o=1+(s>>5)<<2;let c,i,a,f,w;const u=new ArrayBuffer(o),h=new l(u);let p=0;const d=T;for(e=V.bytes.A(e),w=1;(o||1)>p;w++){for(c=i=t.encrypt(d.concat(e,[w])),a=1;n>a;a++)for(i=t.encrypt(i),f=0;f<i.length;f++)c[f]^=i[f];for(a=0;(o||1)>p&&a<c.length;a++)h.setInt32(p,c[a]),p+=4}return u.slice(0,s/8)},T:class{constructor(t){const e=this,n=e.K=K,s=[[],[]];e.L=[new n,new n];const r=e.L[0].blockSize/32;t.length>r&&(t=(new n).update(t).U());for(let e=0;r>e;e++)s[0][e]=909522486^t[e],s[1][e]=1549556828^t[e];e.L[0].update(s[0]),e.L[1].update(s[1]),e.O=new n(e.L[0])}reset(){const t=this;t.O=new t.K(t.L[0]),t.j=!1}update(t){this.j=!0,this.O.update(t)}digest(){const t=this,e=t.O.U(),n=new t.K(t.L[1]).update(e).U();return t.reset(),n}encrypt(t){if(this.j)throw new r("encrypt on already updated hmac called!");return this.update(t),this.digest(t)}}},L=typeof h!=b&&typeof h.getRandomValues==k,O="Invalid password",j="Invalid signature",H=j,N="zipjs-abort-check-password";function q(t){if(L)return h.getRandomValues(t);throw new r("Crypto API not supported")}const G=16,J={name:"PBKDF2"},Q=e.assign({hash:{name:"HMAC"}},J),X=e.assign({iterations:1e3,hash:{name:"SHA-1"}},J),Y=["deriveBits"],Z=[8,12,16],$=[16,24,32],tt=10,et=[0,0,0,0],nt=typeof h!=b,st=nt&&h.subtle,rt=nt&&typeof st!=b,ot=V.bytes,ct=class{constructor(t){const e=this;e.H=[[[],[],[],[],[]],[[],[],[],[],[]]],e.H[0][0][0]||e.N();const n=e.H[0][4],s=e.H[1],o=t.length;let c,i,a,f=1;if(4!==o&&6!==o&&8!==o)throw new r("invalid aes key size");for(e.M=[i=t.slice(0),a=[]],c=o;4*o+28>c;c++){let t=i[c-1];(c%o===0||8===o&&c%o===4)&&(t=n[t>>>24]<<24^n[t>>16&255]<<16^n[t>>8&255]<<8^n[255&t],c%o===0&&(t=t<<8^t>>>24^f<<24,f=f<<1^283*(f>>7))),i[c]=i[c-o]^t}for(let t=0;c;t++,c--){const e=i[3&t?c:c-4];a[t]=4>=c||4>t?e:s[0][n[e>>>24]]^s[1][n[e>>16&255]]^s[2][n[e>>8&255]]^s[3][n[255&e]]}}encrypt(t){return this.G(t,0)}decrypt(t){return this.G(t,1)}N(){const t=this.H[0],e=this.H[1],n=t[4],s=e[4],r=[],o=[];let c,i,a,f;for(let t=0;256>t;t++)o[(r[t]=t<<1^283*(t>>7))^t]=t;for(let l=c=0;!n[l];l^=i||1,c=o[c]||1){let o=c^c<<1^c<<2^c<<3^c<<4;o=o>>8^255&o^99,n[l]=o,s[o]=l,f=r[a=r[i=r[l]]];let w=16843009*f^65537*a^257*i^16843008*l,u=257*r[o]^16843008*o;for(let n=0;4>n;n++)t[n][l]=u=u<<24^u>>>8,e[n][o]=w=w<<24^w>>>8}for(let n=0;5>n;n++)t[n]=t[n].slice(0),e[n]=e[n].slice(0)}G(t,e){if(4!==t.length)throw new r("invalid aes block size");const n=this.M[e],s=n.length/4-2,o=[0,0,0,0],c=this.H[e],i=c[0],a=c[1],f=c[2],l=c[3],w=c[4];let u,h,p,d=t[0]^n[0],y=t[e?3:1]^n[1],m=t[2]^n[2],S=t[e?1:3]^n[3],g=4;for(let t=0;s>t;t++)u=i[d>>>24]^a[y>>16&255]^f[m>>8&255]^l[255&S]^n[g],h=i[y>>>24]^a[m>>16&255]^f[S>>8&255]^l[255&d]^n[g+1],p=i[m>>>24]^a[S>>16&255]^f[d>>8&255]^l[255&y]^n[g+2],S=i[S>>>24]^a[d>>16&255]^f[y>>8&255]^l[255&m]^n[g+3],g+=4,d=u,y=h,m=p;for(let t=0;4>t;t++)o[e?3&-t:t]=w[d>>>24]<<24^w[y>>16&255]<<16^w[m>>8&255]<<8^w[255&S]^n[g++],u=d,d=y,y=m,m=S,S=u;return o}},it=class{constructor(t,e){this.J=t,this.X=e,this.Y=e}reset(){this.Y=this.X}update(t){return this.Z(this.J,t,this.Y)}$(t){if(255&~(t>>24))t+=1<<24;else{let e=t>>16&255,n=t>>8&255,s=255&t;255===e?(e=0,255===n?(n=0,255===s?s=0:++s):++n):++e,t=0,t+=e<<16,t+=n<<8,t+=s}return t}et(t){0===(t[0]=this.$(t[0]))&&(t[1]=this.$(t[1]))}Z(t,e,n){let s;if(!(s=e.length))return[];const r=T.m(e);for(let r=0;s>r;r+=4){this.et(n);const s=t.encrypt(n);e[r]^=s[0],e[r+1]^=s[1],e[r+2]^=s[2],e[r+3]^=s[3]}return T.S(e,r)}},at=E.T;let ft=nt&&rt&&typeof st.importKey==k,lt=nt&&rt&&typeof st.deriveBits==k;class wt extends d{constructor({password:t,rawPassword:e,encryptionStrength:n,checkPasswordOnly:s,checkAuthenticationCode:c=!0}){super({start(){ht(this,t,e,n)},async transform(t,e){const n=this,{password:c,strength:i,nt:a,ready:f}=n;c?(await(async(t,e,n,s)=>{const o=await dt(t,e,n,mt(s,0,Z[e])),c=mt(s,Z[e]);if(o[0]!=c[0]||o[1]!=c[1])throw new r(O)})(n,i,c,mt(t,0,Z[i]+2)),t=mt(t,Z[i]+2),s?e.error(new r(N)):a()):await f;const l=new o(t.length-tt-(t.length-tt)%G);e.enqueue(pt(n,t,l,0,tt,!0))},async flush(t){const{st:e,ot:n,pending:s,ready:o}=this;if(n&&e){await o;const i=mt(s,0,s.length-tt),a=mt(s,s.length-tt);let f=z;if(i.length){const t=gt(ot,i);n.update(t);const s=e.update(t);f=St(ot,s)}const l=mt(St(ot,n.digest()),0,tt);let w=s.length<tt?1:0;for(let t=0;tt>t;t++)w|=l[t]^a[t];if(w&&c)throw new r(H);t.enqueue(f)}}})}}class ut extends d{constructor({password:t,rawPassword:e,encryptionStrength:n}){super({start(){ht(this,t,e,n)},async transform(t,e){const n=this,{password:s,strength:r,nt:c,ready:i}=n;let a=z;s?(a=await(async(t,e,n)=>{const s=q(new o(Z[e]));return W(s,await dt(t,e,n,s))})(n,r,s),c()):await i;const f=new o(a.length+t.length-t.length%G);f.set(a,0),e.enqueue(pt(n,t,f,a.length,0))},async flush(t){const{st:e,ot:n,pending:s,ready:r}=this;if(n&&e){await r;let o=z;if(s.length){const t=e.update(gt(ot,s));n.update(t),o=St(ot,t)}const c=St(ot,n.digest()).slice(0,tt);t.enqueue(W(o,c))}}})}}function ht(t,n,s,r){e.assign(t,{ready:new w(e=>t.nt=e),password:yt(n,s),strength:r-1,pending:z})}function pt(t,e,n,s,r,c){const{st:i,ot:a,pending:f}=t;f.length&&(e=W(f,e));const l=e.length-r;let w;for(n=((t,e)=>{if(e&&e>t.length){const n=t;(t=new o(e)).set(n,0)}return t})(n,s+(l-l%G)),w=0;l-G>=w;w+=G){const t=gt(ot,mt(e,w,w+G));c&&a.update(t);const r=i.update(t);c||a.update(r),n.set(St(ot,r),w+s)}return t.pending=mt(e,w),n}async function dt(n,s,r,c){n.password=null;const i=await(async(t,e,n,s,r)=>{if(!ft)return E.importKey(e);try{return await st.importKey("raw",e,n,!1,r)}catch{return ft=!1,E.importKey(e)}})(0,r,Q,0,Y),a=await(async(t,e,n)=>{if(!lt)return E.V(e,t.salt,X.iterations,n);try{return await st.deriveBits(t,e,n)}catch{return lt=!1,E.V(e,t.salt,X.iterations,n)}})(e.assign({salt:c},X),i,8*(2*$[s]+2)),f=new o(a),l=gt(ot,mt(f,0,$[s])),w=gt(ot,mt(f,$[s],2*$[s])),u=mt(f,2*$[s]);return e.assign(n,{keys:{key:l,ct:w,passwordVerification:u},st:new it(new ct(l),t.from(et)),ot:new at(w)}),u}function yt(t,e){return e===v?(t=>{if(typeof u==b){const e=new o((t=unescape(encodeURIComponent(t))).length);for(let n=0;n<e.length;n++)e[n]=t.charCodeAt(n);return e}return(new u).encode(t)})(t):e}function mt(t,e,n){return t.subarray(e,n)}function St(t,e){return t.C(e)}function gt(t,e){return t.A(e)}class vt extends d{constructor({password:t,rawPassword:e,passwordVerification:n,checkPasswordOnly:s}){super({start(){kt(this,t,e,n)},transform(t,e){const n=this;if(n.password||n.rawPassword){const e=zt(n,t.subarray(0,12));if(n.password=n.rawPassword=null,0!=(e[11]^n.passwordVerification))throw new r(O);t=t.subarray(12)}s?e.error(new r(N)):e.enqueue(zt(n,t))}})}}class bt extends d{constructor({password:t,rawPassword:e,passwordVerification:n}){super({start(){kt(this,t,e,n)},transform(t,e){const n=this;let s,r;if(n.password||n.rawPassword){n.password=n.rawPassword=null;const e=q(new o(12));e[11]=n.passwordVerification,s=new o(t.length+e.length),s.set(Ct(n,e),0),r=12}else s=new o(t.length),r=0;s.set(Ct(n,t),r),e.enqueue(s)}})}}function kt(t,n,s,r){e.assign(t,{password:n,rawPassword:s,passwordVerification:r}),((t,n,s)=>{const r=[305419896,591751049,878082192];if(e.assign(t,{keys:r,it:new R(r[0]),ft:new R(r[2])}),s)for(let e=0;e<s.length;e++)At(t,s[e]);else for(let e=0;e<n.length;e++)At(t,n.charCodeAt(e))})(t,n,s)}function zt(t,e){const n=new o(e.length);for(let s=0;s<e.length;s++)n[s]=It(t)^e[s],At(t,n[s]);return n}function Ct(t,e){const n=new o(e.length);for(let s=0;s<e.length;s++)n[s]=It(t)^e[s],At(t,e[s]);return n}function At(t,e){let[,n]=t.keys;t.it.append([e]);const r=~t.it.get();n=Mt(s.imul(Mt(n+xt(r)),134775813)+1),t.ft.append([n>>>24]);const o=~t.ft.get();t.keys=[r,n,o]}function It(t){const e=2|t.keys[2];return xt(s.imul(e,1^e)>>>8)}function xt(t){return 255&t}function Mt(t){return 4294967295&t}const Pt=new f;function Dt(t){return Pt.get(t)}const Bt="Invalid uncompressed size",Ft=j,Rt="deflate-raw",Ut="gzip",Wt=[31,139,8];class _t extends d{constructor(t,{chunkSize:e,CompressionStreamFallback:n,CompressionStream:s}){super({});const{compressed:r,encrypted:o,useCompressionStream:c,zipCrypto:i,computeCrc32:a,level:f,deflate64:w,format:u,compressionMethod:h}=t,p=this;let d,y,m,S=super.readable;const g=u&&Dt(u),v=a&&r&&!w&&!g&&(!o||i)&&!(!c||!s);if(o&&!i||!a||v||(d=new U,S=jt(S,d)),r)if(g)S=Ht(S,Lt(g.CompressionStream,u,{level:f,chunkSize:e,compressionMethod:h}));else if(v)m=new Tt,S=Ht(S,new s(Ut)),S=jt(S,m);else try{S=Ot(S,c,{level:f,chunkSize:e},s,n)}catch(t){let e;try{e=new s(Ut)}catch{throw t}S=Ht(S,e),S=jt(S,new Tt)}o&&(i?S=jt(S,new bt(t)):(y=new ut(t),S=jt(S,y))),Et(p,S,()=>{o&&!i||!a||(p.crc32=v?m.crc32:new l(d.value.buffer).getUint32(0))})}}class Tt extends d{constructor(){let t,e=10,n=new o(0);super({transform(t,r){if(e){const n=s.min(e,t.length);if(e-=n,!(t=t.subarray(n)).length)return}const o=n.length+t.length;if(8>=o)return void(n=W(n,t));const c=o-8,i=s.min(c,n.length);r.enqueue(W(n.subarray(0,i),t.subarray(0,c-i))),n=W(n.subarray(i),t.subarray(c-i))},flush(){const e=_(n);t.crc32=e.getUint32(0,!0),t.uncompressedSize=e.getUint32(4,!0)}}),t=this}}class Vt extends d{constructor(t,{chunkSize:e,DecompressionStreamFallback:n,DecompressionStream:s}){super({});const{zipCrypto:c,encrypted:i,checkCrc32:a,crc32:f,compressed:u,useCompressionStream:h,deflate64:p,format:m,compressionMethod:S,rawBitFlag:g,outputSize:b}=t;let k,z,C=super.readable;if(i&&(c?C=jt(C,new vt(t)):(z=new wt(t),C=jt(C,z))),u){const t=m&&Dt(m);if(t)C=Ht(C,Lt(t.DecompressionStream,m,{chunkSize:e,compressionMethod:S,rawBitFlag:g,uncompressedSize:b}));else try{C=Ot(C,h,{chunkSize:e,deflate64:p},s,n)}catch(t){if(p||b===v)throw t;let e;try{e=new s(Ut)}catch{throw t}C=((t,e,n)=>{const s=new R;let c,i,a,f=0,l=!1;const u=new w((t,e)=>{i=t,a=e});u.catch(()=>{}),n||i();const h=new d({start(t){const e=new o(10);e.set(Wt),t.enqueue(e)},transform(t,e){e.enqueue(t)},async flush(t){l=!0,y();try{await u}finally{m()}const e=new o(8),r=_(e);r.setUint32(0,s.get(),!0),r.setUint32(4,n,!0),t.enqueue(e)},cancel(t){a(t)}}),p=new d({transform(t,e){s.append(t),f+=t.length,n>f?l&&y():i(),e.enqueue(t)},cancel(t){a(t)}});return t=jt(t,h),jt(t=Ht(t,e),p);function y(){m(),c=setTimeout(()=>a(new r(Bt)),5e3)}function m(){clearTimeout(c)}})(C,e,b)}C=(t=>{const e=t.getReader();return new y({async pull(t){let n;try{n=await e.read()}catch(t){if(t&&t.message)throw t;const e=new r("Invalid compressed data");throw e.cause=t,e}const{value:s,done:o}=n;o?t.close():t.enqueue(s)},cancel:t=>e.cancel(t)})})(C)}a&&(k=new U,C=jt(C,k)),Et(this,C,()=>{if(a){const t=new l(k.value.buffer);if(f!=t.getUint32(0,!1))throw new r(Ft)}})}}const Kt=new f;function Et(t,n,s){n=jt(n,new d({flush:s})),e.defineProperty(t,"readable",{get:()=>n})}function Lt(t,e,n){if(!t)throw new r("Compression method not supported");return new t(e,n)}function Ot(t,e,n,s,r){const o=e&&s?s:r||s,c=n.deflate64?"deflate64-raw":Rt;let i;try{i=new o(c,n)}catch(t){if(!e||!r||o==r)throw t;i=new r(c,n)}return Ht(t,i)}function jt(t,e){return(t=>{if(t instanceof y)return t;const e=t.getReader();return new y({async pull(t){const{value:n,done:s}=await e.read();s?t.close():t.enqueue(n)},cancel:t=>e.cancel(t)})})(t).pipeThrough(e)}function Ht(t,e){const n=e.writable.getWriter(),s=t.getReader();return(async()=>{try{for(;;){await n.ready;const t=await s.read();if(t.done){await n.close();break}await n.write(t.value)}}catch(t){await(async(t,e)=>{try{await t.abort(e)}catch{}})(n,t),await(async(t,e)=>{try{await t.cancel(e)}catch{}})(s,t)}})(),e.readable}const Nt="data",qt="close",Gt="deflate";class Jt extends d{constructor(t,n){super({});const s=this,{codecType:o}=t;let c;o.startsWith(Gt)?c=_t:o.startsWith("inflate")&&(c=Vt),s.outputSize=0;let i=0;const a=new c(t,n),f=super.readable,l=new d({transform(t,e){t&&t.length&&(i+=t.length,e.enqueue(t))},flush(){e.assign(s,{inputSize:i})}}),w=new d({transform(e,n){if(e&&e.length&&(n.enqueue(e),s.outputSize+=e.length,t.outputSize!==v&&s.outputSize>t.outputSize))throw new r(Bt)},flush(){const{crc32:t}=a;e.assign(s,{crc32:t,inputSize:i})}});e.defineProperty(s,"readable",{get:()=>f.pipeThrough(l).pipeThrough(a).pipeThrough(w)})}}class Qt extends d{constructor(t){const e=[];let s=0;function r(){const n=new o(t);let r=0;for(;t>r;){const s=e[0],o=t-r;s.length>o?(n.set(s.subarray(0,o),r),e[0]=s.subarray(o),r+=o):(n.set(s,r),r+=s.length,e.shift())}return s-=t,n}n.isFinite(t)&&t>=1||(t=65536),super({transform(n,o){for(e.push(n),s+=n.length;s>t;)o.enqueue(r())},flush(t){s&&t.enqueue(((t,e)=>{const n=new o(e);let s=0;for(const e of t)n.set(e,s),s+=e.length;return n})(e,s))}})}}let Xt=2;try{typeof navigator!=b&&navigator.hardwareConcurrency&&(Xt=navigator.hardwareConcurrency)}catch{}const Yt=new f,Zt=new f;let $t,te,ee,ne,se,re,oe=0;async function ce(t){let e,o;try{const{options:c,config:i}=t;if(c.format&&await(async(t,e)=>{!Pt.has(t)&&e&&((t,e)=>{const{CompressionStream:n,DecompressionStream:s}=e;if(typeof n!=k&&typeof s!=k)throw new r("Invalid codec module");Pt.set(t,{CompressionStream:n,DecompressionStream:s})})(t,await(import(e)))})(c.format,c.codecURI),i.CompressionStream=self.CompressionStream,i.DecompressionStream=self.DecompressionStream,c.compressed&&!c.format)if(c.useCompressionStream){if(!((t,e)=>{if(!t)return!1;let n=Kt.get(t);n||(n=new f,Kt.set(t,n));let s=n.get(e);if(s===v){try{new t(e),s=!0}catch{s=!1}n.set(e,s)}return s})(c.codecType.startsWith(Gt)?i.CompressionStream:i.DecompressionStream,Rt))try{await self.initModule(t.config)}catch{}}else try{await self.initModule(t.config)}catch{c.useCompressionStream=!0}!i.CompressionStreamFallback&&i.CompressionStreamZlib&&(i.CompressionStreamFallback=i.CompressionStreamZlib),!i.DecompressionStreamFallback&&i.DecompressionStreamZlib&&(i.DecompressionStreamFallback=i.DecompressionStreamZlib);const a={highWaterMark:1},l=t.readable||new y({async pull(t){const e=new w(t=>Yt.set(oe,t));ie({type:"pull",messageId:oe}),oe=(oe+1)%n.MAX_SAFE_INTEGER;const{value:s,done:r}=await e;t.enqueue(s),r&&t.close()}},a);o=t.writable||new m({async write(t){let e;const s=new w(t=>e=t);Zt.set(oe,e),ie({type:Nt,value:t,messageId:oe}),oe=(oe+1)%n.MAX_SAFE_INTEGER,await s}},a),e=new Jt(c,i),$t=new AbortController;const{signal:u}=$t;await l.pipeThrough(e).pipeThrough(new Qt((t=>s.max(t.chunkSize,64))(i))).pipeTo(o,{signal:u,preventClose:!0,preventAbort:!0}),await o.getWriter().close();const{crc32:h,inputSize:p,outputSize:d}=e;ie({type:qt,result:{crc32:h,inputSize:p,outputSize:d}})}catch(t){if(t.outputSize=e?e.outputSize:0,o&&!o.locked)try{await o.getWriter().close()}catch{}ae(t)}}function ie(t){const{value:e}=t;if(e)if(e.length)try{t.value=(n=e,n.byteOffset||n.byteLength!=n.buffer.byteLength?new o(n):n).buffer,p(t,[t.value])}catch{p(t)}else p(t);else p(t);var n}function ae(t=new r("Unknown error")){const{message:e,stack:n,code:s,name:o,outputSize:c,cause:i}=t,a={message:e,stack:n,code:s,name:o,outputSize:c};i&&(a.cause={name:i.name,message:i.message}),p({error:a})}function fe(t,e,n={}){if(!te){const t=new r("WASM module not loaded");throw t.cause=re,t}const c="number"==typeof n.level?n.level:-1,i="number"==typeof n.outBuffer?n.outBuffer:65536,a="number"==typeof n.inBufferSize?n.inBufferSize:65536;return new d({start(){try{let n;if(this.lt=ee(i),this.in=ee(a),this.inBufferSize=a,!this.lt||!this.in)throw new r("allocation failed");if(this.wt=new o(i),t?(this.ut=te.deflate_process,this.ht=te.deflate_last_consumed,this.yt=te.deflate_end,this.St=te.deflate_new(),n="gzip"===e?te.deflate_init_gzip(this.St,c):"deflate-raw"===e?te.deflate_init_raw(this.St,c):te.deflate_init(this.St,c)):"deflate64-raw"===e?(this.ut=te.inflate9_process,this.ht=te.inflate9_last_consumed,this.yt=te.inflate9_end,this.St=te.inflate9_new(),n=te.inflate9_init_raw(this.St)):(this.ut=te.inflate_process,this.ht=te.inflate_last_consumed,this.yt=te.inflate_end,this.St=te.inflate_new(),n="deflate-raw"===e?te.inflate_init_raw(this.St):"gzip"===e?te.inflate_init_gzip(this.St):te.inflate_init(this.St)),0!==n)throw new r("init failed:"+n)}catch(t){throw f(this),t}},transform(e,n){try{const c=e,a=new o(se.buffer),f=this.ut,l=this.ht,w=this.lt,u=this.wt;let h=0;for(;h<c.length;){const e=s.min(c.length-h,32768);if((!this.in||this.inBufferSize<e)&&(this.in&&ne&&(ne(this.in),this.in=0),this.in=ee(e),this.inBufferSize=e,!this.in))throw new r("allocation failed");a.set(c.subarray(h,h+e),this.in);const o=f(this.St,this.in,e,w,i,0),p=16777215&o;if(p&&(u.set(a.subarray(w,w+p),0),n.enqueue(u.slice(0,p))),!t){const t=o>>24&255,e=128&t?t-256:t;if(0>e)throw new r("process error:"+e)}const d=l(this.St);if(0===d)break;h+=d}}catch(t){f(this),n.error(t)}},flush(e){try{const n=new o(se.buffer),s=this.ut,c=this.lt,a=this.wt;for(;;){const o=s(this.St,0,0,c,i,4),f=16777215&o,l=o>>24&255;if(!t){const t=128&l?l-256:l;if(0>t)throw new r("process error:"+t)}if(f&&(a.set(n.subarray(c,c+f),0),e.enqueue(a.slice(0,f))),1===l||0===f)break}}catch(t){e.error(t)}finally{const t=f(this);0!==t&&e.error(new r("end error:"+t))}},cancel(){f(this)}});function f(t){let e=0;return t.St&&t.yt&&(e=t.yt(t.St)),t.St=0,t.in&&ne&&ne(t.in),t.in=0,t.lt&&ne&&ne(t.lt),t.lt=0,e}}addEventListener("message",({data:t})=>{const{type:e,messageId:n,value:s,done:r}=t;try{if("start"==e&&ce(t),e==Nt){const t=Yt.get(n);Yt.delete(n),t({value:s||new o,done:r})}if("ack"==e){const t=Zt.get(n);Zt.delete(n),t()}e==qt&&$t.abort()}catch(t){ae(t)}}),p({type:"ready"});class le{constructor(t="deflate",e){return fe(!0,t,e)}}class we{constructor(t="deflate",e){return fe(!1,t,e)}}le.gt=!0,we.gt=!0;let ue=!1;((t={})=>{const{init:e}=t,n=t.CompressionStreamFallback||t.CompressionStreamZlib,s=t.DecompressionStreamFallback||t.DecompressionStreamZlib;self.initModule=async t=>{e&&await e(t),n&&(t.CompressionStreamFallback=n),s&&(t.DecompressionStreamFallback=s)}})({CompressionStreamFallback:le,DecompressionStreamFallback:we,init:t=>(async(t,{baseURI:e})=>{if(!ue)try{await(async(t,e)=>{let n,s;try{try{s=new URL(t,e)}catch{}const r=await fetch(s);n=await r.arrayBuffer()}catch(e){if(!t.startsWith("data:application/wasm;base64,"))throw e;n=(t=>{const e=t.split(",")[1],n=atob(e),s=n.length,r=new o(s);for(let t=0;s>t;++t)r[t]=n.charCodeAt(t);return r.buffer})(t)}(t=>{if(te=t,({malloc:ee,free:ne,memory:se}=te),"function"!=typeof ee||"function"!=typeof ne||!se)throw te=ee=ne=se=null,new r("Invalid WASM module")})((await WebAssembly.instantiate(n)).instance.exports)})(t,e),ue=!0}catch(t){throw(t=>{re=t})(t),t}})(t.wasmURI,t)})});\n';if("string"==typeof s&&(s=(new TextEncoder).encode(s)),t){const t=new Blob([s],{type:n});return URL.createObjectURL(t)}return "data:"+n+";base64,"+(t=>{let n="";const s=t.length;let r=0;for(;s>r+2;r+=3){const s=t[r]<<16|t[r+1]<<8|t[r+2];n+=e[s>>18&63]+e[s>>12&63]+e[s>>6&63]+e[63&s];}const o=s-r;if(1===o){const s=t[r]<<16;n+=e[s>>18&63]+e[s>>12&63]+"==";}else if(2===o){const s=t[r]<<16|t[r+1]<<8;n+=e[s>>18&63]+e[s>>12&63]+e[s>>6&63]+"=";}return n})(s)}});
|
|
228
248
|
|
|
229
249
|
/*
|
|
230
250
|
Copyright (c) 2025 Gildas Lormeau. All rights reserved.
|
|
@@ -1422,7 +1442,7 @@
|
|
|
1422
1442
|
const DERIVED_BITS_USAGE = ["deriveBits"];
|
|
1423
1443
|
const SALT_LENGTH = [8, 12, 16];
|
|
1424
1444
|
const KEY_LENGTH = [16, 24, 32];
|
|
1425
|
-
const
|
|
1445
|
+
const AUTHENTICATION_CODE_LENGTH = 10;
|
|
1426
1446
|
const COUNTER_DEFAULT_VALUE = [0, 0, 0, 0];
|
|
1427
1447
|
// deno-lint-ignore valid-typeof
|
|
1428
1448
|
const CRYPTO_API_SUPPORTED = typeof crypto != UNDEFINED_TYPE;
|
|
@@ -1462,8 +1482,8 @@
|
|
|
1462
1482
|
} else {
|
|
1463
1483
|
await ready;
|
|
1464
1484
|
}
|
|
1465
|
-
const output = new Uint8Array(chunk.length -
|
|
1466
|
-
controller.enqueue(append(aesCrypto, chunk, output, 0,
|
|
1485
|
+
const output = new Uint8Array(chunk.length - AUTHENTICATION_CODE_LENGTH - ((chunk.length - AUTHENTICATION_CODE_LENGTH) % BLOCK_LENGTH));
|
|
1486
|
+
controller.enqueue(append(aesCrypto, chunk, output, 0, AUTHENTICATION_CODE_LENGTH, true));
|
|
1467
1487
|
},
|
|
1468
1488
|
async flush(controller) {
|
|
1469
1489
|
const {
|
|
@@ -1474,8 +1494,8 @@
|
|
|
1474
1494
|
} = this;
|
|
1475
1495
|
if (hmac && ctr) {
|
|
1476
1496
|
await ready;
|
|
1477
|
-
const chunkToDecrypt = subarray(pending, 0, pending.length -
|
|
1478
|
-
const
|
|
1497
|
+
const chunkToDecrypt = subarray(pending, 0, pending.length - AUTHENTICATION_CODE_LENGTH);
|
|
1498
|
+
const originalAuthenticationCode = subarray(pending, pending.length - AUTHENTICATION_CODE_LENGTH);
|
|
1479
1499
|
let decryptedChunkArray = EMPTY_UINT8_ARRAY;
|
|
1480
1500
|
if (chunkToDecrypt.length) {
|
|
1481
1501
|
const encryptedChunk = toBits(codecBytes, chunkToDecrypt);
|
|
@@ -1483,12 +1503,12 @@
|
|
|
1483
1503
|
const decryptedChunk = ctr.update(encryptedChunk);
|
|
1484
1504
|
decryptedChunkArray = fromBits(codecBytes, decryptedChunk);
|
|
1485
1505
|
}
|
|
1486
|
-
const
|
|
1487
|
-
let
|
|
1488
|
-
for (let
|
|
1489
|
-
|
|
1506
|
+
const authenticationCode = subarray(fromBits(codecBytes, hmac.digest()), 0, AUTHENTICATION_CODE_LENGTH);
|
|
1507
|
+
let invalidAuthenticationCode = pending.length < AUTHENTICATION_CODE_LENGTH ? 1 : 0;
|
|
1508
|
+
for (let indexByte = 0; indexByte < AUTHENTICATION_CODE_LENGTH; indexByte++) {
|
|
1509
|
+
invalidAuthenticationCode |= authenticationCode[indexByte] ^ originalAuthenticationCode[indexByte];
|
|
1490
1510
|
}
|
|
1491
|
-
if (
|
|
1511
|
+
if (invalidAuthenticationCode && checkAuthenticationCode) {
|
|
1492
1512
|
throw new Error(ERR_INVALID_AUTHENTICATION_CODE);
|
|
1493
1513
|
}
|
|
1494
1514
|
controller.enqueue(decryptedChunkArray);
|
|
@@ -1501,8 +1521,6 @@
|
|
|
1501
1521
|
class AESEncryptionStream extends TransformStream {
|
|
1502
1522
|
|
|
1503
1523
|
constructor({ password, rawPassword, encryptionStrength }) {
|
|
1504
|
-
// deno-lint-ignore prefer-const
|
|
1505
|
-
let stream;
|
|
1506
1524
|
super({
|
|
1507
1525
|
start() {
|
|
1508
1526
|
initAesCrypto(this, password, rawPassword, encryptionStrength);
|
|
@@ -1541,12 +1559,11 @@
|
|
|
1541
1559
|
hmac.update(encryptedChunk);
|
|
1542
1560
|
encryptedChunkArray = fromBits(codecBytes, encryptedChunk);
|
|
1543
1561
|
}
|
|
1544
|
-
|
|
1545
|
-
controller.enqueue(concat(encryptedChunkArray,
|
|
1562
|
+
const authenticationCode = fromBits(codecBytes, hmac.digest()).slice(0, AUTHENTICATION_CODE_LENGTH);
|
|
1563
|
+
controller.enqueue(concat(encryptedChunkArray, authenticationCode));
|
|
1546
1564
|
}
|
|
1547
1565
|
}
|
|
1548
1566
|
});
|
|
1549
|
-
stream = this;
|
|
1550
1567
|
}
|
|
1551
1568
|
}
|
|
1552
1569
|
|
|
@@ -1559,7 +1576,7 @@
|
|
|
1559
1576
|
});
|
|
1560
1577
|
}
|
|
1561
1578
|
|
|
1562
|
-
function append(aesCrypto, input, output, paddingStart, paddingEnd,
|
|
1579
|
+
function append(aesCrypto, input, output, paddingStart, paddingEnd, verifyAuthenticationCode) {
|
|
1563
1580
|
const {
|
|
1564
1581
|
ctr,
|
|
1565
1582
|
hmac,
|
|
@@ -1573,11 +1590,11 @@
|
|
|
1573
1590
|
let offset;
|
|
1574
1591
|
for (offset = 0; offset <= inputLength - BLOCK_LENGTH; offset += BLOCK_LENGTH) {
|
|
1575
1592
|
const inputChunk = toBits(codecBytes, subarray(input, offset, offset + BLOCK_LENGTH));
|
|
1576
|
-
if (
|
|
1593
|
+
if (verifyAuthenticationCode) {
|
|
1577
1594
|
hmac.update(inputChunk);
|
|
1578
1595
|
}
|
|
1579
1596
|
const outputChunk = ctr.update(inputChunk);
|
|
1580
|
-
if (!
|
|
1597
|
+
if (!verifyAuthenticationCode) {
|
|
1581
1598
|
hmac.update(outputChunk);
|
|
1582
1599
|
}
|
|
1583
1600
|
output.set(fromBits(codecBytes, outputChunk), offset + paddingStart);
|
|
@@ -1939,7 +1956,7 @@
|
|
|
1939
1956
|
|
|
1940
1957
|
class DeflateStream extends TransformStream {
|
|
1941
1958
|
|
|
1942
|
-
constructor(options, { chunkSize,
|
|
1959
|
+
constructor(options, { chunkSize, CompressionStreamFallback, CompressionStream }) {
|
|
1943
1960
|
super({});
|
|
1944
1961
|
const { compressed, encrypted, useCompressionStream, zipCrypto, computeCrc32, level, deflate64, format, compressionMethod } = options;
|
|
1945
1962
|
const stream = this;
|
|
@@ -1961,7 +1978,7 @@
|
|
|
1961
1978
|
readable = pipeThrough(readable, gzipCrc32Stream);
|
|
1962
1979
|
} else {
|
|
1963
1980
|
try {
|
|
1964
|
-
readable = pipeThroughCompressionStream(readable, useCompressionStream, { level, chunkSize }, CompressionStream,
|
|
1981
|
+
readable = pipeThroughCompressionStream(readable, useCompressionStream, { level, chunkSize }, CompressionStream, CompressionStreamFallback);
|
|
1965
1982
|
} catch (error) {
|
|
1966
1983
|
let gzipStream;
|
|
1967
1984
|
try {
|
|
@@ -1983,14 +2000,9 @@
|
|
|
1983
2000
|
}
|
|
1984
2001
|
}
|
|
1985
2002
|
setReadable(stream, readable, () => {
|
|
1986
|
-
let signature;
|
|
1987
|
-
if (encrypted && !zipCrypto) {
|
|
1988
|
-
signature = encryptionStream.signature;
|
|
1989
|
-
}
|
|
1990
2003
|
if ((!encrypted || zipCrypto) && computeCrc32) {
|
|
1991
|
-
|
|
2004
|
+
stream.crc32 = useGzipCrc32 ? gzipCrc32Stream.crc32 : new DataView(crc32Stream.value.buffer).getUint32(0);
|
|
1992
2005
|
}
|
|
1993
|
-
stream.signature = signature;
|
|
1994
2006
|
});
|
|
1995
2007
|
}
|
|
1996
2008
|
}
|
|
@@ -2028,7 +2040,7 @@
|
|
|
2028
2040
|
},
|
|
2029
2041
|
flush() {
|
|
2030
2042
|
const dataView = getDataView(trailerCandidate);
|
|
2031
|
-
stream.
|
|
2043
|
+
stream.crc32 = dataView.getUint32(0, true);
|
|
2032
2044
|
stream.uncompressedSize = dataView.getUint32(4, true);
|
|
2033
2045
|
}
|
|
2034
2046
|
});
|
|
@@ -2108,9 +2120,9 @@
|
|
|
2108
2120
|
|
|
2109
2121
|
class InflateStream extends TransformStream {
|
|
2110
2122
|
|
|
2111
|
-
constructor(options, { chunkSize,
|
|
2123
|
+
constructor(options, { chunkSize, DecompressionStreamFallback, DecompressionStream }) {
|
|
2112
2124
|
super({});
|
|
2113
|
-
const { zipCrypto, encrypted, checkCrc32,
|
|
2125
|
+
const { zipCrypto, encrypted, checkCrc32, crc32, compressed, useCompressionStream, deflate64, format, compressionMethod, rawBitFlag, outputSize } = options;
|
|
2114
2126
|
let crc32Stream, decryptionStream;
|
|
2115
2127
|
let readable = super.readable;
|
|
2116
2128
|
if (encrypted) {
|
|
@@ -2127,7 +2139,7 @@
|
|
|
2127
2139
|
readable = pipeThroughBackpressured(readable, createCodecStream(codecStreams.DecompressionStream, format, { chunkSize, compressionMethod, rawBitFlag, uncompressedSize: outputSize }));
|
|
2128
2140
|
} else {
|
|
2129
2141
|
try {
|
|
2130
|
-
readable = pipeThroughCompressionStream(readable, useCompressionStream, { chunkSize, deflate64 }, DecompressionStream,
|
|
2142
|
+
readable = pipeThroughCompressionStream(readable, useCompressionStream, { chunkSize, deflate64 }, DecompressionStream, DecompressionStreamFallback);
|
|
2131
2143
|
} catch (error) {
|
|
2132
2144
|
if (deflate64 || outputSize === UNDEFINED_VALUE) {
|
|
2133
2145
|
throw error;
|
|
@@ -2149,8 +2161,8 @@
|
|
|
2149
2161
|
}
|
|
2150
2162
|
setReadable(this, readable, () => {
|
|
2151
2163
|
if (checkCrc32) {
|
|
2152
|
-
const
|
|
2153
|
-
if (
|
|
2164
|
+
const computedCrc32View = new DataView(crc32Stream.value.buffer);
|
|
2165
|
+
if (crc32 != computedCrc32View.getUint32(0, false)) {
|
|
2154
2166
|
throw new Error(ERR_INVALID_CRC32);
|
|
2155
2167
|
}
|
|
2156
2168
|
}
|
|
@@ -2206,17 +2218,17 @@
|
|
|
2206
2218
|
return new CodecStreamClass(format, options);
|
|
2207
2219
|
}
|
|
2208
2220
|
|
|
2209
|
-
function pipeThroughCompressionStream(readable, useCompressionStream, options, CompressionStreamNative,
|
|
2221
|
+
function pipeThroughCompressionStream(readable, useCompressionStream, options, CompressionStreamNative, CompressionStreamFallback) {
|
|
2210
2222
|
const Stream = useCompressionStream && CompressionStreamNative ?
|
|
2211
2223
|
CompressionStreamNative :
|
|
2212
|
-
|
|
2224
|
+
CompressionStreamFallback || CompressionStreamNative;
|
|
2213
2225
|
const format = options.deflate64 ? FORMAT_DEFLATE64_RAW : FORMAT_DEFLATE_RAW;
|
|
2214
2226
|
let codecStream;
|
|
2215
2227
|
try {
|
|
2216
2228
|
codecStream = new Stream(format, options);
|
|
2217
2229
|
} catch (error) {
|
|
2218
|
-
if (useCompressionStream &&
|
|
2219
|
-
codecStream = new
|
|
2230
|
+
if (useCompressionStream && CompressionStreamFallback && Stream != CompressionStreamFallback) {
|
|
2231
|
+
codecStream = new CompressionStreamFallback(format, options);
|
|
2220
2232
|
} else {
|
|
2221
2233
|
throw error;
|
|
2222
2234
|
}
|
|
@@ -2375,9 +2387,9 @@
|
|
|
2375
2387
|
}
|
|
2376
2388
|
},
|
|
2377
2389
|
flush() {
|
|
2378
|
-
const {
|
|
2390
|
+
const { crc32 } = stream;
|
|
2379
2391
|
Object.assign(codec, {
|
|
2380
|
-
|
|
2392
|
+
crc32,
|
|
2381
2393
|
inputSize
|
|
2382
2394
|
});
|
|
2383
2395
|
}
|
|
@@ -2479,7 +2491,7 @@
|
|
|
2479
2491
|
const MESSAGE_ERROR_EVENT_TYPE = "messageerror";
|
|
2480
2492
|
const ERR_WORKER_STARTUP_TIMEOUT = "Worker startup timeout";
|
|
2481
2493
|
|
|
2482
|
-
let webWorkerSupported, webWorkerSource, webWorkerURI, webWorkerOptions;
|
|
2494
|
+
let webWorkerSupported, webWorkerSource, webWorkerURI, webWorkerOptions, createWorkerFailed;
|
|
2483
2495
|
let transferStreamsSupported = true;
|
|
2484
2496
|
try {
|
|
2485
2497
|
transferStreamsSupported = typeof structuredClone == FUNCTION_TYPE && structuredClone(new DOMException("", "AbortError")).code !== UNDEFINED_VALUE;
|
|
@@ -2493,14 +2505,14 @@
|
|
|
2493
2505
|
}
|
|
2494
2506
|
|
|
2495
2507
|
async function supportsDeflate(config) {
|
|
2496
|
-
const { CompressionStream: NativeStream,
|
|
2497
|
-
if (
|
|
2508
|
+
const { CompressionStream: NativeStream, CompressionStreamFallback: FallbackStream } = config;
|
|
2509
|
+
if (FallbackStream && !FallbackStream.requiresModule) {
|
|
2498
2510
|
return true;
|
|
2499
2511
|
}
|
|
2500
2512
|
if (supportsDeflateRaw(NativeStream) || supportsGzip(NativeStream)) {
|
|
2501
2513
|
return true;
|
|
2502
2514
|
}
|
|
2503
|
-
if (
|
|
2515
|
+
if (FallbackStream) {
|
|
2504
2516
|
try {
|
|
2505
2517
|
await initModule$1(config);
|
|
2506
2518
|
return true;
|
|
@@ -2513,12 +2525,16 @@
|
|
|
2513
2525
|
|
|
2514
2526
|
function resetWebWorkerSupport() {
|
|
2515
2527
|
webWorkerSupported = UNDEFINED_VALUE;
|
|
2528
|
+
createWorkerFailed = false;
|
|
2516
2529
|
}
|
|
2517
2530
|
|
|
2518
2531
|
class CodecWorker {
|
|
2519
2532
|
|
|
2520
|
-
constructor(workerData, { readable, writable }, { options, config, streamOptions, useWebWorkers, transferStreams, workerURI }, onTaskFinished) {
|
|
2533
|
+
constructor(workerData, { readable, writable }, { options, config, streamOptions, useWebWorkers, transferStreams, workerURI, createWorker }, onTaskFinished) {
|
|
2521
2534
|
const { signal } = streamOptions;
|
|
2535
|
+
if (createWorkerFailed) {
|
|
2536
|
+
createWorker = UNDEFINED_VALUE;
|
|
2537
|
+
}
|
|
2522
2538
|
Object.assign(workerData, {
|
|
2523
2539
|
busy: true,
|
|
2524
2540
|
generation: (workerData.generation || 0) + 1,
|
|
@@ -2528,6 +2544,7 @@
|
|
|
2528
2544
|
writable,
|
|
2529
2545
|
options: Object.assign({}, options),
|
|
2530
2546
|
workerURI,
|
|
2547
|
+
createWorker,
|
|
2531
2548
|
transferStreams,
|
|
2532
2549
|
terminate() {
|
|
2533
2550
|
return new Promise(resolve => {
|
|
@@ -2563,7 +2580,7 @@
|
|
|
2563
2580
|
// deno-lint-ignore valid-typeof
|
|
2564
2581
|
webWorkerSupported = typeof Worker != UNDEFINED_TYPE;
|
|
2565
2582
|
}
|
|
2566
|
-
return (useWebWorkers && webWorkerSupported ? createWebWorkerInterface : createWorkerInterface)(workerData, config);
|
|
2583
|
+
return (useWebWorkers && ((webWorkerSupported && workerURI) || createWorker) ? createWebWorkerInterface : createWorkerInterface)(workerData, config);
|
|
2567
2584
|
}
|
|
2568
2585
|
}
|
|
2569
2586
|
|
|
@@ -2620,7 +2637,11 @@
|
|
|
2620
2637
|
try {
|
|
2621
2638
|
worker = getWebWorker(workerData.workerURI, baseURI, workerData);
|
|
2622
2639
|
} catch {
|
|
2623
|
-
|
|
2640
|
+
if (workerData.createWorker) {
|
|
2641
|
+
createWorkerFailed = true;
|
|
2642
|
+
} else {
|
|
2643
|
+
webWorkerSupported = false;
|
|
2644
|
+
}
|
|
2624
2645
|
return createWorkerInterface(workerData, config);
|
|
2625
2646
|
}
|
|
2626
2647
|
Object.assign(workerData, {
|
|
@@ -2633,7 +2654,11 @@
|
|
|
2633
2654
|
return await runWebWorker(workerData, { chunkSize, wasmURI, baseURI, workerStartupTimeout });
|
|
2634
2655
|
} catch (error) {
|
|
2635
2656
|
if (error && error.workerStartupFailed) {
|
|
2636
|
-
|
|
2657
|
+
if (workerData.createWorker) {
|
|
2658
|
+
createWorkerFailed = true;
|
|
2659
|
+
} else {
|
|
2660
|
+
webWorkerSupported = false;
|
|
2661
|
+
}
|
|
2637
2662
|
const { reader } = workerData;
|
|
2638
2663
|
if (reader) {
|
|
2639
2664
|
reader.releaseLock();
|
|
@@ -2656,17 +2681,17 @@
|
|
|
2656
2681
|
try {
|
|
2657
2682
|
if (options.compressed && !options.format) {
|
|
2658
2683
|
const deflate = options.codecType.startsWith(CODEC_DEFLATE);
|
|
2659
|
-
const
|
|
2684
|
+
const FallbackStream = deflate ? config.CompressionStreamFallback : config.DecompressionStreamFallback;
|
|
2660
2685
|
const NativeStream = deflate ? config.CompressionStream : config.DecompressionStream;
|
|
2661
2686
|
if (!options.useCompressionStream) {
|
|
2662
2687
|
try {
|
|
2663
2688
|
await initModule$1(config);
|
|
2664
2689
|
} catch {
|
|
2665
|
-
if (!
|
|
2690
|
+
if (!FallbackStream || FallbackStream.requiresModule) {
|
|
2666
2691
|
options.useCompressionStream = true;
|
|
2667
2692
|
}
|
|
2668
2693
|
}
|
|
2669
|
-
} else if (
|
|
2694
|
+
} else if (FallbackStream && FallbackStream.requiresModule && !supportsDeflateRaw(NativeStream)) {
|
|
2670
2695
|
try {
|
|
2671
2696
|
await initModule$1(config);
|
|
2672
2697
|
} catch {
|
|
@@ -2680,12 +2705,12 @@
|
|
|
2680
2705
|
.pipeThrough(new ChunkStream(getChunkSize(config)))
|
|
2681
2706
|
.pipeTo(writable, { preventClose: true, preventAbort: true });
|
|
2682
2707
|
const {
|
|
2683
|
-
|
|
2708
|
+
crc32,
|
|
2684
2709
|
inputSize,
|
|
2685
2710
|
outputSize
|
|
2686
2711
|
} = codecStream;
|
|
2687
2712
|
return {
|
|
2688
|
-
|
|
2713
|
+
crc32,
|
|
2689
2714
|
inputSize,
|
|
2690
2715
|
outputSize
|
|
2691
2716
|
};
|
|
@@ -2791,8 +2816,11 @@
|
|
|
2791
2816
|
}
|
|
2792
2817
|
|
|
2793
2818
|
function getWebWorker(url, baseURI, workerData, isModuleType, useBlobURI = true) {
|
|
2819
|
+
const { createWorker } = workerData;
|
|
2794
2820
|
let worker, resolvedURI, resolvedOptions;
|
|
2795
|
-
if (
|
|
2821
|
+
if (createWorker) {
|
|
2822
|
+
worker = createWorker();
|
|
2823
|
+
} else if (webWorkerURI === UNDEFINED_VALUE || webWorkerSource !== url) {
|
|
2796
2824
|
// deno-lint-ignore valid-typeof
|
|
2797
2825
|
const isFunctionURI = typeof url == FUNCTION_TYPE;
|
|
2798
2826
|
if (isFunctionURI) {
|
|
@@ -3047,7 +3075,7 @@
|
|
|
3047
3075
|
async function runWorker(stream, workerOptions) {
|
|
3048
3076
|
const { options, config } = workerOptions;
|
|
3049
3077
|
const { transferStreams, useWebWorkers, useCompressionStream, compressed, checkCrc32, computeCrc32, encrypted, format, codecURI } = options;
|
|
3050
|
-
const { workerURI, maxWorkers } = config;
|
|
3078
|
+
const { workerURI, createWorker, maxWorkers } = config;
|
|
3051
3079
|
if (format) {
|
|
3052
3080
|
if (codecURI) {
|
|
3053
3081
|
options.codecURI = resolveCodecURI(codecURI, config.baseURI);
|
|
@@ -3059,6 +3087,7 @@
|
|
|
3059
3087
|
const workerSupported = format === UNDEFINED_VALUE || Boolean(options.codecURI);
|
|
3060
3088
|
workerOptions.useWebWorkers = !streamCopy && workerSupported && (useWebWorkers || (useWebWorkers === UNDEFINED_VALUE && config.useWebWorkers));
|
|
3061
3089
|
workerOptions.workerURI = workerOptions.useWebWorkers && workerURI ? workerURI : UNDEFINED_VALUE;
|
|
3090
|
+
workerOptions.createWorker = workerOptions.useWebWorkers && createWorker ? createWorker : UNDEFINED_VALUE;
|
|
3062
3091
|
options.useCompressionStream = useCompressionStream || (useCompressionStream === UNDEFINED_VALUE && config.useCompressionStream);
|
|
3063
3092
|
return (await getWorker()).run();
|
|
3064
3093
|
|
|
@@ -3122,7 +3151,7 @@
|
|
|
3122
3151
|
starvationTimeout = null;
|
|
3123
3152
|
if (pendingRequests.length) {
|
|
3124
3153
|
const [{ resolve, stream, workerOptions }] = pendingRequests.splice(0, 1);
|
|
3125
|
-
const inlineWorkerOptions = Object.assign({}, workerOptions, { useWebWorkers: false, workerURI: UNDEFINED_VALUE });
|
|
3154
|
+
const inlineWorkerOptions = Object.assign({}, workerOptions, { useWebWorkers: false, workerURI: UNDEFINED_VALUE, createWorker: UNDEFINED_VALUE });
|
|
3126
3155
|
resolve(new CodecWorker({}, stream, inlineWorkerOptions, onInlineTaskFinished));
|
|
3127
3156
|
armStarvationTimeout();
|
|
3128
3157
|
}
|
|
@@ -4283,6 +4312,8 @@
|
|
|
4283
4312
|
const PROPERTY_NAME_EXTRA_FIELD = "extraField";
|
|
4284
4313
|
const PROPERTY_NAME_EXTRA_FIELD_INFOZIP = "extraFieldInfoZip";
|
|
4285
4314
|
const PROPERTY_NAME_EXTRA_FIELD_UNIX = "extraFieldUnix";
|
|
4315
|
+
const PROPERTY_NAME_EXTRA_FIELD_UNIX_TYPE1 = "extraFieldUnixType1";
|
|
4316
|
+
const PROPERTY_NAME_EXTRA_FIELD_PKWARE_UNIX = "extraFieldPkwareUnix";
|
|
4286
4317
|
const PROPERTY_NAME_UID = "uid";
|
|
4287
4318
|
const PROPERTY_NAME_GID = "gid";
|
|
4288
4319
|
const PROPERTY_NAME_UNIX_MODE = "unixMode";
|
|
@@ -4299,6 +4330,7 @@
|
|
|
4299
4330
|
const PROPERTY_NAME_EXTRA_FIELD_AES = "extraFieldAES";
|
|
4300
4331
|
const PROPERTY_NAME_EXTRA_FIELD_NTFS = "extraFieldNTFS";
|
|
4301
4332
|
const PROPERTY_NAME_EXTRA_FIELD_EXTENDED_TIMESTAMP = "extraFieldExtendedTimestamp";
|
|
4333
|
+
const PROPERTY_NAME_EXTRA_FIELD_USDZ = "extraFieldUSDZ";
|
|
4302
4334
|
|
|
4303
4335
|
const PROPERTY_NAMES = [
|
|
4304
4336
|
PROPERTY_NAME_FILENAME,
|
|
@@ -4310,6 +4342,7 @@
|
|
|
4310
4342
|
PROPERTY_NAME_COMMENT,
|
|
4311
4343
|
PROPERTY_NAME_RAW_COMMENT,
|
|
4312
4344
|
PROPERTY_NAME_LAST_ACCESS_DATE,
|
|
4345
|
+
PROPERTY_NAME_RAW_LAST_ACCESS_DATE,
|
|
4313
4346
|
PROPERTY_NAME_CREATION_DATE,
|
|
4314
4347
|
PROPERTY_NAME_RAW_CREATION_DATE,
|
|
4315
4348
|
PROPERTY_NAME_OFFSET,
|
|
@@ -4332,6 +4365,8 @@
|
|
|
4332
4365
|
PROPERTY_NAME_EXTRA_FIELD,
|
|
4333
4366
|
PROPERTY_NAME_EXTRA_FIELD_UNIX,
|
|
4334
4367
|
PROPERTY_NAME_EXTRA_FIELD_INFOZIP,
|
|
4368
|
+
PROPERTY_NAME_EXTRA_FIELD_UNIX_TYPE1,
|
|
4369
|
+
PROPERTY_NAME_EXTRA_FIELD_PKWARE_UNIX,
|
|
4335
4370
|
PROPERTY_NAME_UID,
|
|
4336
4371
|
PROPERTY_NAME_GID,
|
|
4337
4372
|
PROPERTY_NAME_UNIX_MODE,
|
|
@@ -4347,7 +4382,8 @@
|
|
|
4347
4382
|
PROPERTY_NAME_EXTRA_FIELD_UNICODE_COMMENT,
|
|
4348
4383
|
PROPERTY_NAME_EXTRA_FIELD_AES,
|
|
4349
4384
|
PROPERTY_NAME_EXTRA_FIELD_NTFS,
|
|
4350
|
-
PROPERTY_NAME_EXTRA_FIELD_EXTENDED_TIMESTAMP
|
|
4385
|
+
PROPERTY_NAME_EXTRA_FIELD_EXTENDED_TIMESTAMP,
|
|
4386
|
+
PROPERTY_NAME_EXTRA_FIELD_USDZ
|
|
4351
4387
|
];
|
|
4352
4388
|
|
|
4353
4389
|
class Entry {
|
|
@@ -4421,6 +4457,7 @@
|
|
|
4421
4457
|
const OPTION_OFFSET = "offset";
|
|
4422
4458
|
const OPTION_USDZ = "usdz";
|
|
4423
4459
|
const OPTION_UNIX_EXTRA_FIELD_TYPE = "unixExtraFieldType";
|
|
4460
|
+
const OPTION_LOCAL_EXTRA_FIELD = "localExtraField";
|
|
4424
4461
|
const OPTION_STRICTNESS = "strictness";
|
|
4425
4462
|
const OPTION_MAX_APPENDED_DATA_SIZE = "maxAppendedDataSize";
|
|
4426
4463
|
const STRICTNESS_STRICT = "strict";
|
|
@@ -4473,7 +4510,7 @@
|
|
|
4473
4510
|
const PROPERTY_NAME_UTF8_SUFFIX = "UTF8";
|
|
4474
4511
|
const CHARSET_CP437 = "cp437";
|
|
4475
4512
|
const BITFLAG_AMBIGUITY_MASK = BITFLAG_ENCRYPTED | BITFLAG_DATA_DESCRIPTOR | BITFLAG_LANG_ENCODING_FLAG;
|
|
4476
|
-
const VENDOR_VERSION_AE_1 = 1;
|
|
4513
|
+
const VENDOR_VERSION_AE_1$1 = 1;
|
|
4477
4514
|
const ZIP64_PROPERTIES = [
|
|
4478
4515
|
[PROPERTY_NAME_UNCOMPRESSED_SIZE, MAX_32_BITS],
|
|
4479
4516
|
[PROPERTY_NAME_COMPRESSED_SIZE, MAX_32_BITS],
|
|
@@ -4866,7 +4903,7 @@
|
|
|
4866
4903
|
config,
|
|
4867
4904
|
bitFlag,
|
|
4868
4905
|
rawBitFlag,
|
|
4869
|
-
|
|
4906
|
+
crc32,
|
|
4870
4907
|
rawLastModDate,
|
|
4871
4908
|
uncompressedSize,
|
|
4872
4909
|
compressedSize
|
|
@@ -4957,7 +4994,7 @@
|
|
|
4957
4994
|
const checkCrc32 = (checkCrc32Option === UNDEFINED_VALUE ?
|
|
4958
4995
|
getOptionValue$1(zipEntry, options, OPTION_CHECK_SIGNATURE) :
|
|
4959
4996
|
checkCrc32Option) && !passThrough &&
|
|
4960
|
-
(!encrypted || zipCrypto || (extraFieldAES && extraFieldAES.vendorVersion == VENDOR_VERSION_AE_1));
|
|
4997
|
+
(!encrypted || zipCrypto || (extraFieldAES && extraFieldAES.vendorVersion == VENDOR_VERSION_AE_1$1));
|
|
4961
4998
|
const workerOptions = {
|
|
4962
4999
|
options: {
|
|
4963
5000
|
codecType: CODEC_INFLATE,
|
|
@@ -4967,9 +5004,9 @@
|
|
|
4967
5004
|
encryptionStrength: extraFieldAES && extraFieldAES.strength,
|
|
4968
5005
|
checkCrc32,
|
|
4969
5006
|
checkAuthenticationCode: getOptionValue$1(zipEntry, options, OPTION_CHECK_AUTHENTICATION_CODE),
|
|
4970
|
-
passwordVerification: zipCrypto && (dataDescriptor ? ((rawLastModDate >>> 8) & MAX_8_BITS) : ((
|
|
5007
|
+
passwordVerification: zipCrypto && (dataDescriptor ? ((rawLastModDate >>> 8) & MAX_8_BITS) : ((crc32 >>> 24) & MAX_8_BITS)),
|
|
4971
5008
|
outputSize: passThrough ? compressedSize : uncompressedSize,
|
|
4972
|
-
|
|
5009
|
+
crc32,
|
|
4973
5010
|
compressed: compressionMethod != 0 && !passThrough,
|
|
4974
5011
|
encrypted,
|
|
4975
5012
|
useWebWorkers: getOptionValue$1(zipEntry, options, OPTION_USE_WEB_WORKERS),
|
|
@@ -4991,7 +5028,7 @@
|
|
|
4991
5028
|
fileEntry,
|
|
4992
5029
|
index,
|
|
4993
5030
|
offset: localHeaderOffset,
|
|
4994
|
-
|
|
5031
|
+
crc32,
|
|
4995
5032
|
compressedSize,
|
|
4996
5033
|
uncompressedSize,
|
|
4997
5034
|
dataOffset,
|
|
@@ -5108,6 +5145,16 @@
|
|
|
5108
5145
|
} else {
|
|
5109
5146
|
directory.compressionMethod = compressionMethod;
|
|
5110
5147
|
}
|
|
5148
|
+
const extraFieldPkwareUnix = extraField.get(EXTRAFIELD_TYPE_PKWARE_UNIX);
|
|
5149
|
+
if (extraFieldPkwareUnix) {
|
|
5150
|
+
readExtraFieldUnixDates(extraFieldPkwareUnix, directory);
|
|
5151
|
+
directory.extraFieldPkwareUnix = extraFieldPkwareUnix;
|
|
5152
|
+
}
|
|
5153
|
+
const extraFieldUnixType1 = extraField.get(EXTRAFIELD_TYPE_UNIX_TYPE1);
|
|
5154
|
+
if (extraFieldUnixType1) {
|
|
5155
|
+
readExtraFieldUnixDates(extraFieldUnixType1, directory);
|
|
5156
|
+
directory.extraFieldUnixType1 = extraFieldUnixType1;
|
|
5157
|
+
}
|
|
5111
5158
|
const extraFieldNTFS = extraField.get(EXTRAFIELD_TYPE_NTFS);
|
|
5112
5159
|
if (extraFieldNTFS) {
|
|
5113
5160
|
readExtraFieldNTFS(extraFieldNTFS, directory);
|
|
@@ -5157,15 +5204,15 @@
|
|
|
5157
5204
|
return;
|
|
5158
5205
|
}
|
|
5159
5206
|
const extraFieldView = getDataView(extraFieldUnicode.data);
|
|
5160
|
-
const
|
|
5161
|
-
|
|
5162
|
-
const
|
|
5163
|
-
|
|
5164
|
-
const
|
|
5207
|
+
const computedCrc32 = new Crc32();
|
|
5208
|
+
computedCrc32.append(fileEntry[rawPropertyName]);
|
|
5209
|
+
const computedCrc32View = getDataView(new Uint8Array(4));
|
|
5210
|
+
computedCrc32View.setUint32(0, computedCrc32.get(), true);
|
|
5211
|
+
const nameCrc32 = getUint32(extraFieldView, 1);
|
|
5165
5212
|
Object.assign(extraFieldUnicode, {
|
|
5166
5213
|
version: getUint8(extraFieldView, 0),
|
|
5167
5214
|
[propertyName]: decodeText(extraFieldUnicode.data.subarray(5)),
|
|
5168
|
-
valid: !fileEntry.bitFlag.languageEncodingFlag &&
|
|
5215
|
+
valid: !fileEntry.bitFlag.languageEncodingFlag && nameCrc32 == getUint32(computedCrc32View, 0)
|
|
5169
5216
|
});
|
|
5170
5217
|
if (extraFieldUnicode.valid) {
|
|
5171
5218
|
directory[propertyName] = extraFieldUnicode[propertyName];
|
|
@@ -5184,7 +5231,7 @@
|
|
|
5184
5231
|
compressionMethod: getUint16(extraFieldView, 5)
|
|
5185
5232
|
});
|
|
5186
5233
|
directory.compressionMethod = extraFieldAES.compressionMethod;
|
|
5187
|
-
if (extraFieldAES.vendorVersion != VENDOR_VERSION_AE_1) {
|
|
5234
|
+
if (extraFieldAES.vendorVersion != VENDOR_VERSION_AE_1$1) {
|
|
5188
5235
|
directory.crc32 = UNDEFINED_VALUE;
|
|
5189
5236
|
}
|
|
5190
5237
|
}
|
|
@@ -5224,6 +5271,22 @@
|
|
|
5224
5271
|
}
|
|
5225
5272
|
}
|
|
5226
5273
|
|
|
5274
|
+
function readExtraFieldUnixDates(extraField, directory) {
|
|
5275
|
+
if (extraField.data.length < 8) {
|
|
5276
|
+
return;
|
|
5277
|
+
}
|
|
5278
|
+
const extraFieldView = getDataView(extraField.data);
|
|
5279
|
+
const lastAccessDate = new Date(getUint32(extraFieldView, 0) * 1000);
|
|
5280
|
+
const lastModDate = new Date(getUint32(extraFieldView, 4) * 1000);
|
|
5281
|
+
const extraFieldData = { lastAccessDate, lastModDate };
|
|
5282
|
+
if (extraField.data.length >= 12) {
|
|
5283
|
+
extraFieldData.uid = getUint16(extraFieldView, 8);
|
|
5284
|
+
extraFieldData.gid = getUint16(extraFieldView, 10);
|
|
5285
|
+
}
|
|
5286
|
+
Object.assign(extraField, extraFieldData);
|
|
5287
|
+
Object.assign(directory, extraFieldData);
|
|
5288
|
+
}
|
|
5289
|
+
|
|
5227
5290
|
function readExtraFieldUnix(extraField, directory, isInfoZip) {
|
|
5228
5291
|
try {
|
|
5229
5292
|
const view = getDataView(extraField.data);
|
|
@@ -5302,7 +5365,7 @@
|
|
|
5302
5365
|
fileEntry,
|
|
5303
5366
|
index,
|
|
5304
5367
|
offset,
|
|
5305
|
-
|
|
5368
|
+
crc32,
|
|
5306
5369
|
compressedSize,
|
|
5307
5370
|
uncompressedSize,
|
|
5308
5371
|
dataOffset,
|
|
@@ -5323,7 +5386,7 @@
|
|
|
5323
5386
|
const dataDescriptorSignature = dataDescriptorArray.length == dataDescriptorLength + DATA_DESCRIPTOR_RECORD_SIGNATURE_LENGTH &&
|
|
5324
5387
|
getUint32(getDataView(dataDescriptorArray), 0) == DATA_DESCRIPTOR_RECORD_SIGNATURE;
|
|
5325
5388
|
if (dataDescriptorSignature) {
|
|
5326
|
-
const
|
|
5389
|
+
const readCrc32 = getUint32(getDataView(dataDescriptorArray), 4);
|
|
5327
5390
|
let readCompressedSize;
|
|
5328
5391
|
let readUncompressedSize;
|
|
5329
5392
|
if (extraFieldZip64) {
|
|
@@ -5333,8 +5396,8 @@
|
|
|
5333
5396
|
readCompressedSize = getUint32(getDataView(dataDescriptorArray), 8);
|
|
5334
5397
|
readUncompressedSize = getUint32(getDataView(dataDescriptorArray), 12);
|
|
5335
5398
|
}
|
|
5336
|
-
const
|
|
5337
|
-
if (
|
|
5399
|
+
const matchCrc32 = (fileEntry.encrypted && !fileEntry.zipCrypto) || readCrc32 == crc32;
|
|
5400
|
+
if (matchCrc32 &&
|
|
5338
5401
|
readCompressedSize == compressedSize &&
|
|
5339
5402
|
readUncompressedSize == uncompressedSize) {
|
|
5340
5403
|
dataDescriptorLength += DATA_DESCRIPTOR_RECORD_SIGNATURE_LENGTH;
|
|
@@ -5503,11 +5566,11 @@
|
|
|
5503
5566
|
throwAmbiguousArchive("mismatched local file header (compression method)");
|
|
5504
5567
|
}
|
|
5505
5568
|
if (!localDirectory.bitFlag.dataDescriptor &&
|
|
5506
|
-
(localDirectory.
|
|
5507
|
-
(localDirectory.
|
|
5569
|
+
(localDirectory.crc32 || localDirectory.compressedSize || localDirectory.uncompressedSize) &&
|
|
5570
|
+
(localDirectory.crc32 != zipEntry.crc32 ||
|
|
5508
5571
|
localDirectory.compressedSize != zipEntry.compressedSize ||
|
|
5509
5572
|
localDirectory.uncompressedSize != zipEntry.uncompressedSize)) {
|
|
5510
|
-
throwAmbiguousArchive("mismatched local file header (
|
|
5573
|
+
throwAmbiguousArchive("mismatched local file header (crc32 or sizes)");
|
|
5511
5574
|
}
|
|
5512
5575
|
}
|
|
5513
5576
|
|
|
@@ -5627,7 +5690,9 @@
|
|
|
5627
5690
|
const ERR_INVALID_MSDOS_DATA = "Invalid msdosAttributes (must be an object with boolean flags)";
|
|
5628
5691
|
|
|
5629
5692
|
const EXTRAFIELD_DATA_AES = new Uint8Array([0x07, 0x00, 0x02, 0x00, 0x41, 0x45, 0x03, 0x00, 0x00]);
|
|
5630
|
-
const
|
|
5693
|
+
const EXTRAFIELD_OFFSET_AES_VENDOR_VERSION = 4;
|
|
5694
|
+
const VENDOR_VERSION_AE_1 = 1;
|
|
5695
|
+
const INFOZIP_EXTRA_FIELD_TYPE$1 = "infozip";
|
|
5631
5696
|
const UNIX_EXTRA_FIELD_TYPE = "unix";
|
|
5632
5697
|
|
|
5633
5698
|
let workers = 0;
|
|
@@ -5721,9 +5786,9 @@
|
|
|
5721
5786
|
zip64UncompressedSize,
|
|
5722
5787
|
extraFieldLength
|
|
5723
5788
|
});
|
|
5724
|
-
const {
|
|
5725
|
-
if (
|
|
5726
|
-
setUint32(headerView, HEADER_OFFSET_SIGNATURE,
|
|
5789
|
+
const { crc32 } = entry;
|
|
5790
|
+
if (crc32 !== UNDEFINED_VALUE) {
|
|
5791
|
+
setUint32(headerView, HEADER_OFFSET_SIGNATURE, crc32);
|
|
5727
5792
|
}
|
|
5728
5793
|
Object.assign(entry, {
|
|
5729
5794
|
zip64UncompressedSize,
|
|
@@ -5908,6 +5973,7 @@
|
|
|
5908
5973
|
internalFileAttribute: metadataInfo.resolvedOptions.internalFileAttributes,
|
|
5909
5974
|
externalFileAttribute: attributesInfo.resolvedOptions.externalFileAttributes,
|
|
5910
5975
|
signature: options[PROPERTY_NAME_SIGNATURE],
|
|
5976
|
+
crc32: options.crc32 === UNDEFINED_VALUE ? options[PROPERTY_NAME_SIGNATURE] : options.crc32,
|
|
5911
5977
|
offset: zipWriter.offset - diskOffset,
|
|
5912
5978
|
diskNumberStart: diskNumber
|
|
5913
5979
|
});
|
|
@@ -5944,7 +6010,7 @@
|
|
|
5944
6010
|
if (unixMode !== UNDEFINED_VALUE && (unixMode < 0 || unixMode > MAX_16_BITS)) {
|
|
5945
6011
|
throw new Error(ERR_INVALID_UNIX_MODE);
|
|
5946
6012
|
}
|
|
5947
|
-
if (unixExtraFieldType !== UNDEFINED_VALUE && unixExtraFieldType !== INFOZIP_EXTRA_FIELD_TYPE && unixExtraFieldType !== UNIX_EXTRA_FIELD_TYPE) {
|
|
6013
|
+
if (unixExtraFieldType !== UNDEFINED_VALUE && unixExtraFieldType !== INFOZIP_EXTRA_FIELD_TYPE$1 && unixExtraFieldType !== UNIX_EXTRA_FIELD_TYPE) {
|
|
5948
6014
|
throw new Error(ERR_INVALID_UNIX_EXTRA_FIELD_TYPE);
|
|
5949
6015
|
}
|
|
5950
6016
|
if (unixExtraFieldType === UNIX_EXTRA_FIELD_TYPE &&
|
|
@@ -5952,7 +6018,7 @@
|
|
|
5952
6018
|
throw new Error(ERR_INVALID_UNIX_ID_SIZE);
|
|
5953
6019
|
}
|
|
5954
6020
|
if (unixExtraFieldType === UNDEFINED_VALUE && (uid !== UNDEFINED_VALUE || gid !== UNDEFINED_VALUE)) {
|
|
5955
|
-
unixExtraFieldType = INFOZIP_EXTRA_FIELD_TYPE;
|
|
6021
|
+
unixExtraFieldType = INFOZIP_EXTRA_FIELD_TYPE$1;
|
|
5956
6022
|
}
|
|
5957
6023
|
let msdosAttributesRaw = getOptionValue(zipWriter, options, PROPERTY_NAME_MSDOS_ATTRIBUTES_RAW);
|
|
5958
6024
|
let msdosAttributes = getOptionValue(zipWriter, options, PROPERTY_NAME_MSDOS_ATTRIBUTES);
|
|
@@ -6124,27 +6190,8 @@
|
|
|
6124
6190
|
if (!zipCrypto && (password !== UNDEFINED_VALUE || rawPassword !== UNDEFINED_VALUE) && !(encryptionStrength >= 1 && encryptionStrength <= 3)) {
|
|
6125
6191
|
throw new Error(ERR_INVALID_ENCRYPTION_STRENGTH);
|
|
6126
6192
|
}
|
|
6127
|
-
|
|
6128
|
-
const
|
|
6129
|
-
if (extraField) {
|
|
6130
|
-
let extraFieldSize = 0;
|
|
6131
|
-
let offset = 0;
|
|
6132
|
-
extraField.forEach(data => extraFieldSize += 4 + getLength(data));
|
|
6133
|
-
rawExtraField = new Uint8Array(extraFieldSize);
|
|
6134
|
-
const rawExtraFieldView = getDataView(rawExtraField);
|
|
6135
|
-
extraField.forEach((data, type) => {
|
|
6136
|
-
if (type > MAX_16_BITS) {
|
|
6137
|
-
throw new Error(ERR_INVALID_EXTRAFIELD_TYPE);
|
|
6138
|
-
}
|
|
6139
|
-
if (getLength(data) > MAX_16_BITS) {
|
|
6140
|
-
throw new Error(ERR_INVALID_EXTRAFIELD_DATA);
|
|
6141
|
-
}
|
|
6142
|
-
setUint16(rawExtraFieldView, offset, type);
|
|
6143
|
-
setUint16(rawExtraFieldView, offset + 2, getLength(data));
|
|
6144
|
-
arraySet(rawExtraField, data, offset + 4);
|
|
6145
|
-
offset += 4 + getLength(data);
|
|
6146
|
-
});
|
|
6147
|
-
}
|
|
6193
|
+
const rawExtraField = serializeExtraField(options[PROPERTY_NAME_EXTRA_FIELD]);
|
|
6194
|
+
const rawLocalExtraField = serializeExtraField(options[OPTION_LOCAL_EXTRA_FIELD]);
|
|
6148
6195
|
return {
|
|
6149
6196
|
comment,
|
|
6150
6197
|
resolvedOptions: {
|
|
@@ -6178,11 +6225,36 @@
|
|
|
6178
6225
|
useCompressionStream,
|
|
6179
6226
|
dataDescriptor,
|
|
6180
6227
|
zip64,
|
|
6181
|
-
rawExtraField
|
|
6228
|
+
rawExtraField,
|
|
6229
|
+
rawLocalExtraField
|
|
6182
6230
|
}
|
|
6183
6231
|
};
|
|
6184
6232
|
}
|
|
6185
6233
|
|
|
6234
|
+
function serializeExtraField(extraField) {
|
|
6235
|
+
if (!extraField) {
|
|
6236
|
+
return EMPTY_UINT8_ARRAY;
|
|
6237
|
+
}
|
|
6238
|
+
let extraFieldSize = 0;
|
|
6239
|
+
let offset = 0;
|
|
6240
|
+
extraField.forEach(data => extraFieldSize += 4 + getLength(data));
|
|
6241
|
+
const rawExtraField = new Uint8Array(extraFieldSize);
|
|
6242
|
+
const rawExtraFieldView = getDataView(rawExtraField);
|
|
6243
|
+
extraField.forEach((data, type) => {
|
|
6244
|
+
if (type > MAX_16_BITS) {
|
|
6245
|
+
throw new Error(ERR_INVALID_EXTRAFIELD_TYPE);
|
|
6246
|
+
}
|
|
6247
|
+
if (getLength(data) > MAX_16_BITS) {
|
|
6248
|
+
throw new Error(ERR_INVALID_EXTRAFIELD_DATA);
|
|
6249
|
+
}
|
|
6250
|
+
setUint16(rawExtraFieldView, offset, type);
|
|
6251
|
+
setUint16(rawExtraFieldView, offset + 2, getLength(data));
|
|
6252
|
+
arraySet(rawExtraField, data, offset + 4);
|
|
6253
|
+
offset += 4 + getLength(data);
|
|
6254
|
+
});
|
|
6255
|
+
return rawExtraField;
|
|
6256
|
+
}
|
|
6257
|
+
|
|
6186
6258
|
async function resolveSizes(zipWriter, reader, { resolvedOptions: metadata }, options) {
|
|
6187
6259
|
const { passThrough, zipCrypto, password, rawPassword, encryptionStrength } = metadata;
|
|
6188
6260
|
let { dataDescriptor, zip64, level, compressionMethod } = metadata;
|
|
@@ -6507,12 +6579,9 @@
|
|
|
6507
6579
|
msdosAttributes
|
|
6508
6580
|
};
|
|
6509
6581
|
let {
|
|
6510
|
-
crc32
|
|
6582
|
+
crc32,
|
|
6511
6583
|
uncompressedSize
|
|
6512
6584
|
} = options;
|
|
6513
|
-
if (signature === UNDEFINED_VALUE) {
|
|
6514
|
-
({ signature } = options);
|
|
6515
|
-
}
|
|
6516
6585
|
let compressedSize = 0;
|
|
6517
6586
|
if (!passThrough) {
|
|
6518
6587
|
uncompressedSize = 0;
|
|
@@ -6550,7 +6619,7 @@
|
|
|
6550
6619
|
if (!passThrough) {
|
|
6551
6620
|
uncompressedSize = result.inputSize;
|
|
6552
6621
|
if (!encrypted || zipCrypto) {
|
|
6553
|
-
|
|
6622
|
+
crc32 = result.crc32;
|
|
6554
6623
|
}
|
|
6555
6624
|
}
|
|
6556
6625
|
if ((!zip64CompressedSize && compressedSize >= MAX_32_BITS) ||
|
|
@@ -6566,7 +6635,7 @@
|
|
|
6566
6635
|
|
|
6567
6636
|
}
|
|
6568
6637
|
setEntryInfo({
|
|
6569
|
-
|
|
6638
|
+
crc32,
|
|
6570
6639
|
compressedSize,
|
|
6571
6640
|
uncompressedSize,
|
|
6572
6641
|
headerInfo,
|
|
@@ -6589,8 +6658,8 @@
|
|
|
6589
6658
|
version,
|
|
6590
6659
|
headerArray,
|
|
6591
6660
|
headerView,
|
|
6592
|
-
signature,
|
|
6593
|
-
crc32: encrypted && !zipCrypto ? UNDEFINED_VALUE :
|
|
6661
|
+
signature: crc32,
|
|
6662
|
+
crc32: encrypted && !zipCrypto && !passThrough ? UNDEFINED_VALUE : crc32,
|
|
6594
6663
|
extraFieldExtendedTimestampFlag,
|
|
6595
6664
|
zip64UncompressedSize,
|
|
6596
6665
|
zip64CompressedSize
|
|
@@ -6611,6 +6680,7 @@
|
|
|
6611
6680
|
dataDescriptor,
|
|
6612
6681
|
directory,
|
|
6613
6682
|
rawExtraField,
|
|
6683
|
+
rawLocalExtraField,
|
|
6614
6684
|
encryptionStrength,
|
|
6615
6685
|
extendedTimestamp,
|
|
6616
6686
|
ntfsTimestamp,
|
|
@@ -6618,7 +6688,8 @@
|
|
|
6618
6688
|
encrypted,
|
|
6619
6689
|
zip64UncompressedSize,
|
|
6620
6690
|
zip64CompressedSize,
|
|
6621
|
-
uncompressedSize
|
|
6691
|
+
uncompressedSize,
|
|
6692
|
+
crc32
|
|
6622
6693
|
} = options;
|
|
6623
6694
|
let { version, compressionMethod } = options;
|
|
6624
6695
|
const compressed = !directory && (compressionMethod === UNDEFINED_VALUE
|
|
@@ -6706,7 +6777,7 @@
|
|
|
6706
6777
|
let rawExtraFieldUnix;
|
|
6707
6778
|
try {
|
|
6708
6779
|
const { uid, gid, unixExtraFieldType } = options;
|
|
6709
|
-
if (unixExtraFieldType == INFOZIP_EXTRA_FIELD_TYPE && (uid !== UNDEFINED_VALUE || gid !== UNDEFINED_VALUE)) {
|
|
6780
|
+
if (unixExtraFieldType == INFOZIP_EXTRA_FIELD_TYPE$1 && (uid !== UNDEFINED_VALUE || gid !== UNDEFINED_VALUE)) {
|
|
6710
6781
|
const uidBytes = packUnixId(uid);
|
|
6711
6782
|
const gidBytes = packUnixId(gid);
|
|
6712
6783
|
const payloadLength = 3 + uidBytes.length + gidBytes.length;
|
|
@@ -6744,11 +6815,14 @@
|
|
|
6744
6815
|
}
|
|
6745
6816
|
if (encrypted && !zipCrypto) {
|
|
6746
6817
|
version = version > VERSION_AES ? version : VERSION_AES;
|
|
6818
|
+
if (passThrough && crc32 !== UNDEFINED_VALUE) {
|
|
6819
|
+
rawExtraFieldAES[EXTRAFIELD_OFFSET_AES_VENDOR_VERSION] = VENDOR_VERSION_AE_1;
|
|
6820
|
+
}
|
|
6747
6821
|
rawExtraFieldAES[9] = compressionMethod;
|
|
6748
6822
|
compressionMethod = COMPRESSION_METHOD_AES;
|
|
6749
6823
|
}
|
|
6750
6824
|
const localExtraFieldZip64Length = writeLocalExtraFieldZip64 ? getLength(rawLocalExtraFieldZip64) : 0;
|
|
6751
|
-
const extraFieldLength = localExtraFieldZip64Length + getLength(rawExtraFieldAES, rawExtraFieldExtendedTimestamp, rawExtraFieldNTFS, rawExtraFieldUnix, rawExtraField);
|
|
6825
|
+
const extraFieldLength = localExtraFieldZip64Length + getLength(rawExtraFieldAES, rawExtraFieldExtendedTimestamp, rawExtraFieldNTFS, rawExtraFieldUnix, rawExtraField, rawLocalExtraField);
|
|
6752
6826
|
if (extraFieldLength > MAX_16_BITS) {
|
|
6753
6827
|
throw new Error(ERR_INVALID_EXTRAFIELD_DATA);
|
|
6754
6828
|
}
|
|
@@ -6782,6 +6856,7 @@
|
|
|
6782
6856
|
localHeader.bytes(rawExtraFieldNTFS);
|
|
6783
6857
|
localHeader.bytes(rawExtraFieldUnix);
|
|
6784
6858
|
localHeader.bytes(rawExtraField);
|
|
6859
|
+
localHeader.bytes(rawLocalExtraField);
|
|
6785
6860
|
if (dataDescriptor) {
|
|
6786
6861
|
if (!zip64CompressedSize) {
|
|
6787
6862
|
setUint32(localHeaderView, HEADER_OFFSET_COMPRESSED_SIZE + LOCAL_HEADER_COMMON_OFFSET, 0);
|
|
@@ -6900,7 +6975,7 @@
|
|
|
6900
6975
|
}
|
|
6901
6976
|
|
|
6902
6977
|
function setEntryInfo({
|
|
6903
|
-
|
|
6978
|
+
crc32,
|
|
6904
6979
|
compressedSize,
|
|
6905
6980
|
uncompressedSize,
|
|
6906
6981
|
headerInfo,
|
|
@@ -6908,6 +6983,7 @@
|
|
|
6908
6983
|
}, {
|
|
6909
6984
|
zip64,
|
|
6910
6985
|
zipCrypto,
|
|
6986
|
+
passThrough,
|
|
6911
6987
|
dataDescriptor
|
|
6912
6988
|
}) {
|
|
6913
6989
|
const {
|
|
@@ -6918,10 +6994,10 @@
|
|
|
6918
6994
|
dataDescriptorView,
|
|
6919
6995
|
dataDescriptorOffset
|
|
6920
6996
|
} = dataDescriptorInfo;
|
|
6921
|
-
if ((!encrypted || zipCrypto) &&
|
|
6922
|
-
setUint32(headerView, HEADER_OFFSET_SIGNATURE,
|
|
6997
|
+
if ((!encrypted || zipCrypto || passThrough) && crc32 !== UNDEFINED_VALUE) {
|
|
6998
|
+
setUint32(headerView, HEADER_OFFSET_SIGNATURE, crc32);
|
|
6923
6999
|
if (dataDescriptor) {
|
|
6924
|
-
setUint32(dataDescriptorView, dataDescriptorOffset,
|
|
7000
|
+
setUint32(dataDescriptorView, dataDescriptorOffset, crc32);
|
|
6925
7001
|
}
|
|
6926
7002
|
}
|
|
6927
7003
|
if (zip64) {
|
|
@@ -6944,15 +7020,15 @@
|
|
|
6944
7020
|
encrypted,
|
|
6945
7021
|
zip64,
|
|
6946
7022
|
localExtraFieldZip64Length,
|
|
6947
|
-
|
|
7023
|
+
crc32,
|
|
6948
7024
|
compressedSize,
|
|
6949
7025
|
uncompressedSize,
|
|
6950
7026
|
zip64UncompressedSize,
|
|
6951
7027
|
zip64CompressedSize
|
|
6952
|
-
}, localHeaderView, { dataDescriptor }) {
|
|
7028
|
+
}, localHeaderView, { dataDescriptor, passThrough }) {
|
|
6953
7029
|
if (!dataDescriptor) {
|
|
6954
|
-
if (!encrypted) {
|
|
6955
|
-
setUint32(localHeaderView, HEADER_OFFSET_SIGNATURE + LOCAL_HEADER_COMMON_OFFSET,
|
|
7030
|
+
if (!encrypted || (passThrough && crc32 !== UNDEFINED_VALUE)) {
|
|
7031
|
+
setUint32(localHeaderView, HEADER_OFFSET_SIGNATURE + LOCAL_HEADER_COMMON_OFFSET, crc32);
|
|
6956
7032
|
}
|
|
6957
7033
|
if (!zip64CompressedSize) {
|
|
6958
7034
|
setUint32(localHeaderView, HEADER_OFFSET_COMPRESSED_SIZE + LOCAL_HEADER_COMMON_OFFSET, compressedSize);
|
|
@@ -8214,8 +8290,8 @@
|
|
|
8214
8290
|
}
|
|
8215
8291
|
});
|
|
8216
8292
|
setDefaultConfiguration({
|
|
8217
|
-
CompressionStreamZlib,
|
|
8218
|
-
DecompressionStreamZlib
|
|
8293
|
+
CompressionStreamFallback: CompressionStreamZlib,
|
|
8294
|
+
DecompressionStreamFallback: DecompressionStreamZlib
|
|
8219
8295
|
});
|
|
8220
8296
|
|
|
8221
8297
|
function terminateWorkersAndModule() {
|
|
@@ -8286,6 +8362,20 @@
|
|
|
8286
8362
|
|
|
8287
8363
|
const ERR_ENTRY_EXISTS = "Entry filename already exists";
|
|
8288
8364
|
const ERR_READABLE_CONSUMED = "Readable stream already consumed";
|
|
8365
|
+
const INFOZIP_EXTRA_FIELD_TYPE = "infozip";
|
|
8366
|
+
const INTERPRETED_EXTRA_FIELD_TYPES = new Set([
|
|
8367
|
+
EXTRAFIELD_TYPE_ZIP64,
|
|
8368
|
+
EXTRAFIELD_TYPE_AES,
|
|
8369
|
+
EXTRAFIELD_TYPE_NTFS,
|
|
8370
|
+
EXTRAFIELD_TYPE_EXTENDED_TIMESTAMP,
|
|
8371
|
+
EXTRAFIELD_TYPE_UNICODE_PATH,
|
|
8372
|
+
EXTRAFIELD_TYPE_UNICODE_COMMENT,
|
|
8373
|
+
EXTRAFIELD_TYPE_USDZ,
|
|
8374
|
+
EXTRAFIELD_TYPE_INFOZIP,
|
|
8375
|
+
EXTRAFIELD_TYPE_UNIX,
|
|
8376
|
+
EXTRAFIELD_TYPE_UNIX_TYPE1,
|
|
8377
|
+
EXTRAFIELD_TYPE_PKWARE_UNIX
|
|
8378
|
+
]);
|
|
8289
8379
|
|
|
8290
8380
|
class ZipEntry {
|
|
8291
8381
|
|
|
@@ -9023,6 +9113,20 @@
|
|
|
9023
9113
|
}
|
|
9024
9114
|
}
|
|
9025
9115
|
|
|
9116
|
+
function getUserExtraField(extraField) {
|
|
9117
|
+
if (extraField) {
|
|
9118
|
+
const userExtraField = new Map();
|
|
9119
|
+
extraField.forEach((field, type) => {
|
|
9120
|
+
if (!INTERPRETED_EXTRA_FIELD_TYPES.has(type)) {
|
|
9121
|
+
userExtraField.set(type, field.data);
|
|
9122
|
+
}
|
|
9123
|
+
});
|
|
9124
|
+
if (userExtraField.size) {
|
|
9125
|
+
return userExtraField;
|
|
9126
|
+
}
|
|
9127
|
+
}
|
|
9128
|
+
}
|
|
9129
|
+
|
|
9026
9130
|
async function exportZip(zipWriter, entry, totalSize, options, readers) {
|
|
9027
9131
|
const selectedEntry = entry;
|
|
9028
9132
|
const entryOffsets = new Map();
|
|
@@ -9060,9 +9164,13 @@
|
|
|
9060
9164
|
uncompressedSize,
|
|
9061
9165
|
encrypted,
|
|
9062
9166
|
zipCrypto,
|
|
9063
|
-
|
|
9167
|
+
crc32,
|
|
9064
9168
|
compressionMethod,
|
|
9065
|
-
extraFieldAES
|
|
9169
|
+
extraFieldAES,
|
|
9170
|
+
internalFileAttributes,
|
|
9171
|
+
extraField,
|
|
9172
|
+
uid,
|
|
9173
|
+
gid
|
|
9066
9174
|
} = child.data;
|
|
9067
9175
|
zipEntryOptions = {
|
|
9068
9176
|
externalFileAttributes,
|
|
@@ -9070,8 +9178,20 @@
|
|
|
9070
9178
|
comment,
|
|
9071
9179
|
lastModDate,
|
|
9072
9180
|
creationDate,
|
|
9073
|
-
lastAccessDate
|
|
9181
|
+
lastAccessDate,
|
|
9182
|
+
internalFileAttributes
|
|
9074
9183
|
};
|
|
9184
|
+
const userExtraField = getUserExtraField(extraField);
|
|
9185
|
+
if (userExtraField) {
|
|
9186
|
+
zipEntryOptions.extraField = userExtraField;
|
|
9187
|
+
}
|
|
9188
|
+
if (uid !== UNDEFINED_VALUE || gid !== UNDEFINED_VALUE) {
|
|
9189
|
+
Object.assign(zipEntryOptions, {
|
|
9190
|
+
uid,
|
|
9191
|
+
gid,
|
|
9192
|
+
unixExtraFieldType: options.unixExtraFieldType || INFOZIP_EXTRA_FIELD_TYPE
|
|
9193
|
+
});
|
|
9194
|
+
}
|
|
9075
9195
|
if (child.passThrough) {
|
|
9076
9196
|
let level, encryptionStrength;
|
|
9077
9197
|
if (compressionMethod === 0) {
|
|
@@ -9084,7 +9204,7 @@
|
|
|
9084
9204
|
passThrough: true,
|
|
9085
9205
|
encrypted,
|
|
9086
9206
|
zipCrypto,
|
|
9087
|
-
|
|
9207
|
+
crc32,
|
|
9088
9208
|
uncompressedSize,
|
|
9089
9209
|
level,
|
|
9090
9210
|
encryptionStrength,
|
|
@@ -9271,6 +9391,8 @@
|
|
|
9271
9391
|
}
|
|
9272
9392
|
}
|
|
9273
9393
|
|
|
9394
|
+
const encodedMimeTypes = "application:0andrew-inset ez,2nodex anx,1pplixware aw,1tom!,4cat!,4serv! atomsrv,5vc!,0bbolin lin,0ccxml!,1dmi-capability cdmia,6ontainer cdmic,5domain cdmid,5object cdmio,5queue cdmiq,1u-seeme cu,0davmount!,1ocbook! dbk,1sptype tsp,2sc+der,4! xdssc,0ecmascript es ecma,1mma!,1nvoy evy,1pub+zip,1xi,0font-tdpfr pfr,1ractals fif,1uturesplash spl,0gml!,1px!,1xf,1zip gz tgz,0hta,1yperstudio stk,0inkml! ink inkml,2ternet-property-stream acx,1pfix,0java-archive jar,5serialized-object ser,5vm class,1sonml+json,0lost! lostxml,0m3g,1ac-binhex40 hqx,2ds!,2rc mrc,4xml! mrcx,2thematica nb ma mb,4ml! mathml mml,1box,1ediaservercontrol! mscml,2talink!,84! meta4,3s!,1ods!,1p21 m21 mp21,24 mp4s,1saccess mdb,2word doc dot wiz,1xf,0oda,1ebps-package! opf,1gg ogx,1lescript axs,1mdoc!,1nenote onetoc onetoc2 onetmp onepkg,1xps,0patch-ops-error! xer,1df,1gp-encrypted pgp,4keys key,4signature asc sig,1ics-rules prf,1kcs10 p10,47-mime p7m p7c,6signature p7s,48 p8,2ix-attr-cert ac,5crl crl,5pkipath pkipath,4cmp pki,1ls!,1ostscript ps ai eps epsi epsf eps2 eps3,1rs.cww cww,1skc! pskcxml,0rar,1df!,1eginfo! rif,2lax-ng-compact-syntax rnc,2source-lists! rl,e-diff! rld,1ls-services! rs,1pki-ghostbusters gbr,5manifest mft,5roa roa,1sd!,2s!,1tf,0sbml!,1cvp-cv-request scq,asponse scs,5vp-request spq,asponse spp,1dp,1et-payment-initiation setpay,4registration-initiation setreg,1hf!,1mil! smi smil,1parql-query rq,7results! srx,1rgs gram,4! grxml,2u!,1sdl!,2ml!,0tei! tei teicorpus,1hraud! tfi,1imestamped-data tsd,0vnd.3gpp.pic-bw-large plb,gsmall psb,gvar pvb,82.tcap tcap,5m.post-it-notes pwn,4accpac.simply.aso aso,iimp imp,6ucobol acu,9rp atc acutc,5dobe.air-application-installer-package+zip air,aformscentral.fcdt fcdt,bxp fxp fxpl,axdp! xdp,bfdf xfdf,5head.space ahead,5irzip.filesecure.azf azf,os azs,5mazon.ebook azw,6ericandynamics.acc acc,6iga.ami ami,5ndroid.package-archive apk,6ser-web-certificate-issue-initiation cii,efunds-transfer-initiation fti,6tix.game-component atx,5pple.installer! mpkg,ampegurl m3u8,5ristanetworks.swi swi,5straea-software.iota iota,5udiograph aep,4blueice.multipass mpm,5mi bmi,5usinessobjects rep,4chemdraw! cdxml,6ipnuts.karaoke-mmd mmd,5inderella cdy,5laymore cla,6oanto.rp9 rp9,7nk.c4group c4g c4d c4f c4p c4u,6uetrust.cartomobile-config c11amc,w-pkg c11amz,5ommonspace csp,6ntact.cmsg cdbcmsg,6smocaller cmc,5rick.clicker clkx,h.keyboard clkk,ipalette clkp,itemplate clkt,iwordbank clkw,7ticaltools.wbs! wbs,5tc-posml pml,5ups-ppd ppd,6rl.car car,9pcurl pcurl,4dart dart,6ta-vision.rdz rdz,5ebian.binary-package deb udeb,6ce.data uvf uvvf uvd uvvd,9ttml! uvt uvvt,9unspecified uvx uvvx,9zip uvz uvvz,6novo.fcselayout-link fe_launch,5na dna,5olby.mlp mlp,5pgraph dpg,5reamfactory dfac,5s-keypoint kpxx,5vb.ait ait,8service svc,5ynageo geo,4ecowin.chart mag,5nliven nml,5pson.esf esf,amsf msf,aquickanime qam,asalt slt,bsf ssf,5szigno3! es3 et3,5zpix-album ez2,apackage ez3,4fdf fdf,6sn.mseed mseed,9seed seed dataless,5lographit gph,6uxtime.clip ftc,5ramemaker fm frame maker book,6ogans.fnc fnc,cltf ltf,5sc.weblaunch fsc,5ujitsu.oasys oas,h2 oa2,h3 oa3,hgp fg5,hprs bh2,8xerox.ddd ddd,focuworks xdw,n.binder xbd,6zzysheet fzs,4genomatix.tuxedo txd,6ogebra.file ggb,dtool ggt,7metry-explorer gex gre,7next gxt,7plan g2w,7space g3w,5mx gmx,5oogle-earth.kml! kml,jz kmz,5rafeq gqf gqs,6oove-account gac,bhelp ghf,bidentity-message gim,cnjector grv,btool-message gtm,gtemplate tpl,bvcard vcg,4hal! hal,6ndheld-entertainment! zmm,5bci hbci,5he.lesson-player les,5p-hpgl hpgl,9id hpid,9s hps,7jlyt jlt,7pcl pcl,axl pclxl,5ydrostatix.sof-data sfd-hdstx,5zn-3d-crossword x3d,4ibm.minipay mpy,9odcap afp listafp list3820,8rights-management irm,8secure-container sc,5ccprofile icc icm,5gloader igl,5mmervision-ivp ivp,iu ivu,5nsors.igm igm,6tercon.formnet xpw xpx,9geo i2g,7u.qbo qbo,afx qfx,5punplugged.rcprofile rcprofile,5repository.package! irp,5s-xpr xpr,6ac.fcs fcs,4jam jam,5cp.javame.midlet-rms rms,5isp jisp,5oost.joda-archive joda,4kahootz ktz ktr,5de.karbon karbon,9chart chrt,9formula kfo,9ivio flw,9ontour kon,9presenter kpr kpt,9spread ksp,9word kwd kwt,5enameaapp htke,5idspiration kia,6nar kne knp,5oan skp skd skt skm,6dak-descriptor sse,4las.las! lasxml,5lamagraphics.life-balance.desktop lbd,vexchange! lbe,5otus-1-2-3 123,aapproach apr,afreelance pre,anotes nsf,aorganizer org,ascreencam scm,awordpro lwp,4macports.portpkg portpkg,5cd mcd,5edcalcdata mc1,7iastation.cdkey cdkey,5fer mwf,6mp mfm,5icrografx.flo flo,figx igx,6f mif,5obius.daf daf,cis dis,bmbk mbk,cqy mqy,csl msl,bplc plc,btxf txf,6phun.application mpn,bcertificate mpc,6zilla.xul! xul,5s-artgalry cil,7cab-compressed cab,7excel xls xlb xlt xlm xla xlc xlw,c.addin.macroenabled.12 xlam,dsheet.binary.macroenabled.12 xlsb,jmacroenabled.12 xlsm,dtemplate.macroenabled.12 xltm,7fontobject eot,7htmlhelp chm,7ims ims,7lrm lrm,7officetheme thmx,8utlook msg,7pki.seccat cat,ctl stl,acertstore sst,8owerpoint ppt pps pot ppa pwz,h.addin.macroenabled.12 ppam,ipresentation.macroenabled.12 pptm,islide.macroenabled.12 sldm,nshow.macroenabled.12 ppsm,itemplate.macroenabled.12 potm,8roject mpp mpt,7word.document.macroenabled.12 docm,ctemplate.macroenabled.12 dotm,aks wps wks wcm wdb,8pl wpl,7xpsdocument xps,6eq mseq,5usician mus,6vee.style msty,5ynfc taglet,4neurolanguage.nlu nlu,5itf ntf nitf,5oblenet-directory nnd,dsealer nns,dweb nnw,6kia.n-gage.data ngdat,hsymbian.install n-gage,aradio-preset rpst,ms rpss,6vadigm.edm edm,fx edx,ext ext,4oasis.opendocument.chart odc,s-template otc,ndatabase odb,nformula odf,u-template odft,ngraphics odg,v-template otg,nimage odi,s-template oti,npresentation odp,z-template otp,nspreadsheet ods,y-template ots,ntext odt,r-master odm otm,stemplate ott,sweb oth,5lpc-sugar xo,5ma.dd2! dd2,5penofficeorg.extension oxt,8xmlformats-officedocument.presentationml.presentation pptx,zresentationml.slide sldx,zresentationml.slideshow ppsx,zresentationml.template potx,yspreadsheetml.sheet xlsx,zpreadsheetml.template xltx,ywordprocessingml.document docx,zordprocessingml.template dotx,5sgeo.mapguide.package mgp,7i.dp dp,9subsystem esa,4palm pdb pqa oprc,6waafile paw,5g.format str,7osasli ei6,5icsel efif,5mi.widget wg,5ocketlearn plf,6werbuilder6 pbd,5reviewsystems.box box,6oteus.magazine mgz,5ublishare-delta-tree qps,5vi.ptid1 ptid,4quark.quarkxpress qxd qxt qwd qwt qxl qxb,4realvnc.bed bed,6cordare.musicxml mxl,m! musicxml,5ig.cryptonote cryptonote,5n-realmedia rm,g-vbr rmvb,5oute66.link66! link66,4sailingtracker.track st,5eemail see,6ma sema,7d semd,7f semf,5hana.informed.formdata ifm,ntemplate itp,jinterchange iif,jpackage ipk,5imtech-mindmapper twd twds,5maf mmf,7rt.teacher teacher,5olent.sdkm! sdkm sdkd,5potfire.dxp dxp,dsfs sfs,5qlite3 db sqlite sqlite3 db-wal sqlite-wal db-shm sqlite-shm,5tardivision.calc sdc,ihart sds,hdraw sda,himpress sdd,hmath sdf smf,hwriter sdw vor,n-global sgl,6epmania.package smzip,estepchart sm,5un.xml.calc sxc,g.template stc,cdraw sxd,g.template std,cimpress sxi,j.template sti,cmath sxm,cwriter sxw,i.global sxg,jtemplate stw,6s-calendar sus susp,5vd svd,5ymbian.install sis sisx,6ncml! xsm,a.dm+wbxml bdm,d! xdm,4tao.intent-module-archive tao,5cpdump.pcap pcap cap dmp,5mobile-livetv tmo,5rid.tpt tpt,7scape.mxs mxs,6ueapp tra,4ufdl ufd ufdl,5iq.theme utz,5majin umj,5nity unityweb,5oml! uoml,4vcx vcx,5isio vsd vst vss vsw vsdx vssx vstx vssm vstm,9nary vis,5sf vsf,4wap.sic sic,9lc slc,8wbxml wbxml,9mlc wmlc,bscriptc wmlsc,5ebturbo wtb,5olfram.player nbp,6rdperfect wpd,f5.1 wp5,5qd wqd,5t.stf stf,4xara xar,5fdl xfdl,4yamaha.hv-dic hvd,escript hvs,evoice hvp,bopenscoreformat osf,q.osfpvg! osfpvg,bsmaf-audio saf,gphrase spf,5ellowriver-custom-menu cmp,4zul zir zirz,5zazz.deck! zaz,1oicexml! vxml,0widget wgt,2nhlp hlp,1sdl!,2policy!,0x-123 wk,27z-compressed 7z,2abiword abw,3ce-compressed ace,3pple-diskimage dmg,3uthorware-bin aab x32 u32 vox,dmap aam,dseg aas,2bcpio bcpio,3ittorrent torrent,3lorb blb blorb,3zip bz,62 bz2 boz,2cbr cbr cba cbt cb7,4z cbz,3df cdf cda,4link vcd,3fs-compressed cfs,3hat chat,4ess-pgn pgn,3ompress z,4nference nsc,3pio cpio,3sh csh,2dgc-compressed dgc,3irector dir dxr cst cct cxt w3d fgd swa,3ms dms,3oom wad,3tbncx! ncx,5ook! dtb,5resource! res,3vi dvi,2eva eva,2font-bdf bdf,7ghostscript gsf,7linux-psf psf,7pcf pcf,7snf snf,7ttf ttf ttc,8ype1 pfa pfb pfm afm,3reearc arc,6mind mm,2gca-compressed gca,3lulx ulx,3numeric gnumeric,3o-sgf sgf,3ramps-xml gramps,5phing-calculator gcf,3tar gtar taz,2hdf hdf,3ttpd-eruby rhtml,8php phtml pht php,b-source phps,b3 php3,c-preprocessed php3p,b4 php4,b5 php5,2ica ica,3nfo info,4stall-instructions install,4ternet-signup ins isp,3phone iii,3so9660-image iso,2java-jnlp-file jnlp,3mol jmz,2killustrator kil,3rita kra krz,2latex latex,3yx lyx,3zh-compressed lzh lha,4x lzx,2maker frm fb fbdoc,3ie mie,3obipocket-ebook prc mobi,3s-application application,5installer msi,5shortcut lnk,5wmd wmd,5xbap xbap,4binder obd,4cardfile crd,5lip clp,4dos-program com exe bat dll,4mediaview mvb m13 m14,6tafile wmf wmz emf emz,5oney mny,4publisher pub,4schedule scd,4terminal trm,4write wri,2netcdf nc,3s-proxy-autoconfig pac dat,3wc nwc,3zb nzb,2object o,3z-application oza,2perfmon pma pmc pmr pmw,5l pm pl,3kcs12 p12 pfx,67-certificates p7b spc,creqresp p7r,3ython-code pyc pyo,2qgis qgs shp shx,3uicktimeplayer qtl,2redhat-package-manager rpm rpa,4search-info-systems ris,3uby rb,2sh sh,4ar shar,4ockwave-flash swf swfl,3ilverlight scr,d-app xap,3ql sql,3tuffit sit,9x sitx,3ubrip srt,3v4cpio sv4cpio,6rc sv4crc,2t3vm-image t3,3ar tar,3ex-gf gf,6pk pk,6tfm tfm,5info texinfo texi,3gif obj,3rash ~ % bak old sik,2ustar ustar,2wais-source src,3ingz wz,2x509-ca-cert crt der cer,3cf xcf,3fig fig,3liff! xlf,3pinstall xpi,3z xz,2zmachine z1 z2 z3 z4 z5 z6 z7 z8,1aml!,1cap-diff! xdf,1enc!,1html! xhtml xht,1ml xml xsl xsd xpdl,3-dtd dtd,1op!,1proc! xpl,1slt!,2pf!,1v! mxml xhvml xvml xvm,0yaml yaml yml,2ng,1in!,1nd.ms-pkipko pko,0zip;audio:0aac,1dpcm adp,1iff aiff aif aff,1mr,3-wb awb,1nnodex axa,0basic au snd,0flac,0midi mid midi kar rmi,1p4 mp4a,2eg mpga mpega mp3 m4a mp2a m2a m3a,4url m3u,0ogg oga ogg spx,1pus,0prs.sid sid,0s3m,1ilk sil,0vnd.dece.audio uva uvva,5igital-winds eol,5ra dra,5ts dts,7.hd dtshd,4lucent.voice lvp,4ms-playready.media.pya pya,4nuera.ecelp4800 ecelp4800,f7470 ecelp7470,f9600 ecelp9600,4rip rip,0wav,1ebm weba,0x-aiff aifc,2caf caf,2gsm gsm,2matroska mka,3s-wax wax,6ma wma,2pn-realaudio ram,e-plugin rmp,2realaudio ra,2sd2 sd2,1m;chemical:0x-alchemy alc,2cache cac cache,7-csf csf,5tvs-binary cbin cascii ctab,3dx cdx,3hem3d c3d,3if cif,3mdf cmdf,4l cml,3ompass cpa,3rossfire bsd,3sml csml csm,3tx ctx,3xf cxf cef,2embl-dl-nucleotide emb embl,2gamess-input inp gam gamin,4ussian-checkpoint fch fchk,cube cub,binput gau gjc gjf,blog gal,3cg8-sequence gcg,3enbank gen,2hin hin,2isostar istr ist,2jcamp-dx jdx dx,2kinemage kin,2macmolecule mcm,5romodel-input mmod,3dl-molfile mol,6rdfile rd,7xnfile rxn,6sdfile sd,6tgf tgf,3mcif mcif,3ol2 mol2,5conn-Z b,4pac-graph gpt,8input mop mopcrt zmt,8out moo,2ncbi-asn1 asn,b-ascii prt ent,cbinary val,2rosdal ros,2swissprot sw,2vamas-iso14976 vms,3md vmd,2xtel xtel,3yz xyz;font:0otf,0woff,42;image:0avif avif avifs,0bmp,0cgm,1is-cod cod,0g3fax g3,1if,0heic heif heic,0ief,0jpeg jpeg jpg jpe jfif jfif-tbnl jif,0ktx,0pcx,1jpeg pjpg,1ng,1rs.btif btif,0sgi,1vg! svg svgz,0tiff tiff tif,0vnd.adobe.photoshop psd,4dece.graphic uvi uvvi uvg uvvg,5jvu djvu djv,5wg dwg,5xf dxf,4fastbidsheet fbs,5px fpx,5st fst,5ujixerox.edmics-mmr mmr,lrlc rlc,4ms-modi mdi,7photo wdp,4net-fpx npx,4wap.wbmp wbmp,4xiff xif,0webp,0x-3ds 3ds,2adobe-dng dng,2canon-cr2 cr2,aw crw,3mu-raster ras,4x cmx,3oreldraw cdr,bpattern pat,btemplate cdt,7photopaint cpt,2epson-erf erf,2freehand fh fhc fh4 fh5 fh7,3uji-raf raf,2icns icns,4on ico,2jg art,3ng jng,2kodak-dcr dcr,8k25 k25,9dc kdc,2minolta-mrw mrw,2nikon-nef nef,2olympus-orf orf,2panasonic-raw raw rw2 rwl,3entax-pef pef ptx,3ict pic pct,3ortable-anymap pnm,bbitmap pbm,bgraymap pgm,bpixmap ppm,2rgb rgb,2sigma-x3f x3f,3ony-arw arw,7sr2 sr2,9f srf,2tga tga,2xbitmap xbm,3pixmap xpm,3windowdump xwd;message:0rfc822 eml mime mht mhtml nws;model:0iges igs iges,0mesh msh mesh silo,0vnd.collada! dae,4dwf dwf,4gdl gdl,5tw gtw,4mts mts,4usdz+zip usdz,4vtu vtu,1rml wrl vrml,0x3d+binary x3db x3dbz,4vrml x3dv x3dvz,3! x3dz;text:0cache-manifest manifest appcache,2lendar ics icz ifb,1ss,2v,0h323 323,1tml html htm shtml stm,0iuls uls,0javascript js,1son,0markdown md markdown mdown markdn,0n3,0plain txt text brf conf def list log in bas diff ksh,1rs.lines.tag dsc,0richtext rtx,0scriptlet sct wsc,1gml sgml sgm,0tab-separated-values tsv,1exmacs tm,1roff t tr roff man me ms,1urtle ttl,0uri-list uri uris urls,0vcard,1nd.curl curl,8.dcurl dcurl,9mcurl mcurl,9scurl scurl,4dvb.subtitle sub,4fly fly,5mi.flexstor flx,4graphviz gv,4in3d.3dml 3dml,9spot spot,4sun.j2me.app-descriptor jad,4wap.si si,9l sl,8wml wml,bscript wmls,0webviewhtml htt,0x-asm s asm,2bibtex bib,3oo boo,2c c h dic,3++hdr h++ hpp hxx hh,5src c++ cpp cxx cc,3omponent htc,2diff patch,3src d,2fortran f for f77 f90,2haskell hs,2java java,2literate-haskell lhs,2moc moc,2nfo nfo,2opml opml,2pascal p pas pp inc,3cs-gcd gcd,3ython py,2scala scala,3etext etx,3fv sfv,2tcl tcl tk,3ex tex ltx sty cls,2uuencode uu,2vcalendar vcs,5rd vcf;video:03gpp 3gp,42 3g2,0annodex axv,0dl,1v dif dv,0fli,0gl,0h261,33,34,0jpeg jpgv,2m jpm jpgm,0mj2 mj2 mjp2,1p2t ts,24 mp4 mp4v mpg4,2eg mpeg mpg mpe m1v m2v mp2 mpa mpv2,0ogg ogv,0quicktime qt mov,0vnd.dece.hd uvh uvvh,9mobile uvm uvvm,9pd uvp uvvp,9sd uvs uvvs,9video uvv uvvv,5vb.file dvb,4fvt fvt,4mpegurl mxu m4u,5s-playready.media.pyv pyv,4uvvu.mp4 uvu uvvu,4vivo viv,0webm,0x-f4v f4v,3lv flv,2la-asf lsf lsx,2m4v m4v,3atroska mpv mkv mk3d mks,3ng mng,3s-asf asf asx asr,5vob vob,5wm wm,7v wmv,7x wmx,6vx wvx,4video avi,2sgi-movie movie,3mv smv;x-conference:0x-cooltalk ice;x-world:0x-vrml vrm flr wrz xaf xof";
|
|
9395
|
+
|
|
9274
9396
|
/*
|
|
9275
9397
|
Copyright (c) 2022 Gildas Lormeau. All rights reserved.
|
|
9276
9398
|
|
|
@@ -9300,1589 +9422,6 @@
|
|
|
9300
9422
|
*/
|
|
9301
9423
|
|
|
9302
9424
|
|
|
9303
|
-
const table = {
|
|
9304
|
-
"application": {
|
|
9305
|
-
"andrew-inset": "ez",
|
|
9306
|
-
"annodex": "anx",
|
|
9307
|
-
"atom+xml": "atom",
|
|
9308
|
-
"atomcat+xml": "atomcat",
|
|
9309
|
-
"atomserv+xml": "atomsrv",
|
|
9310
|
-
"bbolin": "lin",
|
|
9311
|
-
"cu-seeme": "cu",
|
|
9312
|
-
"davmount+xml": "davmount",
|
|
9313
|
-
"dsptype": "tsp",
|
|
9314
|
-
"ecmascript": [
|
|
9315
|
-
"es",
|
|
9316
|
-
"ecma"
|
|
9317
|
-
],
|
|
9318
|
-
"futuresplash": "spl",
|
|
9319
|
-
"hta": "hta",
|
|
9320
|
-
"java-archive": "jar",
|
|
9321
|
-
"java-serialized-object": "ser",
|
|
9322
|
-
"java-vm": "class",
|
|
9323
|
-
"m3g": "m3g",
|
|
9324
|
-
"mac-binhex40": "hqx",
|
|
9325
|
-
"mathematica": [
|
|
9326
|
-
"nb",
|
|
9327
|
-
"ma",
|
|
9328
|
-
"mb"
|
|
9329
|
-
],
|
|
9330
|
-
"msaccess": "mdb",
|
|
9331
|
-
"msword": [
|
|
9332
|
-
"doc",
|
|
9333
|
-
"dot",
|
|
9334
|
-
"wiz"
|
|
9335
|
-
],
|
|
9336
|
-
"mxf": "mxf",
|
|
9337
|
-
"oda": "oda",
|
|
9338
|
-
"ogg": "ogx",
|
|
9339
|
-
"pdf": "pdf",
|
|
9340
|
-
"pgp-keys": "key",
|
|
9341
|
-
"pgp-signature": [
|
|
9342
|
-
"asc",
|
|
9343
|
-
"sig"
|
|
9344
|
-
],
|
|
9345
|
-
"pics-rules": "prf",
|
|
9346
|
-
"postscript": [
|
|
9347
|
-
"ps",
|
|
9348
|
-
"ai",
|
|
9349
|
-
"eps",
|
|
9350
|
-
"epsi",
|
|
9351
|
-
"epsf",
|
|
9352
|
-
"eps2",
|
|
9353
|
-
"eps3"
|
|
9354
|
-
],
|
|
9355
|
-
"rar": "rar",
|
|
9356
|
-
"rdf+xml": "rdf",
|
|
9357
|
-
"rss+xml": "rss",
|
|
9358
|
-
"rtf": "rtf",
|
|
9359
|
-
"xhtml+xml": [
|
|
9360
|
-
"xhtml",
|
|
9361
|
-
"xht"
|
|
9362
|
-
],
|
|
9363
|
-
"xml": [
|
|
9364
|
-
"xml",
|
|
9365
|
-
"xsl",
|
|
9366
|
-
"xsd",
|
|
9367
|
-
"xpdl"
|
|
9368
|
-
],
|
|
9369
|
-
"xspf+xml": "xspf",
|
|
9370
|
-
"zip": "zip",
|
|
9371
|
-
"vnd.android.package-archive": "apk",
|
|
9372
|
-
"vnd.cinderella": "cdy",
|
|
9373
|
-
"vnd.google-earth.kml+xml": "kml",
|
|
9374
|
-
"vnd.google-earth.kmz": "kmz",
|
|
9375
|
-
"vnd.mozilla.xul+xml": "xul",
|
|
9376
|
-
"vnd.ms-excel": [
|
|
9377
|
-
"xls",
|
|
9378
|
-
"xlb",
|
|
9379
|
-
"xlt",
|
|
9380
|
-
"xlm",
|
|
9381
|
-
"xla",
|
|
9382
|
-
"xlc",
|
|
9383
|
-
"xlw"
|
|
9384
|
-
],
|
|
9385
|
-
"vnd.ms-pki.seccat": "cat",
|
|
9386
|
-
"vnd.ms-pki.stl": "stl",
|
|
9387
|
-
"vnd.ms-powerpoint": [
|
|
9388
|
-
"ppt",
|
|
9389
|
-
"pps",
|
|
9390
|
-
"pot",
|
|
9391
|
-
"ppa",
|
|
9392
|
-
"pwz"
|
|
9393
|
-
],
|
|
9394
|
-
"vnd.oasis.opendocument.chart": "odc",
|
|
9395
|
-
"vnd.oasis.opendocument.database": "odb",
|
|
9396
|
-
"vnd.oasis.opendocument.formula": "odf",
|
|
9397
|
-
"vnd.oasis.opendocument.graphics": "odg",
|
|
9398
|
-
"vnd.oasis.opendocument.graphics-template": "otg",
|
|
9399
|
-
"vnd.oasis.opendocument.image": "odi",
|
|
9400
|
-
"vnd.oasis.opendocument.presentation": "odp",
|
|
9401
|
-
"vnd.oasis.opendocument.presentation-template": "otp",
|
|
9402
|
-
"vnd.oasis.opendocument.spreadsheet": "ods",
|
|
9403
|
-
"vnd.oasis.opendocument.spreadsheet-template": "ots",
|
|
9404
|
-
"vnd.oasis.opendocument.text": "odt",
|
|
9405
|
-
"vnd.oasis.opendocument.text-master": [
|
|
9406
|
-
"odm",
|
|
9407
|
-
"otm"
|
|
9408
|
-
],
|
|
9409
|
-
"vnd.oasis.opendocument.text-template": "ott",
|
|
9410
|
-
"vnd.oasis.opendocument.text-web": "oth",
|
|
9411
|
-
"vnd.openxmlformats-officedocument.spreadsheetml.sheet": "xlsx",
|
|
9412
|
-
"vnd.openxmlformats-officedocument.spreadsheetml.template": "xltx",
|
|
9413
|
-
"vnd.openxmlformats-officedocument.presentationml.presentation": "pptx",
|
|
9414
|
-
"vnd.openxmlformats-officedocument.presentationml.slideshow": "ppsx",
|
|
9415
|
-
"vnd.openxmlformats-officedocument.presentationml.template": "potx",
|
|
9416
|
-
"vnd.openxmlformats-officedocument.wordprocessingml.document": "docx",
|
|
9417
|
-
"vnd.openxmlformats-officedocument.wordprocessingml.template": "dotx",
|
|
9418
|
-
"vnd.smaf": "mmf",
|
|
9419
|
-
"vnd.stardivision.calc": "sdc",
|
|
9420
|
-
"vnd.stardivision.chart": "sds",
|
|
9421
|
-
"vnd.stardivision.draw": "sda",
|
|
9422
|
-
"vnd.stardivision.impress": "sdd",
|
|
9423
|
-
"vnd.stardivision.math": [
|
|
9424
|
-
"sdf",
|
|
9425
|
-
"smf"
|
|
9426
|
-
],
|
|
9427
|
-
"vnd.stardivision.writer": [
|
|
9428
|
-
"sdw",
|
|
9429
|
-
"vor"
|
|
9430
|
-
],
|
|
9431
|
-
"vnd.stardivision.writer-global": "sgl",
|
|
9432
|
-
"vnd.sun.xml.calc": "sxc",
|
|
9433
|
-
"vnd.sun.xml.calc.template": "stc",
|
|
9434
|
-
"vnd.sun.xml.draw": "sxd",
|
|
9435
|
-
"vnd.sun.xml.draw.template": "std",
|
|
9436
|
-
"vnd.sun.xml.impress": "sxi",
|
|
9437
|
-
"vnd.sun.xml.impress.template": "sti",
|
|
9438
|
-
"vnd.sun.xml.math": "sxm",
|
|
9439
|
-
"vnd.sun.xml.writer": "sxw",
|
|
9440
|
-
"vnd.sun.xml.writer.global": "sxg",
|
|
9441
|
-
"vnd.sun.xml.writer.template": "stw",
|
|
9442
|
-
"vnd.symbian.install": [
|
|
9443
|
-
"sis",
|
|
9444
|
-
"sisx"
|
|
9445
|
-
],
|
|
9446
|
-
"vnd.visio": [
|
|
9447
|
-
"vsd",
|
|
9448
|
-
"vst",
|
|
9449
|
-
"vss",
|
|
9450
|
-
"vsw",
|
|
9451
|
-
"vsdx",
|
|
9452
|
-
"vssx",
|
|
9453
|
-
"vstx",
|
|
9454
|
-
"vssm",
|
|
9455
|
-
"vstm"
|
|
9456
|
-
],
|
|
9457
|
-
"vnd.wap.wbxml": "wbxml",
|
|
9458
|
-
"vnd.wap.wmlc": "wmlc",
|
|
9459
|
-
"vnd.wap.wmlscriptc": "wmlsc",
|
|
9460
|
-
"vnd.wordperfect": "wpd",
|
|
9461
|
-
"vnd.wordperfect5.1": "wp5",
|
|
9462
|
-
"x-123": "wk",
|
|
9463
|
-
"x-7z-compressed": "7z",
|
|
9464
|
-
"x-abiword": "abw",
|
|
9465
|
-
"x-apple-diskimage": "dmg",
|
|
9466
|
-
"x-bcpio": "bcpio",
|
|
9467
|
-
"x-bittorrent": "torrent",
|
|
9468
|
-
"x-cbr": [
|
|
9469
|
-
"cbr",
|
|
9470
|
-
"cba",
|
|
9471
|
-
"cbt",
|
|
9472
|
-
"cb7"
|
|
9473
|
-
],
|
|
9474
|
-
"x-cbz": "cbz",
|
|
9475
|
-
"x-cdf": [
|
|
9476
|
-
"cdf",
|
|
9477
|
-
"cda"
|
|
9478
|
-
],
|
|
9479
|
-
"x-cdlink": "vcd",
|
|
9480
|
-
"x-chess-pgn": "pgn",
|
|
9481
|
-
"x-cpio": "cpio",
|
|
9482
|
-
"x-csh": "csh",
|
|
9483
|
-
"x-director": [
|
|
9484
|
-
"dir",
|
|
9485
|
-
"dxr",
|
|
9486
|
-
"cst",
|
|
9487
|
-
"cct",
|
|
9488
|
-
"cxt",
|
|
9489
|
-
"w3d",
|
|
9490
|
-
"fgd",
|
|
9491
|
-
"swa"
|
|
9492
|
-
],
|
|
9493
|
-
"x-dms": "dms",
|
|
9494
|
-
"x-doom": "wad",
|
|
9495
|
-
"x-dvi": "dvi",
|
|
9496
|
-
"x-httpd-eruby": "rhtml",
|
|
9497
|
-
"x-freemind": "mm",
|
|
9498
|
-
"x-gnumeric": "gnumeric",
|
|
9499
|
-
"x-go-sgf": "sgf",
|
|
9500
|
-
"x-graphing-calculator": "gcf",
|
|
9501
|
-
"x-gtar": [
|
|
9502
|
-
"gtar",
|
|
9503
|
-
"taz"
|
|
9504
|
-
],
|
|
9505
|
-
"x-hdf": "hdf",
|
|
9506
|
-
"x-httpd-php": [
|
|
9507
|
-
"phtml",
|
|
9508
|
-
"pht",
|
|
9509
|
-
"php"
|
|
9510
|
-
],
|
|
9511
|
-
"x-httpd-php-source": "phps",
|
|
9512
|
-
"x-httpd-php3": "php3",
|
|
9513
|
-
"x-httpd-php3-preprocessed": "php3p",
|
|
9514
|
-
"x-httpd-php4": "php4",
|
|
9515
|
-
"x-httpd-php5": "php5",
|
|
9516
|
-
"x-ica": "ica",
|
|
9517
|
-
"x-info": "info",
|
|
9518
|
-
"x-internet-signup": [
|
|
9519
|
-
"ins",
|
|
9520
|
-
"isp"
|
|
9521
|
-
],
|
|
9522
|
-
"x-iphone": "iii",
|
|
9523
|
-
"x-iso9660-image": "iso",
|
|
9524
|
-
"x-java-jnlp-file": "jnlp",
|
|
9525
|
-
"x-jmol": "jmz",
|
|
9526
|
-
"x-killustrator": "kil",
|
|
9527
|
-
"x-latex": "latex",
|
|
9528
|
-
"x-lyx": "lyx",
|
|
9529
|
-
"x-lzx": "lzx",
|
|
9530
|
-
"x-maker": [
|
|
9531
|
-
"frm",
|
|
9532
|
-
"fb",
|
|
9533
|
-
"fbdoc"
|
|
9534
|
-
],
|
|
9535
|
-
"x-ms-wmd": "wmd",
|
|
9536
|
-
"x-msdos-program": [
|
|
9537
|
-
"com",
|
|
9538
|
-
"exe",
|
|
9539
|
-
"bat",
|
|
9540
|
-
"dll"
|
|
9541
|
-
],
|
|
9542
|
-
"x-netcdf": [
|
|
9543
|
-
"nc"
|
|
9544
|
-
],
|
|
9545
|
-
"x-ns-proxy-autoconfig": [
|
|
9546
|
-
"pac",
|
|
9547
|
-
"dat"
|
|
9548
|
-
],
|
|
9549
|
-
"x-nwc": "nwc",
|
|
9550
|
-
"x-object": "o",
|
|
9551
|
-
"x-oz-application": "oza",
|
|
9552
|
-
"x-pkcs7-certreqresp": "p7r",
|
|
9553
|
-
"x-python-code": [
|
|
9554
|
-
"pyc",
|
|
9555
|
-
"pyo"
|
|
9556
|
-
],
|
|
9557
|
-
"x-qgis": [
|
|
9558
|
-
"qgs",
|
|
9559
|
-
"shp",
|
|
9560
|
-
"shx"
|
|
9561
|
-
],
|
|
9562
|
-
"x-quicktimeplayer": "qtl",
|
|
9563
|
-
"x-redhat-package-manager": [
|
|
9564
|
-
"rpm",
|
|
9565
|
-
"rpa"
|
|
9566
|
-
],
|
|
9567
|
-
"x-ruby": "rb",
|
|
9568
|
-
"x-sh": "sh",
|
|
9569
|
-
"x-shar": "shar",
|
|
9570
|
-
"x-shockwave-flash": [
|
|
9571
|
-
"swf",
|
|
9572
|
-
"swfl"
|
|
9573
|
-
],
|
|
9574
|
-
"x-silverlight": "scr",
|
|
9575
|
-
"x-stuffit": "sit",
|
|
9576
|
-
"x-sv4cpio": "sv4cpio",
|
|
9577
|
-
"x-sv4crc": "sv4crc",
|
|
9578
|
-
"x-tar": "tar",
|
|
9579
|
-
"x-tex-gf": "gf",
|
|
9580
|
-
"x-tex-pk": "pk",
|
|
9581
|
-
"x-texinfo": [
|
|
9582
|
-
"texinfo",
|
|
9583
|
-
"texi"
|
|
9584
|
-
],
|
|
9585
|
-
"x-trash": [
|
|
9586
|
-
"~",
|
|
9587
|
-
"%",
|
|
9588
|
-
"bak",
|
|
9589
|
-
"old",
|
|
9590
|
-
"sik"
|
|
9591
|
-
],
|
|
9592
|
-
"x-ustar": "ustar",
|
|
9593
|
-
"x-wais-source": "src",
|
|
9594
|
-
"x-wingz": "wz",
|
|
9595
|
-
"x-x509-ca-cert": [
|
|
9596
|
-
"crt",
|
|
9597
|
-
"der",
|
|
9598
|
-
"cer"
|
|
9599
|
-
],
|
|
9600
|
-
"x-xcf": "xcf",
|
|
9601
|
-
"x-xfig": "fig",
|
|
9602
|
-
"x-xpinstall": "xpi",
|
|
9603
|
-
"applixware": "aw",
|
|
9604
|
-
"atomsvc+xml": "atomsvc",
|
|
9605
|
-
"ccxml+xml": "ccxml",
|
|
9606
|
-
"cdmi-capability": "cdmia",
|
|
9607
|
-
"cdmi-container": "cdmic",
|
|
9608
|
-
"cdmi-domain": "cdmid",
|
|
9609
|
-
"cdmi-object": "cdmio",
|
|
9610
|
-
"cdmi-queue": "cdmiq",
|
|
9611
|
-
"docbook+xml": "dbk",
|
|
9612
|
-
"dssc+der": "dssc",
|
|
9613
|
-
"dssc+xml": "xdssc",
|
|
9614
|
-
"emma+xml": "emma",
|
|
9615
|
-
"epub+zip": "epub",
|
|
9616
|
-
"exi": "exi",
|
|
9617
|
-
"font-tdpfr": "pfr",
|
|
9618
|
-
"gml+xml": "gml",
|
|
9619
|
-
"gpx+xml": "gpx",
|
|
9620
|
-
"gxf": "gxf",
|
|
9621
|
-
"hyperstudio": "stk",
|
|
9622
|
-
"inkml+xml": [
|
|
9623
|
-
"ink",
|
|
9624
|
-
"inkml"
|
|
9625
|
-
],
|
|
9626
|
-
"ipfix": "ipfix",
|
|
9627
|
-
"jsonml+json": "jsonml",
|
|
9628
|
-
"lost+xml": "lostxml",
|
|
9629
|
-
"mads+xml": "mads",
|
|
9630
|
-
"marc": "mrc",
|
|
9631
|
-
"marcxml+xml": "mrcx",
|
|
9632
|
-
"mathml+xml": [
|
|
9633
|
-
"mathml",
|
|
9634
|
-
"mml"
|
|
9635
|
-
],
|
|
9636
|
-
"mbox": "mbox",
|
|
9637
|
-
"mediaservercontrol+xml": "mscml",
|
|
9638
|
-
"metalink+xml": "metalink",
|
|
9639
|
-
"metalink4+xml": "meta4",
|
|
9640
|
-
"mets+xml": "mets",
|
|
9641
|
-
"mods+xml": "mods",
|
|
9642
|
-
"mp21": [
|
|
9643
|
-
"m21",
|
|
9644
|
-
"mp21"
|
|
9645
|
-
],
|
|
9646
|
-
"mp4": "mp4s",
|
|
9647
|
-
"oebps-package+xml": "opf",
|
|
9648
|
-
"omdoc+xml": "omdoc",
|
|
9649
|
-
"onenote": [
|
|
9650
|
-
"onetoc",
|
|
9651
|
-
"onetoc2",
|
|
9652
|
-
"onetmp",
|
|
9653
|
-
"onepkg"
|
|
9654
|
-
],
|
|
9655
|
-
"oxps": "oxps",
|
|
9656
|
-
"patch-ops-error+xml": "xer",
|
|
9657
|
-
"pgp-encrypted": "pgp",
|
|
9658
|
-
"pkcs10": "p10",
|
|
9659
|
-
"pkcs7-mime": [
|
|
9660
|
-
"p7m",
|
|
9661
|
-
"p7c"
|
|
9662
|
-
],
|
|
9663
|
-
"pkcs7-signature": "p7s",
|
|
9664
|
-
"pkcs8": "p8",
|
|
9665
|
-
"pkix-attr-cert": "ac",
|
|
9666
|
-
"pkix-crl": "crl",
|
|
9667
|
-
"pkix-pkipath": "pkipath",
|
|
9668
|
-
"pkixcmp": "pki",
|
|
9669
|
-
"pls+xml": "pls",
|
|
9670
|
-
"prs.cww": "cww",
|
|
9671
|
-
"pskc+xml": "pskcxml",
|
|
9672
|
-
"reginfo+xml": "rif",
|
|
9673
|
-
"relax-ng-compact-syntax": "rnc",
|
|
9674
|
-
"resource-lists+xml": "rl",
|
|
9675
|
-
"resource-lists-diff+xml": "rld",
|
|
9676
|
-
"rls-services+xml": "rs",
|
|
9677
|
-
"rpki-ghostbusters": "gbr",
|
|
9678
|
-
"rpki-manifest": "mft",
|
|
9679
|
-
"rpki-roa": "roa",
|
|
9680
|
-
"rsd+xml": "rsd",
|
|
9681
|
-
"sbml+xml": "sbml",
|
|
9682
|
-
"scvp-cv-request": "scq",
|
|
9683
|
-
"scvp-cv-response": "scs",
|
|
9684
|
-
"scvp-vp-request": "spq",
|
|
9685
|
-
"scvp-vp-response": "spp",
|
|
9686
|
-
"sdp": "sdp",
|
|
9687
|
-
"set-payment-initiation": "setpay",
|
|
9688
|
-
"set-registration-initiation": "setreg",
|
|
9689
|
-
"shf+xml": "shf",
|
|
9690
|
-
"sparql-query": "rq",
|
|
9691
|
-
"sparql-results+xml": "srx",
|
|
9692
|
-
"srgs": "gram",
|
|
9693
|
-
"srgs+xml": "grxml",
|
|
9694
|
-
"sru+xml": "sru",
|
|
9695
|
-
"ssdl+xml": "ssdl",
|
|
9696
|
-
"ssml+xml": "ssml",
|
|
9697
|
-
"tei+xml": [
|
|
9698
|
-
"tei",
|
|
9699
|
-
"teicorpus"
|
|
9700
|
-
],
|
|
9701
|
-
"thraud+xml": "tfi",
|
|
9702
|
-
"timestamped-data": "tsd",
|
|
9703
|
-
"vnd.3gpp.pic-bw-large": "plb",
|
|
9704
|
-
"vnd.3gpp.pic-bw-small": "psb",
|
|
9705
|
-
"vnd.3gpp.pic-bw-var": "pvb",
|
|
9706
|
-
"vnd.3gpp2.tcap": "tcap",
|
|
9707
|
-
"vnd.3m.post-it-notes": "pwn",
|
|
9708
|
-
"vnd.accpac.simply.aso": "aso",
|
|
9709
|
-
"vnd.accpac.simply.imp": "imp",
|
|
9710
|
-
"vnd.acucobol": "acu",
|
|
9711
|
-
"vnd.acucorp": [
|
|
9712
|
-
"atc",
|
|
9713
|
-
"acutc"
|
|
9714
|
-
],
|
|
9715
|
-
"vnd.adobe.air-application-installer-package+zip": "air",
|
|
9716
|
-
"vnd.adobe.formscentral.fcdt": "fcdt",
|
|
9717
|
-
"vnd.adobe.fxp": [
|
|
9718
|
-
"fxp",
|
|
9719
|
-
"fxpl"
|
|
9720
|
-
],
|
|
9721
|
-
"vnd.adobe.xdp+xml": "xdp",
|
|
9722
|
-
"vnd.adobe.xfdf": "xfdf",
|
|
9723
|
-
"vnd.ahead.space": "ahead",
|
|
9724
|
-
"vnd.airzip.filesecure.azf": "azf",
|
|
9725
|
-
"vnd.airzip.filesecure.azs": "azs",
|
|
9726
|
-
"vnd.amazon.ebook": "azw",
|
|
9727
|
-
"vnd.americandynamics.acc": "acc",
|
|
9728
|
-
"vnd.amiga.ami": "ami",
|
|
9729
|
-
"vnd.anser-web-certificate-issue-initiation": "cii",
|
|
9730
|
-
"vnd.anser-web-funds-transfer-initiation": "fti",
|
|
9731
|
-
"vnd.antix.game-component": "atx",
|
|
9732
|
-
"vnd.apple.installer+xml": "mpkg",
|
|
9733
|
-
"vnd.apple.mpegurl": "m3u8",
|
|
9734
|
-
"vnd.aristanetworks.swi": "swi",
|
|
9735
|
-
"vnd.astraea-software.iota": "iota",
|
|
9736
|
-
"vnd.audiograph": "aep",
|
|
9737
|
-
"vnd.blueice.multipass": "mpm",
|
|
9738
|
-
"vnd.bmi": "bmi",
|
|
9739
|
-
"vnd.businessobjects": "rep",
|
|
9740
|
-
"vnd.chemdraw+xml": "cdxml",
|
|
9741
|
-
"vnd.chipnuts.karaoke-mmd": "mmd",
|
|
9742
|
-
"vnd.claymore": "cla",
|
|
9743
|
-
"vnd.cloanto.rp9": "rp9",
|
|
9744
|
-
"vnd.clonk.c4group": [
|
|
9745
|
-
"c4g",
|
|
9746
|
-
"c4d",
|
|
9747
|
-
"c4f",
|
|
9748
|
-
"c4p",
|
|
9749
|
-
"c4u"
|
|
9750
|
-
],
|
|
9751
|
-
"vnd.cluetrust.cartomobile-config": "c11amc",
|
|
9752
|
-
"vnd.cluetrust.cartomobile-config-pkg": "c11amz",
|
|
9753
|
-
"vnd.commonspace": "csp",
|
|
9754
|
-
"vnd.contact.cmsg": "cdbcmsg",
|
|
9755
|
-
"vnd.cosmocaller": "cmc",
|
|
9756
|
-
"vnd.crick.clicker": "clkx",
|
|
9757
|
-
"vnd.crick.clicker.keyboard": "clkk",
|
|
9758
|
-
"vnd.crick.clicker.palette": "clkp",
|
|
9759
|
-
"vnd.crick.clicker.template": "clkt",
|
|
9760
|
-
"vnd.crick.clicker.wordbank": "clkw",
|
|
9761
|
-
"vnd.criticaltools.wbs+xml": "wbs",
|
|
9762
|
-
"vnd.ctc-posml": "pml",
|
|
9763
|
-
"vnd.cups-ppd": "ppd",
|
|
9764
|
-
"vnd.curl.car": "car",
|
|
9765
|
-
"vnd.curl.pcurl": "pcurl",
|
|
9766
|
-
"vnd.dart": "dart",
|
|
9767
|
-
"vnd.data-vision.rdz": "rdz",
|
|
9768
|
-
"vnd.dece.data": [
|
|
9769
|
-
"uvf",
|
|
9770
|
-
"uvvf",
|
|
9771
|
-
"uvd",
|
|
9772
|
-
"uvvd"
|
|
9773
|
-
],
|
|
9774
|
-
"vnd.dece.ttml+xml": [
|
|
9775
|
-
"uvt",
|
|
9776
|
-
"uvvt"
|
|
9777
|
-
],
|
|
9778
|
-
"vnd.dece.unspecified": [
|
|
9779
|
-
"uvx",
|
|
9780
|
-
"uvvx"
|
|
9781
|
-
],
|
|
9782
|
-
"vnd.dece.zip": [
|
|
9783
|
-
"uvz",
|
|
9784
|
-
"uvvz"
|
|
9785
|
-
],
|
|
9786
|
-
"vnd.denovo.fcselayout-link": "fe_launch",
|
|
9787
|
-
"vnd.dna": "dna",
|
|
9788
|
-
"vnd.dolby.mlp": "mlp",
|
|
9789
|
-
"vnd.dpgraph": "dpg",
|
|
9790
|
-
"vnd.dreamfactory": "dfac",
|
|
9791
|
-
"vnd.ds-keypoint": "kpxx",
|
|
9792
|
-
"vnd.dvb.ait": "ait",
|
|
9793
|
-
"vnd.dvb.service": "svc",
|
|
9794
|
-
"vnd.dynageo": "geo",
|
|
9795
|
-
"vnd.ecowin.chart": "mag",
|
|
9796
|
-
"vnd.enliven": "nml",
|
|
9797
|
-
"vnd.epson.esf": "esf",
|
|
9798
|
-
"vnd.epson.msf": "msf",
|
|
9799
|
-
"vnd.epson.quickanime": "qam",
|
|
9800
|
-
"vnd.epson.salt": "slt",
|
|
9801
|
-
"vnd.epson.ssf": "ssf",
|
|
9802
|
-
"vnd.eszigno3+xml": [
|
|
9803
|
-
"es3",
|
|
9804
|
-
"et3"
|
|
9805
|
-
],
|
|
9806
|
-
"vnd.ezpix-album": "ez2",
|
|
9807
|
-
"vnd.ezpix-package": "ez3",
|
|
9808
|
-
"vnd.fdf": "fdf",
|
|
9809
|
-
"vnd.fdsn.mseed": "mseed",
|
|
9810
|
-
"vnd.fdsn.seed": [
|
|
9811
|
-
"seed",
|
|
9812
|
-
"dataless"
|
|
9813
|
-
],
|
|
9814
|
-
"vnd.flographit": "gph",
|
|
9815
|
-
"vnd.fluxtime.clip": "ftc",
|
|
9816
|
-
"vnd.framemaker": [
|
|
9817
|
-
"fm",
|
|
9818
|
-
"frame",
|
|
9819
|
-
"maker",
|
|
9820
|
-
"book"
|
|
9821
|
-
],
|
|
9822
|
-
"vnd.frogans.fnc": "fnc",
|
|
9823
|
-
"vnd.frogans.ltf": "ltf",
|
|
9824
|
-
"vnd.fsc.weblaunch": "fsc",
|
|
9825
|
-
"vnd.fujitsu.oasys": "oas",
|
|
9826
|
-
"vnd.fujitsu.oasys2": "oa2",
|
|
9827
|
-
"vnd.fujitsu.oasys3": "oa3",
|
|
9828
|
-
"vnd.fujitsu.oasysgp": "fg5",
|
|
9829
|
-
"vnd.fujitsu.oasysprs": "bh2",
|
|
9830
|
-
"vnd.fujixerox.ddd": "ddd",
|
|
9831
|
-
"vnd.fujixerox.docuworks": "xdw",
|
|
9832
|
-
"vnd.fujixerox.docuworks.binder": "xbd",
|
|
9833
|
-
"vnd.fuzzysheet": "fzs",
|
|
9834
|
-
"vnd.genomatix.tuxedo": "txd",
|
|
9835
|
-
"vnd.geogebra.file": "ggb",
|
|
9836
|
-
"vnd.geogebra.tool": "ggt",
|
|
9837
|
-
"vnd.geometry-explorer": [
|
|
9838
|
-
"gex",
|
|
9839
|
-
"gre"
|
|
9840
|
-
],
|
|
9841
|
-
"vnd.geonext": "gxt",
|
|
9842
|
-
"vnd.geoplan": "g2w",
|
|
9843
|
-
"vnd.geospace": "g3w",
|
|
9844
|
-
"vnd.gmx": "gmx",
|
|
9845
|
-
"vnd.grafeq": [
|
|
9846
|
-
"gqf",
|
|
9847
|
-
"gqs"
|
|
9848
|
-
],
|
|
9849
|
-
"vnd.groove-account": "gac",
|
|
9850
|
-
"vnd.groove-help": "ghf",
|
|
9851
|
-
"vnd.groove-identity-message": "gim",
|
|
9852
|
-
"vnd.groove-injector": "grv",
|
|
9853
|
-
"vnd.groove-tool-message": "gtm",
|
|
9854
|
-
"vnd.groove-tool-template": "tpl",
|
|
9855
|
-
"vnd.groove-vcard": "vcg",
|
|
9856
|
-
"vnd.hal+xml": "hal",
|
|
9857
|
-
"vnd.handheld-entertainment+xml": "zmm",
|
|
9858
|
-
"vnd.hbci": "hbci",
|
|
9859
|
-
"vnd.hhe.lesson-player": "les",
|
|
9860
|
-
"vnd.hp-hpgl": "hpgl",
|
|
9861
|
-
"vnd.hp-hpid": "hpid",
|
|
9862
|
-
"vnd.hp-hps": "hps",
|
|
9863
|
-
"vnd.hp-jlyt": "jlt",
|
|
9864
|
-
"vnd.hp-pcl": "pcl",
|
|
9865
|
-
"vnd.hp-pclxl": "pclxl",
|
|
9866
|
-
"vnd.hydrostatix.sof-data": "sfd-hdstx",
|
|
9867
|
-
"vnd.ibm.minipay": "mpy",
|
|
9868
|
-
"vnd.ibm.modcap": [
|
|
9869
|
-
"afp",
|
|
9870
|
-
"listafp",
|
|
9871
|
-
"list3820"
|
|
9872
|
-
],
|
|
9873
|
-
"vnd.ibm.rights-management": "irm",
|
|
9874
|
-
"vnd.ibm.secure-container": "sc",
|
|
9875
|
-
"vnd.iccprofile": [
|
|
9876
|
-
"icc",
|
|
9877
|
-
"icm"
|
|
9878
|
-
],
|
|
9879
|
-
"vnd.igloader": "igl",
|
|
9880
|
-
"vnd.immervision-ivp": "ivp",
|
|
9881
|
-
"vnd.immervision-ivu": "ivu",
|
|
9882
|
-
"vnd.insors.igm": "igm",
|
|
9883
|
-
"vnd.intercon.formnet": [
|
|
9884
|
-
"xpw",
|
|
9885
|
-
"xpx"
|
|
9886
|
-
],
|
|
9887
|
-
"vnd.intergeo": "i2g",
|
|
9888
|
-
"vnd.intu.qbo": "qbo",
|
|
9889
|
-
"vnd.intu.qfx": "qfx",
|
|
9890
|
-
"vnd.ipunplugged.rcprofile": "rcprofile",
|
|
9891
|
-
"vnd.irepository.package+xml": "irp",
|
|
9892
|
-
"vnd.is-xpr": "xpr",
|
|
9893
|
-
"vnd.isac.fcs": "fcs",
|
|
9894
|
-
"vnd.jam": "jam",
|
|
9895
|
-
"vnd.jcp.javame.midlet-rms": "rms",
|
|
9896
|
-
"vnd.jisp": "jisp",
|
|
9897
|
-
"vnd.joost.joda-archive": "joda",
|
|
9898
|
-
"vnd.kahootz": [
|
|
9899
|
-
"ktz",
|
|
9900
|
-
"ktr"
|
|
9901
|
-
],
|
|
9902
|
-
"vnd.kde.karbon": "karbon",
|
|
9903
|
-
"vnd.kde.kchart": "chrt",
|
|
9904
|
-
"vnd.kde.kformula": "kfo",
|
|
9905
|
-
"vnd.kde.kivio": "flw",
|
|
9906
|
-
"vnd.kde.kontour": "kon",
|
|
9907
|
-
"vnd.kde.kpresenter": [
|
|
9908
|
-
"kpr",
|
|
9909
|
-
"kpt"
|
|
9910
|
-
],
|
|
9911
|
-
"vnd.kde.kspread": "ksp",
|
|
9912
|
-
"vnd.kde.kword": [
|
|
9913
|
-
"kwd",
|
|
9914
|
-
"kwt"
|
|
9915
|
-
],
|
|
9916
|
-
"vnd.kenameaapp": "htke",
|
|
9917
|
-
"vnd.kidspiration": "kia",
|
|
9918
|
-
"vnd.kinar": [
|
|
9919
|
-
"kne",
|
|
9920
|
-
"knp"
|
|
9921
|
-
],
|
|
9922
|
-
"vnd.koan": [
|
|
9923
|
-
"skp",
|
|
9924
|
-
"skd",
|
|
9925
|
-
"skt",
|
|
9926
|
-
"skm"
|
|
9927
|
-
],
|
|
9928
|
-
"vnd.kodak-descriptor": "sse",
|
|
9929
|
-
"vnd.las.las+xml": "lasxml",
|
|
9930
|
-
"vnd.llamagraphics.life-balance.desktop": "lbd",
|
|
9931
|
-
"vnd.llamagraphics.life-balance.exchange+xml": "lbe",
|
|
9932
|
-
"vnd.lotus-1-2-3": "123",
|
|
9933
|
-
"vnd.lotus-approach": "apr",
|
|
9934
|
-
"vnd.lotus-freelance": "pre",
|
|
9935
|
-
"vnd.lotus-notes": "nsf",
|
|
9936
|
-
"vnd.lotus-organizer": "org",
|
|
9937
|
-
"vnd.lotus-screencam": "scm",
|
|
9938
|
-
"vnd.lotus-wordpro": "lwp",
|
|
9939
|
-
"vnd.macports.portpkg": "portpkg",
|
|
9940
|
-
"vnd.mcd": "mcd",
|
|
9941
|
-
"vnd.medcalcdata": "mc1",
|
|
9942
|
-
"vnd.mediastation.cdkey": "cdkey",
|
|
9943
|
-
"vnd.mfer": "mwf",
|
|
9944
|
-
"vnd.mfmp": "mfm",
|
|
9945
|
-
"vnd.micrografx.flo": "flo",
|
|
9946
|
-
"vnd.micrografx.igx": "igx",
|
|
9947
|
-
"vnd.mif": "mif",
|
|
9948
|
-
"vnd.mobius.daf": "daf",
|
|
9949
|
-
"vnd.mobius.dis": "dis",
|
|
9950
|
-
"vnd.mobius.mbk": "mbk",
|
|
9951
|
-
"vnd.mobius.mqy": "mqy",
|
|
9952
|
-
"vnd.mobius.msl": "msl",
|
|
9953
|
-
"vnd.mobius.plc": "plc",
|
|
9954
|
-
"vnd.mobius.txf": "txf",
|
|
9955
|
-
"vnd.mophun.application": "mpn",
|
|
9956
|
-
"vnd.mophun.certificate": "mpc",
|
|
9957
|
-
"vnd.ms-artgalry": "cil",
|
|
9958
|
-
"vnd.ms-cab-compressed": "cab",
|
|
9959
|
-
"vnd.ms-excel.addin.macroenabled.12": "xlam",
|
|
9960
|
-
"vnd.ms-excel.sheet.binary.macroenabled.12": "xlsb",
|
|
9961
|
-
"vnd.ms-excel.sheet.macroenabled.12": "xlsm",
|
|
9962
|
-
"vnd.ms-excel.template.macroenabled.12": "xltm",
|
|
9963
|
-
"vnd.ms-fontobject": "eot",
|
|
9964
|
-
"vnd.ms-htmlhelp": "chm",
|
|
9965
|
-
"vnd.ms-ims": "ims",
|
|
9966
|
-
"vnd.ms-lrm": "lrm",
|
|
9967
|
-
"vnd.ms-officetheme": "thmx",
|
|
9968
|
-
"vnd.ms-powerpoint.addin.macroenabled.12": "ppam",
|
|
9969
|
-
"vnd.ms-powerpoint.presentation.macroenabled.12": "pptm",
|
|
9970
|
-
"vnd.ms-powerpoint.slide.macroenabled.12": "sldm",
|
|
9971
|
-
"vnd.ms-powerpoint.slideshow.macroenabled.12": "ppsm",
|
|
9972
|
-
"vnd.ms-powerpoint.template.macroenabled.12": "potm",
|
|
9973
|
-
"vnd.ms-project": [
|
|
9974
|
-
"mpp",
|
|
9975
|
-
"mpt"
|
|
9976
|
-
],
|
|
9977
|
-
"vnd.ms-word.document.macroenabled.12": "docm",
|
|
9978
|
-
"vnd.ms-word.template.macroenabled.12": "dotm",
|
|
9979
|
-
"vnd.ms-works": [
|
|
9980
|
-
"wps",
|
|
9981
|
-
"wks",
|
|
9982
|
-
"wcm",
|
|
9983
|
-
"wdb"
|
|
9984
|
-
],
|
|
9985
|
-
"vnd.ms-wpl": "wpl",
|
|
9986
|
-
"vnd.ms-xpsdocument": "xps",
|
|
9987
|
-
"vnd.mseq": "mseq",
|
|
9988
|
-
"vnd.musician": "mus",
|
|
9989
|
-
"vnd.muvee.style": "msty",
|
|
9990
|
-
"vnd.mynfc": "taglet",
|
|
9991
|
-
"vnd.neurolanguage.nlu": "nlu",
|
|
9992
|
-
"vnd.nitf": [
|
|
9993
|
-
"ntf",
|
|
9994
|
-
"nitf"
|
|
9995
|
-
],
|
|
9996
|
-
"vnd.noblenet-directory": "nnd",
|
|
9997
|
-
"vnd.noblenet-sealer": "nns",
|
|
9998
|
-
"vnd.noblenet-web": "nnw",
|
|
9999
|
-
"vnd.nokia.n-gage.data": "ngdat",
|
|
10000
|
-
"vnd.nokia.n-gage.symbian.install": "n-gage",
|
|
10001
|
-
"vnd.nokia.radio-preset": "rpst",
|
|
10002
|
-
"vnd.nokia.radio-presets": "rpss",
|
|
10003
|
-
"vnd.novadigm.edm": "edm",
|
|
10004
|
-
"vnd.novadigm.edx": "edx",
|
|
10005
|
-
"vnd.novadigm.ext": "ext",
|
|
10006
|
-
"vnd.oasis.opendocument.chart-template": "otc",
|
|
10007
|
-
"vnd.oasis.opendocument.formula-template": "odft",
|
|
10008
|
-
"vnd.oasis.opendocument.image-template": "oti",
|
|
10009
|
-
"vnd.olpc-sugar": "xo",
|
|
10010
|
-
"vnd.oma.dd2+xml": "dd2",
|
|
10011
|
-
"vnd.openofficeorg.extension": "oxt",
|
|
10012
|
-
"vnd.openxmlformats-officedocument.presentationml.slide": "sldx",
|
|
10013
|
-
"vnd.osgeo.mapguide.package": "mgp",
|
|
10014
|
-
"vnd.osgi.dp": "dp",
|
|
10015
|
-
"vnd.osgi.subsystem": "esa",
|
|
10016
|
-
"vnd.palm": [
|
|
10017
|
-
"pdb",
|
|
10018
|
-
"pqa",
|
|
10019
|
-
"oprc"
|
|
10020
|
-
],
|
|
10021
|
-
"vnd.pawaafile": "paw",
|
|
10022
|
-
"vnd.pg.format": "str",
|
|
10023
|
-
"vnd.pg.osasli": "ei6",
|
|
10024
|
-
"vnd.picsel": "efif",
|
|
10025
|
-
"vnd.pmi.widget": "wg",
|
|
10026
|
-
"vnd.pocketlearn": "plf",
|
|
10027
|
-
"vnd.powerbuilder6": "pbd",
|
|
10028
|
-
"vnd.previewsystems.box": "box",
|
|
10029
|
-
"vnd.proteus.magazine": "mgz",
|
|
10030
|
-
"vnd.publishare-delta-tree": "qps",
|
|
10031
|
-
"vnd.pvi.ptid1": "ptid",
|
|
10032
|
-
"vnd.quark.quarkxpress": [
|
|
10033
|
-
"qxd",
|
|
10034
|
-
"qxt",
|
|
10035
|
-
"qwd",
|
|
10036
|
-
"qwt",
|
|
10037
|
-
"qxl",
|
|
10038
|
-
"qxb"
|
|
10039
|
-
],
|
|
10040
|
-
"vnd.realvnc.bed": "bed",
|
|
10041
|
-
"vnd.recordare.musicxml": "mxl",
|
|
10042
|
-
"vnd.recordare.musicxml+xml": "musicxml",
|
|
10043
|
-
"vnd.rig.cryptonote": "cryptonote",
|
|
10044
|
-
"vnd.rn-realmedia": "rm",
|
|
10045
|
-
"vnd.rn-realmedia-vbr": "rmvb",
|
|
10046
|
-
"vnd.route66.link66+xml": "link66",
|
|
10047
|
-
"vnd.sailingtracker.track": "st",
|
|
10048
|
-
"vnd.seemail": "see",
|
|
10049
|
-
"vnd.sema": "sema",
|
|
10050
|
-
"vnd.semd": "semd",
|
|
10051
|
-
"vnd.semf": "semf",
|
|
10052
|
-
"vnd.shana.informed.formdata": "ifm",
|
|
10053
|
-
"vnd.shana.informed.formtemplate": "itp",
|
|
10054
|
-
"vnd.shana.informed.interchange": "iif",
|
|
10055
|
-
"vnd.shana.informed.package": "ipk",
|
|
10056
|
-
"vnd.simtech-mindmapper": [
|
|
10057
|
-
"twd",
|
|
10058
|
-
"twds"
|
|
10059
|
-
],
|
|
10060
|
-
"vnd.smart.teacher": "teacher",
|
|
10061
|
-
"vnd.solent.sdkm+xml": [
|
|
10062
|
-
"sdkm",
|
|
10063
|
-
"sdkd"
|
|
10064
|
-
],
|
|
10065
|
-
"vnd.spotfire.dxp": "dxp",
|
|
10066
|
-
"vnd.spotfire.sfs": "sfs",
|
|
10067
|
-
"vnd.stepmania.package": "smzip",
|
|
10068
|
-
"vnd.stepmania.stepchart": "sm",
|
|
10069
|
-
"vnd.sus-calendar": [
|
|
10070
|
-
"sus",
|
|
10071
|
-
"susp"
|
|
10072
|
-
],
|
|
10073
|
-
"vnd.svd": "svd",
|
|
10074
|
-
"vnd.syncml+xml": "xsm",
|
|
10075
|
-
"vnd.syncml.dm+wbxml": "bdm",
|
|
10076
|
-
"vnd.syncml.dm+xml": "xdm",
|
|
10077
|
-
"vnd.tao.intent-module-archive": "tao",
|
|
10078
|
-
"vnd.tcpdump.pcap": [
|
|
10079
|
-
"pcap",
|
|
10080
|
-
"cap",
|
|
10081
|
-
"dmp"
|
|
10082
|
-
],
|
|
10083
|
-
"vnd.tmobile-livetv": "tmo",
|
|
10084
|
-
"vnd.trid.tpt": "tpt",
|
|
10085
|
-
"vnd.triscape.mxs": "mxs",
|
|
10086
|
-
"vnd.trueapp": "tra",
|
|
10087
|
-
"vnd.ufdl": [
|
|
10088
|
-
"ufd",
|
|
10089
|
-
"ufdl"
|
|
10090
|
-
],
|
|
10091
|
-
"vnd.uiq.theme": "utz",
|
|
10092
|
-
"vnd.umajin": "umj",
|
|
10093
|
-
"vnd.unity": "unityweb",
|
|
10094
|
-
"vnd.uoml+xml": "uoml",
|
|
10095
|
-
"vnd.vcx": "vcx",
|
|
10096
|
-
"vnd.visionary": "vis",
|
|
10097
|
-
"vnd.vsf": "vsf",
|
|
10098
|
-
"vnd.webturbo": "wtb",
|
|
10099
|
-
"vnd.wolfram.player": "nbp",
|
|
10100
|
-
"vnd.wqd": "wqd",
|
|
10101
|
-
"vnd.wt.stf": "stf",
|
|
10102
|
-
"vnd.xara": "xar",
|
|
10103
|
-
"vnd.xfdl": "xfdl",
|
|
10104
|
-
"vnd.yamaha.hv-dic": "hvd",
|
|
10105
|
-
"vnd.yamaha.hv-script": "hvs",
|
|
10106
|
-
"vnd.yamaha.hv-voice": "hvp",
|
|
10107
|
-
"vnd.yamaha.openscoreformat": "osf",
|
|
10108
|
-
"vnd.yamaha.openscoreformat.osfpvg+xml": "osfpvg",
|
|
10109
|
-
"vnd.yamaha.smaf-audio": "saf",
|
|
10110
|
-
"vnd.yamaha.smaf-phrase": "spf",
|
|
10111
|
-
"vnd.yellowriver-custom-menu": "cmp",
|
|
10112
|
-
"vnd.zul": [
|
|
10113
|
-
"zir",
|
|
10114
|
-
"zirz"
|
|
10115
|
-
],
|
|
10116
|
-
"vnd.zzazz.deck+xml": "zaz",
|
|
10117
|
-
"voicexml+xml": "vxml",
|
|
10118
|
-
"widget": "wgt",
|
|
10119
|
-
"winhlp": "hlp",
|
|
10120
|
-
"wsdl+xml": "wsdl",
|
|
10121
|
-
"wspolicy+xml": "wspolicy",
|
|
10122
|
-
"x-ace-compressed": "ace",
|
|
10123
|
-
"x-authorware-bin": [
|
|
10124
|
-
"aab",
|
|
10125
|
-
"x32",
|
|
10126
|
-
"u32",
|
|
10127
|
-
"vox"
|
|
10128
|
-
],
|
|
10129
|
-
"x-authorware-map": "aam",
|
|
10130
|
-
"x-authorware-seg": "aas",
|
|
10131
|
-
"x-blorb": [
|
|
10132
|
-
"blb",
|
|
10133
|
-
"blorb"
|
|
10134
|
-
],
|
|
10135
|
-
"x-bzip": "bz",
|
|
10136
|
-
"x-bzip2": [
|
|
10137
|
-
"bz2",
|
|
10138
|
-
"boz"
|
|
10139
|
-
],
|
|
10140
|
-
"x-cfs-compressed": "cfs",
|
|
10141
|
-
"x-chat": "chat",
|
|
10142
|
-
"x-conference": "nsc",
|
|
10143
|
-
"x-dgc-compressed": "dgc",
|
|
10144
|
-
"x-dtbncx+xml": "ncx",
|
|
10145
|
-
"x-dtbook+xml": "dtb",
|
|
10146
|
-
"x-dtbresource+xml": "res",
|
|
10147
|
-
"x-eva": "eva",
|
|
10148
|
-
"x-font-bdf": "bdf",
|
|
10149
|
-
"x-font-ghostscript": "gsf",
|
|
10150
|
-
"x-font-linux-psf": "psf",
|
|
10151
|
-
"x-font-pcf": "pcf",
|
|
10152
|
-
"x-font-snf": "snf",
|
|
10153
|
-
"x-font-ttf": [
|
|
10154
|
-
"ttf",
|
|
10155
|
-
"ttc"
|
|
10156
|
-
],
|
|
10157
|
-
"x-font-type1": [
|
|
10158
|
-
"pfa",
|
|
10159
|
-
"pfb",
|
|
10160
|
-
"pfm",
|
|
10161
|
-
"afm"
|
|
10162
|
-
],
|
|
10163
|
-
"x-freearc": "arc",
|
|
10164
|
-
"x-gca-compressed": "gca",
|
|
10165
|
-
"x-glulx": "ulx",
|
|
10166
|
-
"x-gramps-xml": "gramps",
|
|
10167
|
-
"x-install-instructions": "install",
|
|
10168
|
-
"x-lzh-compressed": [
|
|
10169
|
-
"lzh",
|
|
10170
|
-
"lha"
|
|
10171
|
-
],
|
|
10172
|
-
"x-mie": "mie",
|
|
10173
|
-
"x-mobipocket-ebook": [
|
|
10174
|
-
"prc",
|
|
10175
|
-
"mobi"
|
|
10176
|
-
],
|
|
10177
|
-
"x-ms-application": "application",
|
|
10178
|
-
"x-ms-shortcut": "lnk",
|
|
10179
|
-
"x-ms-xbap": "xbap",
|
|
10180
|
-
"x-msbinder": "obd",
|
|
10181
|
-
"x-mscardfile": "crd",
|
|
10182
|
-
"x-msclip": "clp",
|
|
10183
|
-
"x-ms-installer": "msi",
|
|
10184
|
-
"x-msmediaview": [
|
|
10185
|
-
"mvb",
|
|
10186
|
-
"m13",
|
|
10187
|
-
"m14"
|
|
10188
|
-
],
|
|
10189
|
-
"x-msmetafile": [
|
|
10190
|
-
"wmf",
|
|
10191
|
-
"wmz",
|
|
10192
|
-
"emf",
|
|
10193
|
-
"emz"
|
|
10194
|
-
],
|
|
10195
|
-
"x-msmoney": "mny",
|
|
10196
|
-
"x-mspublisher": "pub",
|
|
10197
|
-
"x-msschedule": "scd",
|
|
10198
|
-
"x-msterminal": "trm",
|
|
10199
|
-
"x-mswrite": "wri",
|
|
10200
|
-
"x-nzb": "nzb",
|
|
10201
|
-
"x-pkcs12": [
|
|
10202
|
-
"p12",
|
|
10203
|
-
"pfx"
|
|
10204
|
-
],
|
|
10205
|
-
"x-pkcs7-certificates": [
|
|
10206
|
-
"p7b",
|
|
10207
|
-
"spc"
|
|
10208
|
-
],
|
|
10209
|
-
"x-research-info-systems": "ris",
|
|
10210
|
-
"x-silverlight-app": "xap",
|
|
10211
|
-
"x-sql": "sql",
|
|
10212
|
-
"x-stuffitx": "sitx",
|
|
10213
|
-
"x-subrip": "srt",
|
|
10214
|
-
"x-t3vm-image": "t3",
|
|
10215
|
-
"x-tex-tfm": "tfm",
|
|
10216
|
-
"x-tgif": "obj",
|
|
10217
|
-
"x-xliff+xml": "xlf",
|
|
10218
|
-
"x-xz": "xz",
|
|
10219
|
-
"x-zmachine": [
|
|
10220
|
-
"z1",
|
|
10221
|
-
"z2",
|
|
10222
|
-
"z3",
|
|
10223
|
-
"z4",
|
|
10224
|
-
"z5",
|
|
10225
|
-
"z6",
|
|
10226
|
-
"z7",
|
|
10227
|
-
"z8"
|
|
10228
|
-
],
|
|
10229
|
-
"xaml+xml": "xaml",
|
|
10230
|
-
"xcap-diff+xml": "xdf",
|
|
10231
|
-
"xenc+xml": "xenc",
|
|
10232
|
-
"xml-dtd": "dtd",
|
|
10233
|
-
"xop+xml": "xop",
|
|
10234
|
-
"xproc+xml": "xpl",
|
|
10235
|
-
"xslt+xml": "xslt",
|
|
10236
|
-
"xv+xml": [
|
|
10237
|
-
"mxml",
|
|
10238
|
-
"xhvml",
|
|
10239
|
-
"xvml",
|
|
10240
|
-
"xvm"
|
|
10241
|
-
],
|
|
10242
|
-
"yang": "yang",
|
|
10243
|
-
"yin+xml": "yin",
|
|
10244
|
-
"envoy": "evy",
|
|
10245
|
-
"fractals": "fif",
|
|
10246
|
-
"internet-property-stream": "acx",
|
|
10247
|
-
"olescript": "axs",
|
|
10248
|
-
"vnd.ms-outlook": "msg",
|
|
10249
|
-
"vnd.ms-pkicertstore": "sst",
|
|
10250
|
-
"x-compress": "z",
|
|
10251
|
-
"x-perfmon": [
|
|
10252
|
-
"pma",
|
|
10253
|
-
"pmc",
|
|
10254
|
-
"pmr",
|
|
10255
|
-
"pmw"
|
|
10256
|
-
],
|
|
10257
|
-
"ynd.ms-pkipko": "pko",
|
|
10258
|
-
"gzip": [
|
|
10259
|
-
"gz",
|
|
10260
|
-
"tgz"
|
|
10261
|
-
],
|
|
10262
|
-
"smil+xml": [
|
|
10263
|
-
"smi",
|
|
10264
|
-
"smil"
|
|
10265
|
-
],
|
|
10266
|
-
"vnd.debian.binary-package": [
|
|
10267
|
-
"deb",
|
|
10268
|
-
"udeb"
|
|
10269
|
-
],
|
|
10270
|
-
"vnd.hzn-3d-crossword": "x3d",
|
|
10271
|
-
"vnd.sqlite3": [
|
|
10272
|
-
"db",
|
|
10273
|
-
"sqlite",
|
|
10274
|
-
"sqlite3",
|
|
10275
|
-
"db-wal",
|
|
10276
|
-
"sqlite-wal",
|
|
10277
|
-
"db-shm",
|
|
10278
|
-
"sqlite-shm"
|
|
10279
|
-
],
|
|
10280
|
-
"vnd.wap.sic": "sic",
|
|
10281
|
-
"vnd.wap.slc": "slc",
|
|
10282
|
-
"x-krita": [
|
|
10283
|
-
"kra",
|
|
10284
|
-
"krz"
|
|
10285
|
-
],
|
|
10286
|
-
"x-perl": [
|
|
10287
|
-
"pm",
|
|
10288
|
-
"pl"
|
|
10289
|
-
],
|
|
10290
|
-
"yaml": [
|
|
10291
|
-
"yaml",
|
|
10292
|
-
"yml"
|
|
10293
|
-
]
|
|
10294
|
-
},
|
|
10295
|
-
"audio": {
|
|
10296
|
-
"amr": "amr",
|
|
10297
|
-
"amr-wb": "awb",
|
|
10298
|
-
"annodex": "axa",
|
|
10299
|
-
"basic": [
|
|
10300
|
-
"au",
|
|
10301
|
-
"snd"
|
|
10302
|
-
],
|
|
10303
|
-
"flac": "flac",
|
|
10304
|
-
"midi": [
|
|
10305
|
-
"mid",
|
|
10306
|
-
"midi",
|
|
10307
|
-
"kar",
|
|
10308
|
-
"rmi"
|
|
10309
|
-
],
|
|
10310
|
-
"mpeg": [
|
|
10311
|
-
"mpga",
|
|
10312
|
-
"mpega",
|
|
10313
|
-
"mp3",
|
|
10314
|
-
"m4a",
|
|
10315
|
-
"mp2a",
|
|
10316
|
-
"m2a",
|
|
10317
|
-
"m3a"
|
|
10318
|
-
],
|
|
10319
|
-
"mpegurl": "m3u",
|
|
10320
|
-
"ogg": [
|
|
10321
|
-
"oga",
|
|
10322
|
-
"ogg",
|
|
10323
|
-
"spx"
|
|
10324
|
-
],
|
|
10325
|
-
"prs.sid": "sid",
|
|
10326
|
-
"x-aiff": "aifc",
|
|
10327
|
-
"x-gsm": "gsm",
|
|
10328
|
-
"x-ms-wma": "wma",
|
|
10329
|
-
"x-ms-wax": "wax",
|
|
10330
|
-
"x-pn-realaudio": "ram",
|
|
10331
|
-
"x-realaudio": "ra",
|
|
10332
|
-
"x-sd2": "sd2",
|
|
10333
|
-
"adpcm": "adp",
|
|
10334
|
-
"mp4": "mp4a",
|
|
10335
|
-
"s3m": "s3m",
|
|
10336
|
-
"silk": "sil",
|
|
10337
|
-
"vnd.dece.audio": [
|
|
10338
|
-
"uva",
|
|
10339
|
-
"uvva"
|
|
10340
|
-
],
|
|
10341
|
-
"vnd.digital-winds": "eol",
|
|
10342
|
-
"vnd.dra": "dra",
|
|
10343
|
-
"vnd.dts": "dts",
|
|
10344
|
-
"vnd.dts.hd": "dtshd",
|
|
10345
|
-
"vnd.lucent.voice": "lvp",
|
|
10346
|
-
"vnd.ms-playready.media.pya": "pya",
|
|
10347
|
-
"vnd.nuera.ecelp4800": "ecelp4800",
|
|
10348
|
-
"vnd.nuera.ecelp7470": "ecelp7470",
|
|
10349
|
-
"vnd.nuera.ecelp9600": "ecelp9600",
|
|
10350
|
-
"vnd.rip": "rip",
|
|
10351
|
-
"webm": "weba",
|
|
10352
|
-
"x-caf": "caf",
|
|
10353
|
-
"x-matroska": "mka",
|
|
10354
|
-
"x-pn-realaudio-plugin": "rmp",
|
|
10355
|
-
"xm": "xm",
|
|
10356
|
-
"aac": "aac",
|
|
10357
|
-
"aiff": [
|
|
10358
|
-
"aiff",
|
|
10359
|
-
"aif",
|
|
10360
|
-
"aff"
|
|
10361
|
-
],
|
|
10362
|
-
"opus": "opus",
|
|
10363
|
-
"wav": "wav"
|
|
10364
|
-
},
|
|
10365
|
-
"chemical": {
|
|
10366
|
-
"x-alchemy": "alc",
|
|
10367
|
-
"x-cache": [
|
|
10368
|
-
"cac",
|
|
10369
|
-
"cache"
|
|
10370
|
-
],
|
|
10371
|
-
"x-cache-csf": "csf",
|
|
10372
|
-
"x-cactvs-binary": [
|
|
10373
|
-
"cbin",
|
|
10374
|
-
"cascii",
|
|
10375
|
-
"ctab"
|
|
10376
|
-
],
|
|
10377
|
-
"x-cdx": "cdx",
|
|
10378
|
-
"x-chem3d": "c3d",
|
|
10379
|
-
"x-cif": "cif",
|
|
10380
|
-
"x-cmdf": "cmdf",
|
|
10381
|
-
"x-cml": "cml",
|
|
10382
|
-
"x-compass": "cpa",
|
|
10383
|
-
"x-crossfire": "bsd",
|
|
10384
|
-
"x-csml": [
|
|
10385
|
-
"csml",
|
|
10386
|
-
"csm"
|
|
10387
|
-
],
|
|
10388
|
-
"x-ctx": "ctx",
|
|
10389
|
-
"x-cxf": [
|
|
10390
|
-
"cxf",
|
|
10391
|
-
"cef"
|
|
10392
|
-
],
|
|
10393
|
-
"x-embl-dl-nucleotide": [
|
|
10394
|
-
"emb",
|
|
10395
|
-
"embl"
|
|
10396
|
-
],
|
|
10397
|
-
"x-gamess-input": [
|
|
10398
|
-
"inp",
|
|
10399
|
-
"gam",
|
|
10400
|
-
"gamin"
|
|
10401
|
-
],
|
|
10402
|
-
"x-gaussian-checkpoint": [
|
|
10403
|
-
"fch",
|
|
10404
|
-
"fchk"
|
|
10405
|
-
],
|
|
10406
|
-
"x-gaussian-cube": "cub",
|
|
10407
|
-
"x-gaussian-input": [
|
|
10408
|
-
"gau",
|
|
10409
|
-
"gjc",
|
|
10410
|
-
"gjf"
|
|
10411
|
-
],
|
|
10412
|
-
"x-gaussian-log": "gal",
|
|
10413
|
-
"x-gcg8-sequence": "gcg",
|
|
10414
|
-
"x-genbank": "gen",
|
|
10415
|
-
"x-hin": "hin",
|
|
10416
|
-
"x-isostar": [
|
|
10417
|
-
"istr",
|
|
10418
|
-
"ist"
|
|
10419
|
-
],
|
|
10420
|
-
"x-jcamp-dx": [
|
|
10421
|
-
"jdx",
|
|
10422
|
-
"dx"
|
|
10423
|
-
],
|
|
10424
|
-
"x-kinemage": "kin",
|
|
10425
|
-
"x-macmolecule": "mcm",
|
|
10426
|
-
"x-macromodel-input": "mmod",
|
|
10427
|
-
"x-mdl-molfile": "mol",
|
|
10428
|
-
"x-mdl-rdfile": "rd",
|
|
10429
|
-
"x-mdl-rxnfile": "rxn",
|
|
10430
|
-
"x-mdl-sdfile": "sd",
|
|
10431
|
-
"x-mdl-tgf": "tgf",
|
|
10432
|
-
"x-mmcif": "mcif",
|
|
10433
|
-
"x-mol2": "mol2",
|
|
10434
|
-
"x-molconn-Z": "b",
|
|
10435
|
-
"x-mopac-graph": "gpt",
|
|
10436
|
-
"x-mopac-input": [
|
|
10437
|
-
"mop",
|
|
10438
|
-
"mopcrt",
|
|
10439
|
-
"zmt"
|
|
10440
|
-
],
|
|
10441
|
-
"x-mopac-out": "moo",
|
|
10442
|
-
"x-ncbi-asn1": "asn",
|
|
10443
|
-
"x-ncbi-asn1-ascii": [
|
|
10444
|
-
"prt",
|
|
10445
|
-
"ent"
|
|
10446
|
-
],
|
|
10447
|
-
"x-ncbi-asn1-binary": "val",
|
|
10448
|
-
"x-rosdal": "ros",
|
|
10449
|
-
"x-swissprot": "sw",
|
|
10450
|
-
"x-vamas-iso14976": "vms",
|
|
10451
|
-
"x-vmd": "vmd",
|
|
10452
|
-
"x-xtel": "xtel",
|
|
10453
|
-
"x-xyz": "xyz"
|
|
10454
|
-
},
|
|
10455
|
-
"font": {
|
|
10456
|
-
"otf": "otf",
|
|
10457
|
-
"woff": "woff",
|
|
10458
|
-
"woff2": "woff2"
|
|
10459
|
-
},
|
|
10460
|
-
"image": {
|
|
10461
|
-
"gif": "gif",
|
|
10462
|
-
"ief": "ief",
|
|
10463
|
-
"jpeg": [
|
|
10464
|
-
"jpeg",
|
|
10465
|
-
"jpg",
|
|
10466
|
-
"jpe",
|
|
10467
|
-
"jfif",
|
|
10468
|
-
"jfif-tbnl",
|
|
10469
|
-
"jif"
|
|
10470
|
-
],
|
|
10471
|
-
"pcx": "pcx",
|
|
10472
|
-
"png": "png",
|
|
10473
|
-
"svg+xml": [
|
|
10474
|
-
"svg",
|
|
10475
|
-
"svgz"
|
|
10476
|
-
],
|
|
10477
|
-
"tiff": [
|
|
10478
|
-
"tiff",
|
|
10479
|
-
"tif"
|
|
10480
|
-
],
|
|
10481
|
-
"vnd.djvu": [
|
|
10482
|
-
"djvu",
|
|
10483
|
-
"djv"
|
|
10484
|
-
],
|
|
10485
|
-
"vnd.wap.wbmp": "wbmp",
|
|
10486
|
-
"x-canon-cr2": "cr2",
|
|
10487
|
-
"x-canon-crw": "crw",
|
|
10488
|
-
"x-cmu-raster": "ras",
|
|
10489
|
-
"x-coreldraw": "cdr",
|
|
10490
|
-
"x-coreldrawpattern": "pat",
|
|
10491
|
-
"x-coreldrawtemplate": "cdt",
|
|
10492
|
-
"x-corelphotopaint": "cpt",
|
|
10493
|
-
"x-epson-erf": "erf",
|
|
10494
|
-
"x-icon": "ico",
|
|
10495
|
-
"x-jg": "art",
|
|
10496
|
-
"x-jng": "jng",
|
|
10497
|
-
"x-nikon-nef": "nef",
|
|
10498
|
-
"x-olympus-orf": "orf",
|
|
10499
|
-
"x-portable-anymap": "pnm",
|
|
10500
|
-
"x-portable-bitmap": "pbm",
|
|
10501
|
-
"x-portable-graymap": "pgm",
|
|
10502
|
-
"x-portable-pixmap": "ppm",
|
|
10503
|
-
"x-rgb": "rgb",
|
|
10504
|
-
"x-xbitmap": "xbm",
|
|
10505
|
-
"x-xpixmap": "xpm",
|
|
10506
|
-
"x-xwindowdump": "xwd",
|
|
10507
|
-
"bmp": "bmp",
|
|
10508
|
-
"cgm": "cgm",
|
|
10509
|
-
"g3fax": "g3",
|
|
10510
|
-
"ktx": "ktx",
|
|
10511
|
-
"prs.btif": "btif",
|
|
10512
|
-
"sgi": "sgi",
|
|
10513
|
-
"vnd.dece.graphic": [
|
|
10514
|
-
"uvi",
|
|
10515
|
-
"uvvi",
|
|
10516
|
-
"uvg",
|
|
10517
|
-
"uvvg"
|
|
10518
|
-
],
|
|
10519
|
-
"vnd.dwg": "dwg",
|
|
10520
|
-
"vnd.dxf": "dxf",
|
|
10521
|
-
"vnd.fastbidsheet": "fbs",
|
|
10522
|
-
"vnd.fpx": "fpx",
|
|
10523
|
-
"vnd.fst": "fst",
|
|
10524
|
-
"vnd.fujixerox.edmics-mmr": "mmr",
|
|
10525
|
-
"vnd.fujixerox.edmics-rlc": "rlc",
|
|
10526
|
-
"vnd.ms-modi": "mdi",
|
|
10527
|
-
"vnd.ms-photo": "wdp",
|
|
10528
|
-
"vnd.net-fpx": "npx",
|
|
10529
|
-
"vnd.xiff": "xif",
|
|
10530
|
-
"webp": "webp",
|
|
10531
|
-
"x-3ds": "3ds",
|
|
10532
|
-
"x-cmx": "cmx",
|
|
10533
|
-
"x-freehand": [
|
|
10534
|
-
"fh",
|
|
10535
|
-
"fhc",
|
|
10536
|
-
"fh4",
|
|
10537
|
-
"fh5",
|
|
10538
|
-
"fh7"
|
|
10539
|
-
],
|
|
10540
|
-
"x-pict": [
|
|
10541
|
-
"pic",
|
|
10542
|
-
"pct"
|
|
10543
|
-
],
|
|
10544
|
-
"x-tga": "tga",
|
|
10545
|
-
"cis-cod": "cod",
|
|
10546
|
-
"avif": [
|
|
10547
|
-
"avif",
|
|
10548
|
-
"avifs"
|
|
10549
|
-
],
|
|
10550
|
-
"heic": [
|
|
10551
|
-
"heif",
|
|
10552
|
-
"heic"
|
|
10553
|
-
],
|
|
10554
|
-
"pjpeg": [
|
|
10555
|
-
"pjpg"
|
|
10556
|
-
],
|
|
10557
|
-
"vnd.adobe.photoshop": "psd",
|
|
10558
|
-
"x-adobe-dng": "dng",
|
|
10559
|
-
"x-fuji-raf": "raf",
|
|
10560
|
-
"x-icns": "icns",
|
|
10561
|
-
"x-kodak-dcr": "dcr",
|
|
10562
|
-
"x-kodak-k25": "k25",
|
|
10563
|
-
"x-kodak-kdc": "kdc",
|
|
10564
|
-
"x-minolta-mrw": "mrw",
|
|
10565
|
-
"x-panasonic-raw": [
|
|
10566
|
-
"raw",
|
|
10567
|
-
"rw2",
|
|
10568
|
-
"rwl"
|
|
10569
|
-
],
|
|
10570
|
-
"x-pentax-pef": [
|
|
10571
|
-
"pef",
|
|
10572
|
-
"ptx"
|
|
10573
|
-
],
|
|
10574
|
-
"x-sigma-x3f": "x3f",
|
|
10575
|
-
"x-sony-arw": "arw",
|
|
10576
|
-
"x-sony-sr2": "sr2",
|
|
10577
|
-
"x-sony-srf": "srf"
|
|
10578
|
-
},
|
|
10579
|
-
"message": {
|
|
10580
|
-
"rfc822": [
|
|
10581
|
-
"eml",
|
|
10582
|
-
"mime",
|
|
10583
|
-
"mht",
|
|
10584
|
-
"mhtml",
|
|
10585
|
-
"nws"
|
|
10586
|
-
]
|
|
10587
|
-
},
|
|
10588
|
-
"model": {
|
|
10589
|
-
"iges": [
|
|
10590
|
-
"igs",
|
|
10591
|
-
"iges"
|
|
10592
|
-
],
|
|
10593
|
-
"mesh": [
|
|
10594
|
-
"msh",
|
|
10595
|
-
"mesh",
|
|
10596
|
-
"silo"
|
|
10597
|
-
],
|
|
10598
|
-
"vrml": [
|
|
10599
|
-
"wrl",
|
|
10600
|
-
"vrml"
|
|
10601
|
-
],
|
|
10602
|
-
"x3d+vrml": [
|
|
10603
|
-
"x3dv",
|
|
10604
|
-
"x3dvz"
|
|
10605
|
-
],
|
|
10606
|
-
"x3d+xml": "x3dz",
|
|
10607
|
-
"x3d+binary": [
|
|
10608
|
-
"x3db",
|
|
10609
|
-
"x3dbz"
|
|
10610
|
-
],
|
|
10611
|
-
"vnd.collada+xml": "dae",
|
|
10612
|
-
"vnd.dwf": "dwf",
|
|
10613
|
-
"vnd.gdl": "gdl",
|
|
10614
|
-
"vnd.gtw": "gtw",
|
|
10615
|
-
"vnd.mts": "mts",
|
|
10616
|
-
"vnd.usdz+zip": "usdz",
|
|
10617
|
-
"vnd.vtu": "vtu"
|
|
10618
|
-
},
|
|
10619
|
-
"text": {
|
|
10620
|
-
"cache-manifest": [
|
|
10621
|
-
"manifest",
|
|
10622
|
-
"appcache"
|
|
10623
|
-
],
|
|
10624
|
-
"calendar": [
|
|
10625
|
-
"ics",
|
|
10626
|
-
"icz",
|
|
10627
|
-
"ifb"
|
|
10628
|
-
],
|
|
10629
|
-
"css": "css",
|
|
10630
|
-
"csv": "csv",
|
|
10631
|
-
"h323": "323",
|
|
10632
|
-
"html": [
|
|
10633
|
-
"html",
|
|
10634
|
-
"htm",
|
|
10635
|
-
"shtml",
|
|
10636
|
-
"stm"
|
|
10637
|
-
],
|
|
10638
|
-
"iuls": "uls",
|
|
10639
|
-
"plain": [
|
|
10640
|
-
"txt",
|
|
10641
|
-
"text",
|
|
10642
|
-
"brf",
|
|
10643
|
-
"conf",
|
|
10644
|
-
"def",
|
|
10645
|
-
"list",
|
|
10646
|
-
"log",
|
|
10647
|
-
"in",
|
|
10648
|
-
"bas",
|
|
10649
|
-
"diff",
|
|
10650
|
-
"ksh"
|
|
10651
|
-
],
|
|
10652
|
-
"richtext": "rtx",
|
|
10653
|
-
"scriptlet": [
|
|
10654
|
-
"sct",
|
|
10655
|
-
"wsc"
|
|
10656
|
-
],
|
|
10657
|
-
"texmacs": "tm",
|
|
10658
|
-
"tab-separated-values": "tsv",
|
|
10659
|
-
"vnd.sun.j2me.app-descriptor": "jad",
|
|
10660
|
-
"vnd.wap.wml": "wml",
|
|
10661
|
-
"vnd.wap.wmlscript": "wmls",
|
|
10662
|
-
"x-bibtex": "bib",
|
|
10663
|
-
"x-boo": "boo",
|
|
10664
|
-
"x-c++hdr": [
|
|
10665
|
-
"h++",
|
|
10666
|
-
"hpp",
|
|
10667
|
-
"hxx",
|
|
10668
|
-
"hh"
|
|
10669
|
-
],
|
|
10670
|
-
"x-c++src": [
|
|
10671
|
-
"c++",
|
|
10672
|
-
"cpp",
|
|
10673
|
-
"cxx",
|
|
10674
|
-
"cc"
|
|
10675
|
-
],
|
|
10676
|
-
"x-component": "htc",
|
|
10677
|
-
"x-dsrc": "d",
|
|
10678
|
-
"x-diff": "patch",
|
|
10679
|
-
"x-haskell": "hs",
|
|
10680
|
-
"x-java": "java",
|
|
10681
|
-
"x-literate-haskell": "lhs",
|
|
10682
|
-
"x-moc": "moc",
|
|
10683
|
-
"x-pascal": [
|
|
10684
|
-
"p",
|
|
10685
|
-
"pas",
|
|
10686
|
-
"pp",
|
|
10687
|
-
"inc"
|
|
10688
|
-
],
|
|
10689
|
-
"x-pcs-gcd": "gcd",
|
|
10690
|
-
"x-python": "py",
|
|
10691
|
-
"x-scala": "scala",
|
|
10692
|
-
"x-setext": "etx",
|
|
10693
|
-
"x-tcl": [
|
|
10694
|
-
"tcl",
|
|
10695
|
-
"tk"
|
|
10696
|
-
],
|
|
10697
|
-
"x-tex": [
|
|
10698
|
-
"tex",
|
|
10699
|
-
"ltx",
|
|
10700
|
-
"sty",
|
|
10701
|
-
"cls"
|
|
10702
|
-
],
|
|
10703
|
-
"x-vcalendar": "vcs",
|
|
10704
|
-
"x-vcard": "vcf",
|
|
10705
|
-
"n3": "n3",
|
|
10706
|
-
"prs.lines.tag": "dsc",
|
|
10707
|
-
"sgml": [
|
|
10708
|
-
"sgml",
|
|
10709
|
-
"sgm"
|
|
10710
|
-
],
|
|
10711
|
-
"troff": [
|
|
10712
|
-
"t",
|
|
10713
|
-
"tr",
|
|
10714
|
-
"roff",
|
|
10715
|
-
"man",
|
|
10716
|
-
"me",
|
|
10717
|
-
"ms"
|
|
10718
|
-
],
|
|
10719
|
-
"turtle": "ttl",
|
|
10720
|
-
"uri-list": [
|
|
10721
|
-
"uri",
|
|
10722
|
-
"uris",
|
|
10723
|
-
"urls"
|
|
10724
|
-
],
|
|
10725
|
-
"vcard": "vcard",
|
|
10726
|
-
"vnd.curl": "curl",
|
|
10727
|
-
"vnd.curl.dcurl": "dcurl",
|
|
10728
|
-
"vnd.curl.scurl": "scurl",
|
|
10729
|
-
"vnd.curl.mcurl": "mcurl",
|
|
10730
|
-
"vnd.dvb.subtitle": "sub",
|
|
10731
|
-
"vnd.fly": "fly",
|
|
10732
|
-
"vnd.fmi.flexstor": "flx",
|
|
10733
|
-
"vnd.graphviz": "gv",
|
|
10734
|
-
"vnd.in3d.3dml": "3dml",
|
|
10735
|
-
"vnd.in3d.spot": "spot",
|
|
10736
|
-
"x-asm": [
|
|
10737
|
-
"s",
|
|
10738
|
-
"asm"
|
|
10739
|
-
],
|
|
10740
|
-
"x-c": [
|
|
10741
|
-
"c",
|
|
10742
|
-
"h",
|
|
10743
|
-
"dic"
|
|
10744
|
-
],
|
|
10745
|
-
"x-fortran": [
|
|
10746
|
-
"f",
|
|
10747
|
-
"for",
|
|
10748
|
-
"f77",
|
|
10749
|
-
"f90"
|
|
10750
|
-
],
|
|
10751
|
-
"x-opml": "opml",
|
|
10752
|
-
"x-nfo": "nfo",
|
|
10753
|
-
"x-sfv": "sfv",
|
|
10754
|
-
"x-uuencode": "uu",
|
|
10755
|
-
"webviewhtml": "htt",
|
|
10756
|
-
"javascript": "js",
|
|
10757
|
-
"json": "json",
|
|
10758
|
-
"markdown": [
|
|
10759
|
-
"md",
|
|
10760
|
-
"markdown",
|
|
10761
|
-
"mdown",
|
|
10762
|
-
"markdn"
|
|
10763
|
-
],
|
|
10764
|
-
"vnd.wap.si": "si",
|
|
10765
|
-
"vnd.wap.sl": "sl"
|
|
10766
|
-
},
|
|
10767
|
-
"video": {
|
|
10768
|
-
"3gpp": "3gp",
|
|
10769
|
-
"annodex": "axv",
|
|
10770
|
-
"dl": "dl",
|
|
10771
|
-
"dv": [
|
|
10772
|
-
"dif",
|
|
10773
|
-
"dv"
|
|
10774
|
-
],
|
|
10775
|
-
"fli": "fli",
|
|
10776
|
-
"gl": "gl",
|
|
10777
|
-
"mpeg": [
|
|
10778
|
-
"mpeg",
|
|
10779
|
-
"mpg",
|
|
10780
|
-
"mpe",
|
|
10781
|
-
"m1v",
|
|
10782
|
-
"m2v",
|
|
10783
|
-
"mp2",
|
|
10784
|
-
"mpa",
|
|
10785
|
-
"mpv2"
|
|
10786
|
-
],
|
|
10787
|
-
"mp4": [
|
|
10788
|
-
"mp4",
|
|
10789
|
-
"mp4v",
|
|
10790
|
-
"mpg4"
|
|
10791
|
-
],
|
|
10792
|
-
"quicktime": [
|
|
10793
|
-
"qt",
|
|
10794
|
-
"mov"
|
|
10795
|
-
],
|
|
10796
|
-
"ogg": "ogv",
|
|
10797
|
-
"vnd.mpegurl": [
|
|
10798
|
-
"mxu",
|
|
10799
|
-
"m4u"
|
|
10800
|
-
],
|
|
10801
|
-
"x-flv": "flv",
|
|
10802
|
-
"x-la-asf": [
|
|
10803
|
-
"lsf",
|
|
10804
|
-
"lsx"
|
|
10805
|
-
],
|
|
10806
|
-
"x-mng": "mng",
|
|
10807
|
-
"x-ms-asf": [
|
|
10808
|
-
"asf",
|
|
10809
|
-
"asx",
|
|
10810
|
-
"asr"
|
|
10811
|
-
],
|
|
10812
|
-
"x-ms-wm": "wm",
|
|
10813
|
-
"x-ms-wmv": "wmv",
|
|
10814
|
-
"x-ms-wmx": "wmx",
|
|
10815
|
-
"x-ms-wvx": "wvx",
|
|
10816
|
-
"x-msvideo": "avi",
|
|
10817
|
-
"x-sgi-movie": "movie",
|
|
10818
|
-
"x-matroska": [
|
|
10819
|
-
"mpv",
|
|
10820
|
-
"mkv",
|
|
10821
|
-
"mk3d",
|
|
10822
|
-
"mks"
|
|
10823
|
-
],
|
|
10824
|
-
"3gpp2": "3g2",
|
|
10825
|
-
"h261": "h261",
|
|
10826
|
-
"h263": "h263",
|
|
10827
|
-
"h264": "h264",
|
|
10828
|
-
"jpeg": "jpgv",
|
|
10829
|
-
"jpm": [
|
|
10830
|
-
"jpm",
|
|
10831
|
-
"jpgm"
|
|
10832
|
-
],
|
|
10833
|
-
"mj2": [
|
|
10834
|
-
"mj2",
|
|
10835
|
-
"mjp2"
|
|
10836
|
-
],
|
|
10837
|
-
"vnd.dece.hd": [
|
|
10838
|
-
"uvh",
|
|
10839
|
-
"uvvh"
|
|
10840
|
-
],
|
|
10841
|
-
"vnd.dece.mobile": [
|
|
10842
|
-
"uvm",
|
|
10843
|
-
"uvvm"
|
|
10844
|
-
],
|
|
10845
|
-
"vnd.dece.pd": [
|
|
10846
|
-
"uvp",
|
|
10847
|
-
"uvvp"
|
|
10848
|
-
],
|
|
10849
|
-
"vnd.dece.sd": [
|
|
10850
|
-
"uvs",
|
|
10851
|
-
"uvvs"
|
|
10852
|
-
],
|
|
10853
|
-
"vnd.dece.video": [
|
|
10854
|
-
"uvv",
|
|
10855
|
-
"uvvv"
|
|
10856
|
-
],
|
|
10857
|
-
"vnd.dvb.file": "dvb",
|
|
10858
|
-
"vnd.fvt": "fvt",
|
|
10859
|
-
"vnd.ms-playready.media.pyv": "pyv",
|
|
10860
|
-
"vnd.uvvu.mp4": [
|
|
10861
|
-
"uvu",
|
|
10862
|
-
"uvvu"
|
|
10863
|
-
],
|
|
10864
|
-
"vnd.vivo": "viv",
|
|
10865
|
-
"webm": "webm",
|
|
10866
|
-
"x-f4v": "f4v",
|
|
10867
|
-
"x-m4v": "m4v",
|
|
10868
|
-
"x-ms-vob": "vob",
|
|
10869
|
-
"x-smv": "smv",
|
|
10870
|
-
"mp2t": "ts"
|
|
10871
|
-
},
|
|
10872
|
-
"x-conference": {
|
|
10873
|
-
"x-cooltalk": "ice"
|
|
10874
|
-
},
|
|
10875
|
-
"x-world": {
|
|
10876
|
-
"x-vrml": [
|
|
10877
|
-
"vrm",
|
|
10878
|
-
"flr",
|
|
10879
|
-
"wrz",
|
|
10880
|
-
"xaf",
|
|
10881
|
-
"xof"
|
|
10882
|
-
]
|
|
10883
|
-
}
|
|
10884
|
-
};
|
|
10885
|
-
|
|
10886
9425
|
let mimeTypes;
|
|
10887
9426
|
|
|
10888
9427
|
function getMimeType(filename) {
|
|
@@ -10891,17 +9430,25 @@
|
|
|
10891
9430
|
|
|
10892
9431
|
function getMimeTypes() {
|
|
10893
9432
|
if (!mimeTypes) {
|
|
10894
|
-
mimeTypes =
|
|
10895
|
-
|
|
10896
|
-
|
|
10897
|
-
|
|
10898
|
-
|
|
10899
|
-
|
|
10900
|
-
|
|
10901
|
-
|
|
10902
|
-
|
|
10903
|
-
|
|
10904
|
-
|
|
9433
|
+
mimeTypes = decodeMimeTypes(encodedMimeTypes);
|
|
9434
|
+
}
|
|
9435
|
+
return mimeTypes;
|
|
9436
|
+
}
|
|
9437
|
+
|
|
9438
|
+
function decodeMimeTypes(data) {
|
|
9439
|
+
const mimeTypes = Object.create(null);
|
|
9440
|
+
for (const block of data.split(";")) {
|
|
9441
|
+
const colonIndex = block.indexOf(":");
|
|
9442
|
+
const type = block.slice(0, colonIndex);
|
|
9443
|
+
let previousSubtype = "";
|
|
9444
|
+
for (const entry of block.slice(colonIndex + 1).split(",")) {
|
|
9445
|
+
const tokens = entry.split(" ");
|
|
9446
|
+
const subtype = previousSubtype.slice(0, Number.parseInt(tokens[0][0], 36)) + tokens[0].slice(1);
|
|
9447
|
+
previousSubtype = subtype;
|
|
9448
|
+
const expandedSubtype = subtype.replace(/!/g, "+xml");
|
|
9449
|
+
const extensions = tokens.length > 1 ? tokens.slice(1) : [expandedSubtype.split("+")[0]];
|
|
9450
|
+
for (const extension of extensions) {
|
|
9451
|
+
mimeTypes[extension] = type + "/" + expandedSubtype;
|
|
10905
9452
|
}
|
|
10906
9453
|
}
|
|
10907
9454
|
}
|
|
@@ -10937,7 +9484,7 @@
|
|
|
10937
9484
|
*/
|
|
10938
9485
|
|
|
10939
9486
|
|
|
10940
|
-
|
|
9487
|
+
n$1(setDefaultConfiguration);
|
|
10941
9488
|
|
|
10942
9489
|
exports.BlobReader = BlobReader;
|
|
10943
9490
|
exports.BlobWriter = BlobWriter;
|