True Random Number Generator

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

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.

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?

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.

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/