fix: hardening and fixes

This commit is contained in:
fufsob committed 2026-09-15 08:56:33 +00:00
1 parent aa19042ee5
commit a82417a2bd
32 files changed
+619 -256

No files matched your search

+8 -1
View File
@@ -39,7 +39,14 @@ in
profiles = mkOption {
type = types.attrsOf t.profileType;
default = { };
description = "Named AmneziaWG client profiles. Only one global profile can be active.";
description = ''
Named AmneziaWG client profiles. Only one global profile can be active.
A profile moves to a new source port, keeping its routes, when a handshake goes
unanswered: every 5 seconds while it starts (it gives up after 20), and when
proxy-suite-awg-NAME-watchdog sees a rekey not getting through. settings.listenPort
pins the port and turns that off.
'';
};
};
}
+3 -3
View File
@@ -47,7 +47,7 @@ in
'';
};
identityFile = path "Runtime path to the private key. Null uses the agent or OpenSSH defaults." "/run/secrets/proxy-suite-ssh-key";
identityFile = path "Runtime path to the private key; it may stay root-only, as the daemons get a copy they can read. Null uses the agent or OpenSSH defaults." "/run/secrets/proxy-suite-ssh-key";
hostKey = mkOption {
type = types.listOf types.str;
@@ -92,8 +92,8 @@ in
serviceUser = mkOption {
type = token;
default = null;
description = "Unix user running the OpenSSH unit.";
default = "proxy-suite-daemon";
description = "Unix user running the OpenSSH unit. The default, proxy-suite-daemon, runs sandboxed and keeps accepted host keys in /var/lib/proxy-suite/ssh; null runs it as root.";
example = "proxy";
};
+2 -2
View File
@@ -109,8 +109,8 @@ in
file = mkOption {
type = types.nullOr types.str;
default = null;
description = "Rotating log file. Null logs to stderr.";
example = "/var/log/tg-ws-proxy.log";
description = "Rotating log file, written as the proxy-suite-daemon user; /var/log/proxy-suite-tg-ws-proxy is created for it. Null logs to stderr.";
example = "/var/log/proxy-suite-tg-ws-proxy/tg-ws-proxy.log";
};
maxSizeMiB = mkOption {
+5 -3
View File
@@ -39,8 +39,9 @@ in
default = false;
description = ''
Add WARP as an outbound tagged "warp": a SOCKS hop to proxy-suite-warp-tunnel, which
runs WARP as a sing-box WireGuard endpoint on 127.0.0.1:18538 and restarts it on a new
source port when the handshake stops being answered.
runs WARP as a sing-box WireGuard endpoint on 127.0.0.1:18538, as the proxy-suite-daemon user.
The tunnel starts again on a new source port when WARP does not answer within 15 seconds
of a start, or misses three probes later on, unless the uplink itself is down.
'';
};
@@ -48,7 +49,8 @@ in
type = types.bool;
default = false;
description = ''
Add an AmneziaWG profile named "warp" (`proxy-ctl awg on warp`). Requires amneziaWg.enable.
Add an AmneziaWG profile named "warp" (`proxy-ctl awg on warp`). Requires amneziaWg.enable,
and excludes asOutbound: both would use the same WARP key.
'';
};
};