Source-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

CVS commit: src



Module Name:    src
Committed By:   tls
Date:           Tue Apr 17 02:50:39 UTC 2012

Modified Files:
        src/share/man/man4: rnd.4
        src/sys/dev: rndpseudo.c
        src/sys/kern: kern_rndpool.c kern_rndq.c subr_cprng.c
        src/sys/sys: cprng.h rnd.h

Log Message:
Address multiple problems with rnd(4)/cprng(9):

1) Add a per-cpu CPRNG to handle short reads from /dev/urandom so that
   programs like perl don't drain the entropy pool dry by repeatedly
   opening, reading 4 bytes, closing.

2) Really fix the locking around reseeds and destroys.

3) Fix the opportunistic-reseed strategy so it actually works, reseeding
   existing RNGs once each (as they are used, so idle RNGs don't get
   reseeded) until the pool is half empty or newly full again.


To generate a diff of this commit:
cvs rdiff -u -r1.18 -r1.19 src/share/man/man4/rnd.4
cvs rdiff -u -r1.7 -r1.8 src/sys/dev/rndpseudo.c
cvs rdiff -u -r1.1 -r1.2 src/sys/kern/kern_rndpool.c
cvs rdiff -u -r1.2 -r1.3 src/sys/kern/kern_rndq.c
cvs rdiff -u -r1.7 -r1.8 src/sys/kern/subr_cprng.c
cvs rdiff -u -r1.4 -r1.5 src/sys/sys/cprng.h
cvs rdiff -u -r1.30 -r1.31 src/sys/sys/rnd.h

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.




Home | Main Index | Thread Index | Old Index