Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
tuedel
nixos-deployment
Commits
5a39c87d
Commit
5a39c87d
authored
Apr 01, 2022
by
fpletz
🚧
Browse files
luftschleuse: custom ssh moduli, tighten firewall
parent
1fe94f73
Changes
3
Expand all
Hide whitespace changes
Inline
Side-by-side
luftschleuse.nix
View file @
5a39c87d
...
...
@@ -11,7 +11,7 @@ let
cmd
=
"unlockfront"
;
}
{
user
=
"close"
;
msg
=
"
Unl
ocking back door"
;
msg
=
"
L
ocking back door"
;
cmd
=
"lock"
;
}
];
...
...
@@ -50,7 +50,10 @@ in
interfaces
.
wlan0
=
{
ipv4
.
addresses
=
[
{
address
=
"192.168.2.2"
;
prefixLength
=
24
;
}
];
};
firewall
.
trustedInterfaces
=
[
"wlan0"
"eth0"
];
firewall
=
{
allowedUDPPorts
=
[
53
67
];
allowedTCPPorts
=
[
22
80
];
};
};
systemd
.
network
.
links
.
"30-eth0"
=
{
...
...
@@ -68,7 +71,7 @@ in
dhcpV4Config
.
ClientIdentifier
=
"mac"
;
};
environment
.
systemPackages
=
with
pkgs
;
[
colmena
lm_sensors
];
environment
.
systemPackages
=
with
pkgs
;
[
lm_sensors
];
services
.
fail2ban
.
enable
=
false
;
...
...
@@ -150,7 +153,8 @@ in
};
services
.
nginx
=
{
enable
=
true
;
# FIXME: make android believe there is internetz
enable
=
false
;
virtualHosts
.
"_"
=
{
root
=
"/nonexisting"
;
locations
.
"/generate_204"
.
extraConfig
=
"return 204;"
;
...
...
modules/default.nix
View file @
5a39c87d
...
...
@@ -33,6 +33,7 @@
services
.
openssh
=
{
enable
=
true
;
passwordAuthentication
=
lib
.
mkDefault
false
;
moduliFile
=
../static/ssh-moduli
;
};
services
.
fail2ban
.
enable
=
lib
.
mkDefault
true
;
...
...
static/ssh-moduli
0 → 100644
View file @
5a39c87d
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment