FPGA based implementation of a perturbed Chen oscillator for secure embedded cryptosystems

This section begins by comparing our work with other FPGA implementations of the XSG KK algorithm for chaotic systems. Next, we provide an evaluation of the randomness performance of our pseudo-random number generator (PRNG) using the NIST and TestU01 tests. Finally, we present some statistical analysis of the encryption results, like the histogram analysis, the correlation coefficient analysis, the global Shannon entropy analysis, and the key sensitivity.Implementation performancesOur implementation of the RK4 algorithm, as depicted in Table 1, strikes a balance between resource utilization, power consumption, and maximum operating frequency. Reference37 co-simulated the RK4 implementation of the new Chen system using active-HDL in Matlab/Simulink, utilizing 5615 Luts and 144 registers. In the study38, the resource utilization of Luts and flip-flops was reduced to 711 and 202, respectively, using a vhdl code to implement the fourth-order Runge–Kutta resolution of the hyperjerk. But the power consumption was not mentioned. Reference39 achieved resource utilization in Luts and flip-flops up to 2236 and 573, respectively, for the RK4 implementation of the Chen system. However, the maximum operating frequency (FOmax) was limited to 6.649 MHz, while requiring 200 DSPs. In Ref.36, the implementation showcased a reduction in Luts to 2017, achieving a maximum frequency of 113MHz with only 8 DSPs. However, it incurred the highest usage of flip-flops, with a value of 3458 and a power consumption of 73 mW. Meanwhile, in study40 the RK4 implementation of a Hopfield Neural Network oscillator (HNNO) was performed with 37,977 Luts and 47,195 FF.Table 1 Comparison with other FPGA RK4 implementation of chaotic systems.Our design outperforms some others in terms of resource utilization, with 1527 Luts and 468 flip-flops while operating at a FOmax of 51 MHz. Additionally, it only requires 8 DSP multipliers and consumes 112 mW of power. By introducing delay blocks and adjusting the latency in the perturbed Chen system unit, we can further enhance the FOmax of our design. When setting the latency to 1, the FOmax can reach up to 75 MHz. However, this would result in more clock cycles needed to complete the state variable computation. As a result, our design strikes a balance between resource utilization, power consumption, and maximum operating frequency.NIST statistical tests and TestU01To ensure the suitability of the proposed pseudo-random number generator (PRNG) for cryptographic applications, it is essential to evaluate the randomness of the generated sequence. We used two statistical test suites for this purpose. Firstly, the 15 tests of the NIST (National Institute of Standards and Technology) statistical test suite, a widely employed tool commonly utilized for testing pseudo-random number generators41. Secondly, two tests of the TestU01 suite: Rabbit and Alphabit. These tests were designed for binary files. Rabbit and Alphabit apply 40 and 17 different statistical tests, respectively42.For this research, the tested PRNG produced N = 100 sequences of 1 million bits each for three different values of perturbed term \({\varvec{d}}\), with initial values \(\left(-1\boldsymbol{ },-1,-1\right)\) and \(\left(1\boldsymbol{ },1,1\right),\) and control parameter values \(a=35\), \(b=3\) and \(c=28\). When \({\varvec{d}}=0\), the system is equivalent to the original Chen chaotic system. The value \({\varvec{d}}=1.61\) correspond to the highest amplitude value of the Lyapunov exponent spectra. We also generated a set of 100 sequences for the value \({\varvec{d}}=5\).In this study, the NIST SP 800–22 standard software package (NIST Statistical Test Suite (STS) for Random and Pseudorandom Number Generators for Cryptographic Applications, Version 2.1.2; URL Link: https://csrc.nist.gov/projects/random-bit-generation/documentation-and-software) was used, employing the standard test parameters with the P_value α set to 0.01, with the TestU01 tests Rabbit and Alphabit. The proportion of successful sequences that passed the sub-tests is presented in Table 2. For the tests that provide multiple result values, we present the lowest one. In this table, the proportions corresponding to tests where the sequences have a perfect score are formatted in bold. Those corresponding to tests where the results indicated that the sequence did not meet the randomness criteria are followed by an asterisk (*). An overview of the table shows that all the sequences built with the initial condition \((\text{1,1},1)\) have an issue with the non-overlapping template NIST test. They did not meet the randomness criteria. Among the other sequences, the first one with initial conditions \((-1, -1, -1)\) and perturbed term value \(d=-5\) has the highest number of perfect scores. The value \(d=-5\), will be used to perform all the other statistical tests in this study.Table 2 Proportions of NIST and TestU01 statistical tests results for random sequences generated with \(a=35\), \(b=3\) and \(c=28\).Histogram analysisThe pixel distribution, which illustrates the number of pixels at various levels of color intensity, is visualized through the image histogram. Figures 15a,b, 16a and b present a comparison of the histogram results for both the encrypted and original images. The histograms of the encrypted images display a uniform distribution of pixel values for the red, green, and blue channels compared to the histograms of the original images. This makes it difficult for an attacker to deduce any information from the encrypted image about the original image.Fig. 15Histogram of (a) original and (b) of encrypted peppers image for red, green and blue channel.Fig. 16Histogram of (a) original and (b) of encrypted Baboon image for red, green and blue channel.Correlation coefficient analysisCorrelation coefficient analysis compares neighboring pixels in plaintext and ciphered images. In the plaintext image, adjacent pixels correlate horizontally, vertically, and diagonally. In contrast, the ciphered image should have no association between pixels. A high correlation between pixels \((closed to+1 or -1)\) shows statistical attack susceptibility. Thus, good encryption reduces this coefficient \((closed to 0)\). Equation (11) can be used for correlation coefficient computation.$$r_{x,y} = \frac{C(x,y)}{{\sqrt {D(x) \cdot D(y)} }},$$
(11)
where \(C(x,y)\) is the covariance between the values of two adjacent pixel in the image x and y; \(D(x)\) and \(D(y)\) are the variance of x and y respectively, with:$$\left\{ \begin{gathered} C(x,y) = \frac{1}{N}\sum\limits_{i = 1}^{N} {\left( {\left( {x_{i} – E(x)} \right)\left( {y_{i} – E(y)} \right)} \right)} \hfill \\ D(x) = \frac{1}{N}\sum\limits_{i = 1}^{N} {\left( {x_{i} – E(x)} \right)^{2} } \hfill \\ E(x) = \frac{1}{N}\sum\limits_{i = 1}^{N} {x_{i} } \hfill \\ \end{gathered} \right.,$$
(12)
where \(E(x)\) is the mean value of x and N is the number of observations or pairs of data points.The correlation coefficient is calculated by randomly selecting 5000 pairs of adjacent pixels from the original and encrypted images. The correlation coefficient in horizontal, vertical, and diagonal orientations is estimated using Eq. (11) next. Figure 17 shows the selected adjacent pixels of the original Baboon image in horizontal, vertical, and diagonal orientations for the red, blue, and green color components. Figure 18 shows the horizontal, vertical, and diagonal distribution of selected adjacent pixels of the encrypted Baboon picture for the red, blue, and green color components. The results show that the original image has a linear pixel distribution, indicating a significant correlation between adjacent pixels. In contrast, the encrypted image has a random pixel distribution. Thus, the encrypted image has uncorrelated pixels, suggesting no significant association. Table 3 shows encrypted picture correlation coefficients near zero. Thus, predicting encrypted image pixel values is challenging. These results show that the proposed PRNG generated sequence for the image encryption scheme has good performance in fighting against attacks based on the correlation properties of the images.Fig. 17Distribution of 5000 pairs of randomly selected (a) Horizontal adjacent pixels, (b) Vertical adjacent pixels, (c) Diagonal adjacent pixels for the original Baboon image with \(d=-5\) and initial values \((-1,-1,-1)\).Fig. 18Distribution of 5000 pairs of randomly selected (a) Horizontal adjacent pixels, (b) Vertical adjacent pixels, (c) Diagonal adjacent pixels for the encrypted Baboon image with \(d=-5\) and initial values \((-1,-1,-1)\).Table 3 Correlation coefficient value of peppers and Baboon original images, and their corresponding encrypted images.Global Shannon entropy analysisAn image’s Shannon entropy measures its randomness by measuring its average information per bit. Entropy should be around 8 bits per pixel for an 8-bit encoded image for optimal encryption. Equation (13) calculates information entropy for an 8-bit image.$$H(S) = – \sum\limits_{i = 1}^{256} {\left( {P\left( {s_{i} } \right) \times \log_{2} P\left( {s_{i} } \right)} \right)} ,$$
(13)
where \(H(S)\) is the Shannon entropy of the image, \(P(s_{i} )\) is the probability of occurrence of a pixel having a value \(s_{i} .\) The summation runs over all possible values \(s\) in the image source \(S.\)Equation (13) quantifies image-wide Shannon entropy. Encrypted image global Shannon entropies are shown in Table 4. In conclusion, encrypted images have an average global entropy of 7.9992, close to 8. From those results, we infer that the encrypted image has no statistical information that may be exploited to obtain the original image. Table 5 shows that the suggested PRNG generate sequence for image encryption performs equally to recent studies proposed in the literature.Table 4 Global entropy of the encrypted images for \(d=-5\).Table 5 Comparative study of the global entropy for encrypted RGB images.Many chaos-based encryption techniques are used in the literature to secure image transmission using embedded devices. In study43, a chaotic fractional order encryption scheme implemented in an FPGA was proposed. Likewise, the authors in Ref.38 designed a chaotic hyperjerk-based encryption scheme in integer order embedded in an FPGA. In studies44 and45, a chaos-based encryption embedded in a microcontroller was designed using a jerk system and a Modified Hénon Chaotic Map (MHCM), respectively. Moreover, a Raspberry Pi implementation of many chaotic systems, including the Chen system, was used to design an encryption scheme in the study46. In references47 and40, an image encryption algorithm based on a chaotic neural network was designed on an FPGA. Table 5 presents a comparative study of the global entropy for encrypted images between our work and those papers. We obtained an average global entropy value that was similar to the other study. Therefore, we can use the sequences generated with our PRNG for image encryption, as their statistical properties are comparable to those of other recent and diverse encryption schemes.Key sensitivityCryptography requires a secret parameter to be sensitive enough to assure the “avalanche property”: any little change in the parameter will modify the ciphertext. This ensures strong parameter mismatch sensitivity48.Table 6 presents the keys used to achieve the key sensitivity tests. Key1 is the original key used in the above results. Keys 2–4 are used to verify initial condition sensitivity, and Keys 5–7 are used for control parameter sensitivity. Since we represent data with a fixed-point format of 32Q20, there is a difference of one bit with the slightest difference value between Key1 and all the other keys.Table 6 Keys used for the key sensitivity test.At the decryption phase, the decrypted image must be completely different from the original image when using the wrong key. Figure 19 presents the decrypted images with Keys 1–7 for an image encrypted using Key1. The results show that only the right key can decipher the encrypted image. As a consequence, we can attest to the key sensitivity of our design for both initial values and control parameters.Fig. 19Decrypted Baboon image by (a) Key1, (b) Key2, (c) Key3, (d) Key4, (e) Key5, (f) Key6, (g) Key7.All those results show that the introduction of a simple constant perturbation term d in the Chen system significantly enhances the chaotic properties of the system, resulting in superior randomness quality in the PRNG produced and increased security.

Hot Topics

Related Articles