WSSSHT(1)

NAME
wsssht - WSSH Tunnel Setup Tool

SYNOPSIS
wsssht [--config FILE] [--clientid ID] [--tunnel-port PORT] [--tunnel-host HOST] [--wssshd-host HOST] [--wssshd-port PORT] [--interval SEC] [--debug] [--tunnel TRANSPORT] [--tunnel-control TYPES] [--service SERVICE] [--enc ENCODING] [--mode MODE] [--silent] [--bridge] [--script] [--daemon] [--help] [service://]clientid[@wssshd-host][:wssshd-port]

DESCRIPTION
wsssht is a WSSSH tunnel setup tool that establishes secure tunnels through WebSocket connections without automatically executing SSH/SCP commands. It provides connection information for manual use with any TCP client.

Unlike wsssh(1) and wsscp(1), wsssht does not fork and execute external commands. Instead, it sets up the tunnel and displays connection instructions for manual use.

OPTIONS

--config FILE
    Use custom config file (takes precedence over default)

--clientid ID
    Specify the client ID for the tunnel (default: from config)

--tunnel-port PORT
    Specify the local port for the tunnel (default: auto-assigned)

--tunnel-host HOST
    Specify the local IP address to bind the tunnel to (default: 127.0.0.1)

--wssshd-host HOST
    Specify the wssshd server hostname (required if not in config)

--wssshd-port PORT
    WSSH daemon server port (default: 9898)

--interval SEC
    Connection retry interval in seconds (default: 5)

--debug
    Enable debug output

--tunnel TRANSPORT
    Transport for data channel (comma-separated or 'any', or 'websocket' default: any)

--tunnel-control TYPES
    Transport types for control channel (comma-separated or 'any', default: any)

--service SERVICE
    Service type (default: ssh)

--enc ENCODING
    Data encoding: hex, base64, or bin (default: hex)

--mode MODE
    Operating mode: interactive, silent, bridge, script (default: interactive)

--silent
    Shortcut for --mode silent

--bridge
    Shortcut for --mode bridge

--script
    Shortcut for --mode script

--daemon
    Enable daemon mode for lazy initialization

--help
    Display help message and exit

CONNECTION STRING FORMAT
The optional connection string argument supports the following format:

    [service://]clientid[@wssshd-host][:wssshd-port]

Where:

    service
        Optional service prefix (e.g., ssh://, rdp://)

    clientid
        Required client identifier

    wssshd-host
        Optional wssshd server hostname

    wssshd-port
        Optional wssshd server port

Command line options take precedence over values parsed from the connection string.

EXAMPLES

Basic tunnel setup with options:
    wsssht --clientid myclient --wssshd-host mbetter.nexlab.net

Connection string format:
    wsssht myclient@mbetter.nexlab.net:9898

With service prefix:
    wsssht ssh://myclient@mbetter.nexlab.net

Mixed options and connection string:
    wsssht --tunnel websocket myclient@mbetter.nexlab.net

Debug mode:
    wsssht --debug myclient@mbetter.nexlab.net

MANUAL CONNECTION
Once the tunnel is established, wsssht displays connection information:

    ========================================
            WSSH TUNNEL READY
    ========================================
    Tunnel established successfully!
    Local port: 49234
    Target: myclient@mbetter.nexlab.net
    Connect manually using one of these commands:
      Telnet:
        telnet localhost 49234
      Netcat:
        nc localhost 49234
      SSH (if connecting to SSH server):
        ssh -p 49234 user@localhost
      SCP (if connecting to SSH server):
        scp -P 49234 user@localhost:/remote/path ./local/path
      Any TCP client:
        Connect to localhost:49234
    Press Ctrl+C to close the tunnel and exit.
    ========================================

CONFIGURATION
wsssht supports configuration files with the following precedence order:

    1.  Command line options (highest priority)

    2.  User configuration: ~/.config/wsssh/wsssht.conf

    3.  System configuration: /etc/wsssht.conf (lowest priority)

Configuration options:

    wssshd-host=mbetter.nexlab.net
    wssshd-port=9898
    clientid=myclient
    tunnel-port=0
    tunnel-host=127.0.0.1
    tunnel=websocket
    tunnel-control=websocket
    service=ssh
    enc=hex
    interval=5

Note: Unlike wsssh(1) and wsscp(1), wsssht uses its own configuration files wsssht.conf instead of sharing wsssh.conf. System administrators can provide default settings in /etc/wsssht.conf which will be overridden by user settings in ~/.config/wsssh/wsssht.conf and command line options.

SEE ALSO
wsssh(1), wsscp(1), wssshc(1), wssshd(1)

AUTHOR
Written by Stefy Lanza <stefy@nexlab.net> and SexHack.me

COPYRIGHT
Copyright © 2024 Stefy Lanza and SexHack.me

This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

BUGS
Report bugs to https://git.nexlab.net/nexlab/wsssh