Random I1 and MTU on install
I1 becomes a DNS query to a random popular domain (A/AAAA) instead of the shared icloud.com response every key carried. The format sticks to tags both the kernel module and amneziawg-go accept and is checked before awg1.conf is written: a bad I1 fails the whole awg-quick up. With KEEP_DATA=y the old I1 is kept, or generated if missing — the server never checks it, old keys keep their own. MTU is picked from 1320–1376 (AWG_MTU overrides) and kept on reinstall. awg-ctrl now reads MTU from awg1.conf for vpn:// keys instead of a constant. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_013bNGYiDst62wH3ZGTRPFLJ
This commit is contained in:
@@ -150,7 +150,7 @@ func New() (*Server, error) {
|
||||
module, tools := readVersions()
|
||||
s.c = Config{
|
||||
ServerIP: ip, ServerPort: sp, ServerName: name,
|
||||
DNS1: "1.1.1.1", DNS2: "1.0.0.1", MTU: 1376, Subnet: "10.9",
|
||||
DNS1: "1.1.1.1", DNS2: "1.0.0.1", MTU: ReadMTU(s.confPath()), Subnet: "10.9",
|
||||
Keepalive: keepaliveByGen[gen], Params: params, Gen: gen,
|
||||
AwgModule: module, AwgTools: tools,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user