{ config, lib, ... }: let cfg = config.profile.openssh; in { config = lib.mkIf cfg.enable { services.openssh = { enable = true; settings = { PasswordAuthentication = false; UseDns = true; X11Forwarding = false; PermitRootLogin = "no"; }; }; }; }