Default ports and paths
| Endpoint | Default | Use |
|---|---|---|
| HTTPS / WSS | TCP 8191 | Browser assets and browser/native WSS connections |
| WSS upgrade path | /transport | Viewer WebSocket transport |
| Native TLS / TCP | TCP 4815 | Native viewer with --use-tcp |
| Session administration | Local OS endpoint | Privileged tmdtool operations; not a public TCP service |
Allow the selected transport through every relevant host firewall, router, cloud security group, and access policy. A local installation rule does not configure an external network device. Keep remote administration access available while changing firewall rules.
Firewall examples
For an already enabled Ubuntu UFW firewall, restrict WSS to a trusted client subnet. Replace this documentation subnet:
sudo ufw allow from 192.0.2.0/24 to any port 8191 proto tcp
sudo ufw status
Add a TCP 4815 rule only if using native TCP. If enabling UFW for the first time over SSH, allow your SSH access before enabling the firewall.
The Windows MSI can create exceptions for the default ports or defer setup. On macOS, review host firewall policy and external network rules separately. If you change a listener port, update rules and viewer addresses together.
Change listener settings
On Linux/macOS, merge into /etc/tmd/server/tmd.conf:
[transport]
wss-enable = 1
wss-port = 8191
wss-path = /transport
tcp-port = 4815
Values above show the defaults. Windows service equivalents are under the transport subkey of its service registry. Apply configuration during a maintenance window.
Configure TLS certificates
TMD generates a self-signed certificate by default. For managed deployments, supply a PEM server certificate and matching private key, issued for the DNS name used by viewers. Merge these settings, replacing the example paths:
[security]
self-signed-certificate = /etc/tmd/server/tmd.example.com.crt
private-key = /etc/tmd/server/tmd.example.com.key
authentication-method = system
The historical setting name self-signed-certificate is also used to supply your certificate file. Keep the private key readable only by the required service account/administrators. Both files must exist; check startup and the certificate actually presented after restarting. A missing configured file can cause fallback to the generated certificate.
HTTPS is required for the browser viewer's secure-context capabilities, including clipboard and WebCodecs. Browser trust exceptions are per profile/origin; verify the host identity before accepting one.
Test through an SSH tunnel
From the client machine, on a Linux/macOS server with SSH access:
ssh -N -L 8191:127.0.0.1:8191 alice@tmd.example.com
Then connect to https://localhost:8191/#console or #work. A certificate issued only for the server name will not match localhost; verify the expected endpoint rather than interpreting this as a different server. Close the SSH process when the test is complete.
Verify connectivity in order
- Confirm the service and intended listener are running.
- Confirm the requested TMD session reports
active. - Test reachability from the actual client network.
- Verify TLS identity and trust.
- Check system authentication and session ownership.
- Only then investigate codecs or capture if the connected desktop is wrong.
On Linux:
sudo ss -ltnp | grep -E ':4815|:8191'
sudo tmdtool list-sessions --json
A failed TLS handshake before certificate acceptance does not by itself indicate a capture failure. Use both server and viewer logs to place the failure in the connection sequence.