nixos/tor: improve type-checking and hardening
Fixes #77395. Fixes #82790.
This commit is contained in:
@@ -16,7 +16,7 @@ let
|
||||
${concatMapStrings (f: "actionsfile ${f}\n") cfg.actionsFiles}
|
||||
${concatMapStrings (f: "filterfile ${f}\n") cfg.filterFiles}
|
||||
'' + optionalString cfg.enableTor ''
|
||||
forward-socks4a / ${config.services.tor.client.socksListenAddressFaster} .
|
||||
forward-socks5t / 127.0.0.1:9063 .
|
||||
toggle 1
|
||||
enable-remote-toggle 0
|
||||
enable-edit-actions 0
|
||||
@@ -123,6 +123,11 @@ in
|
||||
serviceConfig.ProtectSystem = "full";
|
||||
};
|
||||
|
||||
services.tor.settings.SOCKSPort = mkIf cfg.enableTor [
|
||||
# Route HTTP traffic over a faster port (without IsolateDestAddr).
|
||||
{ addr = "127.0.0.1"; port = 9063; IsolateDestAddr = false; }
|
||||
];
|
||||
|
||||
};
|
||||
|
||||
meta.maintainers = with lib.maintainers; [ rnhmjoj ];
|
||||
|
||||
Reference in New Issue
Block a user