[clug] command to reverse 'xxd -b'??

steve jenkin sjenkin at canb.auug.org.au
Tue Nov 5 22:38:16 MST 2013


John Mills wrote on 6/11/13 6:18 AM:

> Hello all
> I have been lurking and learning from this list. Thank you.
> 
> I wanted to do the von Neumann whole extraction in Perl, since I am 
> (always) learning Perl.
> 
> I hacked up a solution but I'm wondering how to test it.
> 
> Are there any sets of plain and von Neumann-extracted versions of the same 
> file which could be used for testing? I couldn't find any.
> 
> I put some simple one/zero counters into the code and I'm seeing a 
> _decrease_ in neutrality but I'm not sure that's the right measure, as it 
> doesn't deal with locality etc
> 
> Thanks
> John Mills
> 
> ------------------------------------------------------------

John,

Someone wrote me reminding that Paul Wayper did a CLUG talk on Crypto or
RNG's or something related not that long ago... Link & comments anyone?
Don't want to reinvent the wheel :(

There's 'random.org' & CPAN module:
<http://search.cpan.org/~gwilliams/Math-RandomOrg-0.04/lib/Math/RandomOrg.pm>

And another Quantum source: http://random.irb.hr
<http://search.cpan.org/~egor/Random-Quantum-0.04/lib/Random/Quantum.pm>

And what looks nice, with 3 sources to choose from, including
"qrng.anu.edu.au"
<http://search.cpan.org/~dcantrell/Net-Random-2.3/lib/Net/Random.pm>

Caveat: I haven't used any of those PERL modules.

For my testing, I just pulled a few kB from random.org [you get a free
1Mbit allowance based on IP Nr, IIRC and a daily 'top up'...]

Cool thing to look at:
<http://www.nist.gov/itl/csd/ct/nist_beacon.cfm>
<https://beacon.nist.gov/home>

and a nice intro, if you haven't already read it.
<http://www.random.org/randomness/>

There's a shell script he points to that uses 'curl' to grab random
number blocks.
<https://raw.github.com/d4rkcat/randomorg/master/randomorg.sh>

HTH
steve

PS:
It's a really simple HTTP API for random.org, but you might have to retry:

# Fetch 1kB
wget 'http://www.random.org/cgi-bin/randbyte?nbytes=1024&format=h'
 # 1024 bytes in Hexadecimal

[I just got a '503' "Error: Server too busy right now, please back off"]

# Display Quota
wget -q -O - 'http://www.random.org/quota/?format=plain

-- 
Steve Jenkin, Info Tech, Systems and Design Specialist.
0412 786 915 (+61 412 786 915)
PO Box 48, Kippax ACT 2615, AUSTRALIA

sjenkin at canb.auug.org.au http://members.tip.net.au/~sjenkin


More information about the linux mailing list