|
47 | 47 | ./trafficserver.nix |
48 | 48 | ./athens.nix |
49 | 49 | ./remote-builder.nix |
| 50 | + ./services.ssh.nix |
50 | 51 | ]; |
51 | 52 |
|
52 | 53 | # Bootloader. |
|
190 | 191 | enableSSHSupport = true; |
191 | 192 | }; |
192 | 193 |
|
193 | | - # https://nixos.wiki/wiki/SSH |
194 | | - # https://github.com/NixOS/nixpkgs/blob/master/nixos/modules/services/networking/ssh/sshd.nix |
195 | | - # https://github.com/NixOS/nixpkgs/blob/47457869d5b12bdd72303d6d2ba4bfcc26fe8531/nixos/modules/services/security/sshguard.nix |
196 | | - services.openssh = { |
197 | | - enable = true; |
198 | | - openFirewall = true; |
199 | | - settings = { |
200 | | - # default key algos: https://github.com/NixOS/nixpkgs/blob/master/nixos/modules/services/networking/ssh/sshd.nix#L546 |
201 | | - # KexAlgorithms = [ |
202 | | - # "mlkem768x25519-sha256" |
203 | | - # "sntrup761x25519-sha512" |
204 | | - # "sntrup761x25519-sha512@openssh.com" |
205 | | - # "curve25519-sha256" |
206 | | - # "curve25519-sha256@libssh.org" |
207 | | - # "diffie-hellman-group-exchange-sha256" |
208 | | - # ]; |
209 | | - Ciphers = [ |
210 | | - "chacha20-poly1305@openssh.com" |
211 | | - "aes256-gcm@openssh.com" |
212 | | - "aes128-gcm@openssh.com" |
213 | | - # shortned default list |
214 | | - ]; |
215 | | - Macs = [ |
216 | | - "hmac-sha2-512-etm@openssh.com" |
217 | | - "hmac-sha2-256-etm@openssh.com" |
218 | | - "umac-128-etm@openssh.com" |
219 | | - ]; |
220 | | - # HostKeyAlgorithms = [ |
221 | | - # "ssh-ed25519-cert-v01@openssh.com" |
222 | | - # "sk-ssh-ed25519-cert-v01@openssh.com" |
223 | | - # "rsa-sha2-512-cert-v01@openssh.com" |
224 | | - # "rsa-sha2-256-cert-v01@openssh.com" |
225 | | - # "ssh-ed25519" |
226 | | - # "sk-ssh-ed25519@openssh.com" |
227 | | - # "rsa-sha2-512" |
228 | | - # "rsa-sha2-256" |
229 | | - # ]; |
230 | | - UsePAM = true; |
231 | | - KbdInteractiveAuthentication = true; |
232 | | - PermitRootLogin = "prohibit-password"; |
233 | | - PasswordAuthentication = false; |
234 | | - ChallengeResponseAuthentication = false; |
235 | | - X11Forwarding = false; |
236 | | - GatewayPorts = "no"; |
237 | | - }; |
238 | | - }; |
| 194 | + # # https://nixos.wiki/wiki/SSH |
| 195 | + # # https://github.com/NixOS/nixpkgs/blob/master/nixos/modules/services/networking/ssh/sshd.nix |
| 196 | + # # https://github.com/NixOS/nixpkgs/blob/47457869d5b12bdd72303d6d2ba4bfcc26fe8531/nixos/modules/services/security/sshguard.nix |
| 197 | + # services.openssh = { |
| 198 | + # enable = true; |
| 199 | + # openFirewall = true; |
| 200 | + # settings = { |
| 201 | + # # default key algos: https://github.com/NixOS/nixpkgs/blob/master/nixos/modules/services/networking/ssh/sshd.nix#L546 |
| 202 | + # # KexAlgorithms = [ |
| 203 | + # # "mlkem768x25519-sha256" |
| 204 | + # # "sntrup761x25519-sha512" |
| 205 | + # # "sntrup761x25519-sha512@openssh.com" |
| 206 | + # # "curve25519-sha256" |
| 207 | + # # "curve25519-sha256@libssh.org" |
| 208 | + # # "diffie-hellman-group-exchange-sha256" |
| 209 | + # # ]; |
| 210 | + # Ciphers = [ |
| 211 | + # "chacha20-poly1305@openssh.com" |
| 212 | + # "aes256-gcm@openssh.com" |
| 213 | + # "aes128-gcm@openssh.com" |
| 214 | + # # shortned default list |
| 215 | + # ]; |
| 216 | + # Macs = [ |
| 217 | + # "hmac-sha2-512-etm@openssh.com" |
| 218 | + # "hmac-sha2-256-etm@openssh.com" |
| 219 | + # "umac-128-etm@openssh.com" |
| 220 | + # ]; |
| 221 | + # # HostKeyAlgorithms = [ |
| 222 | + # # "ssh-ed25519-cert-v01@openssh.com" |
| 223 | + # # "sk-ssh-ed25519-cert-v01@openssh.com" |
| 224 | + # # "rsa-sha2-512-cert-v01@openssh.com" |
| 225 | + # # "rsa-sha2-256-cert-v01@openssh.com" |
| 226 | + # # "ssh-ed25519" |
| 227 | + # # "sk-ssh-ed25519@openssh.com" |
| 228 | + # # "rsa-sha2-512" |
| 229 | + # # "rsa-sha2-256" |
| 230 | + # # ]; |
| 231 | + # UsePAM = true; |
| 232 | + # KbdInteractiveAuthentication = true; |
| 233 | + # PermitRootLogin = "prohibit-password"; |
| 234 | + # PasswordAuthentication = false; |
| 235 | + # ChallengeResponseAuthentication = false; |
| 236 | + # X11Forwarding = false; |
| 237 | + # GatewayPorts = "no"; |
| 238 | + # }; |
| 239 | + # }; |
239 | 240 |
|
240 | | - services.sshguard.enable = true; |
| 241 | + # services.sshguard.enable = true; |
241 | 242 |
|
242 | 243 | # search for serivces url |
243 | 244 | #https://github.com/search?q=repo%3ANixOS%2Fnixpkgs+path%3A%2F%5Enixos%5C%2Fmodules%5C%2Fservices%5C%2F%2F+openssh&type=code |
|
0 commit comments