phirepass-widgets 0.0.55 → 0.0.57
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/dist/cjs/phirepass-sftp-client.cjs.entry.js +1 -1
- package/dist/cjs/phirepass-terminal.cjs.entry.js +1 -1
- package/dist/cjs/{protocol-DPi8rcp9.js → protocol--wTzAUUX.js} +93 -50
- package/dist/collection/phirepass-channel_bg.wasm +0 -0
- package/dist/components/p-BjjA0Lbo.js +1 -0
- package/dist/components/phirepass-sftp-client.js +1 -1
- package/dist/components/phirepass-terminal.js +1 -1
- package/dist/esm/phirepass-sftp-client.entry.js +1 -1
- package/dist/esm/phirepass-terminal.entry.js +1 -1
- package/dist/esm/{protocol-D7u6YzKp.js → protocol-BjjA0Lbo.js} +92 -49
- package/dist/phirepass-widgets/{p-21fb3b58.entry.js → p-2f7e09d3.entry.js} +1 -1
- package/dist/phirepass-widgets/{p-fec100bd.entry.js → p-7c9d8569.entry.js} +1 -1
- package/dist/phirepass-widgets/p-BjjA0Lbo.js +1 -0
- package/dist/phirepass-widgets/phirepass-channel_bg.wasm +0 -0
- package/dist/phirepass-widgets/phirepass-widgets.esm.js +1 -1
- package/package.json +3 -3
- package/dist/components/p-D7u6YzKp.js +0 -1
- package/dist/phirepass-widgets/p-D7u6YzKp.js +0 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var index = require('./index-YW0ts9D0.js');
|
|
4
|
-
var protocol = require('./protocol
|
|
4
|
+
var protocol = require('./protocol--wTzAUUX.js');
|
|
5
5
|
|
|
6
6
|
const phirepassSftpClientLogoSvg = 'data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgdmlld0JveD0iMCAwIDI0IDI0IiBmaWxsPSJub25lIgogICAgc3Ryb2tlPSJyZ2IoNDYsIDE4NCwgMTM4KSIgc3Ryb2tlLXdpZHRoPSIyIiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiCiAgICBjbGFzcz0ibHVjaWRlIGx1Y2lkZS10ZXJtaW5hbCB3LTMuNSBoLTMuNSB0ZXh0LXByaW1hcnkiPgogICAgPHBvbHlsaW5lIHBvaW50cz0iNCAxNyAxMCAxMSA0IDUiPjwvcG9seWxpbmU+CiAgICA8bGluZSB4MT0iMTIiIHgyPSIyMCIgeTE9IjE5IiB5Mj0iMTkiPjwvbGluZT4KPC9zdmc+Cg==';
|
|
7
7
|
|
|
@@ -24,14 +24,58 @@ class Channel {
|
|
|
24
24
|
const len0 = WASM_VECTOR_LEN;
|
|
25
25
|
const ptr1 = passStringToWasm0(node_id, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
26
26
|
const len1 = WASM_VECTOR_LEN;
|
|
27
|
-
wasm.channel_authenticate(this.__wbg_ptr, ptr0, len0, ptr1, len1, isLikeNone(msg_id) ?
|
|
27
|
+
wasm.channel_authenticate(this.__wbg_ptr, ptr0, len0, ptr1, len1, isLikeNone(msg_id) ? Number.MAX_SAFE_INTEGER : (msg_id) >>> 0);
|
|
28
28
|
}
|
|
29
29
|
connect() {
|
|
30
30
|
wasm.channel_connect(this.__wbg_ptr);
|
|
31
31
|
}
|
|
32
|
+
/**
|
|
33
|
+
* @param {string} node_id
|
|
34
|
+
* @param {string} kind
|
|
35
|
+
* @param {string} host
|
|
36
|
+
* @param {number} port
|
|
37
|
+
* @param {string | null} [username]
|
|
38
|
+
* @param {string | null} [password]
|
|
39
|
+
* @param {number | null} [msg_id]
|
|
40
|
+
*/
|
|
41
|
+
disable_service(node_id, kind, host, port, username, password, msg_id) {
|
|
42
|
+
const ptr0 = passStringToWasm0(node_id, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
43
|
+
const len0 = WASM_VECTOR_LEN;
|
|
44
|
+
const ptr1 = passStringToWasm0(kind, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
45
|
+
const len1 = WASM_VECTOR_LEN;
|
|
46
|
+
const ptr2 = passStringToWasm0(host, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
47
|
+
const len2 = WASM_VECTOR_LEN;
|
|
48
|
+
var ptr3 = isLikeNone(username) ? 0 : passStringToWasm0(username, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
49
|
+
var len3 = WASM_VECTOR_LEN;
|
|
50
|
+
var ptr4 = isLikeNone(password) ? 0 : passStringToWasm0(password, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
51
|
+
var len4 = WASM_VECTOR_LEN;
|
|
52
|
+
wasm.channel_disable_service(this.__wbg_ptr, ptr0, len0, ptr1, len1, ptr2, len2, port, ptr3, len3, ptr4, len4, isLikeNone(msg_id) ? Number.MAX_SAFE_INTEGER : (msg_id) >>> 0);
|
|
53
|
+
}
|
|
32
54
|
disconnect() {
|
|
33
55
|
wasm.channel_disconnect(this.__wbg_ptr);
|
|
34
56
|
}
|
|
57
|
+
/**
|
|
58
|
+
* @param {string} node_id
|
|
59
|
+
* @param {string} kind
|
|
60
|
+
* @param {string} host
|
|
61
|
+
* @param {number} port
|
|
62
|
+
* @param {string | null} [username]
|
|
63
|
+
* @param {string | null} [password]
|
|
64
|
+
* @param {number | null} [msg_id]
|
|
65
|
+
*/
|
|
66
|
+
enable_service(node_id, kind, host, port, username, password, msg_id) {
|
|
67
|
+
const ptr0 = passStringToWasm0(node_id, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
68
|
+
const len0 = WASM_VECTOR_LEN;
|
|
69
|
+
const ptr1 = passStringToWasm0(kind, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
70
|
+
const len1 = WASM_VECTOR_LEN;
|
|
71
|
+
const ptr2 = passStringToWasm0(host, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
72
|
+
const len2 = WASM_VECTOR_LEN;
|
|
73
|
+
var ptr3 = isLikeNone(username) ? 0 : passStringToWasm0(username, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
74
|
+
var len3 = WASM_VECTOR_LEN;
|
|
75
|
+
var ptr4 = isLikeNone(password) ? 0 : passStringToWasm0(password, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
76
|
+
var len4 = WASM_VECTOR_LEN;
|
|
77
|
+
wasm.channel_enable_service(this.__wbg_ptr, ptr0, len0, ptr1, len1, ptr2, len2, port, ptr3, len3, ptr4, len4, isLikeNone(msg_id) ? Number.MAX_SAFE_INTEGER : (msg_id) >>> 0);
|
|
78
|
+
}
|
|
35
79
|
/**
|
|
36
80
|
* @returns {boolean}
|
|
37
81
|
*/
|
|
@@ -59,7 +103,7 @@ class Channel {
|
|
|
59
103
|
var ptr2 = isLikeNone(server_id) ? 0 : passStringToWasm0(server_id, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
60
104
|
var len2 = WASM_VECTOR_LEN;
|
|
61
105
|
const ret = wasm.channel_new(ptr0, len0, ptr1, len1, ptr2, len2);
|
|
62
|
-
this.__wbg_ptr = ret
|
|
106
|
+
this.__wbg_ptr = ret;
|
|
63
107
|
ChannelFinalization.register(this, this.__wbg_ptr, this);
|
|
64
108
|
return this;
|
|
65
109
|
}
|
|
@@ -106,7 +150,7 @@ class Channel {
|
|
|
106
150
|
var len1 = WASM_VECTOR_LEN;
|
|
107
151
|
var ptr2 = isLikeNone(password) ? 0 : passStringToWasm0(password, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
108
152
|
var len2 = WASM_VECTOR_LEN;
|
|
109
|
-
wasm.channel_open_sftp_tunnel(this.__wbg_ptr, ptr0, len0, ptr1, len1, ptr2, len2, isLikeNone(msg_id) ?
|
|
153
|
+
wasm.channel_open_sftp_tunnel(this.__wbg_ptr, ptr0, len0, ptr1, len1, ptr2, len2, isLikeNone(msg_id) ? Number.MAX_SAFE_INTEGER : (msg_id) >>> 0);
|
|
110
154
|
}
|
|
111
155
|
/**
|
|
112
156
|
* @param {string} node_id
|
|
@@ -121,7 +165,7 @@ class Channel {
|
|
|
121
165
|
var len1 = WASM_VECTOR_LEN;
|
|
122
166
|
var ptr2 = isLikeNone(password) ? 0 : passStringToWasm0(password, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
123
167
|
var len2 = WASM_VECTOR_LEN;
|
|
124
|
-
wasm.channel_open_ssh_tunnel(this.__wbg_ptr, ptr0, len0, ptr1, len1, ptr2, len2, isLikeNone(msg_id) ?
|
|
168
|
+
wasm.channel_open_ssh_tunnel(this.__wbg_ptr, ptr0, len0, ptr1, len1, ptr2, len2, isLikeNone(msg_id) ? Number.MAX_SAFE_INTEGER : (msg_id) >>> 0);
|
|
125
169
|
}
|
|
126
170
|
/**
|
|
127
171
|
* @param {string} node_id
|
|
@@ -137,7 +181,7 @@ class Channel {
|
|
|
137
181
|
const len1 = WASM_VECTOR_LEN;
|
|
138
182
|
const ptr2 = passStringToWasm0(filename, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
139
183
|
const len2 = WASM_VECTOR_LEN;
|
|
140
|
-
wasm.channel_send_sftp_delete(this.__wbg_ptr, ptr0, len0, sid, ptr1, len1, ptr2, len2, isLikeNone(msg_id) ?
|
|
184
|
+
wasm.channel_send_sftp_delete(this.__wbg_ptr, ptr0, len0, sid, ptr1, len1, ptr2, len2, isLikeNone(msg_id) ? Number.MAX_SAFE_INTEGER : (msg_id) >>> 0);
|
|
141
185
|
}
|
|
142
186
|
/**
|
|
143
187
|
* @param {string} node_id
|
|
@@ -149,7 +193,7 @@ class Channel {
|
|
|
149
193
|
send_sftp_download_chunk(node_id, sid, download_id, chunk_index, msg_id) {
|
|
150
194
|
const ptr0 = passStringToWasm0(node_id, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
151
195
|
const len0 = WASM_VECTOR_LEN;
|
|
152
|
-
wasm.channel_send_sftp_download_chunk(this.__wbg_ptr, ptr0, len0, sid, download_id, chunk_index, isLikeNone(msg_id) ?
|
|
196
|
+
wasm.channel_send_sftp_download_chunk(this.__wbg_ptr, ptr0, len0, sid, download_id, chunk_index, isLikeNone(msg_id) ? Number.MAX_SAFE_INTEGER : (msg_id) >>> 0);
|
|
153
197
|
}
|
|
154
198
|
/**
|
|
155
199
|
* @param {string} node_id
|
|
@@ -165,7 +209,7 @@ class Channel {
|
|
|
165
209
|
const len1 = WASM_VECTOR_LEN;
|
|
166
210
|
const ptr2 = passStringToWasm0(filename, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
167
211
|
const len2 = WASM_VECTOR_LEN;
|
|
168
|
-
wasm.channel_send_sftp_download_start(this.__wbg_ptr, ptr0, len0, sid, ptr1, len1, ptr2, len2, isLikeNone(msg_id) ?
|
|
212
|
+
wasm.channel_send_sftp_download_start(this.__wbg_ptr, ptr0, len0, sid, ptr1, len1, ptr2, len2, isLikeNone(msg_id) ? Number.MAX_SAFE_INTEGER : (msg_id) >>> 0);
|
|
169
213
|
}
|
|
170
214
|
/**
|
|
171
215
|
* @param {string} node_id
|
|
@@ -178,7 +222,7 @@ class Channel {
|
|
|
178
222
|
const len0 = WASM_VECTOR_LEN;
|
|
179
223
|
const ptr1 = passStringToWasm0(path, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
180
224
|
const len1 = WASM_VECTOR_LEN;
|
|
181
|
-
wasm.channel_send_sftp_list_data(this.__wbg_ptr, ptr0, len0, sid, ptr1, len1, isLikeNone(msg_id) ?
|
|
225
|
+
wasm.channel_send_sftp_list_data(this.__wbg_ptr, ptr0, len0, sid, ptr1, len1, isLikeNone(msg_id) ? Number.MAX_SAFE_INTEGER : (msg_id) >>> 0);
|
|
182
226
|
}
|
|
183
227
|
/**
|
|
184
228
|
* @param {string} node_id
|
|
@@ -194,7 +238,7 @@ class Channel {
|
|
|
194
238
|
const len0 = WASM_VECTOR_LEN;
|
|
195
239
|
const ptr1 = passArray8ToWasm0(data, wasm.__wbindgen_export);
|
|
196
240
|
const len1 = WASM_VECTOR_LEN;
|
|
197
|
-
wasm.channel_send_sftp_upload_chunk(this.__wbg_ptr, ptr0, len0, sid, upload_id, chunk_index, chunk_size, ptr1, len1, isLikeNone(msg_id) ?
|
|
241
|
+
wasm.channel_send_sftp_upload_chunk(this.__wbg_ptr, ptr0, len0, sid, upload_id, chunk_index, chunk_size, ptr1, len1, isLikeNone(msg_id) ? Number.MAX_SAFE_INTEGER : (msg_id) >>> 0);
|
|
198
242
|
}
|
|
199
243
|
/**
|
|
200
244
|
* @param {string} node_id
|
|
@@ -212,7 +256,7 @@ class Channel {
|
|
|
212
256
|
const len1 = WASM_VECTOR_LEN;
|
|
213
257
|
const ptr2 = passStringToWasm0(remote_path, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
214
258
|
const len2 = WASM_VECTOR_LEN;
|
|
215
|
-
wasm.channel_send_sftp_upload_start(this.__wbg_ptr, ptr0, len0, sid, ptr1, len1, ptr2, len2, total_chunks, total_size, isLikeNone(msg_id) ?
|
|
259
|
+
wasm.channel_send_sftp_upload_start(this.__wbg_ptr, ptr0, len0, sid, ptr1, len1, ptr2, len2, total_chunks, total_size, isLikeNone(msg_id) ? Number.MAX_SAFE_INTEGER : (msg_id) >>> 0);
|
|
216
260
|
}
|
|
217
261
|
/**
|
|
218
262
|
* @param {string} node_id
|
|
@@ -264,7 +308,7 @@ const ErrorType = Object.freeze({
|
|
|
264
308
|
function __wbg_get_imports() {
|
|
265
309
|
const import0 = {
|
|
266
310
|
__proto__: null,
|
|
267
|
-
|
|
311
|
+
__wbg_Error_bce6d499ff0a4aff: function(arg0, arg1) {
|
|
268
312
|
const ret = Error(getStringFromWasm0(arg0, arg1));
|
|
269
313
|
return addHeapObject(ret);
|
|
270
314
|
},
|
|
@@ -275,14 +319,14 @@ function __wbg_get_imports() {
|
|
|
275
319
|
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
276
320
|
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
277
321
|
},
|
|
278
|
-
|
|
322
|
+
__wbg___wbindgen_debug_string_edece8177ad01481: function(arg0, arg1) {
|
|
279
323
|
const ret = debugString(getObject(arg1));
|
|
280
324
|
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
281
325
|
const len1 = WASM_VECTOR_LEN;
|
|
282
326
|
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
283
327
|
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
284
328
|
},
|
|
285
|
-
|
|
329
|
+
__wbg___wbindgen_string_get_d109740c0d18f4d7: function(arg0, arg1) {
|
|
286
330
|
const obj = getObject(arg1);
|
|
287
331
|
const ret = typeof(obj) === 'string' ? obj : undefined;
|
|
288
332
|
var ptr1 = isLikeNone(ret) ? 0 : passStringToWasm0(ret, wasm.__wbindgen_export, wasm.__wbindgen_export2);
|
|
@@ -290,17 +334,17 @@ function __wbg_get_imports() {
|
|
|
290
334
|
getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
|
|
291
335
|
getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
|
|
292
336
|
},
|
|
293
|
-
|
|
337
|
+
__wbg___wbindgen_throw_9c31b086c2b26051: function(arg0, arg1) {
|
|
294
338
|
throw new Error(getStringFromWasm0(arg0, arg1));
|
|
295
339
|
},
|
|
296
|
-
|
|
340
|
+
__wbg__wbg_cb_unref_3fa391f3fcdb55f8: function(arg0) {
|
|
297
341
|
getObject(arg0)._wbg_cb_unref();
|
|
298
342
|
},
|
|
299
|
-
|
|
343
|
+
__wbg_call_13665d9f14390edc: function() { return handleError(function (arg0, arg1) {
|
|
300
344
|
const ret = getObject(arg0).call(getObject(arg1));
|
|
301
345
|
return addHeapObject(ret);
|
|
302
346
|
}, arguments); },
|
|
303
|
-
|
|
347
|
+
__wbg_call_dfde26266607c996: function() { return handleError(function (arg0, arg1, arg2) {
|
|
304
348
|
const ret = getObject(arg0).call(getObject(arg1), getObject(arg2));
|
|
305
349
|
return addHeapObject(ret);
|
|
306
350
|
}, arguments); },
|
|
@@ -308,21 +352,21 @@ function __wbg_get_imports() {
|
|
|
308
352
|
const ret = clearInterval(takeObject(arg0));
|
|
309
353
|
return addHeapObject(ret);
|
|
310
354
|
},
|
|
311
|
-
|
|
355
|
+
__wbg_close_e323e9eee669c291: function() { return handleError(function (arg0) {
|
|
312
356
|
getObject(arg0).close();
|
|
313
357
|
}, arguments); },
|
|
314
|
-
|
|
358
|
+
__wbg_data_5fc79a19e47d1531: function(arg0) {
|
|
315
359
|
const ret = getObject(arg0).data;
|
|
316
360
|
return addHeapObject(ret);
|
|
317
361
|
},
|
|
318
|
-
|
|
362
|
+
__wbg_from_fa561fa561dc8031: function(arg0) {
|
|
319
363
|
const ret = Array.from(getObject(arg0));
|
|
320
364
|
return addHeapObject(ret);
|
|
321
365
|
},
|
|
322
|
-
|
|
366
|
+
__wbg_info_e981ac5a3a823282: function(arg0, arg1) {
|
|
323
367
|
console.info(getStringFromWasm0(arg0, arg1));
|
|
324
368
|
},
|
|
325
|
-
|
|
369
|
+
__wbg_instanceof_ArrayBuffer_53db37b06f6b9afe: function(arg0) {
|
|
326
370
|
let result;
|
|
327
371
|
try {
|
|
328
372
|
result = getObject(arg0) instanceof ArrayBuffer;
|
|
@@ -332,66 +376,66 @@ function __wbg_get_imports() {
|
|
|
332
376
|
const ret = result;
|
|
333
377
|
return ret;
|
|
334
378
|
},
|
|
335
|
-
|
|
379
|
+
__wbg_length_56fcd3e2b7e0299d: function(arg0) {
|
|
336
380
|
const ret = getObject(arg0).length;
|
|
337
381
|
return ret;
|
|
338
382
|
},
|
|
339
|
-
|
|
340
|
-
const ret = new
|
|
383
|
+
__wbg_new_02d162bc6cf02f60: function() {
|
|
384
|
+
const ret = new Object();
|
|
341
385
|
return addHeapObject(ret);
|
|
342
386
|
},
|
|
343
|
-
|
|
387
|
+
__wbg_new_310879b66b6e95e1: function() {
|
|
344
388
|
const ret = new Array();
|
|
345
389
|
return addHeapObject(ret);
|
|
346
390
|
},
|
|
347
|
-
|
|
348
|
-
const ret = new
|
|
391
|
+
__wbg_new_7ddec6de44ff8f5d: function(arg0) {
|
|
392
|
+
const ret = new Uint8Array(getObject(arg0));
|
|
349
393
|
return addHeapObject(ret);
|
|
350
394
|
},
|
|
351
|
-
|
|
395
|
+
__wbg_new_with_str_sequence_dfd6f579eac5ed31: function() { return handleError(function (arg0, arg1, arg2) {
|
|
352
396
|
const ret = new WebSocket(getStringFromWasm0(arg0, arg1), getObject(arg2));
|
|
353
397
|
return addHeapObject(ret);
|
|
354
398
|
}, arguments); },
|
|
355
|
-
|
|
399
|
+
__wbg_prototypesetcall_5f9bdc8d75e07276: function(arg0, arg1, arg2) {
|
|
356
400
|
Uint8Array.prototype.set.call(getArrayU8FromWasm0(arg0, arg1), getObject(arg2));
|
|
357
401
|
},
|
|
358
|
-
|
|
402
|
+
__wbg_push_b77c476b01548d0a: function(arg0, arg1) {
|
|
359
403
|
const ret = getObject(arg0).push(getObject(arg1));
|
|
360
404
|
return ret;
|
|
361
405
|
},
|
|
362
|
-
|
|
406
|
+
__wbg_readyState_a1a00cc8898812ac: function(arg0) {
|
|
363
407
|
const ret = getObject(arg0).readyState;
|
|
364
408
|
return ret;
|
|
365
409
|
},
|
|
366
|
-
|
|
410
|
+
__wbg_send_b9d998a91cbc8429: function() { return handleError(function (arg0, arg1, arg2) {
|
|
367
411
|
getObject(arg0).send(getArrayU8FromWasm0(arg1, arg2));
|
|
368
412
|
}, arguments); },
|
|
369
413
|
__wbg_setInterval_cbf1c35c6a692d37: function() { return handleError(function (arg0, arg1) {
|
|
370
414
|
const ret = setInterval(getObject(arg0), arg1);
|
|
371
415
|
return addHeapObject(ret);
|
|
372
416
|
}, arguments); },
|
|
373
|
-
__wbg_set_3bf1de9fab0cd644: function(arg0, arg1, arg2) {
|
|
374
|
-
getObject(arg0)[arg1 >>> 0] = takeObject(arg2);
|
|
375
|
-
},
|
|
376
417
|
__wbg_set_6be42768c690e380: function(arg0, arg1, arg2) {
|
|
377
418
|
getObject(arg0)[takeObject(arg1)] = takeObject(arg2);
|
|
378
419
|
},
|
|
379
|
-
|
|
420
|
+
__wbg_set_78ea6a19f4818587: function(arg0, arg1, arg2) {
|
|
421
|
+
getObject(arg0)[arg1 >>> 0] = takeObject(arg2);
|
|
422
|
+
},
|
|
423
|
+
__wbg_set_binaryType_5c0002dfcf194934: function(arg0, arg1) {
|
|
380
424
|
getObject(arg0).binaryType = __wbindgen_enum_BinaryType[arg1];
|
|
381
425
|
},
|
|
382
|
-
|
|
426
|
+
__wbg_set_onclose_3121e15055418a37: function(arg0, arg1) {
|
|
383
427
|
getObject(arg0).onclose = getObject(arg1);
|
|
384
428
|
},
|
|
385
|
-
|
|
429
|
+
__wbg_set_onerror_1dd52df6279c8dd2: function(arg0, arg1) {
|
|
386
430
|
getObject(arg0).onerror = getObject(arg1);
|
|
387
431
|
},
|
|
388
|
-
|
|
432
|
+
__wbg_set_onmessage_9eb2cf76e70783ad: function(arg0, arg1) {
|
|
389
433
|
getObject(arg0).onmessage = getObject(arg1);
|
|
390
434
|
},
|
|
391
|
-
|
|
435
|
+
__wbg_set_onopen_6f3fc5e2ad3144f1: function(arg0, arg1) {
|
|
392
436
|
getObject(arg0).onopen = getObject(arg1);
|
|
393
437
|
},
|
|
394
|
-
|
|
438
|
+
__wbg_warn_88b0b8569df852e5: function(arg0, arg1) {
|
|
395
439
|
console.warn(getStringFromWasm0(arg0, arg1));
|
|
396
440
|
},
|
|
397
441
|
__wbindgen_cast_0000000000000001: function(arg0, arg1) {
|
|
@@ -410,8 +454,8 @@ function __wbg_get_imports() {
|
|
|
410
454
|
return addHeapObject(ret);
|
|
411
455
|
},
|
|
412
456
|
__wbindgen_cast_0000000000000004: function(arg0, arg1) {
|
|
413
|
-
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [], shim_idx:
|
|
414
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
457
|
+
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [], shim_idx: 5, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
|
|
458
|
+
const ret = makeMutClosure(arg0, arg1, __wasm_bindgen_func_elem_44);
|
|
415
459
|
return addHeapObject(ret);
|
|
416
460
|
},
|
|
417
461
|
__wbindgen_cast_0000000000000005: function(arg0) {
|
|
@@ -448,8 +492,8 @@ function __wbg_get_imports() {
|
|
|
448
492
|
};
|
|
449
493
|
}
|
|
450
494
|
|
|
451
|
-
function
|
|
452
|
-
wasm.
|
|
495
|
+
function __wasm_bindgen_func_elem_44(arg0, arg1) {
|
|
496
|
+
wasm.__wasm_bindgen_func_elem_44(arg0, arg1);
|
|
453
497
|
}
|
|
454
498
|
|
|
455
499
|
function __wasm_bindgen_func_elem_40(arg0, arg1, arg2) {
|
|
@@ -468,7 +512,7 @@ function __wasm_bindgen_func_elem_40_2(arg0, arg1, arg2) {
|
|
|
468
512
|
const __wbindgen_enum_BinaryType = ["blob", "arraybuffer"];
|
|
469
513
|
const ChannelFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
470
514
|
? { register: () => {}, unregister: () => {} }
|
|
471
|
-
: new FinalizationRegistry(ptr => wasm.__wbg_channel_free(ptr
|
|
515
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_channel_free(ptr, 1));
|
|
472
516
|
|
|
473
517
|
function addHeapObject(obj) {
|
|
474
518
|
if (heap_next === heap.length) heap.push(heap.length + 1);
|
|
@@ -568,8 +612,7 @@ function getDataViewMemory0() {
|
|
|
568
612
|
}
|
|
569
613
|
|
|
570
614
|
function getStringFromWasm0(ptr, len) {
|
|
571
|
-
|
|
572
|
-
return decodeText(ptr, len);
|
|
615
|
+
return decodeText(ptr >>> 0, len);
|
|
573
616
|
}
|
|
574
617
|
|
|
575
618
|
let cachedUint8ArrayMemory0 = null;
|
|
@@ -762,7 +805,7 @@ async function __wbg_init(module_or_path) {
|
|
|
762
805
|
}
|
|
763
806
|
|
|
764
807
|
if (module_or_path === undefined) {
|
|
765
|
-
module_or_path = new URL('phirepass-channel_bg.wasm', (typeof document === 'undefined' ? require('u' + 'rl').pathToFileURL(__filename).href : (_documentCurrentScript && _documentCurrentScript.tagName.toUpperCase() === 'SCRIPT' && _documentCurrentScript.src || new URL('protocol
|
|
808
|
+
module_or_path = new URL('phirepass-channel_bg.wasm', (typeof document === 'undefined' ? require('u' + 'rl').pathToFileURL(__filename).href : (_documentCurrentScript && _documentCurrentScript.tagName.toUpperCase() === 'SCRIPT' && _documentCurrentScript.src || new URL('protocol--wTzAUUX.js', document.baseURI).href)));
|
|
766
809
|
}
|
|
767
810
|
const imports = __wbg_get_imports();
|
|
768
811
|
|
|
Binary file
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
class n{__destroy_into_raw(){const n=this.__wbg_ptr;return this.__wbg_ptr=0,_.unregister(this),n}free(){const n=this.__destroy_into_raw();O.__wbg_channel_free(n,0)}authenticate(n,t,e){const r=R(n,O.__wbindgen_export,O.__wbindgen_export2),o=P,c=R(t,O.__wbindgen_export,O.__wbindgen_export2);O.channel_authenticate(this.__wbg_ptr,r,o,c,P,A(e)?Number.MAX_SAFE_INTEGER:e>>>0)}connect(){O.channel_connect(this.__wbg_ptr)}disable_service(n,t,e,r,o,c,i){const s=R(n,O.__wbindgen_export,O.__wbindgen_export2),_=P,u=R(t,O.__wbindgen_export,O.__wbindgen_export2),a=P,f=R(e,O.__wbindgen_export,O.__wbindgen_export2),b=P;var d=A(o)?0:R(o,O.__wbindgen_export,O.__wbindgen_export2),l=P,w=A(c)?0:R(c,O.__wbindgen_export,O.__wbindgen_export2);O.channel_disable_service(this.__wbg_ptr,s,_,u,a,f,b,r,d,l,w,P,A(i)?Number.MAX_SAFE_INTEGER:i>>>0)}disconnect(){O.channel_disconnect(this.__wbg_ptr)}enable_service(n,t,e,r,o,c,i){const s=R(n,O.__wbindgen_export,O.__wbindgen_export2),_=P,u=R(t,O.__wbindgen_export,O.__wbindgen_export2),a=P,f=R(e,O.__wbindgen_export,O.__wbindgen_export2),b=P;var d=A(o)?0:R(o,O.__wbindgen_export,O.__wbindgen_export2),l=P,w=A(c)?0:R(c,O.__wbindgen_export,O.__wbindgen_export2);O.channel_enable_service(this.__wbg_ptr,s,_,u,a,f,b,r,d,l,w,P,A(i)?Number.MAX_SAFE_INTEGER:i>>>0)}is_connected(){return 0!==O.channel_is_connected(this.__wbg_ptr)}is_disconnected(){return 0!==O.channel_is_disconnected(this.__wbg_ptr)}constructor(n,t,e){const r=R(n,O.__wbindgen_export,O.__wbindgen_export2),o=P,c=R(t,O.__wbindgen_export,O.__wbindgen_export2),i=P;var s=A(e)?0:R(e,O.__wbindgen_export,O.__wbindgen_export2);const u=O.channel_new(r,o,c,i,s,P);return this.__wbg_ptr=u,_.register(this,this.__wbg_ptr,this),this}on_connection_close(n){O.channel_on_connection_close(this.__wbg_ptr,A(n)?0:u(n))}on_connection_error(n){O.channel_on_connection_error(this.__wbg_ptr,A(n)?0:u(n))}on_connection_message(n){O.channel_on_connection_message(this.__wbg_ptr,A(n)?0:u(n))}on_connection_open(n){O.channel_on_connection_open(this.__wbg_ptr,A(n)?0:u(n))}on_protocol_message(n){O.channel_on_protocol_message(this.__wbg_ptr,A(n)?0:u(n))}open_sftp_tunnel(n,t,e,r){const o=R(n,O.__wbindgen_export,O.__wbindgen_export2),c=P;var i=A(t)?0:R(t,O.__wbindgen_export,O.__wbindgen_export2),s=P,_=A(e)?0:R(e,O.__wbindgen_export,O.__wbindgen_export2);O.channel_open_sftp_tunnel(this.__wbg_ptr,o,c,i,s,_,P,A(r)?Number.MAX_SAFE_INTEGER:r>>>0)}open_ssh_tunnel(n,t,e,r){const o=R(n,O.__wbindgen_export,O.__wbindgen_export2),c=P;var i=A(t)?0:R(t,O.__wbindgen_export,O.__wbindgen_export2),s=P,_=A(e)?0:R(e,O.__wbindgen_export,O.__wbindgen_export2);O.channel_open_ssh_tunnel(this.__wbg_ptr,o,c,i,s,_,P,A(r)?Number.MAX_SAFE_INTEGER:r>>>0)}send_sftp_delete(n,t,e,r,o){const c=R(n,O.__wbindgen_export,O.__wbindgen_export2),i=P,s=R(e,O.__wbindgen_export,O.__wbindgen_export2),_=P,u=R(r,O.__wbindgen_export,O.__wbindgen_export2);O.channel_send_sftp_delete(this.__wbg_ptr,c,i,t,s,_,u,P,A(o)?Number.MAX_SAFE_INTEGER:o>>>0)}send_sftp_download_chunk(n,t,e,r,o){const c=R(n,O.__wbindgen_export,O.__wbindgen_export2);O.channel_send_sftp_download_chunk(this.__wbg_ptr,c,P,t,e,r,A(o)?Number.MAX_SAFE_INTEGER:o>>>0)}send_sftp_download_start(n,t,e,r,o){const c=R(n,O.__wbindgen_export,O.__wbindgen_export2),i=P,s=R(e,O.__wbindgen_export,O.__wbindgen_export2),_=P,u=R(r,O.__wbindgen_export,O.__wbindgen_export2);O.channel_send_sftp_download_start(this.__wbg_ptr,c,i,t,s,_,u,P,A(o)?Number.MAX_SAFE_INTEGER:o>>>0)}send_sftp_list_data(n,t,e,r){const o=R(n,O.__wbindgen_export,O.__wbindgen_export2),c=P,i=R(e,O.__wbindgen_export,O.__wbindgen_export2);O.channel_send_sftp_list_data(this.__wbg_ptr,o,c,t,i,P,A(r)?Number.MAX_SAFE_INTEGER:r>>>0)}send_sftp_upload_chunk(n,t,e,r,o,c,i){const s=R(n,O.__wbindgen_export,O.__wbindgen_export2),_=P,u=function(n){const t=(0,O.__wbindgen_export)(1*n.length,1)>>>0;return h().set(n,t/1),P=n.length,t}(c);O.channel_send_sftp_upload_chunk(this.__wbg_ptr,s,_,t,e,r,o,u,P,A(i)?Number.MAX_SAFE_INTEGER:i>>>0)}send_sftp_upload_start(n,t,e,r,o,c,i){const s=R(n,O.__wbindgen_export,O.__wbindgen_export2),_=P,u=R(e,O.__wbindgen_export,O.__wbindgen_export2),a=P,f=R(r,O.__wbindgen_export,O.__wbindgen_export2);O.channel_send_sftp_upload_start(this.__wbg_ptr,s,_,t,u,a,f,P,o,c,A(i)?Number.MAX_SAFE_INTEGER:i>>>0)}send_ssh_terminal_resize(n,t,e,r,o,c){const i=R(n,O.__wbindgen_export,O.__wbindgen_export2);O.channel_send_ssh_terminal_resize(this.__wbg_ptr,i,P,t,e,r,o,c)}send_ssh_tunnel_data(n,t,e){const r=R(n,O.__wbindgen_export,O.__wbindgen_export2),o=P,c=R(e,O.__wbindgen_export,O.__wbindgen_export2);O.channel_send_ssh_tunnel_data(this.__wbg_ptr,r,o,t,c,P)}start_heartbeat(n){O.channel_start_heartbeat(this.__wbg_ptr,n)}stop_heartbeat(){O.channel_stop_heartbeat(this.__wbg_ptr)}}Symbol.dispose&&(n.prototype[Symbol.dispose]=n.prototype.free);const t=Object.freeze({Generic:0,0:"Generic",Authentication:10,10:"Authentication",RequiresUsername:100,100:"RequiresUsername",RequiresPassword:110,110:"RequiresPassword",RequiresUsernamePassword:120,120:"RequiresUsernamePassword"});function e(){const n={__proto__:null,__wbg_Error_bce6d499ff0a4aff:function(n,t){return u(Error(w(n,t)))},__wbg_String_8564e559799eccda:function(n,t){const e=R(String(p(t)),O.__wbindgen_export,O.__wbindgen_export2),r=P;l().setInt32(n+4,r,!0),l().setInt32(n+0,e,!0)},__wbg___wbindgen_debug_string_edece8177ad01481:function(n,t){const e=R(f(p(t)),O.__wbindgen_export,O.__wbindgen_export2),r=P;l().setInt32(n+4,r,!0),l().setInt32(n+0,e,!0)},__wbg___wbindgen_string_get_d109740c0d18f4d7:function(n,t){const e=p(t),r="string"==typeof e?e:void 0;var o=A(r)?0:R(r,O.__wbindgen_export,O.__wbindgen_export2),c=P;l().setInt32(n+4,c,!0),l().setInt32(n+0,o,!0)},__wbg___wbindgen_throw_9c31b086c2b26051:function(n,t){throw new Error(w(n,t))},__wbg__wbg_cb_unref_3fa391f3fcdb55f8:function(n){p(n)._wbg_cb_unref()},__wbg_call_13665d9f14390edc:function(){return y((function(n,t){return u(p(n).call(p(t)))}),arguments)},__wbg_call_dfde26266607c996:function(){return y((function(n,t,e){return u(p(n).call(p(t),p(e)))}),arguments)},__wbg_clearInterval_26ba580547547579:function(n){return u(clearInterval(T(n)))},__wbg_close_e323e9eee669c291:function(){return y((function(n){p(n).close()}),arguments)},__wbg_data_5fc79a19e47d1531:function(n){return u(p(n).data)},__wbg_from_fa561fa561dc8031:function(n){return u(Array.from(p(n)))},__wbg_info_e981ac5a3a823282:function(n,t){console.info(w(n,t))},__wbg_instanceof_ArrayBuffer_53db37b06f6b9afe:function(n){let t;try{t=p(n)instanceof ArrayBuffer}catch(n){t=!1}return t},__wbg_length_56fcd3e2b7e0299d:function(n){return p(n).length},__wbg_new_02d162bc6cf02f60:function(){return u(new Object)},__wbg_new_310879b66b6e95e1:function(){return u(new Array)},__wbg_new_7ddec6de44ff8f5d:function(n){return u(new Uint8Array(p(n)))},__wbg_new_with_str_sequence_dfd6f579eac5ed31:function(){return y((function(n,t,e){return u(new WebSocket(w(n,t),p(e)))}),arguments)},__wbg_prototypesetcall_5f9bdc8d75e07276:function(n,t,e){Uint8Array.prototype.set.call(b(n,t),p(e))},__wbg_push_b77c476b01548d0a:function(n,t){return p(n).push(p(t))},__wbg_readyState_a1a00cc8898812ac:function(n){return p(n).readyState},__wbg_send_b9d998a91cbc8429:function(){return y((function(n,t,e){p(n).send(b(t,e))}),arguments)},__wbg_setInterval_cbf1c35c6a692d37:function(){return y((function(n,t){return u(setInterval(p(n),t))}),arguments)},__wbg_set_6be42768c690e380:function(n,t,e){p(n)[T(t)]=T(e)},__wbg_set_78ea6a19f4818587:function(n,t,e){p(n)[t>>>0]=T(e)},__wbg_set_binaryType_5c0002dfcf194934:function(n,t){p(n).binaryType=s[t]},__wbg_set_onclose_3121e15055418a37:function(n,t){p(n).onclose=p(t)},__wbg_set_onerror_1dd52df6279c8dd2:function(n,t){p(n).onerror=p(t)},__wbg_set_onmessage_9eb2cf76e70783ad:function(n,t){p(n).onmessage=p(t)},__wbg_set_onopen_6f3fc5e2ad3144f1:function(n,t){p(n).onopen=p(t)},__wbg_warn_88b0b8569df852e5:function(n,t){console.warn(w(n,t))},__wbindgen_cast_0000000000000001:function(n,t){return u(S(n,t,o))},__wbindgen_cast_0000000000000002:function(n,t){return u(S(n,t,c))},__wbindgen_cast_0000000000000003:function(n,t){return u(S(n,t,i))},__wbindgen_cast_0000000000000004:function(n,t){return u(S(n,t,r))},__wbindgen_cast_0000000000000005:function(n){return u(n)},__wbindgen_cast_0000000000000006:function(n,t){return u(b(n,t))},__wbindgen_cast_0000000000000007:function(n,t){return u(w(n,t))},__wbindgen_cast_0000000000000008:function(n){return u(BigInt.asUintN(64,n))},__wbindgen_object_clone_ref:function(n){return u(p(n))},__wbindgen_object_drop_ref:function(n){T(n)}};return{__proto__:null,"./phirepass-channel_bg.js":n}}function r(n,t){O.__wasm_bindgen_func_elem_44(n,t)}function o(n,t,e){O.__wasm_bindgen_func_elem_40(n,t,u(e))}function c(n,t,e){O.__wasm_bindgen_func_elem_40_1(n,t,u(e))}function i(n,t,e){O.__wasm_bindgen_func_elem_40_2(n,t,u(e))}const s=["blob","arraybuffer"],_="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((n=>O.__wbg_channel_free(n,1)));function u(n){v===m.length&&m.push(m.length+1);const t=v;return v=m[t],m[t]=n,t}const a="undefined"==typeof FinalizationRegistry?{register:()=>{},unregister:()=>{}}:new FinalizationRegistry((n=>O.__wbindgen_export4(n.a,n.b)));function f(n){const t=typeof n;if("number"==t||"boolean"==t||null==n)return`${n}`;if("string"==t)return`"${n}"`;if("symbol"==t){const t=n.description;return null==t?"Symbol":`Symbol(${t})`}if("function"==t){const t=n.name;return"string"==typeof t&&t.length>0?`Function(${t})`:"Function"}if(Array.isArray(n)){const t=n.length;let e="[";t>0&&(e+=f(n[0]));for(let r=1;r<t;r++)e+=", "+f(n[r]);return e+="]",e}const e=/\[object ([^\]]+)\]/.exec(toString.call(n));let r;if(!(e&&e.length>1))return toString.call(n);if(r=e[1],"Object"==r)try{return"Object("+JSON.stringify(n)+")"}catch(n){return"Object"}return n instanceof Error?`${n.name}: ${n.message}\n${n.stack}`:r}function b(n,t){return n>>>=0,h().subarray(n/1,n/1+t)}let d=null;function l(){return(null===d||!0===d.buffer.detached||void 0===d.buffer.detached&&d.buffer!==O.memory.buffer)&&(d=new DataView(O.memory.buffer)),d}function w(n,t){return function(n,t){return F+=t,F>=j&&(U=new TextDecoder("utf-8",{ignoreBOM:!0,fatal:!0}),U.decode(),F=t),U.decode(h().subarray(n,n+t))}(n>>>0,t)}let g=null;function h(){return null!==g&&0!==g.byteLength||(g=new Uint8Array(O.memory.buffer)),g}function p(n){return m[n]}function y(n,t){try{return n.apply(this,t)}catch(n){O.__wbindgen_export3(u(n))}}let m=new Array(1024).fill(void 0);m.push(void 0,null,!0,!1);let v=m.length;function A(n){return null==n}function S(n,t,e){const r={a:n,b:t,cnt:1},o=(...n)=>{r.cnt++;const t=r.a;r.a=0;try{return e(t,r.b,...n)}finally{r.a=t,o._wbg_cb_unref()}};return o._wbg_cb_unref=()=>{0==--r.cnt&&(O.__wbindgen_export4(r.a,r.b),r.a=0,a.unregister(r))},a.register(o,r,r),o}function R(n,t,e){if(void 0===e){const e=N.encode(n),r=t(e.length,1)>>>0;return h().subarray(r,r+e.length).set(e),P=e.length,r}let r=n.length,o=t(r,1)>>>0;const c=h();let i=0;for(;i<r;i++){const t=n.charCodeAt(i);if(t>127)break;c[o+i]=t}if(i!==r){0!==i&&(n=n.slice(i)),o=e(o,r,r=i+3*n.length,1)>>>0;const t=h().subarray(o+i,o+r);i+=N.encodeInto(n,t).written,o=e(o,r,i,1)>>>0}return P=i,o}function T(n){const t=p(n);return function(n){n<1028||(m[n]=v,v=n)}(n),t}let U=new TextDecoder("utf-8",{ignoreBOM:!0,fatal:!0});U.decode();const j=2146435072;let F=0;const N=new TextEncoder;"encodeInto"in N||(N.encodeInto=function(n,t){const e=N.encode(n);return t.set(e),{read:n.length,written:e.length}});let O,P=0;async function q(n){if(void 0!==O)return O;void 0!==n&&(Object.getPrototypeOf(n)===Object.prototype?({module_or_path:n}=n):console.warn("using deprecated parameters for the initialization function; pass a single object instead")),void 0===n&&(n=new URL("phirepass-channel_bg.wasm",import.meta.url));const t=e();("string"==typeof n||"function"==typeof Request&&n instanceof Request||"function"==typeof URL&&n instanceof URL)&&(n=fetch(n));const{instance:r}=await async function(n,t){if("function"==typeof Response&&n instanceof Response){if("function"==typeof WebAssembly.instantiateStreaming)try{return await WebAssembly.instantiateStreaming(n,t)}catch(t){if(!n.ok||!function(n){switch(n){case"basic":case"cors":case"default":return!0}return!1}(n.type)||"application/wasm"===n.headers.get("Content-Type"))throw t;console.warn("`WebAssembly.instantiateStreaming` failed because your server does not serve Wasm with `application/wasm` MIME type. Falling back to `WebAssembly.instantiate` which is slower. Original error:\n",t)}const e=await n.arrayBuffer();return await WebAssembly.instantiate(e,t)}{const e=await WebAssembly.instantiate(n,t);return e instanceof WebAssembly.Instance?{instance:e,module:n}:e}}(await n,t);return function(n){return O=n.exports,d=null,g=null,O}(r)}var I,W,k;!function(n){n.Error="Error",n.AuthSuccess="AuthSuccess",n.TunnelOpened="TunnelOpened",n.TunnelClosed="TunnelClosed",n.TunnelData="TunnelData",n.SFTPListItems="SFTPListItems",n.SFTPDownloadStartResponse="SFTPDownloadStartResponse",n.SFTPDownloadChunk="SFTPDownloadChunk",n.SFTPUploadStartResponse="SFTPUploadStartResponse",n.SFTPUploadChunkAck="SFTPUploadChunkAck"}(I||(I={})),function(n){n[n.Username=0]="Username",n[n.Password=1]="Password",n[n.Default=2]="Default"}(W||(W={})),function(n){n.Disconnected="disconnected",n.Connected="connected",n.Error="error"}(k||(k={}));export{n as C,t as E,W as I,I as P,q as _,k as a}
|