SSH Tunnel Utility
The SSH Tunnel Utility allows to create secure reverse SSH-based connection tunnels to a remote SSH server (hub). Up to three concurrent tunnels can be established, one for local SSH console access, one for the HTTPS Web server connections and one additional (AUX) tunnel to any local service network port like, for example, the Modbus TCP Gateway server.
A tunnel is configured by setting the local TCP port of a network server, and the remote TCP port for the tunnel on the remote SSH server. Connecting to the TCP port associated to a tunnel on the remote server will route the connection and all established traffic, through the tunnel, to the local TCP port defined in the tunnel configuration.
Thanks to the SSH tunnels, a local HSYCO Server that lacks inbound connectivity, could still be accessed via a remote and accessible SSH server configured as a tunnel end-point.
The tunnel configuration parameters can be modified only when tunneling is not enabled.
The "SSH hub host name" is the network name or IP address of the remote SSH tunnel server (hub).
In order to establish a secure connection, the SSH Tunnel Utility authenticates on the remote SSH tunnel server with the user id set in "SSH user on hub" and the "SSH public key" of the HSYCO Server, that must be copied into the "authorized_keys" file on the hub for that user.
If the SSH, HTTPS or AUX port number fields are left empty, the corresponding tunnel is not activated.
Note that the tunnels are only active while HSYCO is running. Restarting HSYCO, all connections established through the tunnels, including the SSH connection, are dropped.
The configuration API
The SSH Tunnel Utility can be dynamically configured, and the tunnel service enabled and disabled, with USER calls in ENVENTS and the user() command in Java or JavaScript.
In the following EVENTS example, the tunnel is enabled at 08:00 and disabled at 18:00.
TIME 0800 : USER sshtunnel.enable = true TIME 1800 : USER sshtunnel.enable = false
User commands
ID | Value | R/W | Description |
---|---|---|---|
backlight.brightness | <brightness> | R | the current backlight brightness of HSYCO Pi Touch Display |
W | set brightness of HSYCO Pi Touch Display to a value between 0 (off) and 255 (max) | ||
battery (base/ups only) |
0 | R | power supply is available |
1 | R | power supply failure, running on UPS battery |