Randomness plays important role in cryptography. We will show the applications of random values in cryptographic algorithms. In dependency on usage, different requirements are set to random numbers. Therefore also a way of their generation is different. We present most known randomness extraction techniques in digital systems. Implementation of random number generators significantly depends on target platform and since no general standard is approved in this area a testing and certification process is very important. Finally, we talk about statistical test suits and interpretation of their results.