summary refs log tree commit diff
path: root/pkgs/os-specific/linux/hostapd
diff options
context:
space:
mode:
authorTom Fitzhenry <tom@tom-fitzhenry.me.uk>2019-12-07 19:10:40 +1100
committerTom Fitzhenry <tom@tom-fitzhenry.me.uk>2019-12-07 19:31:35 +1100
commitfd1c0db18ca5e7803131aa5086b92801db4f336a (patch)
tree46054e209ddb07cae7f00ad6bafb7cf8e5aeabfa /pkgs/os-specific/linux/hostapd
parente22daade26149c756d6a561409b7d6d8d35479a4 (diff)
downloadnixpkgs-fd1c0db18ca5e7803131aa5086b92801db4f336a.tar
nixpkgs-fd1c0db18ca5e7803131aa5086b92801db4f336a.tar.gz
nixpkgs-fd1c0db18ca5e7803131aa5086b92801db4f336a.tar.bz2
nixpkgs-fd1c0db18ca5e7803131aa5086b92801db4f336a.tar.lz
nixpkgs-fd1c0db18ca5e7803131aa5086b92801db4f336a.tar.xz
nixpkgs-fd1c0db18ca5e7803131aa5086b92801db4f336a.tar.zst
nixpkgs-fd1c0db18ca5e7803131aa5086b92801db4f336a.zip
hostapd: use getrandom(2)
Motivation: Devices with few entropy sources on boot hang/block if many services try to
read from /dev/random.

https://w1.fi/cgit/hostap/commit/?id=89a7cdd690b48a0c56380cf4609442ed13527f44
states getrandom() is recommended, but not enabled by default since it
relies on:

* Linux kernel 3.17 (NixOS 19.09 has 4.19; master presumably later)
* glibc 2.25 (NixOS master has 2.27
  https://github.com/NixOS/nixpkgs/blob/master/pkgs/development/libraries/glibc/common.nix#L37 )
Diffstat (limited to 'pkgs/os-specific/linux/hostapd')
-rw-r--r--pkgs/os-specific/linux/hostapd/default.nix1
1 files changed, 1 insertions, 0 deletions
diff --git a/pkgs/os-specific/linux/hostapd/default.nix b/pkgs/os-specific/linux/hostapd/default.nix
index 41d7f236682..5689cc1713f 100644
--- a/pkgs/os-specific/linux/hostapd/default.nix
+++ b/pkgs/os-specific/linux/hostapd/default.nix
@@ -49,6 +49,7 @@ stdenv.mkDerivation rec {
     CONFIG_INTERNETWORKING=y
     CONFIG_HS20=y
     CONFIG_ACS=y
+    CONFIG_GETRANDOM=y
   '' + stdenv.lib.optionalString (sqlite != null) ''
     CONFIG_SQLITE=y
   '';