@PJH @Deadfast Thanks! I've seen protobufs used in strangest places (e.g. home-grown machine learning framework for search engine design elective). I should try them, too. Sending raw Protocol Buffers / FlatBuffers / JSON over TLS does not seem to be the way, since most parsers don't offer a way to read a partial message and ask for more, retaining the state (or stop when one message ends and allow to treat trailing bytes as another message later). @dkf said in NAT traversal and stuff: The amount of experience required to reliably get this sort of thing right with your first attempt is probably more than any ordinary programmer can get across their whole career. I guess this explains the lack of books/courses on application protocol design. @dkf said in NAT traversal and stuff: But it's not a horrible mistake to use JSON (or XML) as a transport encoding over HTTP But pick up a too high level abstraction, and I wouldn't be able to perform the low-level TLS and socket fuckery I want. I'm also afraid of ending up like XMPP and spending more traffic on auxiliary information than messages themselves. The way forward is trying it and seeing what fails. I'll try to get a prototype working soon.