fix: tor userControl conflict

This commit is contained in:
fufsob committed 2026-09-23 02:34:10 +00:00
1 parent ae8f65da2e
commit 8f65fa9c25
3 files changed
+10 -23

No files matched your search

+1 -4
View File
@@ -176,10 +176,7 @@ in
assert hmCfg.systemd.user.services ? proxy-suite-inbounds;
assert hmCfg.systemd.user.services ? proxy-suite-tor;
# Rootless, there is no userControl group to hand the control socket to.
assert
!(lib.hasInfix "proxy-suite-tor-control-dir" (
toString (hmCfg.systemd.user.services.proxy-suite-tor.Service.ExecStartPre or [ ])
));
assert !(hmCfg.systemd.user.services.proxy-suite-tor.Service ? Group);
assert forced hmCfg.systemd.user.services;
# No setpriv on a user manager: nothing to drop to.
assert
+3 -3
View File
@@ -460,9 +460,9 @@ in
# userControl's group can use the control socket: that is `proxy-ctl tor status|newnym`.
(
assert
hasInfix "proxy-suite-tor-control-dir" (
toString (services controlled).proxy-suite-tor.serviceConfig.ExecStartPre
)
(services controlled).proxy-suite-tor.serviceConfig.Group == "proxy-suite"
&& hasInfix "mkdir -p -m 0750" (torStartOf controlled)
&& singBoxTorUnit.serviceConfig.Group == "proxy-suite-daemon"
&& !(singBoxTorUnit.serviceConfig ? ExecStartPre)
&&
(mkProxyCtlDerived singBox).wrapperEnv.TOR_CONTROL_SOCKET == "/run/proxy-suite-tor/control/socket";