Noname manuscript No. (will be inserted by the editor) Generating true random numbers based on multicore CPU using race conditions and chaotic maps Je Sen Teh [0000000155714148] · Moatsum Alawida [0000000181465843] · Azman Samsudin Received: date / Accepted: date Abstract A true random number generator (TRNG) is proposed, harvesting entropy from multicore CPUs to generate non-deterministic outputs. The entropy source is the unpredictable sequence of thread access when parallel threads attempt to access the same memory location, known as race condition or data races. Al- though prior work using the same entropy source ex- ists, they either have low efficiency or insufficient se- curity analysis. The novelty of this work lies in its use of chaotic networks capable of extracting entropy while post-processing outputs simultaneously. These networks are formulated by coupling chaotic maps in the form of chaotic coupled map lattices which have the capability to amplify minor uncertainties, leading to better perfor- mance as compared to other CPU-based TRNGs. We first perform experiments to depict the unpredictable nature of thread access due to race conditions through entropy and scale index analysis. Next, the proposed generator is scrutinized based on a standardized set of evaluation criteria which includes the use of multiple statistical test suites followed by an analysis of its non- deterministic property. We also perform an in-depth en- tropy analysis of the generator’s outputs and measure its degree of non-periodicity. Results indicate that the proposed chaos-based TRNG is fast, evenly distributed, and is secure enough for applications that have high se- curity requirements. Keywords Chaotic map · cryptography · entropy · multicore CPU · parallel processing · random number Je Sen Teh( ) · Moatsum Alawida · Azman Samsudin School of Computer Sciences, Universiti Sains Malaysia Tel.: +6046534046 E-mail: jesen teh@usm.my 1 Introduction Random numbers are utilized in various fields such as cryptography, random sampling, and Monte Carlo sim- ulations. There are two categories of random number generators: a pseudorandom number generator (PRNG) produces the same set of random numbers for a given input seed, whereas a true random number generator (TRNG) produces unpredictable random number se- quences that never repeat. Most TRNGs rely on ran- domness from physical sources such as electronic noise [1], radioactive decay [2] and lasers [3,4], but there are also algorithms that harvest entropy from computer hardware such as DRAM [5], processor schedulers [6], graphic processing units (GPU) [7, 8], microphones [9] and also mobile phone cameras [10]. Another proposed TRNG took advantage of ‘social noise’, generating ran- dom numbers based on messages from Twitter [11]. The entropy of these sources are quantified and a post- processing algorithm is usually applied to eliminate bias. TRNGs are important for applications that require high security because their number sequences cannot be re- produced. Most of these highly sensitive applications are related to cryptography, specifically to generate nonces, one-time pads, initialization vectors, generating session keys, signature key pairs or signature parameters [12]. However, they are generally slower than their PRNG counterparts. Multicore CPUs are widely available in modern com- puters and mobile devices, making them an easily ac- cessible entropy source. Some CPU statistics such as the number of CPU cycles have been used as a seed for PRNGs to produce unpredictable outputs [13]. Al- though the seed itself may be non-deterministic, the underlying generator is still not considered a TRNG because the resulting sequence will always be the same