SV-268141r1131085_rule
V-268141
SRG-OS-000142-GPOS-00071
ANIX-00-000980
CAT II
10
Configure the audit service to use IPv4 TCP syncookies.
Add the following Nix code to the NixOS Configuration, usually located in /etc/nixos/configuration.nix or /etc/nixos/flake.nix:
boot.kernel.sysctl = {
"net.ipv4.tcp_syncookies"=1;
};
Rebuild and switch to the new NixOS configuration:
$ sudo nixos-rebuild switch
Verify NixOS is configured to use IPv4 TCP syncookies with the following command:
$ sudo sysctl net.ipv4.tcp_syncookies
net.ipv4.tcp_syncookies = 1
If the network parameter "ipv4.tcp_syncookies" is not equal to "1" or nothing is returned, this is a finding.
V-268141
False
ANIX-00-000980
Verify NixOS is configured to use IPv4 TCP syncookies with the following command:
$ sudo sysctl net.ipv4.tcp_syncookies
net.ipv4.tcp_syncookies = 1
If the network parameter "ipv4.tcp_syncookies" is not equal to "1" or nothing is returned, this is a finding.
M
5658