oipage 1.9.0 → 1.10.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (67) hide show
  1. package/CHANGELOG +10 -1
  2. package/bin/WebSocket/decodeWsFrame.js +43 -43
  3. package/bin/WebSocket/encodeWsFrame.js +28 -28
  4. package/bin/WebSocket/headersToJSON.js +26 -26
  5. package/bin/WebSocket/index.js +80 -80
  6. package/bin/data/mineTypes.json +104 -104
  7. package/bin/disk.js +42 -42
  8. package/bin/help.js +50 -48
  9. package/bin/intercept.js +15 -15
  10. package/bin/network.js +21 -21
  11. package/bin/proxy.js +75 -75
  12. package/bin/run +134 -132
  13. package/bin/serve.d.ts +76 -71
  14. package/bin/serve.js +188 -187
  15. package/bin/template/404.html +184 -186
  16. package/bin/tools/deleteEmptyFolder.js +33 -33
  17. package/bin/tools/format.js +75 -75
  18. package/bin/tools/network.js +42 -42
  19. package/bin/tools/openBrowser.js +25 -25
  20. package/bin/tools/resolve404.js +83 -83
  21. package/bin/tools/resolveImport.js +88 -88
  22. package/bin/website-htmls/components/ui-select-file/index.html +8 -8
  23. package/bin/website-htmls/components/ui-select-file/index.js +42 -42
  24. package/bin/website-htmls/components/ui-select-file/index.scss +44 -44
  25. package/bin/website-htmls/dialogs/imageSize/index.html +54 -54
  26. package/bin/website-htmls/dialogs/imageSize/index.js +53 -53
  27. package/bin/website-htmls/dialogs/imageSize/index.scss +140 -138
  28. package/bin/website-htmls/dialogs/index.js +52 -52
  29. package/bin/website-htmls/images/addFile.svg +1 -1
  30. package/bin/website-htmls/images/img-to-pdf.svg +1 -1
  31. package/bin/website-htmls/images/recorder-screen.png +0 -0
  32. package/bin/website-htmls/index.html +17 -17
  33. package/bin/website-htmls/main.js +13 -13
  34. package/bin/website-htmls/pages/App/index.html +6 -6
  35. package/bin/website-htmls/pages/App/index.js +22 -22
  36. package/bin/website-htmls/pages/App/index.scss +43 -43
  37. package/bin/website-htmls/pages/appStore/index.html +5 -5
  38. package/bin/website-htmls/pages/appStore/index.js +19 -19
  39. package/bin/website-htmls/pages/appStore/index.scss +43 -43
  40. package/bin/website-htmls/pages/chart/index.html +8 -8
  41. package/bin/website-htmls/pages/chart/index.js +72 -72
  42. package/bin/website-htmls/pages/chart/index.scss +71 -71
  43. package/bin/website-htmls/pages/home/index.html +19 -15
  44. package/bin/website-htmls/pages/home/index.js +19 -19
  45. package/bin/website-htmls/pages/home/index.scss +87 -87
  46. package/bin/website-htmls/pages/image-editor/index.html +27 -27
  47. package/bin/website-htmls/pages/image-editor/index.js +106 -106
  48. package/bin/website-htmls/pages/image-editor/index.scss +69 -69
  49. package/bin/website-htmls/pages/img-to-pdf/index.html +3 -3
  50. package/bin/website-htmls/pages/img-to-pdf/index.js +44 -44
  51. package/bin/website-htmls/pages/img-to-pdf/index.scss +9 -9
  52. package/bin/website-htmls/pages/recorder-screen/index.html +16 -0
  53. package/bin/website-htmls/pages/recorder-screen/index.js +228 -0
  54. package/bin/website-htmls/pages/recorder-screen/index.scss +53 -0
  55. package/bin/website-htmls/router.config.js +29 -26
  56. package/bin/website-htmls/styles/common.css +44 -44
  57. package/bin/website-htmls/styles/normalize.css +94 -94
  58. package/bin/website-plugins/intercept/chart.js +33 -33
  59. package/bin/website-plugins/intercept/getPackage.js +17 -17
  60. package/bin/website-plugins/intercept/head.js +8 -8
  61. package/bin/website-plugins/intercept/index.js +8 -8
  62. package/bin/website-plugins/intercept/oipage-vislite-intercept.js +30 -30
  63. package/bin/website-plugins/intercept/oipage-zipaper-intercept.js +36 -36
  64. package/bin/website-plugins/loader/index.js +11 -11
  65. package/bin/website-plugins/loader/oipage-html-loader.js +7 -7
  66. package/bin/website-plugins/loader/oipage-scss-loader.js +149 -149
  67. package/package.json +1 -1
package/CHANGELOG CHANGED
@@ -180,4 +180,13 @@ v1.9.0:
180
180
  - 优化改造
181
181
  1、调整打包若干细节
182
182
  2、针对应用市场优化UI设计
183
- 3、优化oipage-cli disk --delempty 命令路径不存在时提示
183
+ 3、优化oipage-cli disk --delempty 命令路径不存在时提示
184
+ v1.10.0:
185
+ date:2026-03-27
186
+ changes:
187
+ - 优化改造
188
+ 1、补充应用市场是否启动开关
189
+ - 新增功能
190
+ 1、开发服务器 / 应用市场
191
+ * 屏幕录制
192
+
@@ -1,43 +1,43 @@
1
-
2
- // 处理收到的数据
3
- module.exports = function decodeWsFrame(data) {
4
- let start = 0;
5
- let frame = {
6
- isFinal: (data[start] & 0x80) === 0x80,
7
- opcode: data[start++] & 0xF,
8
- masked: (data[start] & 0x80) === 0x80,
9
- payloadLen: data[start++] & 0x7F,
10
- maskingKey: '',
11
- payloadData: null
12
- };
13
-
14
- if (frame.payloadLen === 126) {
15
- frame.payloadLen = (data[start++] << 8) + data[start++];
16
- } else if (frame.payloadLen === 127) {
17
- frame.payloadLen = 0;
18
- for (let i = 7; i >= 0; --i) {
19
- frame.payloadLen += (data[start++] << (i * 8));
20
- }
21
- }
22
-
23
- if (frame.payloadLen) {
24
- if (frame.masked) {
25
- const maskingKey = [
26
- data[start++],
27
- data[start++],
28
- data[start++],
29
- data[start++]
30
- ];
31
-
32
- frame.maskingKey = maskingKey;
33
-
34
- frame.payloadData = data
35
- .slice(start, start + frame.payloadLen)
36
- .map((byte, idx) => byte ^ maskingKey[idx % 4]);
37
- } else {
38
- frame.payloadData = data.slice(start, start + frame.payloadLen);
39
- }
40
- }
41
-
42
- return frame;
43
- };
1
+
2
+ // 处理收到的数据
3
+ module.exports = function decodeWsFrame(data) {
4
+ let start = 0;
5
+ let frame = {
6
+ isFinal: (data[start] & 0x80) === 0x80,
7
+ opcode: data[start++] & 0xF,
8
+ masked: (data[start] & 0x80) === 0x80,
9
+ payloadLen: data[start++] & 0x7F,
10
+ maskingKey: '',
11
+ payloadData: null
12
+ };
13
+
14
+ if (frame.payloadLen === 126) {
15
+ frame.payloadLen = (data[start++] << 8) + data[start++];
16
+ } else if (frame.payloadLen === 127) {
17
+ frame.payloadLen = 0;
18
+ for (let i = 7; i >= 0; --i) {
19
+ frame.payloadLen += (data[start++] << (i * 8));
20
+ }
21
+ }
22
+
23
+ if (frame.payloadLen) {
24
+ if (frame.masked) {
25
+ const maskingKey = [
26
+ data[start++],
27
+ data[start++],
28
+ data[start++],
29
+ data[start++]
30
+ ];
31
+
32
+ frame.maskingKey = maskingKey;
33
+
34
+ frame.payloadData = data
35
+ .slice(start, start + frame.payloadLen)
36
+ .map((byte, idx) => byte ^ maskingKey[idx % 4]);
37
+ } else {
38
+ frame.payloadData = data.slice(start, start + frame.payloadLen);
39
+ }
40
+ }
41
+
42
+ return frame;
43
+ };
@@ -1,28 +1,28 @@
1
-
2
- // 处理发出的数据
3
- module.exports = function encodeWsFrame(data) {
4
- const isFinal = data.isFinal !== undefined ? data.isFinal : true,
5
- opcode = data.opcode !== undefined ? data.opcode : 1,
6
- payloadData = data.payloadData ? Buffer.from(data.payloadData) : null,
7
- payloadLen = payloadData ? payloadData.length : 0;
8
-
9
- let frame = [];
10
-
11
- if (isFinal) frame.push((1 << 7) + opcode);
12
- else frame.push(opcode);
13
-
14
- if (payloadLen < 126) {
15
- frame.push(payloadLen);
16
- } else if (payloadLen < 65536) {
17
- frame.push(126, payloadLen >> 8, payloadLen & 0xFF);
18
- } else {
19
- frame.push(127);
20
- for (let i = 7; i >= 0; --i) {
21
- frame.push((payloadLen & (0xFF << (i * 8))) >> (i * 8));
22
- }
23
- }
24
-
25
- frame = payloadData ? Buffer.concat([Buffer.from(frame), payloadData]) : Buffer.from(frame);
26
-
27
- return frame;
28
- };
1
+
2
+ // 处理发出的数据
3
+ module.exports = function encodeWsFrame(data) {
4
+ const isFinal = data.isFinal !== undefined ? data.isFinal : true,
5
+ opcode = data.opcode !== undefined ? data.opcode : 1,
6
+ payloadData = data.payloadData ? Buffer.from(data.payloadData) : null,
7
+ payloadLen = payloadData ? payloadData.length : 0;
8
+
9
+ let frame = [];
10
+
11
+ if (isFinal) frame.push((1 << 7) + opcode);
12
+ else frame.push(opcode);
13
+
14
+ if (payloadLen < 126) {
15
+ frame.push(payloadLen);
16
+ } else if (payloadLen < 65536) {
17
+ frame.push(126, payloadLen >> 8, payloadLen & 0xFF);
18
+ } else {
19
+ frame.push(127);
20
+ for (let i = 7; i >= 0; --i) {
21
+ frame.push((payloadLen & (0xFF << (i * 8))) >> (i * 8));
22
+ }
23
+ }
24
+
25
+ frame = payloadData ? Buffer.concat([Buffer.from(frame), payloadData]) : Buffer.from(frame);
26
+
27
+ return frame;
28
+ };
@@ -1,26 +1,26 @@
1
- module.exports = function (headersStr) {
2
-
3
- let headersArray = headersStr.split(/\r{0,1}\n/);
4
- let headersJSON = {};
5
-
6
- // 第一行的内容:GET / HTTP/1.1
7
- let firstLine = headersArray.shift().split(' ');
8
- headersJSON.method = firstLine[0];
9
- headersJSON.url = firstLine[1];
10
- headersJSON.protocol = firstLine[2];
11
-
12
- for (let item of headersArray) {
13
- let temp = item.split(':');
14
-
15
- if (temp.length > 1) {
16
-
17
- let key = temp.shift();
18
- let value = temp.join(':');
19
-
20
- headersJSON[key] = value.trim();
21
-
22
- }
23
- }
24
-
25
- return headersJSON;
26
- };
1
+ module.exports = function (headersStr) {
2
+
3
+ let headersArray = headersStr.split(/\r{0,1}\n/);
4
+ let headersJSON = {};
5
+
6
+ // 第一行的内容:GET / HTTP/1.1
7
+ let firstLine = headersArray.shift().split(' ');
8
+ headersJSON.method = firstLine[0];
9
+ headersJSON.url = firstLine[1];
10
+ headersJSON.protocol = firstLine[2];
11
+
12
+ for (let item of headersArray) {
13
+ let temp = item.split(':');
14
+
15
+ if (temp.length > 1) {
16
+
17
+ let key = temp.shift();
18
+ let value = temp.join(':');
19
+
20
+ headersJSON[key] = value.trim();
21
+
22
+ }
23
+ }
24
+
25
+ return headersJSON;
26
+ };
@@ -1,80 +1,80 @@
1
- const net = require('net');
2
- const crypto = require('crypto');
3
-
4
- const headersToJSON = require('./headersToJSON');
5
- const decodeWsFrame = require('./decodeWsFrame');
6
- const encodeWsFrame = require('./encodeWsFrame');
7
-
8
- module.exports = function (port, name, version) {
9
- let sockets = [];
10
-
11
- let handler = {
12
- notifyBrowser: (msg) => {
13
- for (let socket of sockets) {
14
- socket.write(encodeWsFrame(msg));
15
- }
16
- }
17
- };
18
-
19
- const server = net.createServer(socket => {
20
-
21
- // 错误
22
- socket.on('error', (error) => {
23
- console.log('Connection error:', error.message);
24
- });
25
-
26
- // 数据
27
- socket.on('data', buffer => {
28
- console.log('Connection data:' + (decodeWsFrame(buffer).payloadData?.toString() || "断开连接......"));
29
- });
30
-
31
- // 连接
32
- socket.once('data', buffer => {
33
-
34
- // 把请求头变成容易操作的json
35
- const headers = headersToJSON(buffer.toString());
36
-
37
- // 如果是ws请求
38
- // 就需要建立连接
39
- if (headers.Upgrade == 'websocket') {
40
-
41
- if (headers['Sec-WebSocket-Version'] !== '13') {
42
- console.log('\r\n警告:当前WebSocket版本为' + headers['Sec-WebSocket-Version'] + ",可能存在兼容问题~\r\n");
43
- }
44
-
45
- // 开始连接
46
- /*
47
- 协议中规定的校验用GUID,可参考如下链接:
48
- https://tools.ietf.org/html/rfc6455#section-5.5.2
49
- https://stackoverflow.com/questions/13456017/what-does-258eafa5-e914-47da-95ca-c5ab0dc85b11-means-in-websocket-protocol
50
- */
51
- const GUID = '258EAFA5-E914-47DA-95CA-C5AB0DC85B11';
52
- const key = headers['Sec-WebSocket-Key'];
53
- const hash = crypto.createHash('sha1'); // 创建一个签名算法为sha1的哈希对象
54
-
55
- hash.update(`${key}${GUID}`); // 将key和GUID连接后,更新到hash
56
- const result = hash.digest('base64'); // 生成base64字符串
57
- const header = `HTTP/1.1 101 Switching Protocols\r\nServer: Powered by ${name}@${version}\r\nUpgrade: websocket\r\nConnection: Upgrade\r\nSec-Websocket-Accept: ${result}\r\n\r\n`; // 生成供前端校验用的请求头
58
-
59
- socket.write(header); // 返回HTTP头,告知客户端校验结果,HTTP状态码101表示切换协议:https://httpstatuses.com/101。
60
- // 若客户端校验结果正确,在控制台的Network模块可以看到HTTP请求的状态码变为101 Switching Protocols,同时客户端的ws.onopen事件被触发。
61
-
62
- sockets.push(socket);
63
- }
64
-
65
- // 否则就普通的,
66
- // 普通的由http服务器提供支持
67
- else {
68
- socket.end();
69
-
70
- }
71
- });
72
- });
73
-
74
- // 启动
75
- server.listen(port);
76
-
77
- console.log('<i> \x1b[1m\x1b[32m[' + name + '] Loopback: \x1b[36mws://localhost:' + port + '/\x1b[0m\n');
78
-
79
- return handler;
80
- };
1
+ const net = require('net');
2
+ const crypto = require('crypto');
3
+
4
+ const headersToJSON = require('./headersToJSON');
5
+ const decodeWsFrame = require('./decodeWsFrame');
6
+ const encodeWsFrame = require('./encodeWsFrame');
7
+
8
+ module.exports = function (port, name, version) {
9
+ let sockets = [];
10
+
11
+ let handler = {
12
+ notifyBrowser: (msg) => {
13
+ for (let socket of sockets) {
14
+ socket.write(encodeWsFrame(msg));
15
+ }
16
+ }
17
+ };
18
+
19
+ const server = net.createServer(socket => {
20
+
21
+ // 错误
22
+ socket.on('error', (error) => {
23
+ console.log('Connection error:', error.message);
24
+ });
25
+
26
+ // 数据
27
+ socket.on('data', buffer => {
28
+ console.log('Connection data:' + (decodeWsFrame(buffer).payloadData?.toString() || "断开连接......"));
29
+ });
30
+
31
+ // 连接
32
+ socket.once('data', buffer => {
33
+
34
+ // 把请求头变成容易操作的json
35
+ const headers = headersToJSON(buffer.toString());
36
+
37
+ // 如果是ws请求
38
+ // 就需要建立连接
39
+ if (headers.Upgrade == 'websocket') {
40
+
41
+ if (headers['Sec-WebSocket-Version'] !== '13') {
42
+ console.log('\r\n警告:当前WebSocket版本为' + headers['Sec-WebSocket-Version'] + ",可能存在兼容问题~\r\n");
43
+ }
44
+
45
+ // 开始连接
46
+ /*
47
+ 协议中规定的校验用GUID,可参考如下链接:
48
+ https://tools.ietf.org/html/rfc6455#section-5.5.2
49
+ https://stackoverflow.com/questions/13456017/what-does-258eafa5-e914-47da-95ca-c5ab0dc85b11-means-in-websocket-protocol
50
+ */
51
+ const GUID = '258EAFA5-E914-47DA-95CA-C5AB0DC85B11';
52
+ const key = headers['Sec-WebSocket-Key'];
53
+ const hash = crypto.createHash('sha1'); // 创建一个签名算法为sha1的哈希对象
54
+
55
+ hash.update(`${key}${GUID}`); // 将key和GUID连接后,更新到hash
56
+ const result = hash.digest('base64'); // 生成base64字符串
57
+ const header = `HTTP/1.1 101 Switching Protocols\r\nServer: Powered by ${name}@${version}\r\nUpgrade: websocket\r\nConnection: Upgrade\r\nSec-Websocket-Accept: ${result}\r\n\r\n`; // 生成供前端校验用的请求头
58
+
59
+ socket.write(header); // 返回HTTP头,告知客户端校验结果,HTTP状态码101表示切换协议:https://httpstatuses.com/101。
60
+ // 若客户端校验结果正确,在控制台的Network模块可以看到HTTP请求的状态码变为101 Switching Protocols,同时客户端的ws.onopen事件被触发。
61
+
62
+ sockets.push(socket);
63
+ }
64
+
65
+ // 否则就普通的,
66
+ // 普通的由http服务器提供支持
67
+ else {
68
+ socket.end();
69
+
70
+ }
71
+ });
72
+ });
73
+
74
+ // 启动
75
+ server.listen(port);
76
+
77
+ console.log('<i> \x1b[1m\x1b[32m[' + name + '] Loopback: \x1b[36mws://localhost:' + port + '/\x1b[0m\n');
78
+
79
+ return handler;
80
+ };
@@ -1,105 +1,105 @@
1
- {
2
- "html": "text/html",
3
- "htm": "text/html",
4
- "shtml": "text/html",
5
- "css": "text/css",
6
- "xml": "text/xml",
7
- "gif": "image/gif",
8
- "jpeg": "image/jpeg",
9
- "jpg": "image/jpeg",
10
- "js": "application/javascript",
11
- "atom": "application/atom+xml",
12
- "rss": "application/rss+xml",
13
- "mml": "text/mathml",
14
- "txt": "text/plain",
15
- "jad": "text/vnd.sun.j2me.app-descriptor",
16
- "wml": "text/vnd.wap.wml",
17
- "htc": "text/x-component",
18
- "png": "image/png",
19
- "tif": "image/tiff",
20
- "tiff": "image/tiff",
21
- "wbmp": "image/vnd.wap.wbmp",
22
- "ico": "image/x-icon",
23
- "jng": "image/x-jng",
24
- "bmp": "image/x-ms-bmp",
25
- "svg": "image/svg+xml",
26
- "svgz": "image/svg+xml",
27
- "webp": "image/webp",
28
- "woff": "application/font-woff",
29
- "jar": "application/java-archive",
30
- "war": "application/java-archive",
31
- "ear": "application/java-archive",
32
- "json": "application/json",
33
- "hqx": "application/mac-binhex40",
34
- "doc": "application/msword",
35
- "pdf": "application/pdf",
36
- "ps": "application/postscript",
37
- "eps": "application/postscript",
38
- "ai": "application/postscript",
39
- "rtf": "application/rtf",
40
- "m3u8": "application/vnd.apple.mpegurl",
41
- "xls": "application/vnd.ms-excel",
42
- "eot": "application/vnd.ms-fontobject",
43
- "ppt": "application/vnd.ms-powerpoint",
44
- "wmlc": "application/vnd.wap.wmlc",
45
- "kml": "application/vnd.google-earth.kml+xml",
46
- "kmz": "application/vnd.google-earth.kmz",
47
- "7z": "application/x-7z-compressed",
48
- "cco": "application/x-cocoa",
49
- "jardiff": "application/x-java-archive-diff",
50
- "jnlp": "application/x-java-jnlp-file",
51
- "run": "application/x-makeself",
52
- "pl": "application/x-perl",
53
- "pm": "application/x-perl",
54
- "prc": "application/x-pilot",
55
- "pdb": "application/x-pilot",
56
- "rar": "application/x-rar-compressed",
57
- "rpm": "application/x-redhat-package-manager",
58
- "sea": "application/x-sea",
59
- "swf": "application/x-shockwave-flash",
60
- "sit": "application/x-stuffit",
61
- "tcl": "application/x-tcl",
62
- "tk": "application/x-tcl",
63
- "der": "application/x-x509-ca-cert",
64
- "pem": "application/x-x509-ca-cert",
65
- "crt": "application/x-x509-ca-cert",
66
- "xpi": "application/x-xpinstall",
67
- "xhtml": "application/xhtml+xml",
68
- "xspf": "application/xspf+xml",
69
- "zip": "application/zip",
70
- "bin": "application/octet-stream",
71
- "exe": "application/octet-stream",
72
- "dll": "application/octet-stream",
73
- "deb": "application/octet-stream",
74
- "dmg": "application/octet-stream",
75
- "iso": "application/octet-stream",
76
- "img": "application/octet-stream",
77
- "msi": "application/octet-stream",
78
- "msp": "application/octet-stream",
79
- "msm": "application/octet-stream",
80
- "docx": "application/vnd.openxmlformats-officedocument.wordprocessingml.document",
81
- "xlsx": "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
82
- "pptx": "application/vnd.openxmlformats-officedocument.presentationml.presentation",
83
- "mid": "audio/midi",
84
- "midi": "audio/midi",
85
- "kar": "audio/midi",
86
- "mp3": "audio/mpeg",
87
- "ogg": "audio/ogg",
88
- "m4a": "audio/x-m4a",
89
- "ra": "audio/x-realaudio",
90
- "3gpp": "video/3gpp",
91
- "3gp": "video/3gpp",
92
- "ts": "video/mp2t",
93
- "mp4": "video/mp4",
94
- "mpeg": "video/mpeg",
95
- "mpg": "video/mpeg",
96
- "mov": "video/quicktime",
97
- "webm": "video/webm",
98
- "flv": "video/x-flv",
99
- "m4v": "video/x-m4v",
100
- "mng": "video/x-mng",
101
- "asx": "video/x-ms-asf",
102
- "asf": "video/x-ms-asf",
103
- "wmv": "video/x-ms-wmv",
104
- "avi": "video/x-msvideo"
1
+ {
2
+ "html": "text/html",
3
+ "htm": "text/html",
4
+ "shtml": "text/html",
5
+ "css": "text/css",
6
+ "xml": "text/xml",
7
+ "gif": "image/gif",
8
+ "jpeg": "image/jpeg",
9
+ "jpg": "image/jpeg",
10
+ "js": "application/javascript",
11
+ "atom": "application/atom+xml",
12
+ "rss": "application/rss+xml",
13
+ "mml": "text/mathml",
14
+ "txt": "text/plain",
15
+ "jad": "text/vnd.sun.j2me.app-descriptor",
16
+ "wml": "text/vnd.wap.wml",
17
+ "htc": "text/x-component",
18
+ "png": "image/png",
19
+ "tif": "image/tiff",
20
+ "tiff": "image/tiff",
21
+ "wbmp": "image/vnd.wap.wbmp",
22
+ "ico": "image/x-icon",
23
+ "jng": "image/x-jng",
24
+ "bmp": "image/x-ms-bmp",
25
+ "svg": "image/svg+xml",
26
+ "svgz": "image/svg+xml",
27
+ "webp": "image/webp",
28
+ "woff": "application/font-woff",
29
+ "jar": "application/java-archive",
30
+ "war": "application/java-archive",
31
+ "ear": "application/java-archive",
32
+ "json": "application/json",
33
+ "hqx": "application/mac-binhex40",
34
+ "doc": "application/msword",
35
+ "pdf": "application/pdf",
36
+ "ps": "application/postscript",
37
+ "eps": "application/postscript",
38
+ "ai": "application/postscript",
39
+ "rtf": "application/rtf",
40
+ "m3u8": "application/vnd.apple.mpegurl",
41
+ "xls": "application/vnd.ms-excel",
42
+ "eot": "application/vnd.ms-fontobject",
43
+ "ppt": "application/vnd.ms-powerpoint",
44
+ "wmlc": "application/vnd.wap.wmlc",
45
+ "kml": "application/vnd.google-earth.kml+xml",
46
+ "kmz": "application/vnd.google-earth.kmz",
47
+ "7z": "application/x-7z-compressed",
48
+ "cco": "application/x-cocoa",
49
+ "jardiff": "application/x-java-archive-diff",
50
+ "jnlp": "application/x-java-jnlp-file",
51
+ "run": "application/x-makeself",
52
+ "pl": "application/x-perl",
53
+ "pm": "application/x-perl",
54
+ "prc": "application/x-pilot",
55
+ "pdb": "application/x-pilot",
56
+ "rar": "application/x-rar-compressed",
57
+ "rpm": "application/x-redhat-package-manager",
58
+ "sea": "application/x-sea",
59
+ "swf": "application/x-shockwave-flash",
60
+ "sit": "application/x-stuffit",
61
+ "tcl": "application/x-tcl",
62
+ "tk": "application/x-tcl",
63
+ "der": "application/x-x509-ca-cert",
64
+ "pem": "application/x-x509-ca-cert",
65
+ "crt": "application/x-x509-ca-cert",
66
+ "xpi": "application/x-xpinstall",
67
+ "xhtml": "application/xhtml+xml",
68
+ "xspf": "application/xspf+xml",
69
+ "zip": "application/zip",
70
+ "bin": "application/octet-stream",
71
+ "exe": "application/octet-stream",
72
+ "dll": "application/octet-stream",
73
+ "deb": "application/octet-stream",
74
+ "dmg": "application/octet-stream",
75
+ "iso": "application/octet-stream",
76
+ "img": "application/octet-stream",
77
+ "msi": "application/octet-stream",
78
+ "msp": "application/octet-stream",
79
+ "msm": "application/octet-stream",
80
+ "docx": "application/vnd.openxmlformats-officedocument.wordprocessingml.document",
81
+ "xlsx": "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
82
+ "pptx": "application/vnd.openxmlformats-officedocument.presentationml.presentation",
83
+ "mid": "audio/midi",
84
+ "midi": "audio/midi",
85
+ "kar": "audio/midi",
86
+ "mp3": "audio/mpeg",
87
+ "ogg": "audio/ogg",
88
+ "m4a": "audio/x-m4a",
89
+ "ra": "audio/x-realaudio",
90
+ "3gpp": "video/3gpp",
91
+ "3gp": "video/3gpp",
92
+ "ts": "video/mp2t",
93
+ "mp4": "video/mp4",
94
+ "mpeg": "video/mpeg",
95
+ "mpg": "video/mpeg",
96
+ "mov": "video/quicktime",
97
+ "webm": "video/webm",
98
+ "flv": "video/x-flv",
99
+ "m4v": "video/x-m4v",
100
+ "mng": "video/x-mng",
101
+ "asx": "video/x-ms-asf",
102
+ "asf": "video/x-ms-asf",
103
+ "wmv": "video/x-ms-wmv",
104
+ "avi": "video/x-msvideo"
105
105
  }