Go Down

Topic: True Random Number Generator (Read 3649 times) previous topic - next topic

rusew

Hi All,

I built a true random number generator. There's a how-to here:

http://robseward.com/misc/RNG2/

I'd love to know what you think!


Rob

halley

This is very cool-- been wondering if you could make a fully-self-contained RNG without sensors.  Still worried about it though.  I wouldn't depend on it as anything more than an incremental amount of entropy in a larger system.

Quote
So I wrote a program that calibrates itself.  Thus if the signal changes, the micro-controller adapts. It fixed the problem.


Recalibrating in software, without any adjustment to the circuit, may postpone the problem but I don't think it can fix it.  Just my thinking, but if the median 1/0 ratio continues to shift, you're using fewer and fewer of the bits of the ADC, and eventually you'll be left with a very sloppy all-zero (or all-one) signal.

What are the attacks on this RNG?  Obviously we can assume it doesn't work well if it's physically damaged, but what about undetectable temporary stresses like a blast of freon or a hairdryer over the board?

streety

#2
May 05, 2009, 01:03 pm Last Edit: May 05, 2009, 05:23 pm by streety Reason: 1
Very interesting.  I think halley raises a good point though.  The danger with most cryptographic systems is not the underlying idea but the implementation.  Have you run the output through a testing suite?  I'm thinking of the Diehard tests.

How much random data does it throw out?  Implementations like /dev/random tend to not through out all that much data.  Having said that you wouldn't need all that much data for most arduino projects.

rusew

I haven't had a chance to run it through the DieHard tests. I've only looked at some preliminary statistics.  And Streety, the throughput is about 19200bps. With the Von Neumann filtering the it's halved.

As for attacks with Freon, if the input becomes highly regular, i.e. lots of continuous 0s and 1s, the VN filtering will compensate, though output will slow.

I spent a lot of time thinking of a good algorithm to calculate the median with the limited RAM of the Arduino. The granularity of the calibration is limited by the array size possible in Arduino. If you can think of another way I'd love to hear it.

With more computing power the system could do some self diagnostics and warn of non-random behavior. A previous project of mine did essentially that:

http://robseward.com/itp/thesis/

Go Up