tabby-rdp 0.1.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.
- package/LICENSE +21 -0
- package/README.md +150 -0
- package/dist/desk.js +86 -0
- package/dist/desk.js.map +1 -0
- package/dist/deskScript.js +44 -0
- package/dist/deskScript.js.map +1 -0
- package/dist/desktop.service.js +665 -0
- package/dist/desktop.service.js.map +1 -0
- package/dist/desktopForm.js +96 -0
- package/dist/desktopForm.js.map +1 -0
- package/dist/desktops.js +45 -0
- package/dist/desktops.js.map +1 -0
- package/dist/header.js +164 -0
- package/dist/header.js.map +1 -0
- package/dist/index.js +52 -0
- package/dist/index.js.map +1 -0
- package/dist/rdcleanpath.js +255 -0
- package/dist/rdcleanpath.js.map +1 -0
- package/dist/remoteSetup.js +188 -0
- package/dist/remoteSetup.js.map +1 -0
- package/dist/signin.js +114 -0
- package/dist/signin.js.map +1 -0
- package/dist/ssh.js +54 -0
- package/dist/ssh.js.map +1 -0
- package/dist/sshChannelStream.js +34 -0
- package/dist/sshChannelStream.js.map +1 -0
- package/dist/targets.js +247 -0
- package/dist/targets.js.map +1 -0
- package/dist/ui.js +212 -0
- package/dist/ui.js.map +1 -0
- package/package.json +41 -0
- package/remote/trd-pty.py +561 -0
- package/vendor/IRONRDP-LICENSE +27 -0
- package/vendor/iron-remote-desktop-rdp.js +2878 -0
- package/vendor/iron-remote-desktop.js +4136 -0
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.SSHChannelStream = void 0;
|
|
4
|
+
const stream_1 = require("stream");
|
|
5
|
+
/** Node Duplex over an SSH channel, so tls.connect() can run on top of it. */
|
|
6
|
+
class SSHChannelStream extends stream_1.Duplex {
|
|
7
|
+
constructor(channel) {
|
|
8
|
+
super();
|
|
9
|
+
this.channel = channel;
|
|
10
|
+
channel.data$.subscribe({
|
|
11
|
+
next: d => this.push(Buffer.from(d.buffer, d.byteOffset, d.byteLength)),
|
|
12
|
+
error: e => this.destroy(e instanceof Error ? e : new Error(String(e))),
|
|
13
|
+
});
|
|
14
|
+
channel.eof$.subscribe(() => this.push(null));
|
|
15
|
+
channel.closed$.subscribe(() => {
|
|
16
|
+
this.push(null);
|
|
17
|
+
this.destroy();
|
|
18
|
+
});
|
|
19
|
+
}
|
|
20
|
+
// The channel pushes whenever data arrives; there is no pull side to drive.
|
|
21
|
+
_read() { }
|
|
22
|
+
_write(chunk, _encoding, callback) {
|
|
23
|
+
this.channel.write(new Uint8Array(chunk.buffer, chunk.byteOffset, chunk.byteLength)).then(() => callback(), callback);
|
|
24
|
+
}
|
|
25
|
+
_final(callback) {
|
|
26
|
+
this.channel.eof().then(() => callback(), () => callback());
|
|
27
|
+
}
|
|
28
|
+
_destroy(error, callback) {
|
|
29
|
+
this.channel.close().catch(() => null);
|
|
30
|
+
callback(error);
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
exports.SSHChannelStream = SSHChannelStream;
|
|
34
|
+
//# sourceMappingURL=sshChannelStream.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sshChannelStream.js","sourceRoot":"","sources":["../src/sshChannelStream.ts"],"names":[],"mappings":";;;AAAA,mCAA+B;AAY/B,8EAA8E;AAC9E,MAAa,gBAAiB,SAAQ,eAAM;IACxC,YAAqB,OAAmB;QACpC,KAAK,EAAE,CAAA;QADU,YAAO,GAAP,OAAO,CAAY;QAEpC,OAAO,CAAC,KAAK,CAAC,SAAS,CAAC;YACpB,IAAI,EAAE,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,UAAU,EAAE,CAAC,CAAC,UAAU,CAAC,CAAC;YACvE,KAAK,EAAE,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC,YAAY,KAAK,CAAC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length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
+
};
|
|
8
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9
|
+
exports.RemoteTargets = void 0;
|
|
10
|
+
exports.desktopPaneOf = desktopPaneOf;
|
|
11
|
+
exports.parseSSHCommand = parseSSHCommand;
|
|
12
|
+
const core_1 = require("@angular/core");
|
|
13
|
+
const child_process_1 = require("child_process");
|
|
14
|
+
const stream_1 = require("stream");
|
|
15
|
+
const tabby_core_1 = require("tabby-core");
|
|
16
|
+
const ssh_1 = require("./ssh");
|
|
17
|
+
function isLocalTerminal(tab) {
|
|
18
|
+
const t = tab;
|
|
19
|
+
return t?.profile?.type === 'local' && !!t.element?.nativeElement && typeof t.session?.getChildProcesses === 'function';
|
|
20
|
+
}
|
|
21
|
+
/** The pane a tab or tab-header action refers to: the pane itself, or a split's focused pane. */
|
|
22
|
+
function desktopPaneOf(tab) {
|
|
23
|
+
const pane = tab instanceof tabby_core_1.SplitTabComponent ? tab.getFocusedTab() : tab;
|
|
24
|
+
return (0, ssh_1.isSSHTab)(pane) || isLocalTerminal(pane) ? pane : null;
|
|
25
|
+
}
|
|
26
|
+
// ---- system ssh --------------------------------------------------------------------------------
|
|
27
|
+
function run(file, args, timeoutMs = 10000) {
|
|
28
|
+
return new Promise((resolve, reject) => {
|
|
29
|
+
(0, child_process_1.execFile)(file, args, { timeout: timeoutMs, maxBuffer: 1 << 20 }, (err, stdout, stderr) => {
|
|
30
|
+
if (err) {
|
|
31
|
+
reject(new Error((stderr || err.message).toString().trim().split('\n').pop()));
|
|
32
|
+
}
|
|
33
|
+
else {
|
|
34
|
+
resolve(stdout.toString());
|
|
35
|
+
}
|
|
36
|
+
});
|
|
37
|
+
});
|
|
38
|
+
}
|
|
39
|
+
// ssh(1) options that take an argument.
|
|
40
|
+
const WITH_ARG = new Set('BbcDEeFIiJLlmOopQRSWw');
|
|
41
|
+
// Options worth carrying over to our own connections (identity, config, jump hosts, port, …).
|
|
42
|
+
// Everything else (forwards, TTY, background, control-master, verbosity, X11) is dropped.
|
|
43
|
+
const KEEP_WITH_ARG = new Set('BbcFIiJlmopS');
|
|
44
|
+
const KEEP_FLAG = new Set('46AaCgKkq');
|
|
45
|
+
// -o settings that would make our extra connections do something other than a plain exec/-W.
|
|
46
|
+
const DROP_O = /^(LocalForward|RemoteForward|DynamicForward|RequestTTY|RemoteCommand|SessionType|ControlMaster|ControlPersist|ForkAfterAuthentication|StdinNull|PermitLocalCommand|LocalCommand|ClearAllForwardings|ExitOnForwardFailure|BatchMode)\b/i;
|
|
47
|
+
/** Parses an ssh(1) command line (without the leading `ssh`); null if it has no destination. */
|
|
48
|
+
function parseSSHCommand(tokens) {
|
|
49
|
+
const options = [];
|
|
50
|
+
let i = 0;
|
|
51
|
+
for (; i < tokens.length; i++) {
|
|
52
|
+
const t = tokens[i];
|
|
53
|
+
if (t === '--') {
|
|
54
|
+
i++;
|
|
55
|
+
break;
|
|
56
|
+
}
|
|
57
|
+
if (!t.startsWith('-') || t === '-') {
|
|
58
|
+
break;
|
|
59
|
+
}
|
|
60
|
+
for (let j = 1; j < t.length; j++) {
|
|
61
|
+
const flag = t[j];
|
|
62
|
+
if (WITH_ARG.has(flag)) {
|
|
63
|
+
const value = j + 1 < t.length ? t.slice(j + 1) : tokens[++i];
|
|
64
|
+
if (value === undefined) {
|
|
65
|
+
return null;
|
|
66
|
+
}
|
|
67
|
+
if (KEEP_WITH_ARG.has(flag) && !(flag === 'o' && DROP_O.test(value))) {
|
|
68
|
+
options.push(`-${flag}`, value);
|
|
69
|
+
}
|
|
70
|
+
break;
|
|
71
|
+
}
|
|
72
|
+
if (KEEP_FLAG.has(flag)) {
|
|
73
|
+
options.push(`-${flag}`);
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
const destination = tokens[i];
|
|
78
|
+
return destination ? { options, destination } : null;
|
|
79
|
+
}
|
|
80
|
+
/** `user@hostname:port` as ssh itself resolves it (config aliases, defaults). */
|
|
81
|
+
async function resolveKey(options, destination) {
|
|
82
|
+
const out = await run('ssh', [...options, '-G', destination]);
|
|
83
|
+
const get = (k) => new RegExp(`^${k} (.+)$`, 'm').exec(out)?.[1]?.trim();
|
|
84
|
+
return `${get('user') ?? ''}@${(get('hostname') ?? destination).toLowerCase()}:${get('port') ?? '22'}`;
|
|
85
|
+
}
|
|
86
|
+
/** A target reached with the system `ssh`, non-interactively (keys/agent/control master only). */
|
|
87
|
+
class SystemSSHTarget {
|
|
88
|
+
constructor(key, label, cmd) {
|
|
89
|
+
this.key = key;
|
|
90
|
+
this.label = label;
|
|
91
|
+
this.cmd = cmd;
|
|
92
|
+
}
|
|
93
|
+
args(...extra) {
|
|
94
|
+
return [...this.cmd.options, '-o', 'BatchMode=yes', ...extra, this.cmd.destination];
|
|
95
|
+
}
|
|
96
|
+
async openTcp(host, port) {
|
|
97
|
+
const child = (0, child_process_1.spawn)('ssh', this.args('-o', 'ExitOnForwardFailure=yes', '-W', `${host.includes(':') ? `[${host}]` : host}:${port}`), { stdio: ['pipe', 'pipe', 'pipe'] });
|
|
98
|
+
let stderr = '';
|
|
99
|
+
child.stderr.on('data', d => { stderr += d; });
|
|
100
|
+
const stream = stream_1.Duplex.from({ readable: child.stdout, writable: child.stdin });
|
|
101
|
+
stream.on('close', () => child.kill());
|
|
102
|
+
child.on('exit', () => stream.destroy());
|
|
103
|
+
// Fail fast if ssh can't connect (e.g. it would need a password).
|
|
104
|
+
await new Promise((resolve, reject) => {
|
|
105
|
+
child.once('error', reject);
|
|
106
|
+
child.once('exit', code => reject(new Error(sshFailure(this.label, stderr, code))));
|
|
107
|
+
child.stdout.once('readable', () => resolve());
|
|
108
|
+
setTimeout(resolve, 1500);
|
|
109
|
+
});
|
|
110
|
+
return stream;
|
|
111
|
+
}
|
|
112
|
+
exec(command, stdin) {
|
|
113
|
+
return new Promise((resolve, reject) => {
|
|
114
|
+
const child = (0, child_process_1.spawn)('ssh', [...this.args('-T'), command], { stdio: ['pipe', 'pipe', 'pipe'] });
|
|
115
|
+
let stdout = '';
|
|
116
|
+
let stderr = '';
|
|
117
|
+
child.stdout.on('data', d => { stdout += d; });
|
|
118
|
+
child.stderr.on('data', d => { stderr += d; });
|
|
119
|
+
const timer = setTimeout(() => child.kill(), 60000);
|
|
120
|
+
child.on('error', reject);
|
|
121
|
+
child.on('exit', code => {
|
|
122
|
+
clearTimeout(timer);
|
|
123
|
+
code === 255 ? reject(new Error(sshFailure(this.label, stderr, code))) : resolve(stdout);
|
|
124
|
+
});
|
|
125
|
+
child.stdin.end(stdin);
|
|
126
|
+
});
|
|
127
|
+
}
|
|
128
|
+
}
|
|
129
|
+
function sshFailure(label, stderr, code) {
|
|
130
|
+
const last = stderr.trim().split('\n').pop() ?? '';
|
|
131
|
+
if (/permission denied|password|keyboard-interactive/i.test(last)) {
|
|
132
|
+
return `Couldn't open a second SSH connection to ${label} without a password. Use an SSH key or agent (or a ControlMaster), or open the host as a Tabby SSH profile.`;
|
|
133
|
+
}
|
|
134
|
+
return `ssh to ${label} failed${last ? `: ${last}` : ` (exit ${code})`}`;
|
|
135
|
+
}
|
|
136
|
+
// ---- Tabby SSH tabs ----------------------------------------------------------------------------
|
|
137
|
+
class TabbySSHTarget {
|
|
138
|
+
constructor(key, label, tab) {
|
|
139
|
+
this.key = key;
|
|
140
|
+
this.label = label;
|
|
141
|
+
this.tab = tab;
|
|
142
|
+
}
|
|
143
|
+
openTcp(host, port) { return (0, ssh_1.openTcpStream)(this.tab, host, port); }
|
|
144
|
+
exec(command, stdin) { return (0, ssh_1.execRemote)(this.tab, command, stdin); }
|
|
145
|
+
}
|
|
146
|
+
// ---- detection ---------------------------------------------------------------------------------
|
|
147
|
+
/**
|
|
148
|
+
* Works out which remote a pane is logged into. SSH tabs: their profile. Local terminals: an `ssh`
|
|
149
|
+
* process running under the shell. Results are cached so the header can be updated synchronously.
|
|
150
|
+
*/
|
|
151
|
+
let RemoteTargets = class RemoteTargets {
|
|
152
|
+
constructor() {
|
|
153
|
+
this.cache = new WeakMap();
|
|
154
|
+
this.keys = new Map();
|
|
155
|
+
}
|
|
156
|
+
/** Last known target of a pane (undefined: not looked up yet). */
|
|
157
|
+
cached(pane) {
|
|
158
|
+
return this.cache.get(pane)?.target;
|
|
159
|
+
}
|
|
160
|
+
async targetOf(pane) {
|
|
161
|
+
let target = null;
|
|
162
|
+
let pid;
|
|
163
|
+
try {
|
|
164
|
+
if ((0, ssh_1.isSSHTab)(pane)) {
|
|
165
|
+
const o = pane.profile?.options ?? {};
|
|
166
|
+
const known = this.cache.get(pane)?.target;
|
|
167
|
+
target = known ?? new TabbySSHTarget(await this.key(['-l', o.user ?? '', '-p', String(o.port ?? 22)], o.host ?? ''), o.host ?? 'remote', pane);
|
|
168
|
+
}
|
|
169
|
+
else {
|
|
170
|
+
const found = await this.localSSH(pane);
|
|
171
|
+
pid = found?.pid;
|
|
172
|
+
const known = this.cache.get(pane);
|
|
173
|
+
if (found && known?.target && known.pid === found.pid) {
|
|
174
|
+
target = known.target;
|
|
175
|
+
}
|
|
176
|
+
else if (found) {
|
|
177
|
+
target = new SystemSSHTarget(await this.key(found.cmd.options, found.cmd.destination), found.cmd.destination, found.cmd);
|
|
178
|
+
}
|
|
179
|
+
}
|
|
180
|
+
}
|
|
181
|
+
catch {
|
|
182
|
+
target = null;
|
|
183
|
+
}
|
|
184
|
+
this.cache.set(pane, { target, pid });
|
|
185
|
+
return target;
|
|
186
|
+
}
|
|
187
|
+
key(options, destination) {
|
|
188
|
+
const id = JSON.stringify([options, destination]);
|
|
189
|
+
let key = this.keys.get(id);
|
|
190
|
+
if (!key) {
|
|
191
|
+
key = resolveKey(options, destination);
|
|
192
|
+
key.catch(() => this.keys.delete(id));
|
|
193
|
+
this.keys.set(id, key);
|
|
194
|
+
}
|
|
195
|
+
return key;
|
|
196
|
+
}
|
|
197
|
+
/**
|
|
198
|
+
* The nearest `ssh` client running in the pane: a descendant of the terminal's own process.
|
|
199
|
+
*
|
|
200
|
+
* Found from one `ps` snapshot of the process tree rather than Tabby's child-process list: that list
|
|
201
|
+
* starts from a "true PID" Tabby picks by following the shell's only child a couple of seconds after
|
|
202
|
+
* start, which can be a short-lived helper (prompt/plugin startup) that is gone by the time you type
|
|
203
|
+
* `ssh`, leaving the list empty for good.
|
|
204
|
+
*/
|
|
205
|
+
async localSSH(pane) {
|
|
206
|
+
if (process.platform === 'win32') {
|
|
207
|
+
return null;
|
|
208
|
+
}
|
|
209
|
+
const root = await pane.session.pty?.getPID?.().catch(() => undefined);
|
|
210
|
+
if (!root) {
|
|
211
|
+
return null;
|
|
212
|
+
}
|
|
213
|
+
// pid, ppid, full command line (ps loses quoting; ssh arguments rarely need it)
|
|
214
|
+
const children = new Map();
|
|
215
|
+
for (const line of (await run('ps', ['-ax', '-ww', '-o', 'pid=,ppid=,args='])).split('\n')) {
|
|
216
|
+
const m = /^\s*(\d+)\s+(\d+)\s+(.*)$/.exec(line);
|
|
217
|
+
if (m) {
|
|
218
|
+
const list = children.get(Number(m[2])) ?? [];
|
|
219
|
+
list.push({ pid: Number(m[1]), args: m[3].trim().split(/\s+/) });
|
|
220
|
+
children.set(Number(m[2]), list);
|
|
221
|
+
}
|
|
222
|
+
}
|
|
223
|
+
// Breadth first, so the nearest ssh wins (e.g. the one typed at the prompt, not one it spawned).
|
|
224
|
+
let level = [root];
|
|
225
|
+
for (let depth = 0; depth < 6 && level.length; depth++) {
|
|
226
|
+
const next = [];
|
|
227
|
+
for (const pid of level) {
|
|
228
|
+
for (const child of children.get(pid) ?? []) {
|
|
229
|
+
if (/(^|\/)ssh$/.test(child.args[0] ?? '')) {
|
|
230
|
+
const cmd = parseSSHCommand(child.args.slice(1));
|
|
231
|
+
if (cmd) {
|
|
232
|
+
return { pid: child.pid, cmd };
|
|
233
|
+
}
|
|
234
|
+
}
|
|
235
|
+
next.push(child.pid);
|
|
236
|
+
}
|
|
237
|
+
}
|
|
238
|
+
level = next;
|
|
239
|
+
}
|
|
240
|
+
return null;
|
|
241
|
+
}
|
|
242
|
+
};
|
|
243
|
+
exports.RemoteTargets = RemoteTargets;
|
|
244
|
+
exports.RemoteTargets = RemoteTargets = __decorate([
|
|
245
|
+
(0, core_1.Injectable)({ providedIn: 'root' })
|
|
246
|
+
], RemoteTargets);
|
|
247
|
+
//# sourceMappingURL=targets.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"targets.js","sourceRoot":"","sources":["../src/targets.ts"],"names":[],"mappings":";;;;;;;;;AAiCA,sCAGC;AAgCD,0CA+BC;AAnGD,wCAA0C;AAC1C,iDAA+C;AAC/C,mCAA+B;AAC/B,2CAAgE;AAChE,+BAAmE;AAuBnE,SAAS,eAAe,CAAE,GAAwC;IAC9D,MAAM,CAAC,GAAG,GAAyB,CAAA;IACnC,OAAO,CAAC,EAAE,OAAO,EAAE,IAAI,KAAK,OAAO,IAAI,CAAC,CAAC,CAAC,CAAC,OAAO,EAAE,aAAa,IAAI,OAAO,CAAC,CAAC,OAAO,EAAE,iBAAiB,KAAK,UAAU,CAAA;AAC3H,CAAC;AAED,iGAAiG;AACjG,SAAgB,aAAa,CAAE,GAAwC;IACnE,MAAM,IAAI,GAAG,GAAG,YAAY,8BAAiB,CAAC,CAAC,CAAC,GAAG,CAAC,aAAa,EAAE,CAAC,CAAC,CAAC,GAAG,CAAA;IACzE,OAAO,IAAA,cAAQ,EAAC,IAAI,CAAC,IAAI,eAAe,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,IAAmB,CAAC,CAAC,CAAC,IAAI,CAAA;AAC/E,CAAC;AAED,mGAAmG;AAEnG,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AAC;YACL,CAAC;YACD,KAAK,GAAG,IAAI,CAAA;QAChB,CAAC;QACD,OAAO,IAAI,CAAA;IACf,CAAC;CACJ,CAAA;AA5FY,sCAAa;wBAAb,aAAa;IADzB,IAAA,iBAAU,EAAC,EAAE,UAAU,EAAE,MAAM,EAAE,CAAC;GACtB,aAAa,CA4FzB"}
|
package/dist/ui.js
ADDED
|
@@ -0,0 +1,212 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
+
};
|
|
8
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.RemoteDesktopToolbarButton = exports.RemoteDesktopContextMenu = exports.RemoteDesktopConfig = exports.RemoteDesktopHotkeys = exports.TOGGLE_HOTKEY = void 0;
|
|
13
|
+
exports.toggleLabel = toggleLabel;
|
|
14
|
+
exports.desktopChoices = desktopChoices;
|
|
15
|
+
exports.settingsMenu = settingsMenu;
|
|
16
|
+
const core_1 = require("@angular/core");
|
|
17
|
+
const tabby_core_1 = require("tabby-core");
|
|
18
|
+
const tabby_terminal_1 = require("tabby-terminal");
|
|
19
|
+
const desktop_service_1 = require("./desktop.service");
|
|
20
|
+
const ssh_1 = require("./ssh");
|
|
21
|
+
const targets_1 = require("./targets");
|
|
22
|
+
exports.TOGGLE_HOTKEY = 'remote-desktop-toggle';
|
|
23
|
+
/** Listed in Settings > Hotkeys, where it can be rebound. Works while the desktop has focus too. */
|
|
24
|
+
let RemoteDesktopHotkeys = class RemoteDesktopHotkeys extends tabby_core_1.HotkeyProvider {
|
|
25
|
+
async provide() {
|
|
26
|
+
return [{ id: exports.TOGGLE_HOTKEY, name: 'Remote desktop: switch between desktop and console (SSH tabs and terminals running ssh)' }];
|
|
27
|
+
}
|
|
28
|
+
};
|
|
29
|
+
exports.RemoteDesktopHotkeys = RemoteDesktopHotkeys;
|
|
30
|
+
exports.RemoteDesktopHotkeys = RemoteDesktopHotkeys = __decorate([
|
|
31
|
+
(0, core_1.Injectable)()
|
|
32
|
+
], RemoteDesktopHotkeys);
|
|
33
|
+
let RemoteDesktopConfig = class RemoteDesktopConfig extends tabby_core_1.ConfigProvider {
|
|
34
|
+
constructor() {
|
|
35
|
+
super(...arguments);
|
|
36
|
+
this.defaults = {
|
|
37
|
+
hotkeys: { [exports.TOGGLE_HOTKEY]: [] },
|
|
38
|
+
remoteDesktop: {
|
|
39
|
+
// Shareable session for SSH logins ('desk'): 'native' (trd-pty) or 'tmux' (earlier setup).
|
|
40
|
+
sessionBackend: 'native',
|
|
41
|
+
// When the pane changes size: 'live' | 'reconnect' | 'off'.
|
|
42
|
+
resize: 'live',
|
|
43
|
+
// 'standard' (CSS pixels) | 'retina' (device pixels, remote scaled to match).
|
|
44
|
+
sharpness: 'standard',
|
|
45
|
+
// `desk`: installs a login hook on remotes (applied the next time a desktop opens there).
|
|
46
|
+
desk: false,
|
|
47
|
+
// More desktops behind SSH hosts (e.g. a Windows VM whose RDP port the host forwards); see desktops.ts.
|
|
48
|
+
desktops: [],
|
|
49
|
+
},
|
|
50
|
+
};
|
|
51
|
+
this.platformDefaults = {
|
|
52
|
+
[tabby_core_1.Platform.macOS]: { hotkeys: { [exports.TOGGLE_HOTKEY]: ['⌘-Shift-G'] } },
|
|
53
|
+
[tabby_core_1.Platform.Windows]: { hotkeys: { [exports.TOGGLE_HOTKEY]: ['Ctrl-Shift-G'] } },
|
|
54
|
+
[tabby_core_1.Platform.Linux]: { hotkeys: { [exports.TOGGLE_HOTKEY]: ['Ctrl-Shift-G'] } },
|
|
55
|
+
};
|
|
56
|
+
}
|
|
57
|
+
};
|
|
58
|
+
exports.RemoteDesktopConfig = RemoteDesktopConfig;
|
|
59
|
+
exports.RemoteDesktopConfig = RemoteDesktopConfig = __decorate([
|
|
60
|
+
(0, core_1.Injectable)()
|
|
61
|
+
], RemoteDesktopConfig);
|
|
62
|
+
/** What switching does for this pane right now. Names the desktop when the host has more than one. */
|
|
63
|
+
function toggleLabel(desktop, pane) {
|
|
64
|
+
if (desktop.isVisible(pane)) {
|
|
65
|
+
return 'Back to console';
|
|
66
|
+
}
|
|
67
|
+
const { specs, current } = desktop.choicesOf(pane);
|
|
68
|
+
const what = specs.length > 1 && current ? current.name : 'remote desktop';
|
|
69
|
+
if (desktop.has(pane)) {
|
|
70
|
+
return `Show ${what}`;
|
|
71
|
+
}
|
|
72
|
+
return desktop.isOpenElsewhere(pane) ? `Switch to ${what} (open in another tab)` : `Open ${what}`;
|
|
73
|
+
}
|
|
74
|
+
/**
|
|
75
|
+
* The host's other desktops (besides the one the toggle acts on): open one here, replacing the current one.
|
|
76
|
+
* Then "Add a desktop behind <host>…".
|
|
77
|
+
*/
|
|
78
|
+
function desktopChoices(desktop, pane, targetLabel) {
|
|
79
|
+
const { specs, current } = desktop.choicesOf(pane);
|
|
80
|
+
const items = specs.filter(spec => spec.id !== current?.id).map(spec => ({
|
|
81
|
+
label: desktop.isOpenElsewhere(pane, spec) ? `Switch to ${spec.name} (open in another tab)` : `Open ${spec.name}`,
|
|
82
|
+
click: () => desktop.showDesktop(pane, spec.id),
|
|
83
|
+
}));
|
|
84
|
+
if (targetLabel) {
|
|
85
|
+
items.push({ label: `Add a desktop behind ${targetLabel}…`, click: () => desktop.addDesktop(pane) });
|
|
86
|
+
}
|
|
87
|
+
return items;
|
|
88
|
+
}
|
|
89
|
+
/** Tab header menu (whole tab: its focused pane) and in-terminal menu (that pane). */
|
|
90
|
+
let RemoteDesktopContextMenu = class RemoteDesktopContextMenu extends tabby_core_1.TabContextMenuItemProvider {
|
|
91
|
+
constructor(desktop, targets) {
|
|
92
|
+
super();
|
|
93
|
+
this.desktop = desktop;
|
|
94
|
+
this.targets = targets;
|
|
95
|
+
this.weight = 6;
|
|
96
|
+
}
|
|
97
|
+
async getItems(tab, tabHeader) {
|
|
98
|
+
// For a header right-click Tabby asks the top-level tab and then its focused pane; answer once.
|
|
99
|
+
if (tabHeader && tab.parent instanceof tabby_core_1.SplitTabComponent) {
|
|
100
|
+
return [];
|
|
101
|
+
}
|
|
102
|
+
const pane = (0, targets_1.desktopPaneOf)(tab);
|
|
103
|
+
// Local terminals qualify only while they run ssh.
|
|
104
|
+
if (!pane || !this.desktop.has(pane) && !await this.targets.targetOf(pane)) {
|
|
105
|
+
return [];
|
|
106
|
+
}
|
|
107
|
+
const items = [{
|
|
108
|
+
label: toggleLabel(this.desktop, pane),
|
|
109
|
+
click: () => this.desktop.toggle(pane),
|
|
110
|
+
}, ...desktopChoices(this.desktop, pane, this.targets.cached(pane)?.label)];
|
|
111
|
+
if (this.desktop.has(pane)) {
|
|
112
|
+
items.push({ label: 'Disconnect remote desktop', click: () => this.desktop.disconnect(pane) });
|
|
113
|
+
}
|
|
114
|
+
items.push({ label: 'Remote desktop settings', submenu: settingsMenu(this.desktop) });
|
|
115
|
+
return items;
|
|
116
|
+
}
|
|
117
|
+
};
|
|
118
|
+
exports.RemoteDesktopContextMenu = RemoteDesktopContextMenu;
|
|
119
|
+
exports.RemoteDesktopContextMenu = RemoteDesktopContextMenu = __decorate([
|
|
120
|
+
(0, core_1.Injectable)(),
|
|
121
|
+
__metadata("design:paramtypes", [desktop_service_1.RemoteDesktopService, targets_1.RemoteTargets])
|
|
122
|
+
], RemoteDesktopContextMenu);
|
|
123
|
+
/** Radio items for the `remoteDesktop` settings; shared by the context menus and the header button. */
|
|
124
|
+
function settingsMenu(desktop) {
|
|
125
|
+
const current = desktop.settings();
|
|
126
|
+
const radio = (key, value, label) => ({
|
|
127
|
+
type: 'radio',
|
|
128
|
+
label,
|
|
129
|
+
checked: current[key] === value,
|
|
130
|
+
click: () => desktop.updateSettings({ [key]: value }),
|
|
131
|
+
});
|
|
132
|
+
return [
|
|
133
|
+
{ label: 'When the pane is resized', enabled: false },
|
|
134
|
+
radio('resize', 'live', 'Resize the remote desktop to fit'),
|
|
135
|
+
radio('resize', 'reconnect', 'Reconnect at the new size'),
|
|
136
|
+
radio('resize', 'off', 'Keep the resolution (scale to fit)'),
|
|
137
|
+
{ type: 'separator' },
|
|
138
|
+
{ label: 'Sharpness', enabled: false },
|
|
139
|
+
radio('sharpness', 'standard', 'Standard'),
|
|
140
|
+
radio('sharpness', 'retina', 'Retina (device pixels, remote scaled to match)'),
|
|
141
|
+
{ type: 'separator' },
|
|
142
|
+
{
|
|
143
|
+
type: 'checkbox',
|
|
144
|
+
label: 'Bring the console along with `desk` (installs a login hook; applies on the next desktop connect)',
|
|
145
|
+
checked: current.desk,
|
|
146
|
+
click: () => desktop.updateSettings({ desk: !current.desk }),
|
|
147
|
+
},
|
|
148
|
+
{ type: 'separator' },
|
|
149
|
+
{
|
|
150
|
+
label: 'Remove a desktop',
|
|
151
|
+
enabled: desktop.configuredDesktops().length > 0,
|
|
152
|
+
submenu: desktop.configuredDesktops().map((d, i) => ({
|
|
153
|
+
label: `${d.name ?? `${d.host}:${d.port}`} (behind ${d.via})`,
|
|
154
|
+
click: () => desktop.removeDesktop(i),
|
|
155
|
+
})),
|
|
156
|
+
},
|
|
157
|
+
];
|
|
158
|
+
}
|
|
159
|
+
/** Adds a "Desktop" button to the SSH tab's floating toolbar, next to Reconnect / SFTP / Ports. */
|
|
160
|
+
let RemoteDesktopToolbarButton = class RemoteDesktopToolbarButton extends tabby_terminal_1.TerminalDecorator {
|
|
161
|
+
constructor(desktop, zone) {
|
|
162
|
+
super();
|
|
163
|
+
this.desktop = desktop;
|
|
164
|
+
this.zone = zone;
|
|
165
|
+
}
|
|
166
|
+
attach(terminal) {
|
|
167
|
+
if (!(0, ssh_1.isSSHTab)(terminal)) {
|
|
168
|
+
return;
|
|
169
|
+
}
|
|
170
|
+
const tab = terminal;
|
|
171
|
+
const root = tab.element.nativeElement;
|
|
172
|
+
const insert = () => {
|
|
173
|
+
const toolbar = root.querySelector('terminal-toolbar');
|
|
174
|
+
if (!toolbar || toolbar.querySelector('.trd-toolbar-button')) {
|
|
175
|
+
return !!toolbar;
|
|
176
|
+
}
|
|
177
|
+
const button = document.createElement('button');
|
|
178
|
+
button.className = 'btn btn-sm btn-link me-2 trd-toolbar-button';
|
|
179
|
+
button.title = 'Switch between the remote desktop and the console';
|
|
180
|
+
button.innerHTML = '<i class="fas fa-desktop"></i><span>Desktop</span>';
|
|
181
|
+
button.addEventListener('click', () => this.zone.run(() => this.desktop.toggle(tab)));
|
|
182
|
+
// Next to Reconnect / SFTP / Ports, which sit in a projected container inside the toolbar.
|
|
183
|
+
const anchor = toolbar.querySelector('button .fa-redo')?.closest('button') ?? toolbar.querySelector('button');
|
|
184
|
+
if (!anchor?.parentElement) {
|
|
185
|
+
return false;
|
|
186
|
+
}
|
|
187
|
+
anchor.parentElement.insertBefore(button, anchor);
|
|
188
|
+
return true;
|
|
189
|
+
};
|
|
190
|
+
if (insert()) {
|
|
191
|
+
return;
|
|
192
|
+
}
|
|
193
|
+
// The toolbar renders after the terminal attaches. Watch outside Angular's zone (see header.ts),
|
|
194
|
+
// and give up after a while: the toolbar can be disabled in settings.
|
|
195
|
+
this.zone.runOutsideAngular(() => {
|
|
196
|
+
const observer = new MutationObserver(() => {
|
|
197
|
+
if (insert()) {
|
|
198
|
+
observer.disconnect();
|
|
199
|
+
}
|
|
200
|
+
});
|
|
201
|
+
observer.observe(root, { childList: true, subtree: true });
|
|
202
|
+
setTimeout(() => observer.disconnect(), 30000);
|
|
203
|
+
tab.destroyed$.subscribe(() => observer.disconnect());
|
|
204
|
+
});
|
|
205
|
+
}
|
|
206
|
+
};
|
|
207
|
+
exports.RemoteDesktopToolbarButton = RemoteDesktopToolbarButton;
|
|
208
|
+
exports.RemoteDesktopToolbarButton = RemoteDesktopToolbarButton = __decorate([
|
|
209
|
+
(0, core_1.Injectable)(),
|
|
210
|
+
__metadata("design:paramtypes", [desktop_service_1.RemoteDesktopService, core_1.NgZone])
|
|
211
|
+
], RemoteDesktopToolbarButton);
|
|
212
|
+
//# sourceMappingURL=ui.js.map
|
package/dist/ui.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ui.js","sourceRoot":"","sources":["../src/ui.ts"],"names":[],"mappings":";;;;;;;;;;;;AA8CA,kCAUC;AAMD,wCAUC;AAkCD,oCAkCC;AA5ID,wCAAkD;AAClD,2CAGmB;AACnB,mDAA4E;AAC5E,uDAAyE;AACzE,+BAAgC;AAChC,uCAAqE;AAExD,QAAA,aAAa,GAAG,uBAAuB,CAAA;AAEpD,oGAAoG;AAE7F,IAAM,oBAAoB,GAA1B,MAAM,oBAAqB,SAAQ,2BAAc;IACpD,KAAK,CAAC,OAAO;QACT,OAAO,CAAC,EAAE,EAAE,EAAE,qBAAa,EAAE,IAAI,EAAE,yFAAyF,EAAE,CAAC,CAAA;IACnI,CAAC;CACJ,CAAA;AAJY,oDAAoB;+BAApB,oBAAoB;IADhC,IAAA,iBAAU,GAAE;GACA,oBAAoB,CAIhC;AAGM,IAAM,mBAAmB,GAAzB,MAAM,mBAAoB,SAAQ,2BAAc;IAAhD;;QACM,aAAQ,GAAG;YAChB,OAAO,EAAE,EAAE,CAAC,qBAAa,CAAC,EAAE,EAAE,EAAE;YAChC,aAAa,EAAE;gBACX,2FAA2F;gBAC3F,cAAc,EAAE,QAAQ;gBACxB,4DAA4D;gBAC5D,MAAM,EAAE,MAAM;gBACd,8EAA8E;gBAC9E,SAAS,EAAE,UAAU;gBACrB,0FAA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|
package/package.json
ADDED
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "tabby-rdp",
|
|
3
|
+
"version": "0.1.0",
|
|
4
|
+
"description": "Remote desktop in Tabby's SSH tabs, powered by IronRDP: the host's GNOME desktop, or Windows machines behind it, tunnelled through the SSH connection, with clipboard; `desk` brings the console along",
|
|
5
|
+
"keywords": [
|
|
6
|
+
"tabby-plugin",
|
|
7
|
+
"rdp",
|
|
8
|
+
"remote-desktop",
|
|
9
|
+
"ironrdp",
|
|
10
|
+
"gnome",
|
|
11
|
+
"windows",
|
|
12
|
+
"ssh"
|
|
13
|
+
],
|
|
14
|
+
"author": "meanaverage",
|
|
15
|
+
"license": "MIT",
|
|
16
|
+
"main": "dist/index.js",
|
|
17
|
+
"files": [
|
|
18
|
+
"dist",
|
|
19
|
+
"vendor",
|
|
20
|
+
"remote",
|
|
21
|
+
"LICENSE"
|
|
22
|
+
],
|
|
23
|
+
"engines": {
|
|
24
|
+
"node": ">=18"
|
|
25
|
+
},
|
|
26
|
+
"scripts": {
|
|
27
|
+
"build": "tsc -p tsconfig.json",
|
|
28
|
+
"build:ironrdp": "scripts/build-ironrdp.sh",
|
|
29
|
+
"watch": "tsc -p tsconfig.json --watch",
|
|
30
|
+
"prepublishOnly": "npm run build"
|
|
31
|
+
},
|
|
32
|
+
"dependencies": {
|
|
33
|
+
"ws": "^8.18.0"
|
|
34
|
+
},
|
|
35
|
+
"devDependencies": {
|
|
36
|
+
"@angular/core": "15.2.10",
|
|
37
|
+
"@types/node": "^20.19.0",
|
|
38
|
+
"rxjs": "7.8.2",
|
|
39
|
+
"typescript": "~5.9.3"
|
|
40
|
+
}
|
|
41
|
+
}
|