Understand websocat invocation modes
masterwebsocat operates by creating two connections and exchanging data between them. It supports three primary modes of invocation:
- Simple client mode: Connects to a remote WebSocket server.
- Simple server mode: Starts a local WebSocket server.
- Advanced [socat]-like mode: Uses address specifiers to bridge different types of connections (e.g., bridging a local TCP port to a WebSocket mirror).
If one connection is bytestream-oriented (like terminal stdin/stdout or a TCP connection) and the other is message-oriented (like WebSocket or UDP), websocat defaults to operating in lines, where each line corresponds to a single message. This behavior can be configured via specific options.