# TRNGs from Pre-Formed ReRAM Arrays

^{1}

^{2}

^{*}

## Abstract

**:**

## 1. Introduction

- -
- private keys for digital signature algorithms;
- -
- values to be used in entity authentication mechanisms;
- -
- values to be used in key establishment protocols;
- -
- chip manufacturing (seeding device unique and platform keys);
- -
- initial values (for encryption and MAC algorithms, TCP packet values, etc.);
- -
- PIN and password generation;
- -
- nonce generation and initial counter values for various cryptographic functions;
- -
- and challenges used for protocol authentication exchanges.

## 2. Background Information on PRNGs and TRNGs

#### 2.1. PRNGs versus TRNGs

#### 2.2. Memory-Based TRNGs

#### 2.3. PUFs for the Design of TRNGs

## 3. Randomness of Pre-Formed ReRAMs

#### 3.1. Variations in Resistance Value Due to the Injection Small Electric Currents

#### 3.2. Effect of the Size of the Active Areas on the Levels of Randomness

- when the active area has no defect, the resistance value should be relatively high;
- when one defect is located in the active area, the resistance value should be lower. The resistance reduction could be due to the conductive nature of certain defects;
- when a large number of defects are located in the active area of a particular cell, the addition or subtraction of a few defects does not impact the resistance value anymore.

_{1}, d

_{2}, and d

_{3}with defect densities D

_{1}, D

_{2}, and D

_{3}, are affecting the cells having active areas A

_{c}based on the factors λ

_{1}= A

_{c}D

_{1}, λ

_{2}= A

_{c}D

_{2}, and λ

_{3}= A

_{c}D

_{3}. Available statistical models include Poisson, defect cluster, Murphy, Moore, Price, and many others [46,47,48]. The impact of each type of defect on randomness is low when λ

_{i}<< 1 or λ

_{i}>> 1. Therefore, it is expected that cells with very small active areas, and cells with very large active areas should exhibit a lower randomness. We anticipate that the manufacturing of very small cells could generate additional defects that can impact randomness. The analytical analysis needed to accurately describe these models is not part of the scope of this study, but will be a part of future work.

## 4. Design of TRNGs with Pre-Formed ReRAM Arrays

#### 4.1. Overview of the Architecture of Various TRNG Designs

- The relative cell-to-cell random variations in resistance values are large, typically in the 50% range, providing high inter-PUF entropy, and unicity;
- The variation in resistance values of each cell is small, the intra-PUF variations are low: The relative standard variations of the intra-cell measurements are in the 2% range.

- (a)
- Input stage: To request the generation of a new stream of N random bits, for example N = 1000. The only information requested at this step is the length of the stream.
- (b)
- Initial step: To select a stream of at least N addresses in the ReRAM array. For example, if the array has 1 million cells, 20 bits are needed to find the address of one cell in the array. If N = 1000, at least 20 Kbits are needed to find 1000 addresses. This selection can be done for example, by generating a stream of random numbers from a PRNG or a hash function with extended output function (XOF).
- (c)
- Output: To generate N random bits from the N cells selected in the ReRAM arrays with one of the two following methods:
- Version 1: The median scheme as described in detail in Section 4.2. The stream of N random numbers is generated from the N ReRAM cells selected by the protocol by comparing the resistance values of each cell to a value close to the median. A “0” state is generated if the values are significantly lower than the median value; a “1” state if the values are significantly higher. Most cells of the array are usable for this protocol, with the exception of the cells that are defective, and the ones with values that have resistance values precisely at the median value. These can be excluded from the TRNG.
- Version 2: The pairing scheme as described in detail in Section 4.3. The stream of N random numbers is generated from the N ReRAM pairs of cells selected by the protocol by comparing the resistance value of pairs of cells. A “0” state is generated if the value of the first cell of each pair is significantly lower than the value of the second cell of the same pair; a “1” state if the value of the first cell is significantly higher. Most pairs of the ReRAM array are usable for this protocol with the exception of the pairs that are defective, and the ones with values that have the two cells with exactly the same resistance value. These can also be excluded from the TRNG.

#### 4.2. Version 1: Design of TRNGs with the Median Scheme

**f**bits are needed for each address, a stream of

**f**× l bits is needed for the median scheme. For example, if the size of the array is 1,048,576 = 2

^{20}, then

**f**= 20. A stream longer than N is needed for the protocol to handle the defective cells. The median value M of the resistance values of the entire cell population is also known, as well as some addresses in one array that have values close to the median. The example of Figure 4 shows the implementation with two separate ReRAM arrays, one to find each cell, a second one to find a cell with median value, and an analog circuit comparing the resistance value of the two cells at a given current.

- (a)
- Input stage: Request N random numbers
- (b)
- Initial step:PRNG ⟶ XOF ⟶ random number l × f ⟻For l addresses of cells, each of them f-bit long, with l > N:b
_{11}…b_{1j}…b_{1f}| …. |b_{i1}…b_{ij}…b_{if}| …. |b_{l1}…b_{lj}…b_{lf}Address 1 Address i Address l - (c)
- Output: Compare the resistance value of each cell to the median value M of the distribution:
- a.
- Eliminate the cells that are known to be defective.
- b.
- If a cell has a resistance value higher than M ⟶ generate a “1”.
- c.
- If a cell has a resistance value lower than M ⟶ generate a “0”.
- d.
- If a cell has a resistance value precisely at M ⟶ ignore.
- e.
- If less than N addresses are left ⟶ increase the natural number
**l**and iterate⤴ - f.
- If more than N addresses are left ⟶ keep the first N addresses of the stream.
- g.
- Transfer the final data stream of N random number:${c}_{1}$l ….l${c}_{i}$l….l${c}_{N}$

Algorithm 1: Generate random number from the Fuzzy area close to median in PUF |

1: Procedure: initialize TRNG_SIZE |

2: Call PRNG |

3: Arr [] a ← PRNG |

4: FOR every 3byte in a [] |

5: convert 3byte to one integer number |

6: ENDFOR |

7: PUF←READ ReRAM PUF |

8: while counter is less than size of TRNG_SIZE |

9: Arr [] RESISTANCE ← GET value from PUF [integer number] |

10: ENDLOOP |

11: From all RESISTANCE Compute Median |

12: Arr [] binary |

13: Loop I = 0 to TRNG_SIZE |

14: IF (Median > RESISTANCE [i]) && (RESISTANCE [i] in Fuzzy area) THEN |

15: binary[i] ← append (0) |

16: ELSE IF (Median < RESISTANCE [i]) && (RESISTANCE [i] in Fuzzy area) THEN |

17: binary[i] ← append (1) |

18: ELSE |

19: continuo |

20: ENDIF |

21: ENDLOOP |

22: Convert binary to hexadecimal |

23: Display TRNG |

#### 4.3. Version 2: Design of TRNGs with the Pairing Scheme

**,**

^{f}**f**bits are needed per address, and streams of 2 ×

**f**× l bits are needed for the scheme. The diagram of Figure 5 shows an implementation with two separate ReRAM arrays. The first set of addresses (the

**b**) is pointing at a first array located on the left side of Figure 5; the second set of addresses (the

_{i}**β**) is pointing at the second array located on the right side.

_{i}- (a)
- Input stage: Request N random numbers
- (b)
- Initial step:PRNG ⟶ XOF ⟶ random number 2 × l × f ⟻For 2× l addresses of cells, each of them f-bit long, with l > N:First cell: b
_{11}…b_{1j}…b_{1f}| …. |b_{i1}…b_{ij}…b_{if}| …. |b_{l1}…b_{lj}…b_{lf}Address 1 Address i Address lSecond cell: β_{11}…β_{1j}…β_{1f}| …. |β_{i1}…β_{ij}…β_{if}| …. |β_{l1}…β_{lj}…β_{lf}Address 1′ Address i’ Address l’ - (c)
- Output: Compare the resistance value of each the first cells b
_{i}at address i with their respective matching cells β_{i}: at address i’:- a.
- Eliminate the cells that are known to be defective.
- b.
- If a cell has a resistance value higher than the matching cell ⟶ generate a “1”.
- c.
- If a cell has a resistance value lower than the matching cell ⟶ generate a “0”.
- d.
- If the two cells of a pair have precisely the same resistance value ⟶ ignore.
- e.
- If less than N random bits are left ⟶ increase the natural number l and iterate ⤴
- f.
- If more than N random numbers are generated ⟶ keep only the N random numbers.
- g.
- Transfer the final data stream of N random number:${c}_{1}$l ….l${c}_{i}$l….l${c}_{N}$

- Initial step The PRNG to generate a stream twice as long
- Output steps are replaced by the method to compare the pairs of values

#### 4.4. Experimental Quantification of the Levels of Randomness

- i.
- We are using PUFs as a source of noise; however, the PUFs need to generate the same response at each address most of the time. This property is mandatory for the design of reliable PUFs with low error rates. For each cell, after k-long sequences, the bias toward zeros or ones should be high, in spite of drifts due to environmental effects and aging.
- ii.
- However, a very large, and random, cell-to-cell variation is required to design TRNGs. This is the case in ReRAMs operating in the pre-forming range. The cells located at the edge of the arrays could be different to the one located in the center. In order to minimize this effect, we blanked eight rows on each side of the array. The sequences of n-bit considered for this experimental section only used the cells far away from the edge of the arrays.

**Median scheme:**Shown in Figure 6 is the summary of the 12 tests performed with the suite of NIST tests on the random numbers generated by the median scheme. Six out of twelve tests are passing with scores higher than 96%; however, six tests are failing. The main reason for such lack of randomness is the unbalance between “0”s and “1”s; we observed 2% more “0”s than “1”s, which is not acceptable. The cell population kept for the TRNG is slightly different to the one used to compute the median value. One way to correct the imbalance is to correct the computation of the median, or to add operations post random number generation from the ReRAM array, as presented in Section 5. The simple XORing of blocks of bits is enough to easily pass the NIST suite of test.

**Pairing scheme:**The PRNGs are used to generate pairs of addresses for the pairing scheme, without excluding the pairs with identical resistance values. Shown in Figure 7 is the summary of the suite of NIST tests. Nine out of twelve tests are passing with scores higher than 96%; however, three tests are still failing with scores respectively at 74%, 76/%, and 80%. Such initial levels of randomness of the streams directly originating from the physical elements are encouraging, and more balanced than the streams generated from the median scheme. Here, we do not have to deal with the problem of centering the median value as statistically 50% of the pairs are either “0”s or “1”s. The post processing presented in Section 5 can enhance randomness to easily pass a subset of 12 NIST tests.

## 5. Combining TRNGs with Additional Schemes to Enhance Randomness

#### 5.1. Description of the Protocols Providing Additional Randomness

- (1)
- Step 1: To generate streams of random numbers from the combination of PRNGs, hash functions such as SHA-512, and extended output functions such as shake to select the
**l**addresses needed for the TRNG:b_{11}…b_{1j}…b_{1f}| …. |b_{i1}…b_{ij}…b_{if}| …. |b_{l1}…b_{lj}…b_{lf}Address 1 Address I Address l - (2)
- Step 2: To select only the set of addresses in the ReRAM arrays that have the potential to enhance randomness of the TRNG. Example of addresses that are excluded are:
- a.
- Defective cells due to catastrophic defects during fabrication.
- b.
- Cells with resistance values too far from the median value, see Figure 10. This method excludes the cells that have physical characteristics significantly different from the bulk of the distribution, which could be recognized by the opponents.
- c.
- In the case of the median scheme, elimination of the cells that have a resistance value precisely equal to the median value.
- d.
- In the case of the pairing scheme, elimination of the pairs with two cells that have the same exact resistance value.

- (3)
- Step 3: Generate N random bits by generating random bits from the ReRAM arrays with one of the methods such as the median scheme, or the pairing scheme as described above in Section 5.
- (4)
- Step 4: Enhance randomness by using additional schemes (see Figure 11), such as various methods used to design PRNGs such as congruent operations in such a way that the flip of only a few bits of the incoming data stream can result in different streams of random numbers.

- 1.
- XORing of the data stream by blocks of bits.
- 2.
- Additional hashing and XOF.
- 3.
- Additional encryption schemes using the data stream generated from the arrays as both cryptographic keys, and text to encrypt.

#### 5.2. Experimental Analysis

- (1)
- Step 1: To group the streams of random bits by chunks of 7 bits;
- (2)
- Step 2: Add the 7 bits of each chunk modulo 2 to get a zero or a one. This operation is the logical XOR of 7 consecutive bits: if the number of “1”s is odd, the XORing is a “1”; if the number of “1”s is even, the result is a “0”. Such an operation enhances randomness [41].

- (1)
- Step 1: To group the streams of random bits by chunks of 11 bits;
- (2)
- Step 2: Add each chunk modulo 2 to get one resulting bit, a zero or a one. This operation is equivalent to XORing 11 bits, if the numbers of “1”s is odd, the resulting bit is a “1”, if even the resulting bit is a “0”. The levels of randomness increase with the length of the chunks.

## 6. Conclusions and Future Work

`o`PRNGs, hashing functions, and XOFs to randomly select the group of cells within the ReRAM arrays generating the random numbers.`o`Eliminating certain cells that can reduce randomness and protect the arrays.`o`Post-processing operations: additional hashing, XORing, and encryption.

## Author Contributions

## Funding

## Data Availability Statement

## Acknowledgments

## Conflicts of Interest

## References

- Krietzmann, P.; Schmidt, T.; Wahlish, M. A guideline on Pseudorandom Number Generation (PRNG). arXiv
**2007**, arXiv:11839v2. [Google Scholar] - Maheswari, K.M.; Rajdeep Kundu, R.; Saxena, H. PRNGs: Algorithms and Applications. Int. J. Pure Appl. Math.
**2018**, 118, 331–336. [Google Scholar] - Katzgraber, H. Random Numbers in scientific computing: An introduction. Int. Sch. Comput. Sci.
**2010**, arXiv:1005.4117. [Google Scholar] - Shang, Y.; Bouffanais, R. Influence of the number of topologically interacting neighbors on swarm dynamics. Sci. Rep.
**2015**. [Google Scholar] [CrossRef] [PubMed] - Datcu, O.; Macovei, C.; Hobincu, R. Chaos Based Cryptographic Pseudo-Random Number Generator Template with Dynamic State Change. Appl. Sci.
**2020**, 10, 451. [Google Scholar] [CrossRef] [Green Version] - Stipevic, M.; Koc, C.K. True Random Number Generators. In Open Problems in Mathematics and Computational Science; Springer: Berlin/Heidelberg, Germany, 2014; pp. 275–315. [Google Scholar]
- Jenkins, M.; Zieglar, L. Commercial National Security Algorithms (CNSA) Suite Profile of Certificate Management over CMS; IETF draft-jenkins-cnsa-cmc-profile-00; 2018 Network Working Group. Available online: https://tools.ietf.org/html/draft-jenkins-cnsa-cmc-profile-00 (accessed on 3 January 2021).
- Schneier, B. Did NSA Put a Secret Backdoor in New Encryption Standard? Available online: https://www.wired.com/2007/11/securitymatters-1115/ (accessed on 11 May 2008).
- Sreekumar, L.; Ramesh, P. Selection of an optimum entropy source design for a TRNG. Sci. Procedia Technol.
**2016**, 25, 598–605. [Google Scholar] [CrossRef] [Green Version] - Bakiri, M.; Guyeux, C.; Couchot, J.; Oudjida, A. Survey on Hardware Implementation of Random Number Generators on FPGA: Theory and Experimental Analyses. Available online: https://hal.archives-ouvertes.fr/hal-02182827 (accessed on 24 March 2018).
- Petura, O. True Random Number Generators for Cryptography: Design, Securing and Evaluation. Available online: https://tel.archives-ouvertes.fr/tel-02895861 (accessed on 10 June 2020).
- Ewert, M. A Random Number Generator Based on Electronic Noise and the Xorshift Algorithm. Proc. ICNCC
**2018**, 357–362. [Google Scholar] [CrossRef] [Green Version] - NIST 800-22/revision 1a. A Statistical Test Suite for Random and Pseudorandom Number Generators for Cryptographic Applications; Computer Resource Center (CRC) of NIST: Gaithersburg, MD, USA.
- ISO/IEC 20543:2019 Information Technology—Security Techniques—Test and Analysis Methods for Random Bit Generators within ISO/IEC 19790 and ISO/IEC 15408; ISO/IEC: Geneva, Switzerland, 2019.
- Holcomb, D.E.; Burleson, W.P.; Fu, K. Power-up SRAM state as an Identifying Fingerprint and Source of TRN. IEEE Trans. Comp.
**2009**, 58, 1198–1210. [Google Scholar] [CrossRef] - Wang, W.; Guin, U.; Singh, A. Aging-Resilient SRAM-based TRNG for Lightweight Devices. Comput. Sci. J. Electron. Test.
**2020**, 36, 301–311. [Google Scholar] [CrossRef] - Zhang, X.; Jiang, C.; Dai, G.; Zhong, L.; Fang, W.; Gu, K.; Xiao, G.; Ren, S.; Liu, X.; Zou, S. Improved Performance of SRAM-Based True Random Number Generator by Leveraging Irradiation Exposure. Sensor
**2020**, 20, 6132. [Google Scholar] [CrossRef] - Talukder, B.; Kerns, J.; Ray, B.; Morris, T.; Rahman, T. Exploiting DRAM Latency Variations for Generating True Random Numbers. In Proceedings of the 2019 IEEE International Conference on Consumer Electronics (ICCE), Las Vegas, NV, USA, 11–13 January 2019. [Google Scholar]
- Wang, Y.; Malysa, G.; Wu, S.; Yu, W.-K.; Suh, G.; Kan, E. Flash Memory for Ubiquitous Hardware Security Functions: TRNGs and Device Fingerprints. In Proceedings of the 2012 IEEE Symposium on Security and Privacy, San Francisco, CA, USA, 20–23 May 2012; pp. 33–47. [Google Scholar] [CrossRef] [Green Version]
- Rachid, M.; Ferdaus, F.; Talukder, B.; Henny, P.; Beal, A.; Rahman, M. TRNG Using Latency Variations of FRAM. IEEE Trans. VLSI Syst.
**2020**, 1–10. [Google Scholar] [CrossRef] - Rangarajan, N.; Parthasarathy, A. A spin-based TRNG exploiting the stochastic precessional switching of nanomagnets. J. Appl. Phys.
**2017**, 121, 223905. [Google Scholar] [CrossRef] - Alibeigi, I.; Amirany, A.; Rajaei, R.; Tabandeh, M.; Shouraki, S. A Low-Cost Highly Reliable Spintronic TRNG Circuit for Secure Cryptography. WS Spin
**2020**. [Google Scholar] [CrossRef] - Balatti, S.; Ambroglio, S.; Wang, Z.; Ielmini, D. TRNG by Variability of Resistive Switching in Oxide-Based Devices. IEEE JESTCS
**2015**, 5. [Google Scholar] [CrossRef] [Green Version] - Jiang, H.; Belkin, D.; Savel’ev, S.; Lin, S.; Wang, Z.; Li, Y.; Joshi, S.; Midya, R.; Li, C.; Rao, M.; et al. A novel true random number generator based on a stochastic diffusive memristor. Nat. Commun.
**2017**, 8, 1–9. [Google Scholar] [CrossRef] [Green Version] - Trichina, E.; Handschuh, H. Random Number Generation through Use of Memory Cell Activity. U.S. Patent 8,130,955 B2, 6 March 2012. [Google Scholar]
- Shifren, L.; Aitken, R. Device and Method for Generating Random Numbers. U.S. Patent 9,966,138 B2, 27 November 2001. [Google Scholar]
- McDonald, N.; Van Nostrand, J.; Wysocki, B.; Bishop, S.; Cady, N. Hardware Based Random Number Generator. U.S. Patent 8,680,906 B1, 14 October 2000. [Google Scholar]
- Ielmini, D.; Balatti, S.; Ambrogio, S. Device and Method for Generating Random Numbers. U.S. Patent 15/050,324 A1, 29 August 2017. [Google Scholar]
- Yang, J.; Xia, Q.; Jiang, H. True random number generator circuit using a diffusive memristor. U.S. Patent 2019/0303104 A1, 2019. [Google Scholar]
- Herder, C.; Yu, M.-D.; Koushanfar, F.; Devadas, S. Physical Unclonable Functions and Applications: A Tutorial. Proc. IEEE
**2014**, 102, 1126–1141. [Google Scholar] [CrossRef] - Christensen, T.; Sheets, J. Implementing PUF utilizing EDRAM memory cell capacitance variation. U.S. Patent 8,300,450 B2, 30 October 2012. [Google Scholar]
- Prabhu, P.; Akel, A.; Grupp, L.; Yu, W.-K.S.; Suh, G.E.; Kan, E.; Swanson, S. Extracting Device Fingerprints from Flash Memory by Exploiting Physical Variations. In Proceedings of the 4th International Conference on Trust and Trustworthy Computing, Pittsburgh, PA, USA, 22–24 June 2011. [Google Scholar]
- Plusquellic, J.; Swarup, B. Systems and Methods for Generating PUF’s from Non-Volatile Cells. U.S. Patent 10,216,965, 23 December 2014. [Google Scholar]
- Vatajelu, E.I.; Di Natale, G.; Barbareschi, M.; Torres, L.; Indaco, M.; Prinetto, P. STT-MRAM-Based PUF Architecture exploiting MTJ Fabrication-Induced Variability. ACM Trans.
**2015**. [Google Scholar] [CrossRef] - Chen, A. Comprehensive Assessment of RRAM-based PUF for Hardware Security Applications. In Proceedings of the 2015 IEEE International Electron Devices Meeting (IEDM), Washington, DC, USA, 7–9 December 2015. [Google Scholar]
- Sluis, E.; Schrijen, G.; Handschuh, H. Random Number Generating System Based on Memory Start-Up Noise; LNCS, 6805, Naccache, D., Festschrift, Q., Eds.; Springer: Berlin/Heidelberg, Germany, 2012; pp. 300–318. [Google Scholar]
- Van der Leest, V.; Van der Sluis, E.; Schrijen, G.; Tuyls, P.; Handschuh, H. Efficient Implementation of True Random Number Generator Based on SRAM PUFs. U.S. Patent 9,383,969 B2, 5 July 2016. [Google Scholar]
- Hyde, R.; Pasch, N.; Tegreene, C. Random Number Generator Function in Memory. U.S. Patent 9,323,499 B2, 26 April 2016. [Google Scholar]
- Cambou, B. Random Numbers Generating Systems and related methods. U.S. Patent 9,971,556 B2, 15 May 2018. [Google Scholar]
- Cambou, B. Physically Unlonable Function Generating Systems and Related Methods. U.S. Patent 9,985,791 B2, 29 May 2018. [Google Scholar]
- Cambou, B. Design of TRNG with Ternary PUFs. J. Adv. Sci. Technol. Eng. Syst.
**2018**, 3, 15–29. [Google Scholar] [CrossRef] - Cambou, B. Data Compiler for True Random Number Generation and Related Methods. U.S. Patent 10,175,948 B2, 3 September 2019. [Google Scholar]
- Chand, U.; Huang, K.; Huang, C.; Tseng, T. Mechanism of Nonlinear Switching in HfO2-Based Crossbar RRAM With Inserting Large Bandgap Tunneling Barrier Layer. Trans. Electron Dev.
**2015**, 62, 3665. [Google Scholar] [CrossRef] - Hudec, B.; Hsu, C.-W.; Wang, I.-T.; Lai, W.-L.; Chang, C.-C.; Wang, T.; Frohlich, K.; Ho, C.-H.; Lin, C.-H.; Hou, T.-H. 3D resistive RAM cell design for high-density storage class memory—A review. Sci. China
**2016**, 59. [Google Scholar] [CrossRef] - Chang, Y.; O’ Donnell, J.; Acosta, T.; Kotlyar, R.; Chen, A.; Quintero, P.; Strutt, N.; Golonzka, O.; Connor, C.; Hicks, J. eNVM RRAM reliability performance and modeling in 22FFL FinFET technology. In Proceedings of the 2020 IEEE International Reliability Physics Symposium (IRPS), Dallas, TX, USA, 28 April–30 May 2020; pp. 1–4. [Google Scholar]
- Krueger, D. Semiconductor Yield Modeling Using Generalized Linear Models. Ph.D. Thesis, ASU, Tempe, AZ, USA, 2011. [Google Scholar]
- Tong, L.; Chao, L. Novel yield model for integrated circuits with clustered defects. Sci. Direct Experts Syst. Appl.
**2008**, 34, 2334–2341. [Google Scholar] [CrossRef] - Wang, H.; Li, B.; Tong, S.; Chang, I.; Wang, K. A discrete spatial model for wafer yield prediction. A discrete spatial model for wafer yield prediction. Qual. Eng.
**2017**, 30, 169–182. [Google Scholar] [CrossRef]

**Figure 2.**Resistance values for 100 cells with 50 nA injected current. The size of the active area of Table 180. nm to 2 µm. The levels of randomness are lower with a larger size.

**Figure 6.**NIST-based statistical test of the raw data stream directly generated by TRNGs using the median scheme of pre-formed ReRAM cells. It is a failing NIST suite of randomness tests.

**Figure 7.**NIST-based statistical test of the data stream directly generated by TRNGs using the cell pairing scheme of pre-formed ReRAM cells, without removing the pairs with identical resistance values.

**Figure 8.**Testing the data stream generated by TRNGs using the cell pairing scheme of pre-formed ReRAM cells, after removing the pairs with identical resistance values.

**Figure 9.**Block diagram of an improved TRNG based on pre-formed ReRAM cells and additional steps enhancing randomness.

**Figure 12.**Test results of the data stream generated with the median scheme, with post processing, the XORing of blocks of 7 bits together. This passes NIST’s test of randomness.

**Figure 13.**Statistical test of the random numbers generated by the cell pairing scheme with a XORing by 7 bits.

**Figure 14.**Statistical test of the data stream generated with pairing scheme, elimination of the pairs with identical resistance values, and a XORing by chunk of 11 bits.

Publisher’s Note: MDPI stays neutral with regard to jurisdictional claims in published maps and institutional affiliations. |

© 2021 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (http://creativecommons.org/licenses/by/4.0/).

## Share and Cite

**MDPI and ACS Style**

Cambou, B.; Telesca, D.; Assiri, S.; Garrett, M.; Jain, S.; Partridge, M.
TRNGs from Pre-Formed ReRAM Arrays. *Cryptography* **2021**, *5*, 8.
https://doi.org/10.3390/cryptography5010008

**AMA Style**

Cambou B, Telesca D, Assiri S, Garrett M, Jain S, Partridge M.
TRNGs from Pre-Formed ReRAM Arrays. *Cryptography*. 2021; 5(1):8.
https://doi.org/10.3390/cryptography5010008

**Chicago/Turabian Style**

Cambou, Bertrand, Donald Telesca, Sareh Assiri, Michael Garrett, Saloni Jain, and Michael Partridge.
2021. "TRNGs from Pre-Formed ReRAM Arrays" *Cryptography* 5, no. 1: 8.
https://doi.org/10.3390/cryptography5010008