nixpkgs/pkgs
Joachim Fasting 75b9a7beac
grsecurity: implement a single NixOS kernel
This patch replaces the old grsecurity kernels with a single NixOS
specific grsecurity kernel.  This kernel is intended as a general
purpose kernel, tuned for casual desktop use.

Providing only a single kernel may seem like a regression compared to
offering a multitude of flavors.  It is impossible, however, to
effectively test and support that many options.  This is amplified by
the reality that very few seem to actually use grsecurity on NixOS,
meaning that bugs go unnoticed for long periods of time, simply because
those code paths end up never being exercised.  More generally, it is
hopeless to anticipate imagined needs.  It is better to start from a
solid foundation and possibly add more flavours on demand.

While the generic kernel is intended to cover a wide range of use cases,
it cannot cover everything.  For some, the configuration will be either
too restrictive or too lenient.  In those cases, the recommended
solution is to build a custom kernel --- this is *strongly* recommended
for security sensitive deployments.

Building a custom grsec kernel should be as simple as
```nix
linux_grsec_nixos.override {
  extraConfig = ''
    GRKERNSEC y
    PAX y
    # and so on ...
  '';
}
```

The generic kernel should be usable both as a KVM guest and host.  When
running as a host, the kernel assumes hardware virtualisation support.
Virtualisation systems other than KVM are *unsupported*: users of
non-KVM systems are better served by compiling a custom kernel.

Unlike previous Grsecurity kernels, this configuration disables `/proc`
restrictions in favor of `security.hideProcessInformation`.

Known incompatibilities:
- ZFS: can't load spl and zfs kernel modules; claims incompatibility
  with KERNEXEC method `or` and RAP; changing to `bts` does not fix the
  problem, which implies we'd have to disable RAP as well for ZFS to
  work
- `kexec()`: likely incompatible with KERNEXEC (unverified)
- Xen: likely incompatible with KERNEXEC and UDEREF (unverified)
- Virtualbox: likely incompatible with UDEREF (unverified)
2016-06-14 00:08:20 +02:00
..
applications Merge pull request #15891 from abbradar/krita 2016-06-09 23:34:07 +04:00
build-support grsecurity: implement a single NixOS kernel 2016-06-14 00:08:20 +02:00
data geolite-legacy: 2016-06-06 -> 2016-06-08 2016-06-08 19:53:48 +02:00
desktops Merge branch 'kde-propagate' 2016-06-09 12:40:04 -05:00
development Merge pull request #16093 from rushmorem/update-go 2016-06-10 00:14:56 +02:00
games Merge pull request #16097 from mimadrid/update/klavaro-3.02 2016-06-10 00:18:39 +02:00
misc Merge pull request #16017 from kamilchm/rework-go 2016-06-09 17:09:13 +02:00
os-specific grsecurity: implement a single NixOS kernel 2016-06-14 00:08:20 +02:00
servers buildGoPackage: use Go 1.6 by default 2016-06-09 13:08:10 +02:00
shells no more goPackages 2016-06-09 13:08:00 +02:00
stdenv stdenv: fix paxmark 2016-05-27 18:57:59 +02:00
test Remove cruft 2016-04-26 17:31:54 +02:00
tools storebrowse: mark broken 2016-06-09 22:09:07 +02:00
top-level grsecurity: implement a single NixOS kernel 2016-06-14 00:08:20 +02:00