security improvements among other things

This commit is contained in:
Schrottkatze 2023-03-18 17:54:57 +01:00
parent bd85fdb12f
commit 1d2c6bb0f0
8 changed files with 66 additions and 32 deletions

View file

@ -6,5 +6,6 @@
./neovim.nix
./zsh.nix
./flatpak.nix
./firewall.nix
];
}

View file

@ -4,17 +4,6 @@
config = {
networking = {
networkmanager.wifi.backend = "iwd";
firewall = {
allowedTCPPorts = [
8384
22000
];
allowedUDPPorts = [
8080
22000
21027
];
};
extraHosts = ''
127.0.0.1 www.youtube.com
127.0.0.1 www.reddit.com

38
modules/firewall.nix Normal file
View file

@ -0,0 +1,38 @@
{ config, lib, pkgs, ... }:
{
config = {
networking = {
firewall = {
enable = true;
allowedTCPPorts = [
# ssh
22
# http, https
80 443
# syncthing web ui
8384
# syncthing
22000
# mumble
64738
];
allowedUDPPorts = [
8080
# other
12333
# syncthing discovery
21027
# mumble
64738
];
};
};
};
}