Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot

comment on

( #3333=superdoc: print w/replies, xml ) Need Help??

OpenBSD talks about /dev/srandom, which produces a cryptographically strong source of bits, but it just blocks on my machine. I wonder if I have to fiddle with a kernel setting to make it work.

update: turns out that on OpenBSD, you cannot just open R, '/dev/srandom' and hope that it works. Apparently (and this strikes me as incredibly klugey, but maybe it's more bulletproof), you have to do something like:

dd if=/dev/srandom of=./bits bs=4096 count=1

and after a suitably impressive wait you will have some strong random bits waiting for you in ./bits.

Otherwise an alternative is to grab some bits from a random seed. Maybe for v2.0. I think Linux has /dev/random which blocks if the entropy pool is exhausted, which would be the way to go on that platform. Trouble is that OpenBSD doesn't implement that device, it is RFU.

update: It looks like the lava lamp is dead.

g r i n d e r

In reply to Re:x2 spew - print out random characters by grinder
in thread spew - print out random characters by grinder

Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":

  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.
  • Log In?

    What's my password?
    Create A New User
    and the web crawler heard nothing...

    How do I use this? | Other CB clients
    Other Users?
    Others musing on the Monastery: (4)
    As of 2020-07-10 22:48 GMT
    Find Nodes?
      Voting Booth?

      No recent polls found