feat(cli): select transport in config; server MultiServer + client dial handover

- aura-cli config gains [transport] (order + per-transport ports + obfuscate/
  masquerade); server binds all enabled transports via MultiServer, client uses
  dial() with UDP->TCP->QUIC handover. Config examples updated; backward-compatible
  (defaults to udp,tcp,quic). 21 cli tests incl. a real-UDP-transport loopback.
- docs/sing-box.md: integration approach note (process-bridge now; native Go
  outbound for phones, with crypto-library mapping + KAT requirement).
- Normalize rustfmt across the v2 transport files (tcp/dial/udp contract).

Whole workspace: 97 tests pass, clippy -D warnings clean, fmt clean. Deploy flow
(pki init/issue-server/issue-client) validated with the release binary.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
xah30
2026-05-25 21:41:59 +03:00
parent d72fbe8d68
commit d5b9a8611d
15 changed files with 682 additions and 94 deletions
+16
View File
@@ -51,3 +51,19 @@ cidr = "10.7.0.0/24"
[mimicry]
# Enable traffic padding to blend packet sizes into HTTPS buckets.
padding = false
[transport]
# Fallback order tried left-to-right ("handover"): the first transport that connects wins. Aura's
# own UDP transport is primary; TCP/443 and QUIC (HTTP/3 mimicry) are fallbacks for networks that
# throttle or block plain UDP. Omitting this whole section uses ["udp","tcp","quic"] on 443/443/444.
order = ["udp", "tcp", "quic"]
# Per-transport server ports. The server IP comes from [client] server_addr above (its port there is
# ignored). The UDP transport and QUIC both ride UDP, so udp_port and quic_port MUST differ; TCP may
# reuse the UDP port number.
udp_port = 443
tcp_port = 443
quic_port = 444
# UDP: pad datagrams up to HTTPS size buckets to blur the on-wire size distribution.
obfuscate = true
# TCP: prepend a minimal HTTP/1.1 preamble (Host = [client] sni) so the open resembles plain HTTP.
masquerade = true