Crypt Gen Random - Method of Operation

Method of Operation

Microsoft-provided cryptography providers share the same implementation of CryptGenRandom, currently based on an internal function called RtlGenRandom. Only a general outline of the algorithm had been published as of 2007:

generates as specified in FIPS 186-2 appendix 3.1 with SHA-1 as the G function. And with entropy from:

  • The current process ID (GetCurrentProcessID).
  • The current thread ID (GetCurrentThreadID).
  • The tick count since boot time (GetTickCount).
  • The current time (GetLocalTime).
  • Various high-precision performance counters (QueryPerformanceCounter).
  • An MD4 hash of the user's environment block, which includes username, computer name, and search path.
  • High-precision internal CPU counters, such as RDTSC, RDMSR, RDPMC
Source: Writing Secure Code, Second Edition. ISBN 0-7356-1722-8.

Read more about this topic:  Crypt Gen Random

Famous quotes containing the words method of, method and/or operation:

    Government by average opinion is merely a circuitous method of going to the devil; those who profess to lead but in fact slavishly follow this average opinion are simply the fastest runners and the loudest squeakers of the herd which is rushing blindly down to its destruction.
    Thomas Henry Huxley (1825–95)

    Protestantism has the method of Jesus with His secret too much left out of mind; Catholicism has His secret with His method too much left out of mind; neither has His unerring balance, His intuition, His sweet reasonableness. But both have hold of a great truth, and get from it a great power.
    Matthew Arnold (1822–1888)

    It is critical vision alone which can mitigate the unimpeded operation of the automatic.
    Marshall McLuhan (1911–1980)