CN112261239B - Plaintext related image encryption method based on PUD adaptive decomposition - Google Patents

Plaintext related image encryption method based on PUD adaptive decomposition Download PDF

Info

Publication number
CN112261239B
CN112261239B CN202010988855.5A CN202010988855A CN112261239B CN 112261239 B CN112261239 B CN 112261239B CN 202010988855 A CN202010988855 A CN 202010988855A CN 112261239 B CN112261239 B CN 112261239B
Authority
CN
China
Prior art keywords
image
pud
plaintext
pseudo
original
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202010988855.5A
Other languages
Chinese (zh)
Other versions
CN112261239A (en
Inventor
吴永飞
刘西林
岳俊宏
周稻祥
高佩婷
李明
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Taiyuan University of Technology
Original Assignee
Taiyuan University of Technology
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Taiyuan University of Technology filed Critical Taiyuan University of Technology
Priority to CN202010988855.5A priority Critical patent/CN112261239B/en
Publication of CN112261239A publication Critical patent/CN112261239A/en
Application granted granted Critical
Publication of CN112261239B publication Critical patent/CN112261239B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N1/00Scanning, transmission or reproduction of documents or the like, e.g. facsimile transmission; Details thereof
    • H04N1/32Circuits or arrangements for control or supervision between transmitter and receiver or between image input and image output device, e.g. between a still-image camera and its memory or between a still-image camera and a printer device
    • H04N1/32101Display, printing, storage or transmission of additional information, e.g. ID code, date and time or title
    • H04N1/32144Display, printing, storage or transmission of additional information, e.g. ID code, date and time or title embedded in the image data, i.e. enclosed or integrated in the image, e.g. watermark, super-imposed logo or stamp
    • H04N1/32149Methods relating to embedding, encoding, decoding, detection or retrieval operations
    • H04N1/32267Methods relating to embedding, encoding, decoding, detection or retrieval operations combined with processing of the image
    • H04N1/32272Encryption or ciphering
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/002Countermeasures against attacks on cryptographic mechanisms
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/08Key distribution or management, e.g. generation, sharing or updating, of cryptographic keys or passwords
    • H04L9/0861Generation of secret information including derivation or calculation of cryptographic keys or passwords
    • H04L9/0869Generation of secret information including derivation or calculation of cryptographic keys or passwords involving random numbers or seeds

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Signal Processing (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Multimedia (AREA)
  • Storage Device Security (AREA)

Abstract

本发明涉及一种基于PUD自适应分解的明文相关图像加密方法,将明文图像进行自适应PUD分解,对分解后的二维分量进行置乱‑扩散操作。本方法采用的加密密钥与明文相关,获得加密图像能够高效的抵抗选择明文攻击,选择密文攻击,同时对滤波噪声攻击,剪切攻击以及差分攻击方面有较强的鲁棒性,进一步提高加密图像的安全性和鲁棒性,可应用于图像安全、图像保密通信领域。

Figure 202010988855

The invention relates to a plaintext-related image encryption method based on PUD adaptive decomposition. The plaintext image is subjected to adaptive PUD decomposition, and a scrambling-diffusion operation is performed on the decomposed two-dimensional components. The encryption key used in this method is related to the plaintext, and the encrypted image can be effectively resisted against the chosen plaintext attack and the chosen ciphertext attack, and at the same time, it has strong robustness to the filtering noise attack, shearing attack and differential attack, which further improves the The security and robustness of encrypted images can be applied to the fields of image security and image security communication.

Figure 202010988855

Description

一种基于PUD自适应分解的明文相关图像加密方法A PUD Adaptive Decomposition-Based Plaintext Related Image Encryption Method

技术领域technical field

本发明涉及图像加密技术领域,更具体地说,涉及一种基于PUD 自适应分解的明文相关图像加密方法。The invention relates to the technical field of image encryption, and more particularly, to a plaintext related image encryption method based on PUD adaptive decomposition.

背景技术Background technique

随着计算机网络和通信技术的迅猛发展,多媒体内容如数字图像,视频序列和音频信号的使用和交换呈现出爆炸性增长的趋势。而作为视觉多媒体内容的数字图像已被广泛用于许多领域,包括医疗,商业和军事。针对这些应用,数字图像通过公共通道传输以及在云平台上存储必须保证图像的安全性,并且只能由授权机构访问。因此,数字图像的安全性问题变得越来越重要,已经成为一个亟待解决的问题。With the rapid development of computer network and communication technology, the use and exchange of multimedia content such as digital images, video sequences and audio signals has shown an explosive growth trend. And digital images as visual multimedia content have been widely used in many fields, including medical, commercial and military. For these applications, the transmission of digital images through public channels and storage on cloud platforms must ensure image security and can only be accessed by authorized agencies. Therefore, the security of digital images becomes more and more important and has become an urgent problem to be solved.

数字图像不同于传统的文本消息,其具有数据容量大、相邻像素间相关性强、冗余度高等特性,因此,传统文本加密算法如AES、 DES等不再适用于图像加密。目前,图像加密方法可以大体上分为基于空间域和基于变换域两类加密方法。在这两类加密域中通常使用的加密操作为置乱-扩散操作。由于基于空间域的加密算法通常具有有限的密钥空间并且对于经典的统计攻击是不安全的中的排列扩,因此,基于空间域的加密算法不能满足安全性要求。为了克服这些限制,在变换域中使用基于置换扩散的图像加密技术,例如傅里叶变换(FT),离散余弦变换(DCT)和离散小波变换(DWT),可实现更好的安全性。然而,由于这些基于变换域的加密算法在变换图像的过程中通常使用固定的基函数(三角函数,小波函数),因此基于变换域的图像加密算法也存在着安全性低易于被破解的风险。Different from traditional text messages, digital images have the characteristics of large data capacity, strong correlation between adjacent pixels, and high redundancy. Therefore, traditional text encryption algorithms such as AES and DES are no longer suitable for image encryption. At present, image encryption methods can be roughly divided into two types of encryption methods based on spatial domain and based on transform domain. The cryptographic operations commonly used in these two types of cryptographic domains are scrambling-diffusion operations. Since spatial domain-based encryption algorithms usually have a limited key space and are insecure against classical statistical attacks, the spatial domain-based encryption algorithms cannot meet the security requirements. To overcome these limitations, better security is achieved using permutation diffusion-based image encryption techniques, such as Fourier Transform (FT), Discrete Cosine Transform (DCT), and Discrete Wavelet Transform (DWT), in the transform domain. However, since these transform domain-based encryption algorithms usually use fixed basis functions (trigonometric functions, wavelet functions) in the process of transforming images, transform domain-based image encryption algorithms also have the risk of low security and easy to be cracked.

为了设计安全性强的图像加密方法,基于传统的变换域(如离散 FT变换、DCT变换、DWT变换等)对图像进行加密很难进一步提高算法的安全性和可靠性。In order to design an image encryption method with strong security, it is difficult to further improve the security and reliability of the algorithm by encrypting images based on traditional transform domains (such as discrete FT transform, DCT transform, DWT transform, etc.).

发明内容SUMMARY OF THE INVENTION

为克服现有技术的不足,本发明提供了基于PUD自适应分解的明文相关图像加密方法,该方法对噪声攻击,剪切和差分攻击方面有较强的鲁棒性,可应用于图像加密保护、图像保密通信领域。In order to overcome the deficiencies of the prior art, the present invention provides a plaintext related image encryption method based on PUD adaptive decomposition, the method has strong robustness to noise attack, clipping and differential attack, and can be applied to image encryption protection. , the field of image security communication.

本发明通过以下技术方案实现:本发明提供一种基于PUD自适应分解的明文相关图像加密方法,包括步骤:The present invention is achieved through the following technical solutions: the present invention provides a clear text related image encryption method based on PUD adaptive decomposition, comprising steps:

步骤1)取待加密的原始明文图像,设置分解次数为N,利用伪随机数生成器生成伪随机序列;Step 1) take the original plaintext image to be encrypted, set the number of times of decomposition as N, and utilize a pseudo-random number generator to generate a pseudo-random sequence;

步骤2)对原始明文图像进行PUD自适应分解:Step 2) Perform PUD adaptive decomposition on the original plaintext image:

根据PUD分解技术对原始明文图像分解,得到三部分分量,分别为一个二维分量,两个一维分量以及原始明文图像的灰度平均值;The original plaintext image is decomposed according to the PUD decomposition technology, and three components are obtained, which are a two-dimensional component, two one-dimensional components and the grayscale average value of the original plaintext image;

步骤3)图像加密操作:Step 3) Image encryption operation:

对原始明文图像分解后得到的二维分量,采用置乱-扩散的方式对其进行加密,采用的密钥是灰度平均值和经过随机化操作的两个一维分量,最终得到加密图像。The two-dimensional components obtained by decomposing the original plaintext image are encrypted by scrambling-diffusion method.

其中,步骤1)利用伪随机数生成器生成伪随机序列的步骤中,采用伪随机数生成器产生256比特大小的伪随机数序列。Wherein, in step 1) in the step of generating a pseudo-random sequence by using a pseudo-random number generator, a pseudo-random number sequence with a size of 256 bits is generated by using a pseudo-random number generator.

其中,步骤1)获取待加密的原始明文图像之后,包括对所述原始明文图像进行插值化的步骤,以将所述原始明文图像转化为像素值格式为M*M的格式。Wherein, step 1) includes the step of interpolating the original plaintext image after obtaining the original plaintext image to be encrypted, so as to convert the original plaintext image into a format with a pixel value format of M*M.

其中,在步骤2)对原始明文图像进行PUD自适应分解,得到两个一维分量后,包括步骤:Wherein, in step 2), the PUD adaptive decomposition is performed on the original plaintext image, and after two one-dimensional components are obtained, the following steps are included:

对两个一维分量F1,G1随机化操作,分别与所述伪随机数生成器生成的伪随机序列执行异或操作,得到新的一维分量F2,G2Randomize the two one-dimensional components F 1 , G 1 , and perform an exclusive OR operation with the pseudo-random sequence generated by the pseudo-random number generator to obtain new one-dimensional components F 2 , G 2 .

其中,步骤3)具体包括以下步骤:Wherein, step 3) specifically includes the following steps:

步骤3a)使用置乱算法将二维分量的像素值进行全局置乱,改变相邻像素的相似性关系;Step 3a) use scrambling algorithm to perform global scrambling on the pixel value of the two-dimensional component, and change the similarity relationship of adjacent pixels;

步骤3b)采用扩散算法,对置乱后的二维分量的像素值进行改变,使得加密后的像素值与初始二维分量像素值不同,保证图像的安全性。Step 3b) adopts a diffusion algorithm to change the pixel value of the scrambled two-dimensional component, so that the encrypted pixel value is different from the original two-dimensional component pixel value, so as to ensure the security of the image.

其中,置乱算法为Arnold变换。Among them, the scrambling algorithm is Arnold transform.

其中,扩散算法采用异或操作的方式。Among them, the diffusion algorithm adopts the way of XOR operation.

其中,加密算法与解密算法相对应,在图像解密算法中,相反操作来正确恢复解密图像。Among them, the encryption algorithm corresponds to the decryption algorithm, and in the image decryption algorithm, the reverse operation is performed to correctly restore the decrypted image.

与现有技术相比,本发明具有如下有益效果:Compared with the prior art, the present invention has the following beneficial effects:

本发明提出基于PUD自适应分解的明文相关图像加密算法;由于PUD分解方法的自适应属性,对于不同的图像,得到的一维分量完全不。即使对于同一幅图像,也可以通过设置不同的分解次数,使得图像分解后得到的一维分量不同。因此,可以利用与明文相关的序列对图像进行加密。该技术能够有效的抵抗选择明文攻击,选择密文攻击。对噪声攻击、剪切攻击以及差分攻击方面有较强的鲁棒性,具有较高的图像保密的安全性和鲁棒性,可应用于高级别的图像安全、图像保密通信领域。The invention proposes a plaintext related image encryption algorithm based on PUD adaptive decomposition; due to the adaptive property of the PUD decomposition method, for different images, the obtained one-dimensional components are completely different. Even for the same image, different one-dimensional components can be obtained after image decomposition by setting different times of decomposition. Thus, the image can be encrypted with a sequence associated with the plaintext. This technology can effectively resist chosen plaintext attack and chosen ciphertext attack. It has strong robustness to noise attack, clipping attack and differential attack, and has high security and robustness of image confidentiality, and can be applied to high-level image security and image confidentiality communication fields.

附图说明Description of drawings

下面将结合附图及实施例对本发明作进一步说明,附图中:The present invention will be further described below in conjunction with the accompanying drawings and embodiments, in which:

图1是本发明提供的一种基于PUD自适应分解的明文相关图像加密算法的流程示意图。FIG. 1 is a schematic flowchart of a plaintext related image encryption algorithm based on PUD adaptive decomposition provided by the present invention.

图2是本发明提供的一种基于PUD自适应分解的明文相关图像加密算法处理的原始图。FIG. 2 is an original diagram of a plaintext related image encryption algorithm processing based on PUD adaptive decomposition provided by the present invention.

图3是本发明提供的一种基于PUD自适应分解的明文相关图像加密算法中对原始图像加密后的图像。FIG. 3 is an image after encrypting the original image in a plaintext related image encryption algorithm based on PUD adaptive decomposition provided by the present invention.

图4是本发明提供的一种基于PUD自适应分解的明文相关图像加密算法图2原始图像的直方图效果图。FIG. 4 is a histogram effect diagram of the original image of FIG. 2 based on a PUD adaptive decomposition-based plaintext related image encryption algorithm provided by the present invention.

图5是本发明提供的一种基于PUD自适应分解的明文相关图像加密算法中图3加密后的图像的直方图效果图FIG. 5 is a histogram effect diagram of the encrypted image in FIG. 3 in a plaintext related image encryption algorithm based on PUD adaptive decomposition provided by the present invention

图6是本发明提供的一种基于PUD自适应分解的明文相关图像加密算法对加密图像添加高斯噪声后的解密图像。FIG. 6 is a decrypted image after adding Gaussian noise to the encrypted image by a plaintext related image encryption algorithm based on PUD adaptive decomposition provided by the present invention.

图7是本发明提供的一种基于PUD自适应分解的明文相关图像加密算法对加密图像添加椒盐噪声后的解密图像。FIG. 7 is a decrypted image after adding salt and pepper noise to the encrypted image by a plaintext related image encryption algorithm based on PUD adaptive decomposition provided by the present invention.

图8是本发明提供的一种基于PUD自适应分解的明文相关图像加密算法中对加密图像的裁剪区域示意图。FIG. 8 is a schematic diagram of a cropped region of an encrypted image in a plaintext related image encryption algorithm based on PUD adaptive decomposition provided by the present invention.

图9是本发明提供的一种基于PUD自适应分解的明文相关图像加密算法按图8区域裁剪后的示意图。FIG. 9 is a schematic diagram of a plaintext related image encryption algorithm based on PUD adaptive decomposition provided by the present invention after cropping according to the area of FIG. 8 .

图10是本发明提供的一种基于PUD自适应分解的明文相关图像加密算法中原始明文图像(图2)经过一个随机bit改变的图像。FIG. 10 is an image of the original plaintext image (FIG. 2) changed by a random bit in a plaintext related image encryption algorithm based on PUD adaptive decomposition provided by the present invention.

图11是本发明提供的一种基于PUD自适应分解的明文相关图像加密算法中原始明文图像的密文图像。FIG. 11 is a ciphertext image of an original plaintext image in a plaintext related image encryption algorithm based on PUD adaptive decomposition provided by the present invention.

图12是本发明提供的一种基于PUD自适应分解的明文相关图像加密算法的改变图像后的密文图像。FIG. 12 is a ciphertext image after changing the image of a plaintext related image encryption algorithm based on PUD adaptive decomposition provided by the present invention.

图13是本发明提供的一种基于PUD自适应分解的明文相关图像加密算法的两幅密文图像的绝对差值。FIG. 13 is the absolute difference between two ciphertext images of a plaintext related image encryption algorithm based on PUD adaptive decomposition provided by the present invention.

具体实施方式Detailed ways

为了对本发明的技术特征、目的和效果有更加清楚的理解,现对照附图详细说明本发明的具体实施方式。In order to have a clearer understanding of the technical features, objects and effects of the present invention, the specific embodiments of the present invention will now be described in detail with reference to the accompanying drawings.

如图1所示,本实施例所述的基于PUD自适应分解的明文相关图像加密方法,包括如下步骤:As shown in FIG. 1 , the method for encrypting plaintext related images based on PUD adaptive decomposition described in this embodiment includes the following steps:

步骤1)伪随机数序列的产生:Step 1) Generation of pseudo-random number sequence:

利用已有的随机数生成器,产生512比特大小的伪随机数序列;Use the existing random number generator to generate a pseudo-random number sequence with a size of 512 bits;

步骤2)明文图像的分解:Step 2) Decomposition of the plaintext image:

采用PUD分解技术对原始明文图像进行分解,得到三部分分量,分别为一个二维分量,两个一维分量以及图像的灰度平均值;The original plaintext image is decomposed by PUD decomposition technology, and three components are obtained, which are a two-dimensional component, two one-dimensional components and the average gray level of the image;

步骤3)图像加密的操作:Step 3) Operation of image encryption:

针对PUD技术分解原始明文图像得到的二维分量,进行置乱-扩散操作,最终得到加密图像。Aiming at the two-dimensional components obtained by decomposing the original plaintext image by PUD technology, scrambling-diffusion operation is performed, and finally an encrypted image is obtained.

优选地,所述步骤2)具体包括以下步骤:Preferably, the step 2) specifically includes the following steps:

步骤2a)将原始明文图像进行PUD分解,得到三部分分量,其中包括一个二维分量,两个一维分量及原始图像的灰度平均值。Step 2a) Perform PUD decomposition on the original plaintext image to obtain three-part components, including one two-dimensional component, two one-dimensional components and the grayscale average value of the original image.

步骤2b)采用模运算将图像的灰度平均值处理,得到两个广义 Arnold变换的参数。In step 2b), the average value of the gray level of the image is processed by modulo operation to obtain two parameters of the generalized Arnold transform.

步骤2c)将两个一维分量与步骤1)生成的伪随机数序列进行异或操作,得到两个随机序列。Step 2c) XOR the two one-dimensional components with the pseudo-random number sequence generated in step 1) to obtain two random sequences.

优选地,所述步骤3)具体包括以下步骤:Preferably, the step 3) specifically includes the following steps:

步骤3a)针对二维分量的空间像素进行置乱操作,得到置乱图像;优选地,所采用的置乱算法为Arnold变换;Step 3a) scrambling operation is performed for the spatial pixels of the two-dimensional component to obtain a scrambling image; preferably, the scrambling algorithm adopted is Arnold transformation;

步骤3b)针对置乱后的图像分别用两个随机化的一位序列进行行与列的异或操作,对图像进行扩散,得到加密图像。Step 3b) For the scrambled image, use two randomized one-bit sequences to perform the row and column XOR operation respectively, and diffuse the image to obtain an encrypted image.

优选地,所述的明文相关的图像加密方法,在图像加密过程中需要设置分解次数,对于同一幅图像,可以设置不同的分解次数,以便产生完全不同的密钥,进一步产生完全不同的加密图像。Preferably, in the image encryption method related to plaintext, the number of times of decomposition needs to be set during the image encryption process. For the same image, different times of decomposition can be set to generate completely different keys and further generate completely different encrypted images. .

具体的,步骤1)中具体包括伪随机数序列的产生,利用伪随机数生成器生成一个长度为512bit的伪随机数序列K。Specifically, step 1) specifically includes the generation of a pseudo-random number sequence, and a pseudo-random number sequence K with a length of 512 bits is generated by using a pseudo-random number generator.

步骤2)中具体包括图像的PUD分解算法,包括步骤如下:In step 2), the PUD decomposition algorithm of the image is specifically included, and the steps are as follows:

Step 2.1:选择分解次数,将原始明文图I像进行分解,得到三部分分量,分别为二维分量P,一维分量F1,G1,原始图像的灰度平均值C00Step 2.1: Select the number of decomposition times, decompose the original plaintext image I, and obtain three components, which are the two-dimensional component P, the one-dimensional components F 1 , G 1 , and the grayscale average value C 00 of the original image.

Step 2.2:将分解后得到图像灰度平均值C00进行如下方式的两次模运算,得到广义Arnold变化的两个参数p,q;Step 2.2: Perform two modulo operations on the average value C 00 of the image gray level obtained after decomposition to obtain the two parameters p, q of the generalized Arnold change;

p=mod(c00×1015,255)p=mod(c 00 ×10 15 ,255)

q=mod(c00×1017,255)q=mod(c 00 ×10 17 ,255)

Step 2.3:将原始图像分解后得到的两个一维分量F1,G1与伪随机序列K进行异或操作,得到两个随机序列F2,G2Step 2.3: Perform XOR operation on the two one-dimensional components F 1 , G 1 obtained after decomposing the original image with the pseudo-random sequence K to obtain two random sequences F 2 , G 2 .

Figure BDA0002690157510000061
Figure BDA0002690157510000061

Figure BDA0002690157510000062
Figure BDA0002690157510000062

所述的步骤3)中具体包括图像加密算法,包括步骤如下:Described step 3) specifically includes image encryption algorithm, including steps as follows:

Step 3.1:将二维分量P中的像素位置,利用Arnold变换进行如下方式的置乱变换,得到置乱后的图像P'。Step 3.1: Use the Arnold transform to perform the following scrambling transformation on the pixel positions in the two-dimensional component P to obtain the scrambled image P'.

Figure BDA0002690157510000063
Figure BDA0002690157510000063

Step 3.2:对置乱图像P',分别采用F2,G2按照行异或与列异或,最终得到加密图像。Step 3.2: For the scrambled image P', use F 2 and G 2 respectively according to row XOR and column XOR, and finally obtain an encrypted image.

选取如图2所示的Lena图像作为原始明文图像,选择分解次数为 N=5。The Lena image shown in Figure 2 is selected as the original plaintext image, and the number of times of decomposition is selected as N=5.

步骤一:伪随机数序列K的产生,本步骤实现了加密密钥的产生。Step 1: the generation of the pseudo-random number sequence K, this step realizes the generation of the encryption key.

本步骤采用随机数生成器,产生长度为256bit的密钥K为:This step uses a random number generator to generate a key K with a length of 256 bits:

K='9F7ED402FBF47A4F91F44824E7288A684849B3E8C5F495384 96A3A83131373A5A510F5FF5DEDC6CD838DB139FB31E11D982C51 48C7A53B8380CB49AD6ADAC4D7'(十六进制形式)。K='9F7ED402FBF47A4F91F44824E7288A684849B3E8C5F495384 96A3A83131373A5A510F5FF5DEDC6CD838DB139FB31E11D982C51 48C7A53B8380CB49AD6ADAC4D7' (hexadecimal form).

步骤二:原始明文图像的PUD分解:Step 2: PUD decomposition of the original plaintext image:

所述的步骤二中具体包括图像的PUD分解,包括步骤如下:Described step 2 specifically includes the PUD decomposition of the image, including the steps as follows:

Step 1:将输入的明文图像分解N次,得到二维分量P,一维分量 F1,G1,原始图像的灰度平均值C00Step 1: Decompose the input plaintext image N times to obtain the two-dimensional component P, the one-dimensional components F 1 , G 1 , and the grayscale average value C 00 of the original image.

I=P+F1+G1+C00 I=P+F 1 +G 1 +C 00

以实验为例,将256×256大小的Lena图像进行5次分解,将得到256×256大小的二维分量,两个256长的一维分量F1,G1,以及明文图像的灰度平均值C00Taking the experiment as an example, the Lena image of size 256×256 is decomposed 5 times, and the two-dimensional component of size 256×256, two one-dimensional components F 1 , G 1 of 256 length, and the average gray level of the plaintext image will be obtained. value C 00 .

Step 2:将图像灰度平均值C00进行取模运算,得到用于对图像置乱阶段的两个参数,如下所示:Step 2: Perform the modulo operation on the average value of the image gray level C 00 to obtain two parameters for the image scrambling stage, as shown below:

p=mod(C00×1015,255)p=mod(C 00 ×10 15 ,255)

q=mod(C00×1017,255)q=mod(C 00 ×10 17 ,255)

Step 3:对两个分量F1,G1与密钥K进行异或操作,得到两个随机序列F2,G2,如下所示:Step 3: Perform XOR operation on the two components F 1 , G 1 and the key K to obtain two random sequences F 2 , G 2 , as shown below:

Figure BDA0002690157510000071
Figure BDA0002690157510000071

Figure BDA0002690157510000072
Figure BDA0002690157510000072

步骤三:对二维分量加密,所述的步骤三中具体包括认证信息的提取算法,包括步骤如下:Step 3: Encrypt the two-dimensional component, and the step 3 specifically includes an extraction algorithm for authentication information, including the following steps:

Step 1:将二维分量P中的像素位置,利用Arnold变换进行如下方式的置乱变换,得到置乱后的图像P'。Step 1: The pixel position in the two-dimensional component P is scrambled in the following manner by using Arnold transformation to obtain the scrambled image P'.

Figure BDA0002690157510000073
Figure BDA0002690157510000073

Step 2:对置乱图像P',分别采用F2,G2按照行异或于列异或,具体过程如下:Step 2: For the scrambled image P', use F 2 , G 2 respectively according to the row XOR and the column XOR, the specific process is as follows:

从第1行到第M行依次进行异或操作:The XOR operation is performed sequentially from line 1 to line M:

i=1:M;i=1:M;

temp=P’(i,:);temp = P'(i,:);

P’(i,:)=P’(i,:)bitxor F2 P'(i,:)=P'(i,:)bitxor F 2

从第1列到第M列依次进行异或操作:The XOR operation is performed sequentially from column 1 to column M:

j=1:M;j=1:M;

temp=P’(:,j);temp=P'(:,j);

P’(:,j)=P’(:,j)bitxor G2 P'(:,j)=P'(:,j)bitxor G 2

最终得到密文图像C。Finally, the ciphertext image C is obtained.

如图2-3所示,其中图2为原始图像,图3为加密后的图像。As shown in Figure 2-3, Figure 2 is the original image and Figure 3 is the encrypted image.

结合图4-5来看,图4为Lena原始明文图像的直方图,可以看出像素值的分布波动比较大,而加密后的密文图像的直方图如图5所示,不同灰度的分布频率是均匀的,直方图是平坦的,可以看出本实施例所述的加密方法能够较好的抵抗统计攻击,加密效果较好。Combined with Figure 4-5, Figure 4 is the histogram of the original plaintext image of Lena. It can be seen that the distribution of pixel values fluctuates greatly, and the histogram of the encrypted ciphertext image is shown in Figure 5. The distribution frequency is uniform, and the histogram is flat. It can be seen that the encryption method described in this embodiment can better resist statistical attacks, and the encryption effect is better.

图6和图7为对密文图像添加高斯噪声和椒盐噪声后得到的解密效果,图6为添加高斯噪声后的解密图像,图7为添加椒盐噪声后的解密图像,可以看出本实施例所述的加密方法能抵抗噪声攻击。Figures 6 and 7 show the decryption effect obtained by adding Gaussian noise and salt and pepper noise to the ciphertext image. Figure 6 is the decrypted image after adding Gaussian noise, and Figure 7 is the decrypted image after adding salt and pepper noise. It can be seen that this embodiment The encryption method described is resistant to noise attacks.

图8和图9为对密文图像进行裁剪后的得到解密效果,图8为对密文图像的裁剪区域,图9为对裁剪后的解密图像,可以看出本实施例所述的加密方法能剪切攻击。Figures 8 and 9 show the decryption effect after cutting the ciphertext image, Figure 8 shows the cropping area of the ciphertext image, Figure 9 shows the decrypted image after cutting, and it can be seen that the encryption method described in this embodiment Can cut attack.

在选择明文攻击的时候,攻击者会选取一副图像进行加密,然后对原始图像的像素值随机地改变1bit,并对改变后的图像进行加密,然后比较两幅加密图像的不同,以便发现密钥的线索。如果从Lena 图像中随机选取一个像素值,并且将其总的一位改变,那么由原始图像和改变后的图像得到的加密图像完全不同。如图10-13所示,图10 为原始Lena图像经过一个随机bit改变的图像,图11为原始Lena图像的密文图像,图12为改变图像的密文图像,图13为两幅密文图像的绝对值差。从图13可以看出,随机改变原始明文图像的一个随机位,得到的密文图像与原始图像的密文图像具有很大的差异,因此本实施例所述的方法能够有效地抵抗差分攻击。When choosing a plaintext attack, the attacker will select an image to encrypt, and then randomly change the pixel value of the original image by 1 bit, encrypt the changed image, and then compare the differences between the two encrypted images in order to find the encrypted image. key clue. If a pixel value is randomly selected from the Lena image and its total one bit is changed, the encrypted image obtained from the original image and the changed image is completely different. As shown in Figure 10-13, Figure 10 is the original Lena image changed by a random bit, Figure 11 is the ciphertext image of the original Lena image, Figure 12 is the ciphertext image of the changed image, and Figure 13 is two ciphertext images The absolute value difference of the image. As can be seen from Figure 13, by randomly changing a random bit of the original plaintext image, the obtained ciphertext image is very different from the ciphertext image of the original image, so the method described in this embodiment can effectively resist differential attacks.

由此可见,本发明对这几中图像攻击操作都具有很强的鲁棒性。It can be seen that the present invention has strong robustness to these several image attack operations.

上面结合附图对本发明的实施例进行了描述,但是本发明并不局限于上述的具体实施方式,上述的具体实施方式仅仅是示意性的,而不是限制性的,本领域的普通技术人员在本发明的启示下,在不脱离本发明宗旨和权利要求所保护的范围情况下,还可做出很多形式,这些均属于本发明的保护之内。The embodiments of the present invention have been described above in conjunction with the accompanying drawings, but the present invention is not limited to the above-mentioned specific embodiments, which are merely illustrative rather than restrictive. Under the inspiration of the present invention, without departing from the scope of protection of the present invention and the claims, many forms can be made, which all belong to the protection of the present invention.

Claims (4)

1.一种基于PUD自适应分解的明文相关图像加密方法,其特征在于,所述方法包括如下步骤:1. A plaintext related image encryption method based on PUD adaptive decomposition, is characterized in that, described method comprises the steps: 步骤1)取待加密的原始明文图像,设置分解次数为N,利用伪随机数生成器生成伪随机序列;利用伪随机数生成器生成伪随机序列的步骤中,采用伪随机数生成器产生256比特大小的伪随机数序列;获取待加密的原始明文图像之后,包括对所述原始明文图像进行插值化的步骤,以将所述原始明文图像转化为像素值格式为M*M的格式;Step 1) Take the original plaintext image to be encrypted, set the number of decompositions to N, and use the pseudo-random number generator to generate a pseudo-random sequence; in the step of using the pseudo-random number generator to generate the pseudo-random sequence, use the pseudo-random number generator to generate 256 A bit-sized pseudo-random number sequence; after obtaining the original plaintext image to be encrypted, the step of interpolating the original plaintext image is included, so as to convert the original plaintext image into a format whose pixel value format is M*M; 步骤2)对原始明文图像进行PUD自适应分解:Step 2) Perform PUD adaptive decomposition on the original plaintext image: 对原始明文图像进行PUD自适应分解,得到两个一维分量后,包括步骤:Perform PUD adaptive decomposition on the original plaintext image to obtain two one-dimensional components, including steps: 对两个一维分量F1,G1随机化操作,分别与所述伪随机数生成器生成的伪随机序列执行异或操作,得到新的一维分量F2,G2Randomize the two one-dimensional components F 1 , G 1 , and perform an exclusive OR operation with the pseudo-random sequence generated by the pseudo-random number generator to obtain new one-dimensional components F 2 , G 2 ; 根据PUD分解技术对原始明文图像分解,得到三部分分量,分别为一个二维分量,两个一维分量以及原始明文图像的灰度平均值;The original plaintext image is decomposed according to the PUD decomposition technology, and three components are obtained, which are a two-dimensional component, two one-dimensional components and the grayscale average value of the original plaintext image; 步骤3)图像加密操作:Step 3) Image encryption operation: 对原始明文图像分解后得到的二维分量,采用置乱-扩散的方式对其进行加密,采用的密钥是灰度平均值和经过随机化操作的两个一维分量,最终得到加密图像,具体包括以下步骤:The two-dimensional components obtained by decomposing the original plaintext image are encrypted by scrambling-diffusion method. Specifically include the following steps: 步骤3a)使用置乱算法将二维分量的像素值进行全局置乱,改变相邻像素的相似性关系;Step 3a) use a scrambling algorithm to globally scram the pixel values of the two-dimensional components to change the similarity relationship between adjacent pixels; 步骤3b)采用扩散算法,对置乱后的二维分量的像素值进行改变,使得加密后的像素值与初始二维分量像素值不同,保证图像的安全性。Step 3b) adopts a diffusion algorithm to change the pixel value of the scrambled two-dimensional component, so that the encrypted pixel value is different from the original two-dimensional component pixel value, so as to ensure the security of the image. 2.根据权利要求1所述的基于PUD自适应分解的明文相关图像加密方法,其特征在于,所述置乱算法为Arnold变换。2 . The plaintext related image encryption method based on PUD adaptive decomposition according to claim 1 , wherein the scrambling algorithm is Arnold transform. 3 . 3.根据权利要求1所述的基于PUD自适应分解的明文相关图像加密方法,其特征在于,所述扩散算法采用异或操作的方式。3 . The plaintext related image encryption method based on PUD adaptive decomposition according to claim 1 , wherein the diffusion algorithm adopts an exclusive OR operation. 4 . 4.根据权利要求1所述的基于PUD自适应分解的明文相关图像加密方法,其特征在于,加密算法与解密算法相对应,在图像解密算法中,相反操作来正确恢复解密图像。4. The plaintext-related image encryption method based on PUD adaptive decomposition according to claim 1, wherein the encryption algorithm corresponds to the decryption algorithm, and in the image decryption algorithm, the reverse operation is performed to correctly restore the decrypted image.
CN202010988855.5A 2020-09-18 2020-09-18 Plaintext related image encryption method based on PUD adaptive decomposition Active CN112261239B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010988855.5A CN112261239B (en) 2020-09-18 2020-09-18 Plaintext related image encryption method based on PUD adaptive decomposition

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010988855.5A CN112261239B (en) 2020-09-18 2020-09-18 Plaintext related image encryption method based on PUD adaptive decomposition

Publications (2)

Publication Number Publication Date
CN112261239A CN112261239A (en) 2021-01-22
CN112261239B true CN112261239B (en) 2022-05-17

Family

ID=74232360

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010988855.5A Active CN112261239B (en) 2020-09-18 2020-09-18 Plaintext related image encryption method based on PUD adaptive decomposition

Country Status (1)

Country Link
CN (1) CN112261239B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113344762B (en) * 2021-05-24 2022-11-29 太原理工大学 Double scrambling image encryption method based on AFD adaptive decomposition

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP1503594A2 (en) * 2003-07-28 2005-02-02 Samsung Electronics Co., Ltd. Discrete wavelet transform unit and method for adaptively encoding a still image based on energy of each block
CN101729854A (en) * 2009-12-24 2010-06-09 公安部第一研究所 Method for distributing code stream encrypting and decrypting keys in SIP video monitoring system
CN102142258A (en) * 2011-03-31 2011-08-03 上海第二工业大学 Wavelet transform and Arnold based adaptive gray-scale watermark embedded method
CN105553639A (en) * 2015-12-10 2016-05-04 北京理工大学 A Multi-Image Encryption and Decryption Method Based on Compressed Sensing
CN108322622A (en) * 2018-02-23 2018-07-24 哈尔滨理工大学 A kind of color digital image encryption method based on 2D-VMD and octuple hyperchaotic system
CN109544436A (en) * 2018-10-26 2019-03-29 天津大学 EVD-HG and DWT-SVD self-adapting watermarking image processing method
CN110084737A (en) * 2019-05-10 2019-08-02 钱涛 A kind of watermark insertion and extracting method based on two-dimensional adaptive Fourier decomposition

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
FR2849565B1 (en) * 2002-12-31 2005-06-03 Medialive ADAPTIVE AND PROGRESSIVE PROTECTION OF FIXED IMAGES CODED IN WAVELET
CN107977580B (en) * 2016-10-25 2020-07-07 中国电信股份有限公司 Medical image encryption and decryption method and device and medical image processing system

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP1503594A2 (en) * 2003-07-28 2005-02-02 Samsung Electronics Co., Ltd. Discrete wavelet transform unit and method for adaptively encoding a still image based on energy of each block
CN101729854A (en) * 2009-12-24 2010-06-09 公安部第一研究所 Method for distributing code stream encrypting and decrypting keys in SIP video monitoring system
CN102142258A (en) * 2011-03-31 2011-08-03 上海第二工业大学 Wavelet transform and Arnold based adaptive gray-scale watermark embedded method
CN105553639A (en) * 2015-12-10 2016-05-04 北京理工大学 A Multi-Image Encryption and Decryption Method Based on Compressed Sensing
CN108322622A (en) * 2018-02-23 2018-07-24 哈尔滨理工大学 A kind of color digital image encryption method based on 2D-VMD and octuple hyperchaotic system
CN109544436A (en) * 2018-10-26 2019-03-29 天津大学 EVD-HG and DWT-SVD self-adapting watermarking image processing method
CN110084737A (en) * 2019-05-10 2019-08-02 钱涛 A kind of watermark insertion and extracting method based on two-dimensional adaptive Fourier decomposition

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
《2D Partial Unwinding—A Novel Non-Linear Phase》;Yanting Li, Liming Zhang;《IEEE TRANSACTIONS ON IMAGE PROCESSING》;20191010;全文 *

Also Published As

Publication number Publication date
CN112261239A (en) 2021-01-22

Similar Documents

Publication Publication Date Title
Cancellaro et al. A commutative digital image watermarking and encryption method in the tree structured Haar transform domain
Soleymani et al. A survey on principal aspects of secure image transmission
Farschi et al. A novel chaotic approach for information hiding in image
Shuihua et al. An asymmetric image encryption based on matrix transformation
Sharma et al. A new image encryption using modified aes algorithm and its comparision with aes
Sathananthavathi et al. Secure visual communication with advanced cryptographic and ımage processing techniques
Hussein et al. Design and simulation a video steganography system by using FFTturbo code methods for copyrights application
CN112261239B (en) Plaintext related image encryption method based on PUD adaptive decomposition
Ahmed et al. A perceptually scalable and jpeg compression tolerant image encryption scheme
Wu et al. A novel image encryption scheme with adaptive Fourier decomposition
Atee et al. Cryptography and image steganography using dynamic encryption on LSB and color image based data hiding
Patel et al. Performance Evaluation of Steganography and AES encryption based on different formats of the Image
Banupriya et al. Video steganography using LSB algorithm for security application
Sun et al. A Novel Image Steganography Based on Contourlet Transform and Hill Cipher.
Shafique et al. A color image encryption algorithm based on chaotic map and discrete wavelet transform
Mondal et al. A highly secure steganography scheme for secure communication
Mishra et al. Hybrid image encryption and decryption using cryptography and watermarking technique for high security applications
Agarwal et al. Robust and secure watermarking for propagation of digital multimedia by paillier homomorphic cryptosystem with arnold transformation
Aparna et al. A review on cryptographic algorithms for speech signal security
Prajwalasimha et al. Image Encryption based on Pseudo Hadamard Transformation with Constant Co-efficient
Janakiraman et al. Pixel bit manipulation for encoded hiding—An inherent stego
Ghrare et al. Development of Hybrid Data Security System using LSB Steganography and AES Cryptography
Aarthi et al. Image encryption using binary bit plane and rotation method for an image security
Malik et al. Reversible data hiding in encrypted text using Paillier cryptosystem
Ahmad et al. A multi-level blocks scrambling based chaotic image cipher

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant