Documentation
¶
Overview ¶
test_server is a Unix-domain-socket helper used by the JS cross-language e2e tests Framing: 4-byte big-endian length prefix + raw envelope bytes
CLI flags:
-socket <path> UDS path to listen on -self-id <string> server's own ID -private-key <hex> server's 32-byte private key -client-id <string> the single paired client's ID -client-pub <hex> the client's 65-byte public key -drop-ack if set, the server drops the first renewKeyAck frame to simulate a lost ACK -drop-first-request if set, the server drops the first non-renewal request frame to simulate a lost response
Registered handlers (so the JS test can exercise them):
echo returns the incoming payload unchanged
add expects {a, b} and returns {sum}
trigger-push sends a server Push of type "tick" carrying {n: 42}, then replies {ok: true}
push-under-stashed builds and writes a push envelope encrypted with the stashed pre-renewal
session, bypassing the server's live session cache. The stash is taken
automatically inside CommitClientPublicKey just before a key rotation,
so this handler exercises the case where an in-flight push from before
a renewal arrives after the client has already committed a new key
Click to show internal directories.
Click to hide internal directories.