Commit graph

5 commits

Author SHA1 Message Date
9e050b140b cli: rename -reconnect-delay to -reconnect-delay-secs
All time arguments now use -secs suffix with integer seconds for
consistency (-reconnect-delay-secs, -keepalive-timeout-secs).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-07-11 11:56:37 -03:00
1a397c363f tunnel: add -keepalive-timeout-secs for dead connection detection
Tracks last server receive time (atomic) and runs a watchdog goroutine
that closes the connection if no data arrives within the timeout,
triggering reconnection. Also fixes Close() to guard Conn.Close()
inside sync.Once so concurrent/repeated calls are safe.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-07-11 11:54:12 -03:00
51824b830e netcfg: add -connmark flag for DNAT reply routing
When VPN traffic is DNAT'd to local namespaces/VMs, reply packets have
a different source IP (namespace veth) so the policy route's
"from <VPN_IP>" rule doesn't match. CONNMARK marks all connections
arriving on the VPN interface and restores the mark on reply packets,
routing them back through the tunnel via fwmark rule.

New flag: -connmark (requires -policy-route-table)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-06-07 01:06:17 +05:30
42f8333783 rename -dhcp flag to -no-dhcp for cleaner UX
DHCP is on by default; use -no-dhcp to disable.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-06-06 17:53:01 +05:30
8a3ea06c9e add CLAUDE.md with project context and protocol notes
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-06-06 17:45:19 +05:30