On Thu, Dec 24, 2015 at 11:57:27AM +0100, Guillem Jover wrote: > Currently libbsd implements getentropy(2) using only a fallback, which > has the same problems as on old GNU/Linux and other Unix systems. Uses > file descriptors which are susceptible to limits or exhaustion (and > relies on /dev which might not be available on a chroot, but that > might be an unrealistic constraint on the Hurd). > > I guess this could be implemented by using native Hurd interfaces, but > I've not thought if that would suffer from similar problems as the > above, and if we might need another interface implemented from the > Hurd side. > > I'm not sure I'll have time soon to look into this, so if some Hurd > porter could take a stab at this that'd be highly appreciated. This > might also help when and if getentropy(2) gets added to glibc, which > AIUI was talked about some time ago.
The good news is that getentropy() is now part of glibc, and as of 2.31 it's implemented in Hurd as well. The bad news is that from a quick glimpse the glibc implementation looks to be relying on /dev and suspectible to the fd exhaustion mentioned above. In any case, I don't think it's a libbsd bug anymore though. Guillem, not sure what you'd want to do with this bug (mark as done? reassign to glibc?) -- leaving it up to you. HTH! Faidon

