[WireGuard] [PATCH] use runtime check for getrandom syscall
Daniel Kahn Gillmor
dkg at fifthhorseman.net
Sat Jul 2 23:39:41 CEST 2016
On Sat 2016-07-02 16:10:42 -0400, Jason A. Donenfeld wrote:
> WireGuard supports kernels ≥4.1. getrandom was added in 3.17. So, all
> kernels on which wg is useful support getrandom.
Sure, but in that case why bother with the compile-time check at all,
and why not just use getrandom(2) directly instead of syscall(2)?
It's also possible to generate machine configs (with wg) on a machine
that doesn't plan to run it (e.g., if you're deploying psk's through a
configuration-management system).
With the patch, wg should just work on any of these systems.
--dkg
More information about the WireGuard
mailing list