Commit Graph
4 Commits
Author SHA1 Message Date
Max Lv 892b45d1e5 Add the C++ TCP relay engine and run ss-tunnel on it
One engine (src/relay/tcp) for the four TCP relays: connections live in a
fixed pool owned through PoolPtr, handshake, cipher state and buffers are
inline, timeouts are intrusive deadline lists on one timer and DNS answers
come back through generation-checked handles. A full pool refuses new
connections and pauses accepting until a slot frees.

ss-tunnel is the first user; its hand-written relay callbacks are gone.
tests/tunnel_interop.py covers every method against ss-server and
shadowsocks-rust.
2026-10-14 22:53:09 +08:00
Max Lv ca359160b2 Include C++ headers before crypto.h in test_crypto_aead2022_cpp.cpp
crypto.h defines min/max macros for the C sources; libstdc++ headers
included after it fail to parse.
2026-10-14 22:53:08 +08:00
Max Lv f92f578cce Include <algorithm> for std::min in test_crypto_aead2022_cpp.cpp 2026-10-14 22:53:08 +08:00
Max Lv 47163a57fd Add allocation-free C++ SIP022 codecs
TCP request/response streams with the salt echo between the two
directions, an exact-match salt pool on FixedLru, and UDP packets sealed
and opened in place with caller-owned session state. Differentially
tested against aead2022.cpp in both roles; the steady phase allocates
nothing.
2026-10-14 22:53:08 +08:00