[Verse-dev] Random number generation

Emil Brink emil at obsession.se
Tue Jun 7 18:20:41 CEST 2005


Hey.

Last Friday, Eskil and I talked a little to a guy from the Theory Group
at NADA (parent institution of where we work, at least until the recent
renaming) about the Verse crypto layer.

Anyway, we got a lot of tips about areas that need improvement, some of
which we already knew about.

One such are is the random number generation, which has always been
unsuitable for cryptography, since it was based on the rand() standard
C function.

In order to start fixing this, I today wrote and committed a new module,
called "v_randgen.c". This module has a simple (three functions so far)
API to generate random numbers, and is used by the prime-searching code.

On Linux and Mac OS X systems, this API simply reads /dev/urandom for
random bits.

It is currently lacking serious code for Win32, where it still uses the
rand() call. I will fix that as soon as I'm back in the office (I've
been feeling a bit sick today, so stayed at home). Shouldn't be too
hard, I surfed a bit and think I know some Win32 functions to use.

Regards,

/Emil


More information about the Verse-dev mailing list