A novel spectrogram visual security encryption algorithm based on block compressed sensing and five-dimensional chaotic system

Based on block compressed sensing theory, combined with a five-dimensional chaotic system, we propose and analyze a novel spectrogram visual security encryption algorithm. This research is devoted to solving the compression, encryption and steganography problems of spectrograms involving large data volumes and high complexity. First, the discrete wavelet transform is applied to the spectrogram to generate the coefficient matrix. Then, block compressed sensing is applied to compress and preencrypt the spectrogram. Second, we design a new five-dimensional chaotic system. Then, several typical evaluation methods, such as the phase diagram, Lyapunov exponent, bifurcation diagram and sample entropy, are applied to deeply analyze the chaotic behavior and dynamic performance of the system. Moreover, the corresponding Simulink model has been built, which proves the realizability of the chaotic system. Importantly, the measurement matrix required for compressed sensing is constructed by the chaotic sequence. Third, dynamic Josephus scrambling and annular diffusion are performed on the secret image to obtain the cipher image. Finally, an improved least significant bit embedding method and alpha channel synchronous embedding are designed to obtain a steganographic image with visual security properties. To make the initial keys of each image completely different from other images, the required keys are produced using the SHA-256 algorithm. The experimental results confirm that the visual security cryptosystem designed in this study has better compression performance, visual security and reconstruction quality. Furthermore, it is able to effectively defend against a variety of conventional attack methods, such as statistical attacks and entropy attacks.


Introduction
Massive amounts of high-energy particles are sent into the universe by solar radio bursts [1]. When these highenergy particles pass through the earth, they easily lead to disorder in the geomagnetic field and cause auroras, which affect the stable operation of satellite communication and power supply networks [2]. As a result, the operational safety of spacecraft in near-orbit of the earth can be seriously affected [3]. Solar radio spectrograms record precious solar radio burst data, which are of great significance for predicting catastrophic events in space. However, these solar radio spectrograms are vulnerable to theft and malicious tampering during network transmission. Therefore, designing an encryption algorithm with higher security is particularly important for the transmission security of spectrograms.
At present, digital image encryption methods studied in academia are primarily composed of two different types [4,5]. First, the traditional method usually realizes image encryption by confusing the value or position of each plain image pixel [6]. After the encryption process, a noise-like image can be obtained. Such traditional encryption methods mainly include chaos theory [7,8], DNA encoding [9], pixel scrambling and pixel diffusion [10]. However, with the diversification of deciphering methods available, traditional encryption technology has been unable to meet the higher security requirement for images in the security field. The second method consists of image visual security encryption technology [11,12]. This technology combines traditional encryption methods with image steganography; that is, it embeds an encrypted image into a specified carrier image using lossless or lossy methods, and then an encrypted image with visual significance is obtained [13,14]. The image steganography techniques mainly consist of least significant bit (LSB) embedding [15], wavelet obtained weights (WOW) [16], interpolation technology (IT) [17] and lifting wavelet transform (LWT) [18]. Compared with traditional encryption technology, visual security encryption technology has better concealment and security. As a result, this method has gradually become the main method in the field of image protection and data privacy.
In 2015, after visual security encryption technology with the dual advantages of image encryption and steganography was proposed, it immediately received the attention of many scholars [19,20]. In 2015, Zhou et al. designed a practicable visual security encryption system combining the nonlinear fractional Mellin transform with two-dimensional compressed sensing (2DCS) [21]. First, the selected plain images were measured by the measurement matrix to realize compression and encryption, and then a nonlinear fractional Mellin transform was performed for secondary encryption. This scheme improves the encryption performance of the cryptosystem to a certain extent. In 2019, Gong et al. unveiled a novel visual encryption technology by introducing compressed sensing theory (CS) and the RSA public key encryption algorithm [22]. The algorithm uses a one-dimensional cascaded chaotic map and DNA encoding to scramble and diffuse unencrypted images. It presents good reconstruction quality and security performance. In the same year, Gong et al. again published a novel encryption technology that combined a one-dimensional chaotic map and compressed sensing [23]. In this technology, every original image was first scrambled by the Arnold transformation, and then, compressed sensing was applied to the scrambled image, which reduced the effect of blocking. Furthermore, the keys used were closely related to the original image, which resulted in better secrecy performance. Currently, image visual security encryption algorithms are trending toward diversification and high security.
An ideal visual security encryption algorithm needs to exhibit excellent encryption performance, compression performance and reconstruction quality. However, the current encryption technology generally has the following shortcomings.
(1) The encryption stage adopts a low-dimensional chaotic system and simple scrambling and diffusion algorithms, which have the shortcomings of low security, ease of deciphering, and difficulty resisting conventional attack methods. (2) The traditional image steganography process may lead to energy loss and some pixel value changes in the image, which will lose some details of the plain images and reduce the reconstruction performance. (3) Some colour images with large data volume and high complexity are a difficult challenge to the visual security encryption algorithm, and there are shortcomings such as low security and poor reconstruction quality.
To deal with the problems raised above, this study proposes a spectrogram visual security encryption scheme that combines block compressed sensing (BCS) with a five-dimensional chaotic system. Compared with the existing encryption schemes, our research has additional advantages.
(1) In view of the large data size and high complexity of spectrograms, block compressed sensing theory is adopted. The spectrogram is first divided into several pixel blocks and then compressed. On the premise of ensuring the reconstruction quality, the efficiency of the encryption algorithm is greatly improved.
(2) A new five-dimensional chaotic system is proposed. The Lyapunov exponent spectra (LEs), phase diagrams and sample entropy (SE) are analyzed in detail. Importantly, an analogue circuit is constructed to verify the effectiveness of the system. In addition, the SHA-256 function has been implemented to guarantee that all plain images have a unique key stream of their own. The sensitivity of our proposed visual security algorithm to plain images is improved effectively. (3) Dynamic Josephus scrambling and annular diffusion are introduced in the encryption process. This can break the correlation distribution and improve the capacity of the designed algorithm to defend against violent attacks. (4) The lossless colour image embedding method is adopted, which improves the restoration effect and robustness of the visual security algorithm.
The structure of this paper is as follows. Section 2 introduces and analyzes the five-dimensional chaotic system, block compressed sensing, dynamic Josephus scrambling and the construction method of the measurement matrix. The visual security encryption algorithm is explained in detail in Sect. 3. The experimental results and performance evaluation of our proposed algorithm are presented in Sect. 4. Finally, this study is summarized.

Compressed sensing
The basic premise of CS is that if a signal is sparse, it can be reconstructed from sampling points whose number is far below the requirements of the sampling theorem. Therefore, CS is usually applied to scenes with large data sizes and high complexity, which can help achieve the goal of reducing the sampling rate and data size [24,25]. For a two-dimensional (2D) image X ∈ R N ×N , there is a 2D sparse matrix ψ ∈ R N ×N , which can be used to sparse X , as described in Eq. 1.
where Q ∈ R N ×N is the coefficient matrix and (•) T is the transpose operation. Moreover, if there are only a few nonzero values in Q, then X can be called a 2D sparse signal.
Considering that X is a 2D signal, it needs to be converted to 1D signal before sampling, as shown in the following equation.
where x ∈ R N 2 ×1 represents the 1D signal matrix, y ∈ R M 2 ×1 is the measurement vector, vec(•) is used to construct the 1D vector, and φ ∈ R M 2 ×N 2 represents the measurement matrix. Solar radio spectrograms are used to record the fine structure of solar radio bursts and have a huge data volume [26]. Therefore, it is necessary to block it and then apply the compressed sensing theory. This is called block compressed sensing. The spectrogram can be decomposed into three components R, G and B. Here, we use component R as an example for description. First, the component R is segmented into n blocks of size m × m pixels denoted as x i . Then, each pixel block is observed using the same measurement matrix. Finally, n measurement vectors y i can be obtained.
After obtaining n measurement vectors, each pixel block is reconstructed using the same reconstruction algorithm, and then a complete image can be obtained by combining them. The reconstruction technology introduced in the study is orthogonal matching pursuit (OMP). Meanwhile, in Sect. 2.3 we construct a measurement matrix through the five-dimensional chaotic system, which can effectively heighten the compression effect and reconstruction quality of BCS.

Five-dimensional chaotic system
Multi-dimensional chaotic systems have multiple system parameters and system variables. It usually exhibits chaotic behavior that is much less predictable than lowdimensional chaotic systems. In addition, due the limited precision of modern computers, low-dimensional chaotic systems will exhibit short-period phenomena and dynamic degradation. Therefore, we decided to design a high-dimensional chaotic system to construct a cryptographic system that is more difficult to decipher and can withstand various types of attacks.

Mathematical model
In 2004, Liu et al. published a novel 3D chaotic system [27]. This system is defined by Eq. 4.
where a, b and c are system parameters and x, y and z are system variables. Figure 1a-d shows the phase diagrams of the chaotic system with respect to the three system variables x, y and z, respectively.
If we introduce two new system variables w and v into system (4), then a novel five-dimensional chaotic system can be acquired. The specific mathematical model is described by Eq. 5.
in addition, the initial values required for the following analysis are shown in Eq. 6. [ Figure 2a-j shows the 3D phase diagrams of the fivedimensional chaotic system with respect to the five system variables x, y, z, w and v, respectively. Clearly, the chaotic system we have constructed presents complex dynamic behavior, and the motion trajectory covers every position in the attractor region. The time domain waveform diagrams of the new system are given in Fig. 3a-e. We can observe that the chaotic system presents a quasiperiodic state. The time domain waveform seems random, but there is no definite period.
Equation 7 is solved after setting the system parameters of the five-dimensional chaotic system to a = 7, b = 22, c = 8.1, d = 2, e = 15 and f = 5. Then, the equilibrium point P(0, 0, 0, 0, 0) can be obtained. Finally, we solve the equilibrium point P to obtain the Jacobian matrix, which is given in Eq. 8.
We set det (J − λI ) = 0, where λ is the eigenvalue and I is the five-dimensional identity matrix. Then, five eigenvalues can be obtained as, Obviously, the five eigenvalues are not all negative real numbers. Therefore, the equilibrium point P is an unstable saddle focus.

Lyapunov exponent (LE)
The LE is one of the core indicators used to measure the dynamic behavior of a chaotic system. If a system has a positive LE, then even if the initial conditions have a slight difference, the two trajectories will diverge exponentially with time [28]. The LE can be calculated by the following steps.
We assume that the equation of the chaotic system is .., n, and f (x) is the Jacobian matrix of f . The Jacobian matrix can be obtained by Eq. 9.
Firstly, set , and then perform modulus operation on n characteristic roots. Finally, arrange them from large to small: λ n . The LEs λ k can be defined by Eq. 10.
We simulated and analyzed the LEs of the system parameters a, b, c and f of the five-dimensional chaotic system. The final results are given in Fig. 4a-d. When calculating the Lyapunov exponents, we only set one parameter as a variable, and the other parameters remain unchanged. The corresponding relationship is shown in Table 1.
(1) The LEs of the parameter a are shown in Fig. 4a.
Obviously, the chaotic system always has a LE greater than 0 when the parameter .00], the Five-Dimensional chaotic system has a LE greater than 0, indicating that the proposed chaotic system has complex dynamic behavior.

Bifurcation diagram
Bifurcation diagrams are usually used to describe the dynamic behavior of chaotic systems with changes in system parameters [27]. In the bifurcation diagram, one system parameter is selected as the abscissa, and another parameter is arbitrarily taken as the ordinate. Then, the state discrete points are drawn on the twodimensional plane so that the mutation process of the chaotic system can be observed more intuitively. We conduct a simulation analysis for the bifurcation diagrams of the new chaotic system with respect to parameters a, b, c and f . The simulation results are given in Fig. 5a-d. We can clearly observe that the characteristics of the bifurcation diagram are basically consistent with the Lyapunov exponential spectra. In addition, for Fig. 5a, the details of the bifurcation diagram are locally enlarged. The left magnification area presents a complex chaotic state, while the right magnification area shows a periodic state.

Power spectrum
The chaotic signal is an aperiodic signal, which exhibits a continuous power spectrum without obvious peaks [29]. Therefore, we can detect whether a signal has chaotic characteristics by simulating the power spectrum. We simulated the power spectrum of the chaotic sequences x and y generated by the new system, as shown in Fig.6a, b. Obviously, their power spectrum is continuous, and there are no obvious peaks. Therefore, the new chaotic system we proposed has complex dynamic behavior.

Sensitivity analysis
As long as the initial conditions of the chaotic system change slightly, the final motion trajectory will be completely different as the iteration proceeds [30]. This key point can be seen intuitively from the time domain waveform diagrams of the system. We have simulated the five-dimensional chaotic system under different initial conditions with only slight differences, and the simulation results are given in Fig. 7a-e. We obviously find that when the system parameter x is changed by only 0.001 or even 0.00001, the final dynamic trajectory will become completely uncorrelated. Therefore, the chaotic system we have designed is extremely sensitive to the initial conditions.

Chaotic model simulation
It is very important to construct a chaotic simulation model for the in-depth analysis of the specific characteristics of the chaotic system [31,32]. Furthermore, we can set the relevant parameters of all modules in the model, which can more intuitively observe the attractor trajectory of the chaotic system.
We built the simulation model of the proposed chaotic system in Simulink. Figure 8 displays the construction of this model. Figure 9a-c exhibits the phase diagrams of the new system on three different threedimensional planes through the 3D oscilloscope. It can be clearly seen that their motion trajectories are basically the same as those in Fig. 2a, b, e. Therefore, 9614 F. Yan et al. Power spectrum of the chaotic system: a sequence x; b sequence y the new chaotic system we designed is achievable and effective.

Chaos-based measurement matrix
The construction of a measurement matrix is one of the key points of compressed sensing theory. The measurement matrix is used to sample the original signal and obtain the measurement signal. The sampling rate is much lower than that in the Nyquist sampling theorem.
Obviously, the data volume of the measurement signal is much smaller than that of the original signal, and the key information will not be lost and this will ensure the quality of the reconstructed signal. Therefore, designing a reasonable measurement matrix is crucial to the acquisition of measurement values and the quality of image reconstruction.
In this study, the measurement matrix is constructed by the designed five-dimensional chaotic system. First, the sequence P can be obtained by sampling the generated chaotic sequence X and then quantizing it to [-1, where X is a chaotic sequence, p is a sequence of length M 2 × N 2 , mod() is the mod operation. Finally, the sequence p is constructed as the measurement matrix φ through Eq. 12.
where φ is measurement matrix.

Dynamic Josephus scrambling
Josephus scrambling is derived from the Josephus ring problem. We select a spectrogram of size M × N × 3 and take channel R as an example to illustrate it. First, we set the length of Josephus as M × N , the starting position as S, and the counting interval as g. Second, we start counting from the S th pixel, extract the pixel counted to g, and record it in the scrambling sequence A of size M × N in order. Then, pixels are selected repeatedly according to this rule until the last pixel. Finally, the scrambled image X 1 can be obtained by rearranging plain X with the subscript index N o of each element in A. Among them, S and g are updated and iterated in real time by the five-dimensional chaotic system. Dynamic Josephus scrambling can be defined as the following equation.

Solar radio spectrogram
The solar radio spectrogram uses changes in colour depth to show the relationship between solar radio intensity, time and frequency [33]. When the data acquisition system receives the solar radio signal collected by the observation system, the upper computer draws the digital signal into the spectrogram. The colour depth of the spectrogram changes in real time according to the signal strength. Therefore, we can judge whether solar radio burst occurs by observing the colour changes of the spectrogram. Figure 10 shows the solar radio spectrogram generated by the 15-110 MHz solar radio observation system at the Cha Shan Solar Radio Observatory of Shandong University. The highlighted area of the spectrogram is a rare solar radio burst observed by the observatory on July 5, 2022.

Visual security encryption algorithm
To achieve visual security encryption of high-complexity spectrograms under limited computing resources, we propose a novel spectrogram encryption algorithm. The algorithm mainly consists of BCS, a five-dimensional chaotic system and LSB and proposes the concept of alpha channel synchronous embedding. This method effectively improves the encryption performance, compression performance and embedding capacity of the security algorithm. It is composed of three parts: compression, encryption and embedding. Figure 11 shows the flowchart of the corresponding algorithm. First, DWT is performed on the spectrogram, and then BCS is implemented to complete compression and preencryption. In particular, the measurement matrix is not a Gaussian matrix but is instead constructed by our designed chaotic system. Considering the necessity of further heightening the security of the encryption system, dynamic Josephus scrambling and annular diffusion are implemented on the compressed image, and then an absolutely disordered cipher image is generated. Finally, the cipher image is embedded using LSB and the alpha channel synchronous embedding method to obtain the steganographic images. The specific procedures of the visual security cryptosystem are described below.
The size of spectrogram selected in this paper is 512 × 1024 × 3, and the size of carrier image is 1024 × 1024 × 3.

Initial key generator
To ensure that an image corresponds to only a unique key stream, the SHA-256 algorithm is selected to receive the 256-bit index combined with an original spectrogram. Then, this 256-bit hash value is divided into 32 matrices of the same size, denoted as k i , where i = 1, 2..., 32. Each matrix consists of 8 binary numbers and is converted to a decimal number. Finally, 32 groups of decimal numbers are used to obtain the keys required by our five-dimensional chaotic system. The key generator is described below. .

Block compression
Step 1: The keys x, y, z, w and v are input into the chaotic system we constructed for iteration. Then the chaotic sequences X , Y , Z , W and V are obtained. Meanwhile, the spectrogram is broken up into multiple 512 × 512 matrix blocks, and the compression ratio is set to F = 0.8.
Step 2: DWT is implemented on the three colour channels of the spectrogram. Then, three coefficient matrices R 1 , G 1 and B 1 are obtained.
Step 3: The chaotic sequence X is sampled according to Eq. 15 to obtain the sequence X 1 , where M = N = 512. Then the chaos-based measurement matrix φ is constructed by combining the steps given in Sect. 2.3. Step 4: First, the coefficient matrices R 1 , G 1 and B 1 are reconstructed into one-dimensional matrices R 2 , G 2 and B 2 . Then, compression measurements are performed on matrices R 2 , G 2 and B 2 , as shown in Eq. 16.
Step 5: The matrices R 3 , G 3 and B 3 generated after measurement are quantized to obtain the secret image. The quantization formula is given by Eq. 17.

Encryption process
Step 1: According to Section 2.4, dynamic Josephus scrambling is performed on the three channels R 4 , G 4 Step 2: The chaotic sequences W and V are sampled to obtain diffusion indices W 1 and V 1 . .
Step 3: First, the matrices R 5 , G5 and B 5 are converted to one-dimensional vectors R 6 , G 6 and B 6 . Second, R 6 , G 6 and B 6 are laterally diffused according to Eq. 20.
Finally, vertical diffusion, as shown in Eq. 21 is performed on the diffused matrices R 7 , G 7 and B 7 to complete encryption (the formulas all take R 6 as an example). The schematic diagram of annular diffusion is displayed in Fig. 12.

Embedding process
Step 1: The three channel matrices R 8 , G 8 and B 8 of the cipher image are converted into binary matrices R 9 , Step 2: According to Eq. 22, the alpha channel matrix A is constructed and then converted into a binary matrix A .
where ones(•) is used to generate the all-one matrix.
Step 3: In combination with the rules stipulated in Eq. 23, matrices R 9 , G 9 and B 9 are embedded into matrices R , G , B and A , respectively.
where H and L represent the upper half pixel block and the lower half pixel block of the carrier image, respectively.
Step 4: The steganographic image Q with visual safety significance is generated by combining the colour matrices R , G , B and alpha matrices A . The decryption and encryption procedures are reversible, and the keys required are the same for both procedures.

Experimental simulation and security analysis
To estimate the confidentiality and compression performance of our designed encryption system, a spectrogram with a pixel size of 512 × 1024 × 3 was chosen as the plain image, which contained fine solar radio burst data. For the carrier image, we selected a colour image with coronal mass ejection recorded, and its pixel size was 1024×1024×3. Figure 13 presents the corresponding simulation results. We can clearly determine that the encrypted spectrogram is completely irregular and has no visual connection to the original spectrogram. Furthermore, there is no intuitive discrepancy between the steganographic image and the carrier image. The decrypted spectrogram obtained by extracting, decrypting and reconstructing the steganographic image also contains most of the effective information of the original spectrogram.
To quantitatively measure the information hiding effect and compression performance of the visual security algorithm, we calculated the peak signal-tonoise ratio (PSNR) and normalized mean squared error (NMSE) between the cipher image and the original spectrogram and between the steganographic image and the carrier image. PSNR and NMSE are used to represent the similarity between the original image and the reconstructed image. The larger the PSNR, the smaller the NMSE, and the better the reconstructed quality will be. The results are listed in Table 2. Equation 24 gives the calculation formulas of PSNR and NMSR. The experimental data prove that our proposed visual security algorithm exhibits a perfect compression effect and reconstruction quality. (24)

The influence of chaotic system on visual security algorithm
The construction of a reasonable measurement matrix plays an indispensable role in the compression performance and reconstruction quality of the encryption algorithm. In this study, the measurement matrix is constructed by the chaotic sequence produced through our designed chaotic system. Therefore, the parameter changes of the chaotic system will have a corresponding influence on the performance of the visual security cryptosystem. We make two parameters a and b of the chaotic system vary between [5,14] and [14,21], respectively, while keeping other parameters unchanged. The PSNR between the encrypted images and original images, the steganographic images and carrier images were simulated and analyzed, and the analysis curves are given in Fig. 14a-d. Apparently, the chaotic system we proposed presents stable dynamic characteristics, and the change in system parameters does not lead to a significant decrease in compression performance and reconstruction quality. Additionally, imposing changes to the variables of the chaotic system has a negligible effect on the encrypted algorithm.

Statistical attack analysis
Statistical attacks are often used by attackers to attack various vulnerabilities in encryption systems. We conducted three main analyses to measure the effectiveness of the encryption scheme through the following histograms, correlation, and information entropy.

Histogram analysis
Unprocessed images generally have very obvious features, and most of their grey values are closely related, which may only be distributed around several grey values. After the encryption process, the correlation between these grey values is destroyed, and the pixel value will be distributed more evenly, which greatly increases the difficulty of deciphering. Figure 15ac gives the histograms of the spectrogram and the encrypted spectrogram in three channels R, G and B. Figure 15d-f displays the histograms of the carrier image and the steganographic image in three colour channels.
Clearly, the histogram distribution characteristics of the encrypted spectrogram are completely hidden, making it difficult for hackers to obtain valuable radio burst data. Meanwhile, the histogram distributions of the carrier image and steganographic image are basically not different, which presents splendid visual security. Consequently, the visual security cryptosystem we designed can effectively protect against histogram attacks.

Correlation analysis
The correlation between adjacent pixels for the original spectrogram to be encrypted is very high, which means that the grey values of adjacent pixels are very close. An attacker can use adjacent pixel values to infer the original images. Breaking this correlation has become the ultimate goal of encryption. The equation of the correlation coefficient can be described as follows.
where w and v represent the values of adjacent pixels and Q wv represents the correlation coefficient. Table 3 gives the correlation coefficients of the original spectrogram and the corresponding encrypted spectrogram in three different directions and is compared with the literature [34,35]. Figure 16 more intuitively exhibits the pixel distribution law of the encrypted spectrogram after encryption by our proposed cryptosystem. Obviously, the correlation coefficients between adjacent pixels of the encrypted spectrogram are all approximately 0, which has better encryption performance than the algorithms proposed in the literature [34,35]. In addition, the pixel distribution of the encrypted spectrogram is also spread over the whole area. It is difficult for an attacker to find the law of deciphering the encryption system from the correlation distribution between adjacent pixels. Therefore, the scheme designed in this paper can break pixel correlation and defend various attack techniques effectively.

Information entropy analysis
As a standard index of system information content, information entropy reflects the ordering degree of the whole image pixels. The greater the information entropy, the more difficult it is for the image to be deciphered by the entropy attack. Information entropy is defined as Eq. 26.
where g(e) represents the probability of e and L represents the total amount of symbol n i . Table 4 lists the information entropy of the spectrogram and the corresponding cipher image in each colour channel and compares the performance with the literature [34][35][36][37][38]. Clearly, after being encrypted by our visual security algorithm, the information entropy of the encrypted spectrogram is closer to the theoretical value of 8. The useful information of the original image is effectively disturbed by the scrambling and diffusion process, which makes it extremely difficult to extract the original information. Therefore, we can conclude that the algorithm we have designed is effective in breaking the aggregation distribution of image pixels and defending against entropy attacks.

Sensitivity analysis of plain image
Plaintext sensitivity compares the difference in the cipher image generated by encrypting the original image with only minor differences using the same algorithm. Scrambling and diffusing the spectrogram to disrupt its pixel values and correlation distribution is an important method to resist chosen-plaintext attacks.
To verify the sensitivity of the encryption algorithm to plaintext, we randomly pick a pixel of the spectrogram and randomly add 1 to it. Then, the encryption experiment was implemented on the spectrogram, and the Number of Pixels Change Rate (NPCR) and the Unified Average Changing Intensity (UACI) of the corresponding original image were calculated. NPCR and where U and V are the size of the spectrogram and F 1 (u, v) and F 2 (u, v) are the grayscale values of the corresponding cipher image, which differ by only one pixel.
After changing only one pixel of the original spectrogram, the resulting NPCR and UACI between the corresponding encrypted spectrogram are displayed in Table 5. Obviously, the NPCR and UACI of our algorithm are closer to the theoretical values of 99.61% and 33.46%, respectively, than in the literature [34,35,39,40]. The position and intensity of each pixel corresponding to the original image and the encrypted image have changed. Not only does the scrambling and diffusion process change the pixels of the image, but compressive sensing also contributes. Therefore, even a subtle difference in the original spectrogram will lead to an entirely different encrypted spectrogram.

Data loss attack analysis
In the image transmission procedure, if some pixels of the encrypted image are clipped maliciously, the reconstruction quality will inevitably decline. Hence, a perfect encryption algorithm is supposed to recover the original data from the cropped image as much as possible. Figure 17a-c shows the reconstructed images   Figure 18 shows the reconstructed spectrograms under pixel loss of different volumes. Obviously, even though the cipher images lose some data, our cryptosystem can still recover much effective information. The conclusions testify that our encryption algorithm is able to defend against high-intensity pixel loss attacks and is very suitable for secure image transmission.

Compression performance analysis
The essence of compressed sensing theory is to reduce the sampling rate to decrease the amount of information, which will inevitably lead to a reduction in reconstruction quality [41]. In addition, dividing the encrypted images into blocks will inevitably affect the quality of image reconstruction. Therefore, we conducted encryption experiments on multiple spectrograms and colour Lena images under different compression rates and block volumes to measure the compression ability of the visual security algorithm. Table 6 compares the experimental results in this paper with the literature [5,[42][43][44]. We can see that our algorithm has a higher PSNR than in the literature [5,[42][43][44]. Figure 19 shows the encrypted spectrograms and the corresponding reconstructed spectrograms at compression rates of 0.8, 0.65 and 0.5. We can conclude that as the compression ratio increases, in spite of the reconstruction quality of the image deteriorating, a huge amount of the efficient data of the original spectrograms can still be obtained. Figure 20a, b displays the PSNR variation curves of the multiple spectrograms and colour Lena image under different compression rates and different block volumes, respectively. Obviously, our encryption algorithm has a high PSNR. Therefore, our method can better reconstruct the original image with good compression performance. This is because our algorithm employs fully reversible embedding and extraction operations.

Visual safety analysis
The correlation distribution of the grey value of the steganography image should be highly similar to that of the carrier image [45]. To verify its performance, multi- ple spectrograms and colour Lena images were selected and input into the encryption system we designed and then embedded into the carrier images to acquire the steganographic images. Finally, the similarity between them was qualitatively analyzed by PSNR and NMSE. Table 7 lists the specific simulation conclusions. Obviously, compared with the literature [5,43,44], the algorithm we proposed has higher PSNR and presents better visual security. Furthermore, the gray value distribution of the carrier image and steganography image has been simulated and are given in Fig. 21a-f. It can be seen that the pixel distribution of the carrier image and stegano-graphic image is very similar, and they are both on the diagonal. This is because the algorithm adopts the LSB algorithm to embed the pixels of the encrypted image into the low position and alpha channel of the carrier image, which basically has no impact on the pixels of the carrier image. Therefore, the algorithm has good visual security and cannot intuitively see any effective information from steganographic image.

Conclusion
Based on the five-dimensional chaotic system, BCS and LSB, a new spectrogram visual security encryption algorithm is proposed. First, the algorithm uses DWT and BCS to compress and preencrypt the spectrogram. Second, the secret image is secondarily encrypted using dynamic Josephus scrambling and annular diffusion. Finally, we embed the encrypted image into the carrier image by using the improved LSB and alpha channel synchronous embedding to obtain the steganographic image. Furthermore, to heighten the sensitivity of our encryption algorithm to plain images, the SHA-256 function has been introduced to construct the initial keys required by the cryptosystem. The experimental Fig. 21 Correlation distribution for three components of the carrier image: a horizontal, b diagonal, c vertical; Correlation distribution for three components of the steganographic image: d horizontal, e diagonal, f vertical analysis proves that the image visual security algorithm has adequate encryption performance and security. It can defend against various conventional attack methods. Moreover, our technique can hide the distribution law of pixel grey values in solar radio spectrograms effectively and ensure information security during spectrogram transmission.
Publisher's Note Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.
Springer Nature or its licensor (e.g. a society or other partner) holds exclusive rights to this article under a publishing agreement with the author(s) or other rightsholder(s); author self-archiving of the accepted manuscript version of this article is solely governed by the terms of such publishing agreement and applicable law.