On Sat, 30 Jul 2016 18:09:22 -0400
Theodore Ts'o wrote as excerpted:
> On Fri, Jul 29, 2016 at 01:31:14PM -0400, Alex Xu wrote:
> > When qemu is started with -object rng-random,filename=/dev/urandom,
> > and immediately (i.e. with no initrd and as the first thing in
> > init):
> >
> > 1. the gues
On Fri, Jul 29, 2016 at 01:31:14PM -0400, Alex Xu wrote:
>
> My understanding was that all three methods of obtaining entropy from
> userspace all receive data from the CSPRNG in the kernel, and that the
> only difference is that /dev/random and getrandom may block depending
> on the kernel's esti
On Fri, 29 Jul 2016 19:03:51 +0200
Stephan Mueller wrote as excerpted:
> Am Freitag, 29. Juli 2016, 10:14:07 CEST schrieb Alex Xu:
> > I don't follow. Assuming you are correct and this is the issue, then
> > reading 128 bits (16 bytes) from /dev/random should "exhaust the
> > supply" and then both
Am Freitag, 29. Juli 2016, 10:14:07 CEST schrieb Alex Xu:
Hi Alex,
> On Fri, 29 Jul 2016 15:12:30 +0200
>
> Stephan Mueller wrote as excerpted:
> > Am Freitag, 29. Juli 2016, 09:03:45 CEST schrieb Alex Xu:
> > > In my opinion, assuming I am not doing something terribly wrong,
> > > this constit
On Fri, 29 Jul 2016 15:12:30 +0200
Stephan Mueller wrote as excerpted:
> Am Freitag, 29. Juli 2016, 09:03:45 CEST schrieb Alex Xu:
> > In my opinion, assuming I am not doing something terribly wrong,
> > this constitutes a bug in the kernel's handling of getrandom calls
> > at boot, possibly only
Am Freitag, 29. Juli 2016, 09:03:45 CEST schrieb Alex Xu:
Hi Alex,
> On Fri, 29 Jul 2016 12:24:27 +0200
>
> Nikos Mavrogiannopoulos wrote:
> > On Fri, Jul 29, 2016 at 7:40 AM, Stephan Mueller
> >
> > wrote:
> > > And finally, you have a coding error that is very very common but
> > > fatal wh
On Fri, 29 Jul 2016 12:24:27 +0200
Nikos Mavrogiannopoulos wrote:
> On Fri, Jul 29, 2016 at 7:40 AM, Stephan Mueller
> wrote:
> > And finally, you have a coding error that is very very common but
> > fatal when reading from /dev/random: you do not account for short
> > reads which implies that y
On Fri, Jul 29, 2016 at 7:40 AM, Stephan Mueller wrote:
> And finally, you have a coding error that is very very common but fatal when
> reading from /dev/random: you do not account for short reads which implies
> that your loop continues even in the case of short reads.
>
> Fix your code with som
Am Donnerstag, 28. Juli 2016, 18:07:32 CEST schrieb Alex Xu:
Hi Alex,
> Linux 4.6, also tried 4.7, qemu 2.6, using this C program:
I am not sure what problem you are referring to, but that is an expected
behavior.
You get partial reads when reading from /dev/random with a minimum of 64
bits.
Linux 4.6, also tried 4.7, qemu 2.6, using this C program:
#include
#include
#include
#include
int main(int argc, char *argv[]) {
char buf[16];
int fd;
if (argc != 2)
return 1;
for (int i = 0; i < atoi(argv[1]); i++) {
sleep(1);
if ((fd = open("/dev/
10 matches
Mail list logo