Page MenuHomeFreeBSD

stop looping if it fails, we'll try again in 100ms..
Needs ReviewPublic

Authored by jmg on Mar 3 2023, 6:44 PM.
Tags
None
Referenced Files
F132940067: D38897.diff
Tue, Oct 21, 8:36 AM
Unknown Object (File)
Fri, Oct 10, 2:49 AM
Unknown Object (File)
Wed, Oct 8, 6:10 PM
Unknown Object (File)
Wed, Oct 1, 10:29 AM
Unknown Object (File)
Wed, Oct 1, 12:23 AM
Unknown Object (File)
Sun, Sep 28, 1:07 AM
Unknown Object (File)
Tue, Sep 23, 5:01 PM
Unknown Object (File)
Sep 16 2025, 1:16 AM

Details

Reviewers
None
Group Reviewers
csprng

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Skipped
Unit
Tests Skipped
Build Status
Buildable 50134
Build 47026: arc lint + arc unit

Event Timeline

jmg requested review of this revision.Mar 3 2023, 6:44 PM

No objection. I'll let someone else stamp it.

I don't have a major objection to this, but I'm nervous of the lower-numbered pools being favoured. I'm not formally requesting changes yet, as I could be persuaded that I'm wrong.

sys/dev/random/random_harvestq.c
303

This may result in the lower-numbered pools being favoured, which is undesirable. All pools need an equal chance at this entropy. A fix may be to make i static, and simply increment it mod(npools), with the loop terminating at the point where it wraps.

the comment says

We don't perform any other verification of an entropy source (i.e., length is allowed to be anywhere from 1 to sizeof(entropy), quality is unchecked, etc)

is there a way we could do that?

not in a live / production system, unless it's via dtrace