Implement SSH port forwarding and improve jump host UI
Port Forwarding (new): - Add PortForward model with local/remote direction, bind/dest addresses - Implement ForwardManager in sshclient/portforward.go with full bidirectional tunnel support for both local and remote forwarding - Integrate ForwardManager into SSH client lifecycle (auto-start on connect, clean shutdown on close) - Add session manager methods: ListPortForwards, StartPortForward, StopPortForward with event emission - Add API surface: ListPortForwards, StartPortForward, StopPortForward - Add validation for port-forward rules in ValidateSSHConfig - Add port forwarding section to profile editor with direction, bind/dest host/port, label, and enable toggle - Add frontend event handling for forward:started/stopped/error - Style port-forward rows with charcoal card design matching jump hosts Jump Host UI improvements: - Add private key path field to jump host editor rows - Collect privateKeyPath in form value collection - Restyle jump host rows as two-line cards with clear field grouping
This commit is contained in:
@@ -180,6 +180,21 @@ class App {
|
||||
);
|
||||
});
|
||||
|
||||
// Port-forwarding events
|
||||
window.runtime.EventsOn('session:forward:started', (payload) => {
|
||||
const fwd = payload.forward || {};
|
||||
const label = fwd.label || `${fwd.bindHost || ''}:${fwd.bindPort} → ${fwd.destHost}:${fwd.destPort}`;
|
||||
this.notifications.success(`Forward started: ${label}`);
|
||||
});
|
||||
|
||||
window.runtime.EventsOn('session:forward:stopped', (payload) => {
|
||||
this.notifications.info(`Forward stopped: ${payload.forwardID}`);
|
||||
});
|
||||
|
||||
window.runtime.EventsOn('session:forward:error', (payload) => {
|
||||
this.notifications.error(`Forward error: ${payload.error}`);
|
||||
});
|
||||
|
||||
// Telnet negotiation debug messages
|
||||
window.runtime.EventsOn('session:debug', (payload) => {
|
||||
console.debug('[session:debug]', payload);
|
||||
|
||||
Reference in New Issue
Block a user