You are on page 1of 5

Received: 23 July 2018 Revised: 10 February 2019 Accepted: 22 March 2019

DOI: 10.1002/jnm.2604

RESEARCH ARTICLE

FPGA implementation of chaos‐based high‐speed true


random number generator

Ramji Gupta | Alpana Pandey | Rajendra Kumar Baghel

Department of Electronics and


Abstract
Communication Engineering, MANIT,
Bhopal, India A true random number generator (TRNG) is a basic building block of many
modern cryptographic systems. As field programmable gate array (FPGA) has
Correspondence
Ramji Gupta, Department of Electronics
a flexible architecture and low‐cost test cycle, hence, it becomes an ideal plat-
and Communication Engineering, form for hardware implementation of digital systems. This paper presents an
MANIT, Bhopal 462003, India. FPGA implementation of a high‐speed TRNG that is based on a chaotic oscil-
Email: ramjigupta38@yahoo.com
lator at 100 MHz frequency with speed of 1600 Mbps. The experimental results
show that the proposed generator is faster and more compact than the existing
chaotic ring‐oscillator‐based TRNGs, and further, it is verified that the gener-
ated bit sequences pass all TRNG tests in National Institute of Standards and
Technology (NIST SP 800‐22). The proposed TRNG is implemented in two
FPGA families: Nexys 4 DDR XC7A100TCSG‐1 (Artix 7) and Basys 3
XC7A35T1CPG236C (Artix 7) Xilinx Vivado v.2017.3 design suite.

KEYWORDS
chaotic oscillator, field programmable gate array (FPGA), true random number generator (TRNG)

1 | INTRODUCTION

True random number generators (TRNGs) are an inseparable part of any security system that uses encryption and
decryption as its main protective measure. With high entropy and good speed, they find applications in software security
via password generation, protocols to validate aforesaid parties, and vector initialization. TRNG overcomes the limitation
of pseudorandom numbers generators using microscopic or macroscopic phenomenon such as electrical noise and cir-
cularly polarized photons, as these sources produce predictable outcomes.1,2 TRNG based on analogue circuits requires
larger area, high power consumption, and having low speed.3 On the other hand, digital logic and field programmable
gate array (FPGA)‐based TRNG have good flexibility, high speed, reduced size, and less complexity. Digital TRNGs have
mainly three components: entropy source such as ring oscillator (RO) or chaotic oscillator (CO), entropy harvester such
as sampler, and postprocessor such as LFSR.4-6 Our aim is to design TRNG containing digital components to make
design simple and suited for FPGA implementation. Digital implementation of TRNG has limited sources of randomness
like frequency of free running oscillator, random phase shift and clock signals, and meta‐stability of circuit elements.
The speed of the TRNGs depends upon the used entropy sources such as accumulated jitter1,4,7 and transition effect.6
CO can be used as an entropy source and the achieved output bit rate are in the range of 125 Mbit/s.8 Self‐time ring‐
based TRNG (STRNG) gives a high bit rate with larger area.9 TRNG based on critical sampling requires a fast oscillator
with manual placement.10 TNRG based on two metastable flip‐flops (FFs) uses an adaptive feedback loop to control the
randomness.2 We propose an FPGA implementation of TRNG using CO as a source of randomness in addition to meta‐
stability state of the FF stage, which provide a high bit rate with small area in terms of LUT's and registers compared
with previous designs.
Int J Numer Model. 2019;e2604. wileyonlinelibrary.com/journal/jnm © 2019 John Wiley & Sons, Ltd. 1 of 5
https://doi.org/10.1002/jnm.2604
2 of 5 GUPTA ET AL.

2 | CHAOS‐ B A S E D TR N G

The proposed chaos‐based TRNG with multiple sampling uses CO as a source of randomness and output of the RO to
provide clock signal. The CO frequency is kept minimum three times the RO frequency to pass the National Institute of
Standards and Technology (NIST) test. The schematic diagram of CO consists of 16 inverter in series is presented in
Figure 1. RO also consists of 16 inverters in series is presented in Figure 2. The schematic diagram of chaos‐based pro-
posed TRNG is presented in Figure 3. The output bit rate can be easily increased either by increasing the global clock
frequency or by adding identical TRNGs in parallel. The proposed design of TRNG consists of chaos‐based 16 identical
TRNGs in parallel to increase the bit rate. The output signal of CO is sampled into the positive edge triggered D FF,
which works as a sampler. The clock pulse is provided by the RO. For randomness of CO, the maximum achieved clock
frequency of RO founds 100 MHz. So under the design framework the proposed TRNG generates 16 bits in 10 nanosec-
onds at the output. CO and RO start oscillation at enable high. The output of CO is sampled to the D FF at the intervals
of Tclk, and it generates 16 bit random string in 10 nanoseconds. CO and RO did not oscillate at enable low, and FFs
retain the previous value.
Further to increase randomness, postprocessing unit (PPU) is added to the circuit as presented in Figure 4. The PPU
consists of 4 bit linear feedback shift resister (LFSR) connected to the TRNG, which remove the raw numbers from gen-
erated bit strings and improve the randomness. Other PPU structures like longer bit LFSR or encryption algorithms can
be used for better performance. The schematic diagram of PPU unit implemented in FPGA is shown in Figure 5.

3 | IMPLEMENTATION A ND TEST RESULTS

The proposed TRNG is implemented with Nexys 4 DDR XC7A100TCSG‐1 (Artix 7) and Basys 3 XC7A35T1CPG236C
(Artix 7) FPGA families. Nexys 4 and Basys 3 give high performance with Vivado Design Suite of Xilinx's, which
includes several new tools and design flows that expedite and improve the latest design methods. It runs faster and
make better use of FPGA resources.
For the NIST test, 106 bit streams were generated from TRNG, and the bit streams at the output of PPU were trans-
mitted from the FPGA board to the PC using the USB port of the Nexys 4 DDR and Basys 3 evaluation board with the
help of interface unit. The interface unit is implemented by a FIFO‐UART (Universal Asynchronous Receive Transmit)
combination. For NIST test results, the level of significance is set to P = .01.11 In the result, all P value are greater than
.01, which confirms that generated bit string is random as shown in Table 1.
The area (LUT and register) and throughput of the proposed TRNG are given in Table 2. Experimental results show
that the proposed design gives the same bit rate with and without PPU, hence, eliminate the need of this unit in the
design. The experimental result also shows that the proposed design unit is work as TRNG for 2n stages of parallel
TRNGs connected only when value of n is even.
The statistics of the TRNGs implemented previously is given in Table 3. It can be observed from Tables 2 and 3 that
the presented TRNG is optimized in terms of bit rate and area. At a very high bit rate of 1600 Mbps, the proposed TRNG
occupy a relatively low area. The parameter bit rate to area ratio (BPA) of proposed TRNG is better than the TRNGs
compared in Table 3.

FIGURE 1 Schematic of chaotic oscillator

FIGURE 2 Schematic of ring oscillator


GUPTA ET AL. 3 of 5

FIGURE 3 Structure of proposed true


random number generator (TRNG)

FIGURE 4 True random number


generator (TRNG) with postprocessing
unit

FIGURE 5 Schematic of postprocessing unit (PPU)


4 of 5 GUPTA ET AL.

TABLE 1 NIST test results of proposed TRNG

Artix7 Nexus‐4 Artix7 Basys‐3


Test P Value Result P Value Result

Frequency (monobit) 0.579 Successful 0.783 Successful


Block frequency 0.288 Successful 0.433 Successful
Cumulative sums (forward) 0.097 Successful 0.387 Successful
Cumulative sums (inverse) 0.453 Successful 0.613 Successful
Runs 0.288 Successful 0.783 Successful
Longest run 0.539 Successful 0.563 Successful
Rank 0.349 Successful 0.231 Successful
FFT 0.999 Successful 0.342 Successful
Nonoverlapping 0.734 Successful 0.672 Successful
Overlapping 0.342 Successful 0.876 Successful
Universal 0.394 Successful 0.453 Successful
Approximate entropy 0.743 Successful 0.821 Successful
Random excursions (x = +1) 0.384 Successful 0.781 Successful
Random excur. Variant(x = −1) 0.832 Successful 0.912 Successful
Serial (m = 16) 0.403 Successful 0.994 Successful
Linear complexity 0.754 Successful 0.834 Successful

Abbreviation: FFT, Fast Fourier Transform; TRNG, true random number generator.

TABLE 2 Implementation results of proposed TRNG in two FPGA families

Area (LUT + Reg.)


Mbit=s
BPA ( )
FPGA Family TRNG TRNG with PPU Bit Rate, Mbit/s LUT þ Reg:
Nexus 4 DDR Artix7 581 + 16 593 + 32 1600 2.6800
Basys 3 Artix7 581 + 16 593 + 32 1600 2.6800

Abbreviations: FPGA, field programmable gate array; PPU, postprocessing unit; TRNG, true random number generator.

TABLE 3 Implementation statistics results of previous TRNGs

Koyuncu and
Sunar et al4 Cherkaoui et al9 Turan Ozcerit12 Wu and Li13 Cherkaoui et al14 Choi et al15

Area (LUT + Reg) 525 + 130 352 + 256 12430 + 32 298 511 21 + 15
Bit rate (Mbps) 2.2 245 58.76 150 133 12.5
BPA 0.0033 0.42 0.0047 0.5033 0.260 0.33
FPGA family Cyclone V Cyclone V Vertex‐6 Altera Cyclone III Cyclone V
Cyclone IV

Abbreviations: FPGA, field programmable gate array; TRNG, true random number generator.

4 | CONCLUSION

We presented a chaos‐based TRNG using CO at 100 MHz using multiple sampling implemented in two FPGA family:
Nexys 4 DDR XC7A100TCSG‐1 (Artix 7) and Basys 3 (Artix 7) Xilinx vivado v.2017.3 design suite passed all the NIST
GUPTA ET AL. 5 of 5

test. The clock timing of 10 nanoseconds and 16 bit TRNGs that were added in parallel increased the bit rate. The exper-
imental results showed that the proposed TRNG is faster and more compact than previously implemented TRNGs.

ORCID
Ramji Gupta https://orcid.org/0000-0002-4126-4323

R EF E RE N C E S
1. Baudet M, Lubicz D, Micolod J, Tassiaux A. On the security of oscillator‐based random number generators. J Cryptol. 2011;24(2):398‐425.
https://doi.org/10.1007/s00145‐010‐9089‐3
2. Wieczorek P. Dual‐metastability fpga‐based true random number generator. Electron Lett. 2013;49(12):744‐745. https://doi.org/10.1049/
el.2012.4126
3. Ramji Gupta A, Pandey RKB. Comparative analysis of true random number generator. In: 1st International Conference on New Frontiers
in Engineering, Science & Technology. Vol. 8‐12 India: New Delhi; 2018:219‐222. ISBN:978‐93‐86238‐41‐2.
4. Sunar B, Martin WJ, Stinson DR. A provably secure true random number generator with built‐in tolerance to active attacks. IEEE Trans
Comput. 2007;56(1):109‐119. https://doi.org/10.1109/TC.2007.250627
5. Fischer V, Drutarovský M. True random number generator embedded in reconfigurable hardware. In: Int. Workshop Cryptographic
Hardware and Embedded Systems. California, USA: Redwood Shores; 2002:415‐430. https://doi.org/10.1007/3‐540‐36400‐5_30
6. Varchola M, Drutarovsky M. New high entropy element for FPGA based true random number generators. In: Int Workshop Cryptographic
Hardware and Embedded Systems. California, USA: Santa Barbara; 2010:351‐365. https://doi.org/10.1007/978‐3‐642‐15031‐9_24
7. Kohlbrenner P, Gaj K. An embedded true random number generator for FPGAs. In: Int Symp on Field Programmble Gate Arrays.
California: Monterey; 2004:71‐78. https://doi.org/10.1145/968280.968292
8. Yang Y, Jia S, Wang Y, Zhang S, Liu C, “A reliable true random number generator based on novel chaotic ring oscillator”, IEEE
conference, 978‐1‐4673‐6853‐7/17/$31.00 2017.
9. Cherkaoui A, Fischer V, Aubert A, Fesquet L. A self‐timed ring based true random number generator. In: Int Symp Asynchronous Circuits
Systems. California, USA: Santa Monica; 2013:99‐106. https://doi.org/10.1109/ASYNC.2013.15
10. Petura O, Mureddu U, Bochard N, Fischer V, Bossuet L. A survey of AIS‐20/31 compliant TRNG cores suitable for FPGA devices. In:
Int Conf Field‐Programmable Logic and Applications. Switzerland: Lausanne; 2016:1‐10. https://doi.org/10.1109/FPL.2016.75773799
11. Bassham LEIII, Rukhin AL, Soto J, et al. SP 800‐22 rev. statistical test suite for random and pseudorandom number generators for
cryptographic applications. In: National Institute of Standards and Technology (NIST). USA: Special Publication 800‐22; 2010.
12. Koyuncu I, Turan Ozcerit A. The design and realization of a new high speed FPGA‐based true random number generator. Comput Electr
Eng. 58:204‐214. https://doi.org/10.1016/j.compeleceng.2016.07.005
13. Wu Xufan and Li Shuguo; “A new digital true random number generator based on delay chain feedback loop”, IEEE conference 978‐1‐
4673‐6853‐7/17/$31.00, 2017.
14. Cherkaoui A, Fischer V, Fesquet L, Aubert A. A very high speed true random number generator with entropy assessment. In:
International Conference on Cryptographic Hardware and Embedded Systems; 2013:179‐196.
15. Choi P, Lee M‐K, Kim DK. Fast compact true random number generator based on multiple sampling. Electron Lett. 2017;53(13):841‐843.

How to cite this article: Gupta R, Pandey A, Baghel RK. FPGA implementation of chaos‐based high‐speed true
random number generator. Int J Numer Model. 2019;e2604. https://doi.org/10.1002/jnm.2604

You might also like