added stuff
This commit is contained in:
parent
6d31f5b5a1
commit
7d4f626b7d
907 changed files with 70990 additions and 0 deletions
26
nyx/hosts/enyo/kernel/config/security.nix
Normal file
26
nyx/hosts/enyo/kernel/config/security.nix
Normal file
|
@ -0,0 +1,26 @@
|
|||
{lib, ...}: let
|
||||
inherit (lib.kernel) yes;
|
||||
inherit (lib.attrsets) mapAttrs;
|
||||
inherit (lib.modules) mkForce;
|
||||
in {
|
||||
boot.kernelPatches = [
|
||||
{
|
||||
# enable lockdown LSM
|
||||
name = "kernel-lockdown-lsm";
|
||||
patch = null;
|
||||
extraStructuredConfig = mapAttrs (_: mkForce) {
|
||||
SECURITY_LOCKDOWN_LSM = yes;
|
||||
LOCKDOWN_LSM_EARLY = yes;
|
||||
LOCK_DOWN_KERNEL_FORCE_CONFIDENTIALITY = yes;
|
||||
|
||||
MODULE_SIG = yes;
|
||||
MODULE_SIG_SHA512 = yes;
|
||||
MODULE_SIG_FORCE = yes;
|
||||
|
||||
# used to avoid a systemd error:
|
||||
# systemd[1]: bpf-lsm: Failed to load BPF object: Invalid argument
|
||||
BPF_LSM = yes;
|
||||
};
|
||||
}
|
||||
];
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue