lkml.org 
[lkml]   [2007]   [Jun]   [26]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    From
    SubjectRe: [PATCH] hw_random: add quality categories
    Date
    On Tuesday 26 June 2007 16:32:37 Matt Mackall wrote:
    > > No wait. You are missing the whole point of this
    > > quality category.
    > > The whole point of it is to prevent defaulting to a bad RNG, if
    > > there's a bad and a good one in a machine.
    > > Well, what's bad.
    > > It's easy. HWRNGs like the one in bcm43xx are bad.
    > > It's proprietary and nobody knows what it does (I guess
    > > it gathers the entropy from the network or something
    > > and hashes that in hardware).
    > > So such a device would be QUAL_LOW.
    >
    > If it's gathering its entropy from the network, it is not a QUAL_LOW
    > RNG because it is not a hardware random number generator at all!
    >
    > Such a device is QUAL_PSEUDO or QUAL_UNKNOWN. If it's known or
    > suspected to be bogus, it should be so marked.

    No, it should not be marked pseudo. It _is_ a RNG in hardware.
    Where it gets its entropy from is unknown. (I'm just guessing
    around).
    PSEUDO is for example for entropy gathered from hardware sensors.
    That's not a RNG (so pseudo) and it's even worse than the proprietary
    bcm43xx thing. So bcm43xx(LOW) would win the default over the sensor.
    But if there's a RNG in the CPU, it would win over bcm43xx.
    And an extension board would win over the CPU.
    Yeah, the extension board could in fact produce worse entropy than
    the in-CPU thing. If that's the case, remove it from the machine
    (or disable it in the sysfs interface).

    > Once you've merged your LOW class with PSEUDO, you're left with a
    > meaningless, unquantifiable distinction between NORMAL and HIGH.

    No, that's not true. I explained the difference to you and it's even
    explained in the kdoc help text. Re-read it, please.
    HIGH is for seperate dedicated extension devices that you buy and
    stick into your machine. So it would default to that, as you want
    to use that by default (why would you otherwise stick it in).

    To say it again: It all is _just_ for defining a sane _default_
    policy. That's all.
    Currently the policy is: "Select whatever comes first", which is
    random. So it could select crap (bcm43xx) over not-so-crap (in-CPU-RNG).

    --
    Greetings Michael.
    -
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    More majordomo info at http://vger.kernel.org/majordomo-info.html
    Please read the FAQ at http://www.tux.org/lkml/

    \
     
     \ /
      Last update: 2007-06-26 16:49    [W:2.673 / U:0.948 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site