Nested tmux over SSH: why Ctrl-k worked through a relay but not directly
Ctrl-k reached my remote tmux when I logged in through a relay, but the same key went to local tmux when I connected directly. The loopback login, nb, and nbx all reached the intended SSH server. The problem was how my local helper decided where to send the key.
The fix was to treat known forwarded endpoints differently from a relay. For ports 62222 and 62223, I already knew the destination used Ctrl-k, so I could skip detection. For a relay, I still needed to detect when the second SSH connection started and ended. This follows up on my two-hop tmux setup.







