From 9c74f9a51ba8dbd27de4d36453950997ff551dec Mon Sep 17 00:00:00 2001 From: Peter Simons Date: Mon, 29 Oct 2012 17:10:17 +0100 Subject: [PATCH] modules/programs/ssh.nix: configure AddressFamily properly Explicitly restrict ssh clients to use of IPv4 addresses if IPv6 support is not enabled. --- modules/programs/ssh.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/modules/programs/ssh.nix b/modules/programs/ssh.nix index 5c4b8c3a9a1..123ef3c0256 100644 --- a/modules/programs/ssh.nix +++ b/modules/programs/ssh.nix @@ -42,6 +42,7 @@ in [ { # SSH configuration. Slight duplication of the sshd_config # generation in the sshd service. source = pkgs.writeText "ssh_config" '' + AddressFamily ${if config.networking.enableIPv6 then "any" else "inet"} ${optionalString cfg.setXAuthLocation '' XAuthLocation ${pkgs.xorg.xauth}/bin/xauth ''}