INPAK
INPAK is the suggested interface pattern for HELLO peers. Its listener accepts a connection and hands it to the appropriate handler. When it picks HELLO, the HELLO engine handles the greeting, commands, and replies.
- Plain text
- A line of text can start a serial HELLO session. The client can also wait for the greeting.
- HTTP
- A web request reaches the HTTP handler. A WebSocket upgrade at
/_wsopens a HELLO session in the browser. - TLS
- On a TLS connection, a client can select serial HELLO using the ALPN identifier
jmpkit-hello/1.
Try the same port two ways
JMPKit is a reference service using HELLO and INPAK. Connect with netcat and type PING to get PONG, or use a browser to open the JMPKit site on the same port.
nc hello.jmpkit.com 38761
See the captured exchange in the INPAK Library topic.
Run the JMPKit reference locally
With a copy of the JMPKit project, run this from V6/hello. Pick a free local port if 19000 is in use.
python3 -m venv .venv
.venv/bin/python -m pip install -r requirements.txt
.venv/bin/python server.py --bind 127.0.0.1 --port 19000 --site-root ../www
Open http://127.0.0.1:19000/ for the web page, or run nc 127.0.0.1 19000 for serial HELLO.