CN110430335A - A method, device and storage medium for information camouflage and restoration - Google Patents
A method, device and storage medium for information camouflage and restoration Download PDFInfo
- Publication number
- CN110430335A CN110430335A CN201910711927.9A CN201910711927A CN110430335A CN 110430335 A CN110430335 A CN 110430335A CN 201910711927 A CN201910711927 A CN 201910711927A CN 110430335 A CN110430335 A CN 110430335A
- Authority
- CN
- China
- Prior art keywords
- sequence
- bit string
- texture
- formula
- image
- 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.)
- Granted
Links
- 238000000034 method Methods 0.000 title claims abstract description 84
- 238000011084 recovery Methods 0.000 claims abstract description 10
- 238000004590 computer program Methods 0.000 claims description 27
- 239000003086 colorant Substances 0.000 claims description 12
- 230000006870 function Effects 0.000 claims description 12
- 238000013507 mapping Methods 0.000 claims description 6
- NAWXUBYGYWOOIX-SFHVURJKSA-N (2s)-2-[[4-[2-(2,4-diaminoquinazolin-6-yl)ethyl]benzoyl]amino]-4-methylidenepentanedioic acid Chemical compound C1=CC2=NC(N)=NC(N)=C2C=C1CCC1=CC=C(C(=O)N[C@@H](CC(=C)C(O)=O)C(O)=O)C=C1 NAWXUBYGYWOOIX-SFHVURJKSA-N 0.000 claims description 5
- 238000006243 chemical reaction Methods 0.000 claims description 3
- 238000012545 processing Methods 0.000 abstract description 8
- 230000005540 biological transmission Effects 0.000 abstract description 4
- 230000001419 dependent effect Effects 0.000 abstract 1
- 230000015572 biosynthetic process Effects 0.000 description 12
- 238000003786 synthesis reaction Methods 0.000 description 12
- 238000010586 diagram Methods 0.000 description 11
- 238000010276 construction Methods 0.000 description 2
- 238000000605 extraction Methods 0.000 description 2
- 238000001308 synthesis method Methods 0.000 description 2
- 230000000007 visual effect Effects 0.000 description 2
- 230000003044 adaptive effect Effects 0.000 description 1
- 238000003491 array Methods 0.000 description 1
- 230000009286 beneficial effect Effects 0.000 description 1
- 238000004891 communication Methods 0.000 description 1
- 238000011960 computer-aided design Methods 0.000 description 1
- 238000013500 data storage Methods 0.000 description 1
- 230000003247 decreasing effect Effects 0.000 description 1
- 238000011161 development Methods 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 230000002452 interceptive effect Effects 0.000 description 1
- 239000011159 matrix material Substances 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 238000010422 painting Methods 0.000 description 1
- 230000002441 reversible effect Effects 0.000 description 1
- 239000004065 semiconductor Substances 0.000 description 1
- 238000012546 transfer Methods 0.000 description 1
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/90—Determination of colour characteristics
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N1/00—Scanning, transmission or reproduction of documents or the like, e.g. facsimile transmission; Details thereof
- H04N1/32—Circuits 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/32101—Display, printing, storage or transmission of additional information, e.g. ID code, date and time or title
- H04N1/32144—Display, 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/32149—Methods relating to embedding, encoding, decoding, detection or retrieval operations
- H04N1/32267—Methods relating to embedding, encoding, decoding, detection or retrieval operations combined with processing of the image
- H04N1/32272—Encryption or ciphering
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N1/00—Scanning, transmission or reproduction of documents or the like, e.g. facsimile transmission; Details thereof
- H04N1/44—Secrecy systems
- H04N1/448—Rendering the image unintelligible, e.g. scrambling
- H04N1/4486—Rendering the image unintelligible, e.g. scrambling using digital data encryption
Landscapes
- Engineering & Computer Science (AREA)
- Multimedia (AREA)
- Signal Processing (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Theoretical Computer Science (AREA)
- Image Processing (AREA)
- Editing Of Facsimile Originals (AREA)
Abstract
本发明属于图像信息安全和数字图像信号处理交叉领域,公开了一种信息伪装和恢复的方法、设备及存储介质。在伪装时,首先将秘密信息编码为密钥图像上的坐标以避免秘密信息的直接信道传输,其次引入多备份,将坐标点进一步编码为给出样例图像的高频颜色序列并由密钥伪随机放置在空白待合成纹理图像上,最后按逐像素点纹理生成策略来生成含密纹理图像。在恢复时,根据密钥提取颜色序列,然后结合多备份的区间扩展策略由样例图像恢复坐标并依据密钥图像提取秘密信息。与现有方法相比,本方法通过逐像素点进行纹理合成,不会留下明显的拼接痕迹和重复模式,且秘密信息完全依赖于密钥,具备一定的抗攻击能力和较高的安全性。
The invention belongs to the intersection field of image information security and digital image signal processing, and discloses an information camouflage and recovery method, device and storage medium. In camouflage, first encode the secret information into the coordinates on the key image to avoid the direct channel transmission of the secret information, then introduce multiple backups, further encode the coordinate points into the high-frequency color sequence of the given sample image and use the key Pseudo-randomly placed on the blank texture image to be synthesized, and finally a pixel-by-pixel texture generation strategy is used to generate a dense texture image. When recovering, the color sequence is extracted according to the key, and then the coordinates are recovered from the sample image combined with the interval expansion strategy of multiple backups, and the secret information is extracted according to the key image. Compared with existing methods, this method synthesizes texture pixel by pixel without leaving obvious splicing traces and repeated patterns, and the secret information is completely dependent on the key, which has certain anti-attack ability and high security .
Description
技术领域technical field
本发明属于图像信息安全和数字图像信号处理交叉领域,涉及一种信息伪装和恢复的方法、设备及存储介质。The invention belongs to the intersection field of image information security and digital image signal processing, and relates to a method, device and storage medium for information camouflage and restoration.
背景技术Background technique
随着互联网的发展,越来越多的信息通过网络传输,在给人们带来极大便利的同时,也存在一定安全隐患。为保护传输中秘密信息的安全,人们提出用图像来隐藏秘密信息,例如,针对密写的文献:毛炳华,2019(毛炳华,王子驰,张新鹏.基于DCT域相关性的非对称JPEG隐写[J].计算机科学,2019,46(01):203-207.);GANDHARBA S,2016(GANDHARBAS.Adaptive pixel value differencing steganography using both vertical andhorizontal[J].Multimedia Tools and Applications,2016,75(21):13541-13556.);YANG T Y,2017(YANG T Y,CHEN H S.Matrix embedding in steganography with binaryReed-Muller codes[J].IET Image Processing,2017,11(7):522-529.)和张洋,2018(张洋,邵利平,任平安.免基向量EMD(n,m)模型及其在图像密写上的应用[J].计算机辅助设计与图形学学报,2018,30(8):1490-1504.);针对分存的文献:欧阳显斌,2017(欧阳显斌,邵利平,乐志芳.非等量备份和双认证自修复有限域图像分存[J].软件学报,2017,12(28):3306-3346.)和黄燕燕,2018(黄燕燕,邵利平.结合EMD-cl嵌入的多载体密图分存方法[J].中国图象图形学报,2018,23(8):1108-1130.)上。但这些方法的本质都是传统修改式嵌入的信息隐藏方法,需修改载体图像,会对嵌密载体视觉质量造成较大影响,容易引起攻击者的怀疑。With the development of the Internet, more and more information is transmitted through the network. While bringing great convenience to people, there are also certain security risks. In order to protect the security of secret information in transmission, people propose to use images to hide secret information, for example, for steganographic literature: Mao Binghua, 2019 (Mao Binghua, Wang Zichi, Zhang Xinpeng. Asymmetric JPEG steganography based on DCT domain correlation[J ]. Computer Science, 2019, 46(01): 203-207.); GANDHARBA S, 2016 (GANDHARBAS. Adaptive pixel value differencing steganography using both vertical and horizontal[J]. Multimedia Tools and Applications, 2016, 75(21): 13541-13556.); YANG TY, 2017 (YANG TY, CHEN H S. Matrix embedding in steganography with binary Reed-Muller codes [J]. IET Image Processing, 2017, 11(7): 522-529.) and Zhang Yang , 2018 (Zhang Yang, Shao Liping, Ren Pingan. Basis-free EMD(n, m) model and its application in image steganography [J]. Journal of Computer-Aided Design and Graphics, 2018, 30(8): 1490-1504.); Literature for shared storage: Ouyang Xianbin, 2017 (Ouyang Xianbin, Shao Liping, Le Zhifang. Non-equivalent backup and dual-authentication self-repair finite field image sharing[J]. Software Journal, 2017, 12(28): 3306-3346.) and Huang Yanyan, 2018 (Huang Yanyan, Shao Liping. Multi-carrier dense image sharing method combined with EMD- cl embedding [J]. Chinese Journal of Image and Graphics, 2018, 23( 8): 1108-1130.) on. However, the essence of these methods is the traditional modified embedding information hiding method, which needs to modify the carrier image, which will have a great impact on the visual quality of the embedded carrier and easily arouse the suspicion of the attacker.
为避免这类问题,人们提出了纹理生成式无载体信息隐藏,它主要包括纹理构造式信息隐藏和纹理拼接式信息隐藏。其中纹理构造式信息隐藏是通过模拟纹理生成的方式来产生一些类自然纹理,例如:QIAN Z X,2018(QIAN Z X,PAN L,LI S,ZHANG XP.Steganography by constructing marbling texture[C]//第//2018ChinaInformation Hiding Workshop(CIHW2018),Guang Zhou,2018:17-35.);潘琳,2016(潘琳,钱振兴,张新鹏.基于构造纹理图像的数字隐写[J].应用科学学报,2016,34(5):625-632.)和XU J,2015(XU J,MAO X,JIN X,et al.Hidden message in a deformation-basedtexture[J].Visual Computer International Journal of Computer Graphics,2015,31(12):1653-1669.)等,这类方法都是通过生成类水影画纹理来隐藏秘密信息,但所生成的纹理都是非自然纹理,从而不能对秘密信息进行有效掩盖。In order to avoid such problems, texture generative no-carrier information hiding is proposed, which mainly includes texture construction information hiding and texture splicing information hiding. Among them, texture construction information hiding is to generate some natural textures by simulating texture generation, for example: QIAN Z X, 2018 (QIAN Z X, PAN L, LI S, ZHANG XP. Steganography by constructing marbling texture[C]//section //2018ChinaInformation Hiding Workshop (CIHW2018), Guang Zhou, 2018: 17-35.); Pan Lin, 2016 (Pan Lin, Qian Zhenxing, Zhang Xinpeng. Digital steganography based on structured texture images [J]. Chinese Journal of Applied Science, 2016 , 34(5): 625-632.) and XU J, 2015 (XU J, MAO X, JIN X, et al. Hidden message in a deformation-based texture[J]. Visual Computer International Journal of Computer Graphics, 2015, 31(12): 1653-1669.), etc. These methods hide the secret information by generating water-like shadow painting textures, but the generated textures are all unnatural textures, so the secret information cannot be effectively covered.
纹理拼接式隐藏最早来源于OTORI H,2007(OTORI H,KURIYAMA S.Data-embeddable texture synthesis[C]//International Symposium on Smart Graphics,Kyoto,Japan,2007:146-157.)和OTORI H,2009(OTORI H,KURIYAMA S.Texture synthesisfor mobile data communications[J].IEEE Computer Graphics and Applications,2009,29(6):74-81.),这类方法通过样例纹理填充的方式来对表达秘密信息的局部二值模式像素点进行掩盖,但由于不能很好地对局部二值模式进行掩盖,从而易引起密写分析者的怀疑和导致秘密信息泄露。为避免此问题,WU C,2015(WU C,WANG C M.Steganographyusing reversible texture synthesis[J].Transactions on Image Processing,2015,24(1):130-139.);QIN Z C,2017(QIN Z C,LI M,WU B.Robust steganography viapatch-based texture synthesis[C]//International Conference on InternetMultimedia Computing and Service.Springer,Singapore,2017:429-439.)和QIAN Z X,2016(QIAN Z X,ZHOU H,ZHANG W M,et al.Robust steganography using texturesynthesis[C]//Advances in Intelligent Information Hiding and MultimediaSignal Processing.Proceeding of the Twelfth International Conference onIntelligent Information Hiding and Multimedia Signal Processing,2016:21-23.)都是通过纹理小块拼接的方式来产生与给定样本相似的含密纹理。但WU C,2015引入镜像操作使得编码和非编码样本小块存在明显的区别特征,导致编码小块直接泄露。QIN Z C,2017和QIAN Z X,2016秘密信息分段和样本小块类别之间存在着固定的一一对应关系,易引起攻击者的怀疑,导致安全性较低。另外WU C,2015,QIN Z C,2017和QIAN Z X,2016中含密纹理图像是采用EFROS A A,2001(EFROS A A,FREEMAN W T.Image quilting fortexture synthesis and transfer[C]//Proc.of the 28th Annual Conference onComputer Graphics and Interactive Techniques,2001:341-346.)中的缝合线算法来对重叠区域的纹理进行拼接,不可避免地会产生缝合痕迹与重复纹理模式,从而不能对秘密信息进行掩盖。Texture splicing hiding originated from OTORI H, 2007 (OTORI H, KURIYAMA S. Data-embeddable texture synthesis[C]//International Symposium on Smart Graphics, Kyoto, Japan, 2007: 146-157.) and OTORI H, 2009 (OTORI H, KURIYAMA S. Texture synthesis for mobile data communications[J]. IEEE Computer Graphics and Applications, 2009, 29(6): 74-81.), this type of method expresses secret information by filling sample textures However, since the local binary pattern cannot be well covered, it is easy to cause the suspicion of the steganalyzer and lead to the leakage of secret information. To avoid this problem, WU C, 2015 (WU C, WANG C M. Steganography using reversible texture synthesis[J]. Transactions on Image Processing, 2015, 24(1): 130-139.); QIN Z C, 2017 (QIN Z C , LI M, WU B. Robust steganography viapatch-based texture synthesis[C]//International Conference on InternetMultimedia Computing and Service. Springer, Singapore, 2017: 429-439.) and QIAN Z X, 2016 (QIAN Z X, ZHOU H, ZHANG W M, et al. Robust steganography using texture synthesis[C]//Advances in Intelligent Information Hiding and Multimedia Signal Processing. Proceeding of the Twelfth International Conference on Intelligent Information Hiding and Multimedia Signal Processing, 2016: 21-23. Block concatenation is used to generate dense textures similar to a given sample. However, WU C, 2015 introduced the mirroring operation to make the coded and non-coded sample blocks have obvious distinguishing features, resulting in the direct leakage of coded small blocks. QIN Z C, 2017 and QIAN Z X, 2016 There is a fixed one-to-one correspondence between secret information segments and sample small block categories, which can easily arouse the suspicion of attackers and lead to low security. In addition, WU C, 2015, QIN Z C, 2017 and QIAN Z X, 2016 contain dense texture images using EFROS A A, 2001 (EFROS A A, FREEMAN W T.Image quilting fortexture synthesis and transfer[C]//Proc.of the 28th Annual Conference on Computer Graphics and Interactive Techniques, 2001: 341-346.) stitches textures in overlapping regions, which will inevitably produce stitching traces and repeated texture patterns, so that secret information cannot be concealed.
发明内容Contents of the invention
本发明的目的在于克服上述现有技术的缺点,提供一种信息伪装和恢复的方法、设备及存储介质。The purpose of the present invention is to overcome the above-mentioned shortcomings of the prior art, and provide a method, device and storage medium for disguising and recovering information.
为达到上述目的,本发明采用以下技术方案予以实现:In order to achieve the above object, the present invention adopts the following technical solutions to achieve:
一种信息伪装方法,包括以下步骤:A method for disguising information comprises the following steps:
S1:通过预设密钥k1生成R阶密钥图S,输入2值秘密信息比特序列B,将2值秘密信息比特序列B编码为2R进制数序列R;S1: Generate an R-order key map S through the preset key k 1 , input a binary secret information bit sequence B, and encode the binary secret information bit sequence B into a 2-ary R number sequence R;
S2:通过R阶密钥图S中与2R进制数序列R中元素相同像素值的像素坐标,将2R进制数序列R编码为2值比特位串b;S2: Encode the 2-ary number sequence R into a binary bit string b through the pixel coordinates of the same pixel value in the R-order key map S as the element in the 2-ary number sequence R ;
S3:在预设纹理样例图T中挑选出m+t种颜色构成调色板序列V,初始化空白图像K,通过预设密钥k2生成随机坐标序列C;S3: Select m+t colors from the preset texture sample map T to form a palette sequence V, initialize a blank image K, and generate a random coordinate sequence C through the preset key k 2 ;
S4:通过调色板序列V中元素和元素索引的映射关系,将2值比特位串b的3重备份编码为颜色序列V′,结合随机坐标序列C在空白图像K上放置颜色序列V′中的所有元素;S4: Through the mapping relationship between elements and element indexes in the palette sequence V, encode the 3-fold backup of the binary bit string b into a color sequence V', combine the random coordinate sequence C to place the color sequence V' on the blank image K all elements in
S5:通过逐像素点纹理生成策略对空白图像K中剩余位置进行纹理填充,得到含密纹理图像K。S5: Fill the remaining positions in the blank image K with texture through a pixel-by-pixel texture generation strategy to obtain a dense texture image K.
本发明信息伪装方法进一步的改进在于:The further improvement of the information camouflaging method of the present invention lies in:
所述S1的具体方法为:The specific method of said S1 is:
S1-1:通过预设密钥k1生成分辨率为h1×w1的R阶密钥图 S1-1: Generate an R-order key map with a resolution of h 1 ×w 1 through the preset key k 1
S1-2:输入2值秘密信息比特序列B,将B中的每R个比特为一组转换为长度为l1的2R进制数序列其中l1由式(1)确定;S1-2: Input the 2-value secret information bit sequence B, convert each R bit in B into a group of 2 R -ary number sequences with length l 1 Wherein l 1 is determined by formula (1);
其中,符号表示向上取整;Among them, the symbol Indicates rounding up;
所述S2的具体方法为:The specific method of said S2 is:
通过R阶密钥图S中与2R进制数序列R中元素相同像素值的像素坐标,将2R进制数序列R编码为2值比特位串其中l2由式(2)确定;Encode the 2-ary number sequence R into a 2-valued bit string through the pixel coordinates of the same pixel value in the R-order key map S as the element in the 2-ary number sequence R Wherein l 2 is determined by formula (2);
所述S2的具体方法为:The specific method of said S2 is:
S2-1:对2R进制数序列中的每个元素ri,在R阶密钥图S中随机选择与ri值相等的元素并记录其对应的坐标位置(ui,vi),通过式(3)将ui和vi转换为长度为的2进制比特位串 S2-1: Pair of 2 R -ary number sequences For each element r i in the R-order key map S, randomly select an element equal to the value of r i and record its corresponding coordinate position (u i , v i ), and convert u i and v i into lengths of The binary bit string of
其中,bin(ui)为2值转换函数,用于将ui转换为2值比特位串,对于ui∈[0,h1-1],bin(ui)将ui转换为长度为的2值比特位串,对于vi∈[0,w1-1],bin(vi)将vi转换为长度为的2值比特位串,符号“||”为比特位串串联函数;Among them, bin(u i ) is a binary conversion function, which is used to convert u i into a binary bit string. For u i ∈ [0, h 1 -1], bin(u i ) converts u i into length for 2-value bit string of , for v i ∈ [0, w 1 -1], bin(v i ) converts v i to length The 2-value bit string of , the symbol "||" is a bit string concatenation function;
S2-2:重复S2-1至转换为l1个2进制比特位串通过式(4)将l1个2进制比特位串串联得到2值比特位串 S2-2: Repeat S2-1 to Convert to l 1 binary bit string Through formula (4) will l 1 binary bit string Concatenate to get 2-valued bit string
所述S3的具体方法为:The specific method of said S3 is:
S3-1:在分辨率h2×w2的预设纹理样例图中挑选出现频率最高的m+t种颜色构成调色板序列V=(vi)m+t;S3-1: Sample images of preset textures at resolution h 2 ×w 2 Select the m+t colors with the highest frequency of occurrence to form a palette sequence V=(v i ) m+t ;
S3-2:初始化分辨率为h3×w3的R阶空白图像 S3-2: Initialize an R-order blank image with a resolution of h 3 ×w 3
S3-3:通过预设密钥k2生成长度为3·l3的随机坐标序列其中(xi,yi)∈h3×w3且随机坐标序列C中坐标两两不等,l3通过式(5)确定:S3-3: Generate a random coordinate sequence of length 3 l 3 through the preset key k 2 Where ( xi , y i )∈h 3 ×w 3 and the coordinates in the random coordinate sequence C are not equal, l 3 is determined by formula (5):
其中,符号表示向下取整;Among them, the symbol Indicates rounding down;
所述S4的具体方法为:The specific method of said S4 is:
S4-1:将2值比特位串b中的2值比特以个比特为1组转换为长度为l3的序列 S4-1: Bind the 2-valued bits in the 2-valued bit string b to A group of bits is converted into a sequence of length l 3
S4-2:将序列中的每一个元素di,通过式(6)编码为di的备份 S4-2: Convert the sequence Each element d i in is encoded as a backup of d i by formula (6)
S4-3:重复S4-2至将D编码为3·l3个元素通过式(7)得到颜色序列V′;S4-3: Repeat S4-2 to encode D as 3 l 3 elements Obtain the color sequence V' by formula (7);
S4-4:将作为空白图像K中(x3·i+k,y3·i+k),i=0,1,…,l3-1,k=0,1,2位置的元素;S4-4: will As the blank image K (x 3·i+k , y 3·i+k ), i=0, 1,..., l 3 -1, k=0, 1, 2 elements;
所述S5的具体方法为:The concrete method of described S5 is:
S5-1:在空白图像K中,对任意ki,j且记以ki,j为中心的γ×γ邻域为N(ki,j),在纹理样例图T中遍历所有元素tx,y为中心的γ×γ邻域N′(tx,y),通过式(8)得到N(ki,j)与N′(tx,y)的相似度并从中选取与N(ki,j)最相似的邻域按对ki,j赋值;S5-1: In the blank image K, for any k i, j and Denote the γ×γ neighborhood centered on ki, j as N(ki , j ), traverse all the γ×γ neighborhoods N′(t x y) centered on all elements t x, y in the texture sample map , y ), get the similarity between N(ki , j ) and N′(t x, y ) through formula (8), and select the neighborhood most similar to N(ki , j ) according to Assign values to k i, j ;
其中,p,q是对应8邻域N(ki,j),N′(tx,y)中对应位置的像素点,R(x),G(x),B(x)分别代表像素点x的R,G,B分量值,d(N(ki,j),N′(tx,y))越小表明N(ki,j)与N′(tx,y)越相似;Among them, p, q are the corresponding pixel points in the 8 neighborhoods N(k i, j ), N′(t x, y ), and R(x), G(x), B(x) respectively represent the pixels For the R, G, and B component values of point x, the smaller d(N(k i, j ), N′(t x, y )), the smaller N(k i, j ) and N′(t x, y ) are. resemblance;
S5-2:重复S5-1至空白图像K中所有元素完成赋值,得到含密纹理图像K。S5-2: Repeat S5-1 to all elements in the blank image K After completing the assignment, a dense texture image K is obtained.
本发明又一方面,一种计算机可读存储介质,所述计算机可读存储介质存储有计算机程序,所述计算机程序被处理器执行时实现所述信息伪装方法的步骤。In yet another aspect of the present invention, a computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the information masquerading method are realized.
本发明又一方面,一种计算机设备,包括存储器、处理器以及存储在所述存储器中并可在所述处理器上运行的计算机程序,所述处理器执行所述计算机程序时实现所述信息伪装方法的步骤。In yet another aspect of the present invention, a computer device includes a memory, a processor, and a computer program stored in the memory and operable on the processor, and the information is realized when the processor executes the computer program. The steps of the masquerading method.
本发明又一方面,一种信息恢复方法,包括以下步骤:In yet another aspect of the present invention, an information recovery method includes the following steps:
R1:通过预设密钥k2生成随机坐标序列C,通过随机坐标序列C从输入的含密纹理图K′中提取出颜色序列V′;R1: Generate a random coordinate sequence C through the preset key k 2 , and extract the color sequence V' from the input dense texture map K' through the random coordinate sequence C;
R2:在预设纹理样例图T中挑选出m+t种颜色构成调色板序列V,通过调色板序列V中的元素和元素索引的映射关系,将颜色序列V′解码为2值比特位串b;R2: Select m+t colors from the preset texture sample map T to form a palette sequence V, and decode the color sequence V' into 2 values through the mapping relationship between the elements in the palette sequence V and the element indexes bit string b;
R3:通过预设密钥k1生成R阶密钥图S,结合2值比特位串b在密钥图S中提取出秘密信息B。R3: Generate the R-order key map S through the preset key k 1 , and extract the secret information B from the key map S by combining the binary bit string b.
本发明信息恢复方法进一步的改进在于:The further improvement of the information recovery method of the present invention lies in:
所述R1的具体方法为:The concrete method of described R1 is:
R1-1:通过预设密钥k2生成长度为3·l3的随机坐标序列其中(xi,yi)∈h3×w3且随机坐标序列C中坐标两两不等;R1-1: Generate a random coordinate sequence with a length of 3 l 3 through the preset key k 2 Where ( xi , y i )∈h 3 ×w 3 and the coordinates in the random coordinate sequence C are not equal to each other;
R1-2:通过随机坐标序列C从输入的含密纹理图中,对每个(xi,yi)∈C,找到(x3·i+k,y3·i+k),i∈[0,l3-1],k=0,1,2位置的所有元素并组合,得到颜色序列V′;R1-2: From the input dense texture map through the random coordinate sequence C , for each (x i , y i )∈C, find (x 3·i+k , y 3·i+k ), i∈[0, l 3 -1], k=0, 1, 2 all elements of position and combined to obtain the color sequence V';
所述R2的具体方法为:The concrete method of described R2 is:
R2-1:在分辨率h2×w2的纹理样例图中挑选出现频率最高的m+t种颜色构成调色板序列V=(vi)m+t;R2-1: Texture sample image at resolution h 2 ×w 2 Select the m+t colors with the highest frequency of occurrence to form a palette sequence V=(v i ) m+t ;
R2-2:根据调色板序列V找出的索引位置通过式(9)计算 R2-2: Find out according to the palette sequence V index position of Calculated by formula (9)
记位于区间[0,m-1]的元素数量记为Ec,通过以下5种情况计算di:remember The number of elements in the interval [0, m-1] is recorded as E c , and d i is calculated through the following five situations:
①若Ec=0,置 ①If E c =0, set
②若Ec=1且位于区间[0,m-1]的元素值为v,置di=v;②If E c =1 and The element value in the interval [0, m-1] is v, set d i =v;
③若Ec=2且位于区间[0,m-1]的元素值为v1,v2,置di=(v1+v2)/2;③If E c =2 and The element values in the interval [0, m-1] are v 1 , v 2 , set d i =(v 1 +v 2 )/2;
④若Ec=3且存在两个及两个以上的值相等,记相等值为v,置di=v;④ If E c =3 and There are two or more values that are equal, record the equal value as v, and set d i =v;
⑤若Ec=3且两两不等,置 ⑤If E c =3 and Not equal to each other, set
R2-3:重复R2-2至随机坐标序列C中所有坐标处理完毕,通过式(10)得到长度为l2的2值比特位串b:R2-3: Repeat R2-2 until all the coordinates in the random coordinate sequence C have been processed, and the 2 -value bit string b of length l2 is obtained by formula (10):
其中,Left()是2值比特位串截取函数,第1个参数为要截取的2值比特位串,第2个参数是从左起截取的长度;l2通过式(11)确定;Wherein, Left () is a binary bit string interception function, the first parameter is the binary bit string to be intercepted, and the second parameter is the length intercepted from the left; 12 is determined by formula (11);
所述R3的具体方法为:The concrete method of described R3 is:
R3-1:通过预设密钥k1生成分辨率为h1×w1的R阶密钥图 R3-1: Generate an R-order key map with a resolution of h 1 ×w 1 through the preset key k 1
R3-2:将2值比特位串b的2值比特以为1组,划分为l1组,记为分别通过式(12)和式(13)从每个分组中截取前个2值比特和后个2值比特作为坐标(ui,vi),然后通过式(14)将R阶密钥图S中(ui,vi)位置对应的元素赋值给ri,其中i=0,1,…,l1-1;R3-2: Bind the 2-valued bits of the 2-valued bit string b to is 1 group, divided into l 1 groups, recorded as From each group through formula (12) and formula (13) respectively before interception 2-valued bits and after two 2-value bits as the coordinates (u i , v i ), and then assign the element corresponding to the position (u i , v i ) in the R-order key map S to r i through formula (14), where i=0, 1 ,...,l 1 -1;
其中,Right()是2值比特位串截取函数,第1个参数为要截取的2值比特位串,第2个参数从右起截取的长度;Wherein, Right () is a binary bit string interception function, the first parameter is the binary bit string to be intercepted, and the length of the second parameter intercepted from the right;
R3-3:将ri,i=0,1,…,l1-1分别转换为长度为R的2进制比特位串,将所有长度为R的2进制比特位串串联为长度为N的2进制比特位串,得到秘密信息B=(Bi)N。R3-3: convert r i , i=0, 1, ..., l 1 -1 into binary bit strings of length R respectively, and concatenate all binary bit strings of length R into a length of The binary bit string of N, the secret information B=(B i ) N is obtained.
本发明又一方面,一种计算机可读存储介质,所述计算机可读存储介质存储有计算机程序,所述计算机程序被处理器执行时实现所述信息恢复方法的步骤。In yet another aspect of the present invention, a computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the information restoration method are implemented.
本发明又一方面,一种计算机设备,包括存储器、处理器以及存储在所述存储器中并可在所述处理器上运行的计算机程序,所述处理器执行所述计算机程序时实现所述信息恢复方法的步骤。In yet another aspect of the present invention, a computer device includes a memory, a processor, and a computer program stored in the memory and operable on the processor, and the information is realized when the processor executes the computer program. The steps of the recovery method.
与现有技术相比,本发明具有以下有益效果:Compared with the prior art, the present invention has the following beneficial effects:
本发明采用逐像素点纹理合成的方法来产生含密纹理,含密纹理图像是逐点生成而不是纹理小块拼接生成,所以避免了基于缝合线算法的块拼接生成式信息隐藏存在的固有拼接痕迹并减少了重复模式的产生,安全性更高,且不易引起攻击者的怀疑。有效解决了传统基于块拼接纹理合成的信息隐藏方法中由于含密纹理图像采用缝合线算法来对重叠区域的纹理进行拼接,不可避免地会产生缝合痕迹与重复纹理模式,从而不能对秘密信息进行掩盖的问题。通过密钥产生的密钥图坐标来表达秘密信息,含密掩体图中嵌入的是秘密信息在密钥图中的坐标信息而不是秘密信息,避免了秘密信息的直接信道传输,且秘密信息的嵌入和提取过程完全依赖于密钥,具有较高的安全性。有效解决了现有基于块拼接纹理合成的信息隐藏方法由于使用样本小块编码秘密信息,秘密信息在信道中传输,安全性不高的问题。本发明引入了基于多备份和区间扩展的认证策略,在嵌密时嵌入多份秘密信息,在提取时,将多份秘密信息全部提取出来,然后对比多份秘密信息,将秘密信息相同最多份的秘密信息作为正确提取出的秘密信息,若都不相同则取均值作为秘密信息,该策略可有效地提高了提取秘密信息的抗攻击能力。有效解决了现有基于块拼接纹理合成的信息隐藏方法由于缺少认证信息,若含密掩体图遭受攻击之后无法确定提取出的秘密信息是否为正确的秘密信息的问题。The present invention adopts the pixel-by-pixel texture synthesis method to generate dense texture, and the dense texture image is generated point by point instead of splicing small texture blocks, so it avoids the inherent splicing existing in the block splicing generative information hiding based on the suture line algorithm Traces and reduce the generation of repeated patterns, higher security, and less likely to arouse the suspicion of attackers. It effectively solves the problem that in the traditional information hiding method based on block splicing texture synthesis, because the dense texture image uses the seam algorithm to stitch the texture of the overlapping area, it will inevitably produce stitching traces and repeated texture patterns, so that the secret information cannot be hidden. cover up the problem. The secret information is expressed through the coordinates of the key map generated by the key, and the coordinate information of the secret information in the key map is embedded in the secret bunker map instead of the secret information, which avoids the direct channel transmission of the secret information, and the secret information The process of embedding and extracting completely depends on the key, which has high security. It effectively solves the problem that the existing information hiding method based on block splicing texture synthesis is not high in security due to the use of small sample blocks to encode secret information, and the secret information is transmitted in the channel. The present invention introduces an authentication strategy based on multi-backup and interval expansion. When embedding multiple secret information, when extracting, all multiple secret information are extracted, and then compared with multiple secret information, the secret information is the same at most The secret information is taken as the correctly extracted secret information, and if they are not the same, the average value is taken as the secret information. This strategy can effectively improve the anti-attack ability of extracting secret information. It effectively solves the problem that the existing information hiding method based on block splicing texture synthesis lacks authentication information, and it is impossible to determine whether the extracted secret information is correct secret information if the secret bunker map is attacked.
附图说明Description of drawings
图1为本发明信息伪装方法流程图;Fig. 1 is the flow chart of information camouflage method of the present invention;
图2为本发明信息恢复方法流程图;Fig. 2 is a flow chart of the information recovery method of the present invention;
图3为本发明的纹理样例图,为64×64分辨率的8位彩色图像纹理1;Fig. 3 is a texture sample diagram of the present invention, which is an 8-bit color image texture 1 with a resolution of 64×64;
图4为本发明的纹理样例图,为64×64分辨率的8位彩色图像纹理2;Fig. 4 is a texture sample diagram of the present invention, which is an 8-bit color image texture 2 with a resolution of 64 × 64;
图5为本发明的纹理样例图,为64×64分辨率的8位彩色图像纹理3;Fig. 5 is a texture sample diagram of the present invention, which is an 8-bit color image texture 3 with a resolution of 64×64;
图6为本发明的纹理样例图,为64×64分辨率的8位彩色图像纹理4;Fig. 6 is a texture sample diagram of the present invention, which is an 8-bit color image texture 4 with a resolution of 64×64;
图7为本发明的密图,为64×64分辨率的8位灰度图像lena;Fig. 7 is a dense image of the present invention, which is an 8-bit grayscale image lena of 64 × 64 resolution;
图8为本发明的以图3为纹理样例图,图7为密图生成的分辨率为512×512的含密纹理1,用户密钥取key1=6546,key2=7653;Fig. 8 is a sample map of the texture in Fig. 3 of the present invention, and Fig. 7 is a dense texture 1 with a resolution of 512 × 512 generated by the dense map, and the user key is key 1 = 6546, key 2 = 7653;
图9为本发明的以图4为纹理样例图,图7为密图生成的分辨率为512×512的含密纹理2,用户密钥取key1=6548,key2=7659;Fig. 9 is a sample map of the texture in Fig. 4 of the present invention, Fig. 7 is a dense texture 2 with a resolution of 512 × 512 generated by the dense map, and the user key is key 1 = 6548, key 2 = 7659;
图10为本发明的以图5为纹理样例图,图7为密图生成的分辨率为512×512的含密纹理3,用户密钥取key1=6546,key2=7653;Fig. 10 is an example map of the texture in Fig. 5 of the present invention, and Fig. 7 is a dense texture 3 with a resolution of 512 × 512 generated by the dense map, and the user key is key 1 = 6546, key 2 = 7653;
图11为本发明的以图6为纹理样例图,图7为密图生成的分辨率为512×512的含密纹理4,用户密钥取key1=6548,key2=7659;Fig. 11 is an example map of the texture in Fig. 6 of the present invention, and Fig. 7 is a dense texture 4 with a resolution of 512 × 512 generated by the dense map, and the user key is key 1 = 6548, key 2 = 7659;
图12为本发明的由图8恢复出的密图,相对于图7的误码率BR为0%;Fig. 12 is the secret map recovered by Fig. 8 of the present invention, and the bit error rate BR is 0% with respect to Fig. 7;
图13为本发明的由图9恢复出的密图,相对于图7的误码率BR为0%;Fig. 13 is the secret map recovered by Fig. 9 of the present invention, and the bit error rate BR relative to Fig. 7 is 0%;
图14为本发明的由图10恢复出的密图,相对于图7的误码率BR为0%;Fig. 14 is the cryptography restored by Fig. 10 of the present invention, and is 0% with respect to the bit error rate BR of Fig. 7;
图15为本发明的由图11恢复出的密图,相对于图7的误码率BR为0%;Fig. 15 is the secret map restored by Fig. 11 of the present invention, and is 0% with respect to the bit error rate BR of Fig. 7;
图16为本发明的对图8进行1.9%的剪裁攻击图;Fig. 16 is a 1.9% clipping attack diagram for Fig. 8 of the present invention;
图17为本发明的对图9进行3.4%的剪裁攻击图;Fig. 17 is a 3.4% clipping attack diagram of Fig. 9 in the present invention;
图18为本发明的对图10进行4.1%的剪裁攻击图;Figure 18 is a 4.1% clipping attack diagram of Figure 10 of the present invention;
图19为本发明的对图11进行2.6%的剪裁攻击图;Fig. 19 is a 2.6% clipping attack diagram of Fig. 11 according to the present invention;
图20为本发明的对图8进行8%的随机噪声攻击图;Fig. 20 is the 8% random noise attack diagram of Fig. 8 of the present invention;
图21为本发明的对图9进行20%的随机噪声攻击图;Figure 21 is a 20% random noise attack diagram of Figure 9 of the present invention;
图22为本发明的对图10进行15%的随机噪声攻击图;Figure 22 is a 15% random noise attack figure for Figure 10 of the present invention;
图23为本发明的对图11进行10%的随机噪声攻击图;Figure 23 is a 10% random noise attack diagram of Figure 11 of the present invention;
图24为本发明的由图16恢复出的密图,相对于图7的误码率BR为0.63%,峰值信噪比PSNR=为30.7281dB;Fig. 24 is the encrypted image recovered from Fig. 16 according to the present invention. Compared with Fig. 7, the bit error rate BR is 0.63%, and the peak signal-to-noise ratio PSNR=is 30.7281dB;
图25为本发明的由图17恢复出的密图,相对于图7的误码率BR为1.12%,峰值信噪比PSNR=为28.1291dB;Fig. 25 is the encrypted image recovered from Fig. 17 according to the present invention. Compared with Fig. 7, the bit error rate BR is 1.12%, and the peak signal-to-noise ratio PSNR=is 28.1291dB;
图26为本发明的由图18恢复出的密图,相对于图7的误码率BR为1.37%,峰值信噪比PSNR=为26.7750dB;Fig. 26 is the encrypted image recovered from Fig. 18 according to the present invention. Compared with Fig. 7, the bit error rate BR is 1.37%, and the peak signal-to-noise ratio PSNR=26.7750dB;
图27为本发明的由图19恢复出的密图,相对于图7的误码率BR为0.85%,峰值信噪比PSNR=为29.8146dB;Fig. 27 is the encrypted image recovered from Fig. 19 according to the present invention. Compared with Fig. 7, the bit error rate BR is 0.85%, and the peak signal-to-noise ratio PSNR=29.8146dB;
图28为本发明的由图20恢复出的密图,相对于图7的误码率BR为2.66%,峰值信噪比PSNR=为24.3136dB;Fig. 28 is the encrypted image recovered from Fig. 20 according to the present invention. Compared with Fig. 7, the bit error rate BR is 2.66%, and the peak signal-to-noise ratio PSNR=24.3136dB;
图29为本发明的由图21恢复出的密图,相对于图7的误码率BR为6.35%,峰值信噪比PSNR=为20.1874dB;Fig. 29 is the encrypted image recovered from Fig. 21 according to the present invention. Compared with Fig. 7, the bit error rate BR is 6.35%, and the peak signal-to-noise ratio PSNR=20.1874dB;
图30为本发明的由图22恢复出的密图,相对于图7的误码率BR为4.79%,峰值信噪比PSNR=为21.7039dB;Fig. 30 is the encrypted image recovered from Fig. 22 according to the present invention. Compared with Fig. 7, the bit error rate BR is 4.79%, and the peak signal-to-noise ratio PSNR=21.7039dB;
图31为本发明的由图23恢复出的密图,相对于图7的误码率BR为3.13%,峰值信噪比PSNR=为23.7018dB。Fig. 31 is the encrypted image recovered from Fig. 23 according to the present invention. Compared with Fig. 7, the bit error rate BR is 3.13%, and the peak signal-to-noise ratio PSNR=23.7018dB.
具体实施方式Detailed ways
为了使本技术领域的人员更好地理解本发明方案,下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅是本发明一部分的实施例,而不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都应当属于本发明保护的范围。In order to enable those skilled in the art to better understand the solutions of the present invention, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only It is an embodiment of a part of the present invention, but not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by persons of ordinary skill in the art without making creative efforts shall fall within the protection scope of the present invention.
需要说明的是,本发明的说明书和权利要求书及上述附图中的术语“第一”、“第二”等是用于区别类似的对象,而不必用于描述特定的顺序或先后次序。应该理解这样使用的数据在适当情况下可以互换,以便这里描述的本发明的实施例能够以除了在这里图示或描述的那些以外的顺序实施。此外,术语“包括”和“具有”以及他们的任何变形,意图在于覆盖不排他的包含,例如,包含了一系列步骤或单元的过程、方法、系统、产品或设备不必限于清楚地列出的那些步骤或单元,而是可包括没有清楚地列出的或对于这些过程、方法、产品或设备固有的其它步骤或单元。It should be noted that the terms "first" and "second" in the description and claims of the present invention and the above drawings are used to distinguish similar objects, but not necessarily used to describe a specific sequence or sequence. It is to be understood that the data so used are interchangeable under appropriate circumstances such that the embodiments of the invention described herein can be practiced in sequences other than those illustrated or described herein. Furthermore, the terms "comprising" and "having", as well as any variations thereof, are intended to cover a non-exclusive inclusion, for example, a process, method, system, product or device comprising a sequence of steps or elements is not necessarily limited to the expressly listed instead, may include other steps or elements not explicitly listed or inherent to the process, method, product or apparatus.
下面以JAVA jdk1.8.0_65为实施环境结合附图及实施例对本发明做进一步的详细说明。The present invention will be further described in detail below with JAVA jdk1.8.0_65 as the implementation environment in conjunction with the accompanying drawings and embodiments.
下面结合附图对本发明做进一步详细描述:The present invention is described in further detail below in conjunction with accompanying drawing:
参见图1,本发明信息伪装方法,包括以下步骤:Referring to Fig. 1, the information camouflage method of the present invention comprises the following steps:
第1步:首先通过预设密钥k1生成分辨率为h1×w1的R阶密钥图然后输入长度为N的2值秘密信息比特序列B=(Bi)N,最后将2值秘密信息比特序列B中的每R个比特为一组转换为长度为l1的2R进制数序列其中l1由式(1)确定;Step 1: First generate an R-order key map with a resolution of h 1 ×w 1 through the preset key k 1 Then input a binary secret information bit sequence B=(B i ) N with a length of N, and finally convert each R bit in the binary secret information bit sequence B into a group of 2 R -ary numbers with a length of l 1 sequence Wherein l 1 is determined by formula (1);
其中,符号表示向上取整。Among them, the symbol Indicates rounding up.
例如:若取线性同余随机发生器的随机种子作为密钥k1,则由k1=6546,R=8,h1=w1=16可生成S=(si,j)16×16,si,j∈[0,28-1],假设输入的2值秘密信息比特序列B=(1101011010110010)2,则N=16,则按式(1)可得到长度为的2R=28=256进制数序列R,R中包含2个元素r0=(11010110)2=214,r1=(10110010)2=178,即R=(r0=214,r1=178)。For example: if the random seed of the linear congruent random generator is used as the key k 1 , then S=(s i, j ) 16×16 can be generated by k 1 =6546, R=8, h 1 =w 1 =16 , s i, j ∈ [0, 2 8 -1], assuming the input binary secret information bit sequence B=(1101011010110010) 2 , then N=16, then the length can be obtained according to formula (1): 2 R =2 8 =256 hexadecimal number sequence R, R contains 2 elements r 0 =(11010110) 2 =214, r 1 =(10110010) 2 =178, namely R=(r 0 =214, r 1 = 178).
第2步:对于2R进制数序列中的每个元素ri,在R阶密钥图S中随机选择与ri值相等的元素并记录其对应的坐标位置(ui,vi),按式(3)将ui和vi转换为长度为的2进制比特位串由此可将转换为l1个2进制比特位串将其按式(4)进行比特位串联可得到2值比特位串其中l2由式(2)确定;Step 2: For 2 R -ary number sequences For each element r i in the R-order key map S, randomly select an element equal to the value of r i And record its corresponding coordinate position (u i , v i ), convert u i and v i into lengths according to formula (3) The binary bit string of From this you can Convert to l 1 binary bit string Concatenate the bits according to formula (4) to get the 2-value bit string Wherein l 2 is determined by formula (2);
式(3)中,bin(ui)为2值转换函数,用于将ui转换为2值比特位串,对于ui∈[0,h1-1],bin(ui)可将ui转换为长度为的2值比特位串,对于vi∈[0,w1-1],bin(vi)可将vi转换为长度为的2值比特位串,符号“||”为比特位串串联函数;In formula (3), bin(u i ) is a binary conversion function, which is used to convert u i into a binary bit string. For u i ∈ [0, h 1 -1], bin(u i ) can be U i is converted to a length of 2-value bit string of , for v i ∈ [0, w 1 -1], bin(v i ) can convert v i into a length of The 2-value bit string of , the symbol "||" is a bit string concatenation function;
例如:对于R=(r0=214,r1=178)中的2个元素r0=214,r1=178,若与r0相等的R阶密钥图S中元素为s4,6=214,则记录其对应的坐标位置(u0,v0)=(4,6),这里可将u0=4转换为个2进制位bin(u0)=(0100)2,可将v0=6转换为个2进制位bin(v0)=(0110)2,从而按式(3)得到对于r1=178,若与r1相等的S中元素为s5,2=178,则将按式(4)进行比特位串联可得到2值比特位串其中 For example: for 2 elements r 0 =214, r 1 =178 in R=(r 0 =214, r 1 =178), if the elements in the R-order key map S equal to r 0 are s 4,6 =214, then record its corresponding coordinate position (u 0 , v 0 )=(4,6), where u 0 =4 can be transformed into A binary bit bin(u 0 )=(0100) 2 , can convert v 0 =6 into A binary bit bin(v 0 )=(0110) 2 , thus get For r 1 =178, if the element in S equal to r 1 is s 5,2 =178, then will Concatenate bits according to formula (4) to get 2-valued bit string in
第3步:首先从纹理样例图中挑选出现频率最高的m+t种颜色构成调色板序列V=(vi)m+t,然后初始化分辨率为h3×w3的R阶空白图像由密钥k2生成长度为3·l3的随机坐标序列其中(xi,yi)∈h3×w3且C中坐标两两不等,l3按式(5)确定,符号表示向下取整;Step 3: First start with the texture sample image Select the m+t colors with the highest frequency to form a palette sequence V=(v i ) m+t , and then initialize an R-order blank image with a resolution of h 3 ×w 3 A random coordinate sequence of length 3 l 3 is generated by the key k 2 Where ( xi , y i )∈h 3 ×w 3 and the coordinates in C are not equal, l 3 is determined according to formula (5), the symbol Indicates rounding down;
例如:取h2=w2=64,m=16,t=2,则可从纹理样例图T=(tx,y)64×64中挑选出现频率最高的18种颜色构成调色板序列V=(vi)18;取h3=w3=512,R=8,可得分辨率为512×512的8阶空白图像K=(ki,j=28-1=255)512×512;若取线性同余随机发生器的随机种子作为密钥k2,取k2=7653,l2=16,由式(5)可得则可生成长度为3·l3=3·4=12且坐标两两不等的随机坐标序列为:C=((55,64),(49,74),(82,84),(228,113),(89,73),(169,196),(170,165),(253,129),(104,222),(116,62),(235,246),(235,161));For example: take h 2 =w 2 =64, m=16, t=2, then you can select 18 colors with the highest frequency from the texture sample image T=(t x, y ) 64×64 to form a palette Sequence V=(v i ) 18 ; take h 3 =w 3 =512, R=8, an 8th-order blank image K=(ki , j =2 8 -1=255) with a resolution of 512×512 can be obtained 512×512 ; if the random seed of the linear congruential random generator is used as the key k 2 , k 2 =7653, l 2 =16, it can be obtained from formula (5) Then a random coordinate sequence with a length of 3·l 3 =3·4=12 and two different coordinates can be generated: C=((55,64), (49,74), (82,84), (228 , 113), (89, 73), (169, 196), (170, 165), (253, 129), (104, 222), (116, 62), (235, 246), (235, 161 ));
第4步:通过调色板序列V中的元素和元素索引的映射关系,将2值比特位串b的3重备份编码为颜色序列V′,最后结合随机坐标序列C在空白图像K中放置颜色序列V′中的所有元素。具体方法是:Step 4: Through the mapping relationship between the elements in the palette sequence V and the element indexes, encode the 3-fold backup of the binary bit string b into a color sequence V′, and finally combine the random coordinate sequence C and place it in the blank image K All elements in the color sequence V'. The specific method is:
1)将2值比特位串b中的2值比特以个比特为1组转换为长度为l3的序列其中l3按式(6)确定,对于中每一个元素di,通过式(7)将di编码为di的备份 1) Bind the 2-valued bits in the 2-valued bit string b to A group of bits is converted into a sequence of length l 3 where l 3 is determined according to formula (6), for For each element d i in , encode d i as a backup of d i through formula (7)
2)反复执行1),可将D编码为3·l3个元素将其作为颜色序列V′,如式(8)所示;2) Execute 1) repeatedly, and D can be coded as 3·l 3 elements Use it as the color sequence V', as shown in formula (8);
3)将作为空白图像K中(x3·i+k,y3·i+k),i=0,1,…,l3-1,k=0,1,2位置的元素;3) Will As the blank image K (x 3·i+k , y 3·i+k ), i=0, 1,..., l 3 -1, k=0, 1, 2 elements;
例如:E.g:
1)取b=(0100011001010010)2,l2=16,将b中的2值比特以个比特为1组转换为长度为的序列D=(d0,d1,d2,d3)=((0100)2,(0110)2,(0101)2,(0010)2)=(4,6,5,2),对于d0=4,通过式(6)可计算其中(x3·0+0,y3·0+0)=(x0,y0)=(55,64)为C中的第0个坐标,同理可得 1) Take b=(0100011001010010) 2 , l 2 =16, set the binary bits in b to Bits are converted into a group with a length of The sequence D=(d 0 , d 1 , d 2 , d 3 )=((0100) 2 , (0110) 2 , (0101) 2 , (0010) 2 )=(4, 6, 5, 2), For d 0 =4, it can be calculated by formula (6) Where (x 3·0+0 ,y 3·0+0 )=(x 0 ,y 0 )=(55,64) is the 0th coordinate in C, similarly, it can be obtained
2)对于d1=6,可得对于d2=5,可得 对于d3=2,可得按式(7)可得:2) For d 1 =6, it can be obtained For d 2 =5, we can get For d 3 =2, we can get According to formula (7), we can get:
3)将作为K中(x3·i+k,y3·i+k)=(x3·0+0,y3·0+0)=(55,64)位置的元素,将作为K中(x1,y1)=(49,74)位置的元素,将作为K中(x2,y2)=(82,84)位置的元素;将作为K中(x3·i+k,y3·i+k)=(x3·1+0,y3·1+0)=(x3,y3)=(228,113)位置的元素,将作为K中(x4,y4)=(89,73)位置的元素,将作为K中(x5,y5)=(169,196)位置的元素;将作为K中(x3·i+k,y3·i+k)=(x3·2+0,y3·2+0)=(x6,y6)=(170,165)位置的元素,将作为K中(x7,y7)=(253,129)位置的元素,将作为K中(x8,y8)=(104,222)位置的元素;将作为K中(x3·i+k,y3·i+k)=(x3·3+0,y3·3+0)=(x9,y9)=(116,62)位置的元素,将作为K中(x10,y10)=(253,246)位置的元素,将作为K中(x11,y11)=(235,161)位置的元素。3) Will As an element at position (x 3·i+k , y 3·i+k )=(x 3·0+0 , y 3·0+0 )=(55,64) in K, the As an element at position (x 1 , y 1 )=(49, 74) in K, set As an element at position (x 2 , y 2 )=(82, 84) in K; As (x 3·i+k , y 3·i+k )=(x 3·1+0 , y 3·1+0 )=(x 3 , y 3 )=(228,113) position in K element, will As an element at position (x 4 , y 4 )=(89, 73) in K, the As an element at position (x 5 , y 5 )=(169, 196) in K; As (x 3·i+k , y 3·i+k )=(x 3·2+0 , y 3·2+0 )=(x 6 , y 6 )=(170,165) position in K element, will As the element at position (x 7 , y 7 )=(253, 129) in K, set As an element at position (x 8 , y 8 )=(104, 222) in K; As (x 3·i+k , y 3·i+k )=(x 3·3+0 , y 3·3+0 )=(x 9 , y 9 )=(116,62) position in K element, will As the element at position (x 10 , y 10 )=(253, 246) in K, the As an element at position (x 11 , y 11 )=(235, 161) in K.
第5步:首先结合逐像素点纹理生成策略,对空白图像K中剩余位置进行纹理填充,具体方法为:Step 5: First, combine the pixel-by-pixel texture generation strategy to fill the remaining positions in the blank image K with texture. The specific method is:
在空白图像K中,对任意ki,j且记以ki,j为中心的γ×γ邻域为N(ki,j),在纹理样例图T中遍历所有元素tx,y为中心的γ×γ邻域N′(tx,y),按式(8)计算N(ki,j)与N′(tx,y)的相似度,选取与N(ki,j)最相似的γ×γ邻域按对ki,j赋值;反复执行直至空白图像K中所有元素完成赋值,然后将空白图像K输出作为生成的含密纹理图像。In a blank image K, for any k i, j and Denote the γ×γ neighborhood centered on ki, j as N(ki , j ), traverse all the γ×γ neighborhoods N′(t x y) centered on all elements t x, y in the texture sample map , y ), calculate the similarity between N(k i, j ) and N′(t x, y ) according to formula (8), and select the γ×γ neighborhood most similar to N(k i, j ) according to Assign values to k i, j ; execute repeatedly until all elements in the blank image K Complete the assignment, and then output the blank image K as the generated dense texture image.
例如:以γ×γ=3×3为例,若 假设最小,即则按对ki,j赋值,同理可完成空白图像K中所有元素的赋值。For example: Take γ×γ=3×3 as an example, if suppose minimum, ie then press Assign values to k i and j , and in the same way, all elements in the blank image K can be completed assignment.
参见图2,本发明信息恢复方法,包括以下步骤:Referring to Fig. 2, the information recovery method of the present invention comprises the following steps:
第1步:首先输入信道接收到的含密纹理图通过预设密钥k2生成长度为3·l3的随机坐标序列其中(xi,yi)∈h3×w3且C中坐标两两不等,在含密纹理图K′中,对每个(xi,yi)∈C,找到(x3·i+k,y3·i+k),i∈[0,l3-1],k=0,1,2位置的所有元素最终得到颜色序列V′;Step 1: First input the dense texture image received by the channel Generate a random coordinate sequence with a length of 3 l 3 through the preset key k 2 Where ( xi , y i )∈h 3 ×w 3 and the coordinates in C are not equal, in the dense texture map K′, for each ( xi , y i )∈C, find (x 3 · i+k , y 3·i+k ), i∈[0, l 3 -1], k=0, 1, all elements in 2 positions Finally get the color sequence V';
例如:若输入信道接收到的含密纹理图K′=(ki,j)512×512,则h3=w3=512;For example: if the dense texture map K′=(k i, j ) 512×512 received by the input channel, then h 3 =w 3 =512;
仍取线性同余随机发生器的随机数种子作为密钥k2,则按k2=7653,l3=4,可生成长度为3·l3=3·4=12的随机坐标序列为:C=((55,64),(49,74),(82,84),(228,113),(89,73),(169,196),(170,165),(253,129),(104,222),(116,62),(235,246),(235,161));Still take the random number seed of the linear congruential random generator as the key k 2 , then according to k 2 =7653, l 3 =4, the random coordinate sequence with a length of 3·l 3 =3·4=12 can be generated as follows: C=((55, 64), (49, 74), (82, 84), (228, 113), (89, 73), (169, 196), (170, 165), (253, 129) , (104, 222), (116, 62), (235, 246), (235, 161));
在含密纹理图K′中,对每个(xi,yi)∈C,例如对于(x3·i+k,y3·i+k)=(x3·0+0,y3·0+0)=(55,64)可以找到元素对于(x1,y1)=(49,74)可以找到对于(x11,y11)=(235,161)可以找到最终可得颜色序列 In the dense texture map K′, for each (x i , y i )∈C, for example, for (x 3·i+k , y 3·i+k )=(x 3·0+0 , y 3 0+0 )=(55, 64) can find the element For (x 1 , y 1 )=(49, 74) one can find For (x 11 , y 11 )=(235, 161) one can find final color sequence
第2步:首先从纹理样例图中挑选出m+t种颜色构成调色板序列V=(vi)m+t,然后通过调色板序列V中的元素和元素索引的映射关系,将颜色序列V′解码为坐标序列b,具体方法是:Step 2: Start with texture sample image Select m+t colors to form a palette sequence V=(v i ) m+t , and then decode the color sequence V′ into a coordinate sequence b through the mapping relationship between the elements in the palette sequence V and the element indexes , the specific method is:
1)根据调色板序列V找出的索引位置然后按式(9)计算 1) Find out according to the palette sequence V index position of Then calculate according to formula (9)
2)记位于区间[0,m-1]的元素数量记为Ec,则按以下5种情况计算di:2) note The number of elements in the interval [0, m-1] is recorded as E c , and d i is calculated according to the following five situations:
①若Ec=0,则置 ①If E c =0, set
②若Ec=1且位于区间[0,m-1]的元素值为v,则置di=v;②If E c =1 and The value of the element located in the interval [0, m-1] is v, then set d i =v;
③若Ec=2且位于区间[0,m-1]的元素值为v1,v2,则置di=(v1+v2)/2;③If E c =2 and The element values in the interval [0, m-1] are v 1 and v 2 , then set d i =(v 1 +v 2 )/2;
④若Ec=3且存在两个及两个以上的值相等,记相等值为v,则置di=v;④ If E c =3 and There are two or more values that are equal, record the equal value as v, then set d i = v;
⑤若Ec=3且两两不等,则置 ⑤If E c =3 and If the pair is not equal, set
3)重复执行2)直至随机坐标序列C中所有坐标处理完毕,然后按式(10)得到长度为l2的2值坐标序列b:3) Repeat 2) until all the coordinates in the random coordinate sequence C are processed, and then according to the formula (10) to obtain the binary coordinate sequence b with a length of l 2 :
式(10)中,Left()是2值比特位串截取函数,其中第1个参数为要截取的2值比特位串,第2个参数是从左起截取的长度,l2按式(11)确定:In formula (10), Left() is a binary bit string interception function, wherein the first parameter is the binary bit string to be intercepted, and the second parameter is the length to be intercepted from the left, l 2 according to formula ( 11) Determine:
例如:取h2=w2=64,m=16,t=2,则可从T=(tx,y)64×64中挑选出现频率最高的18种颜色构成调色板序列V=(vi)18;For example: take h 2 =w 2 =64, m=16, t=2, then 18 colors with the highest frequency of occurrence can be selected from T=(t x, y ) 64×64 to form a palette sequence V=( v i ) 18 ;
1)若根据V=(vi)18找出的索引位置为的索引位置为的索引位置为的索引位置为的索引位置为的索引位置为的索引位置为的索引位置为的索引位置为的索引位置为的索引位置为的索引位置为则按式(9)可得:1) If find out according to V=(v i ) 18 is indexed at is indexed at is indexed at is indexed at is indexed at is indexed at is indexed at is indexed at is indexed at is indexed at is indexed at is indexed at Then according to formula (9), we can get:
同理得 empathy
2)若记则位于区间[0,15]的元素数量为Ec=3,由Ec=3且存在两个及两个以上的值相等,记相等值v=4,所以d0=4;2) Ruoji but The number of elements in the interval [0, 15] is E c =3, by E c =3 and There are two or more values that are equal, record the equal value v=4, so d 0 =4;
3)若记则位于区间[0,15]的元素数量为Ec=3,由Ec=3且存在两个及两个以上的值相等,记相等值v=6,得d1=6;若记则位于区间[0,15]的元素数量为Ec=3,由Ec=3且存在两个及两个以上的值相等,记相等值v=5,得d2=5;若记则位于区间[0,15]的元素数量为Ec=3,由Ec=3且存在两个及两个以上的值相等,记相等值v=2,得d3=2;假设l1=2,按式(10)得到长度为的2值坐标序列b=Left(bin(d0)||bin(d1)||bin(d2)||bin(d3),l2)=Left(bin(4)||bin(6)||bin(5)||bin(2),8)=(0100011001010010)2;3) Ruoji but The number of elements in the interval [0, 15] is E c =3, by E c =3 and There are two or more values that are equal, record the equal value v=6, get d 1 =6; if record but The number of elements in the interval [0, 15] is E c =3, by E c =3 and There are two or more values that are equal, record the equal value v=5, get d 2 =5; if record but The number of elements in the interval [0, 15] is E c =3, by E c =3 and There are two or more values that are equal, record the equal value v=2, get d 3 =2; suppose l 1 =2, According to formula (10), the length is Binary coordinate sequence b=Left(bin(d 0 )||bin(d 1 )||bin(d 2 )||bin(d 3 ), l 2 )=Left(bin(4)||bin( 6)||bin(5)||bin(2), 8)=(0100011001010010) 2 ;
第3步:首先通过预设密钥k1生成R阶密钥图S的具体方法是由密钥k1生成分辨率为h1×w1的R阶密钥图si,j∈[0,2R-1],然后结合2值比特位串b在R阶密钥图S中提取出秘密信息B,具体方法是:Step 3: Firstly, the specific method of generating the R-order key map S through the preset key k 1 is to generate an R-order key map S with a resolution of h 1 ×w 1 from the key k 1 s i, j ∈ [0, 2 R -1], and then combined with the binary bit string b to extract the secret information B in the R-order key map S, the specific method is:
1)将2值比特位串b的2值比特以为1组,划分为l1组,记为分别按式(12)和式(13)从每个分组中截取前个2值比特和后个2值比特作为坐标(ui,vi),然后将S中(ui,vi)位置对应的元素赋值给ri如式(14)所示,其中i=0,1,…,l1-1;1) Bind the binary bit of the binary bit string b to is 1 group, divided into l 1 groups, recorded as According to formula (12) and formula (13) from each group before interception 2-valued bits and after two 2-value bits as the coordinates (u i , v i ), and then assign the element corresponding to the position (u i , v i ) in S to r i as shown in formula (14), where i=0, 1, ..., l 1 -1;
2)将ri,i=0,1,…,l1-1分别转换为长度为R的2进制比特位串并将其串联为长度为N的2进制比特位串B=(Bi)N输出。2) convert r i , i=0, 1, ..., l 1 -1 into binary bit strings of length R and concatenate them into binary bit strings of length N B=(B i ) N output.
例如:取线性同余随机数发生器的随机种子作为密钥k1,例如取k1=6546,R=8,h1=w1=16,则可生成分辨率为16×16的8阶密钥图S,假设b=(0 1 0 0 0 1 1 0 0 1 02;For example: take the random seed of the linear congruential random number generator as the key k 1 , for example, take k 1 =6546, R=8, h 1 =w 1 =16, then an 8th order with a resolution of 16×16 can be generated Key map S, suppose b=(0 1 0 0 0 1 1 0 0 1 0 2 ;
1)取l1=2,将b的2值比特以为1组,划分为l1=2组,分别为按式(11)截取的前个2值比特得到按式(12)截取的后个2值比特得到同理可由得u1=(0101)2,v1=(0010)2,假设S上元素s4,6=214,s5,2=178,然后将S中(u0,v0)=(4,6)位置对应的元素赋值给r0,可得r0=s4,6=214,将S中(u1,v1)=(5,2)位置对应的元素赋值给r1,可得r1=s5,2=178;1) Take l 1 =2, Set the 2-value bits of b to is 1 group, divided into l 1 =2 groups, respectively Intercept according to formula (11) before 2-valued bits get Intercept according to formula (12) after the 2-valued bits get By the same token Get u 1 =(0101) 2 , v 1 =(0010) 2 , assuming that elements s 4,6 =214, s 5,2 =178 in S, then (u 0 , v 0 )=(4, 6) The element corresponding to the position is assigned to r 0 , r 0 = s 4, 6 = 214, and the element corresponding to the position (u 1 , v 1 ) = (5, 2) in S is assigned to r 1 , it can be obtained r 1 =s 5,2 =178;
2)将r0=214,r1=178分别转换为长度为R=8的2进制比特位串并将其串联为长度为N=16的2进制比特位串B=(bin(r0)||bin(ri))=((bin(214)||bin(178)))=(1101011010110010)2输出。2) Convert r 0 =214, r 1 =178 into binary bit strings of length R=8 respectively and concatenate them into binary bit strings of length N=16 B=(bin(r 0 )||bin(r i ))=((bin(214)||bin(178)))=(1101011010110010) 2 output.
参见图3~图31,图8~图11是以图3~图6为纹理样例图,以图7为密图,用户密钥分别取key1=6546、key2=7653,key1=6548、key2=7659,key1=6546、key2=7653,key1=6548、key2=7659,按图1对应的嵌入流程得到公开的含密纹理图像。图12~图15是按图2提取流程,提供正确的密钥,依次从图8~图11中提取出的密图,相对于图7的误码率BR都为0%,因此密图可正确提取。图16~图19是对图8~图11分别进行1.9%、3.4%、4.1%、2.6%的剪裁攻击后的含密纹理图像。图24~图27是按照图2提取流程,从图16~图19中提取出的密图,图24相对于图7的误码率BR为0.63%,PSNR=30.7281dB,图25相对于图7的误码率BR为1.12%,PSNR=28.1291dB,图26相对于图7的误码率BR为1.37%,PSNR=26.7750dB,图27相对于图7的误码率BR为0.85%,PSNR=29.8146dB,因此重构密图与原密图足够相似,说明本发明的方法有一定的抗剪裁攻击能力。图20~图23是对图8~图11分别进行8%、20%、15%、10%的随机噪声攻击后的含密纹理图像。图28~图31是按照图2提取流程,从图20~图23中提取出的密图,图28相对于图7的误码率BR为2.66%,PSNR=24.3136dB,图29相对于图7的误码率BR为6.35%,PSNR=20.1874dB,图30相对于图7的误码率BR为4.79%,PSNR=21.7039dB,图31相对于图7的误码率BR为3.13%,PSNR=23.7018dB,因此重构密图与原密图足够相似,说明本发明的方法有一定的抗随机噪声攻击能力。Refer to Figures 3 to 31, Figures 8 to 11 use Figures 3 to 6 as texture sample images, and Figure 7 as the encrypted image, and the user keys are respectively key 1 = 6546, key 2 = 7653, key 1 = 6548, key 2 = 7659, key 1 = 6546, key 2 = 7653, key 1 = 6548, key 2 = 7659, according to the embedding process corresponding to Figure 1 to obtain the public dense texture image. Fig. 12~Fig. 15 is according to Fig. 2 extracting process, provides correct key, and the cipher map extracted from Fig. 8 ~ Fig. 11 successively, all is 0% with respect to the bit error rate BR of Fig. 7, so cipher map can be Extract correctly. Figures 16 to 19 are images with dense textures after performing 1.9%, 3.4%, 4.1%, and 2.6% clipping attacks on Figures 8 to 11, respectively. Figures 24 to 27 are the dense maps extracted from Figures 16 to 19 according to the extraction process in Figure 2. Compared with Figure 7, the bit error rate BR of Figure 24 is 0.63%, PSNR=30.7281dB, and Figure 25 is compared to Figure 7 The bit error rate BR of 7 is 1.12%, PSNR=28.1291dB, the bit error rate BR of Fig. 26 relative to Fig. 7 is 1.37%, PSNR = 26.7750dB, the bit error rate BR of Fig. 27 relative to Fig. 7 is 0.85%, PSNR=29.8146dB, so the reconstructed secret image is similar enough to the original secret image, indicating that the method of the present invention has a certain ability to resist clipping attacks. Figures 20 to 23 are images with dense textures after 8%, 20%, 15%, and 10% random noise attacks are performed on Figures 8 to 11, respectively. Figures 28 to 31 are the dense maps extracted from Figures 20 to 23 according to the extraction process in Figure 2. Compared with Figure 7, the bit error rate BR of Figure 28 is 2.66%, PSNR=24.3136dB, and Figure 29 is compared to Figure 7 The bit error rate BR of 7 is 6.35%, PSNR=20.1874dB, the bit error rate BR of Fig. 30 relative to Fig. 7 is 4.79%, PSNR = 21.7039dB, and the bit error rate BR of Fig. 31 relative to Fig. 7 is 3.13%, PSNR=23.7018dB, so the reconstructed secret image is similar enough to the original secret image, which shows that the method of the present invention has a certain ability of resisting random noise attack.
本发明信息伪装方法和信息恢复方法如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。基于这样的理解,本发明实现上述实施例方法中的全部或部分流程,也可以通过计算机程序来指令相关的硬件来完成,所述的计算机程序可存储于一计算机可读存储介质中,该计算机程序在被处理器执行时,可实现上述各个方法实施例的步骤。其中,所述计算机程序包括计算机程序代码,所述计算机程序代码可以为源代码形式、对象代码形式、可执行文件或某些中间形式等。计算机可读存储介质包括永久性和非永久性、可移动和非可移动媒体可以由任何方法或技术来实现信息存储。信息可以是计算机可读指令、数据结构、程序的模块或其他数据。需要说明的是,所述计算机可读介质包含的内容可以根据司法管辖区内立法和专利实践的要求进行适当的增减,例如在某些司法管辖区,根据立法和专利实践,计算机可读介质不包括电载波信号和电信信号。If the information camouflage method and the information recovery method of the present invention are implemented in the form of software function units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the present invention realizes all or part of the processes in the methods of the above embodiments, and can also be completed by instructing related hardware through a computer program. The computer program can be stored in a computer-readable storage medium, and the computer When the program is executed by the processor, the steps in the above-mentioned various method embodiments can be realized. Wherein, the computer program includes computer program code, and the computer program code may be in the form of source code, object code, executable file or some intermediate form. Computer-readable storage media includes both volatile and non-permanent, removable and non-removable media by any method or technology for storage of information. Information may be computer readable instructions, data structures, modules of a program, or other data. It should be noted that the content contained in the computer-readable medium may be appropriately increased or decreased according to the requirements of legislation and patent practice in the jurisdiction. For example, in some jurisdictions, computer-readable media Excludes electrical carrier signals and telecommunication signals.
在示例性实施例中,还提供了一种计算机可读存储介质,所述计算机可读存储介质存储有计算机程序,所述计算机程序被处理器执行时实现所述信息伪装方法或信息恢复方法的步骤。其中,所述计算机存储介质可以是计算机能够存取的任何可用介质或数据存储设备,包括但不限于磁性存储器(例如软盘、硬盘、磁带、磁光盘(MO)等)、光学存储器(例如CD、DVD、BD、HVD等)、以及半导体存储器(例如ROM、EPROM、EEPROM、非易失性存储器(NANDFLASH)、固态硬盘(SSD))等。In an exemplary embodiment, a computer-readable storage medium is also provided, the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the method for disguising information or the method for recovering information is implemented. step. Wherein, the computer storage medium may be any available medium or data storage device that can be accessed by a computer, including but not limited to magnetic storage (such as floppy disk, hard disk, magnetic tape, magneto-optical disk (MO), etc.), optical storage (such as CD, DVD, BD, HVD, etc.), and semiconductor memory (such as ROM, EPROM, EEPROM, non-volatile memory (NANDFLASH), solid-state disk (SSD)), etc.
在示例性实施例中,还提供了一种计算机设备,包括存储器、处理器以及存储在所述存储器中并可在所述处理器上运行的计算机程序,所述处理器执行所述计算机程序时实现所述信息伪装方法或信息恢复方法的步骤。处理器可能是中央处理单元(CentralProcessingUnit,CPU),还可以是其他通用处理器、数字信号处理器(DigitalSignalProcessor,DSP)、专用集成电路(ApplicationSpecificIntegratedCircuit,ASIC)、现成可编程门阵列(Field-ProgrammableGateArray,FPGA)或者其他可编程逻辑器件、分立门或者晶体管逻辑器件、分立硬件组件等。In an exemplary embodiment, there is also provided a computer device, including a memory, a processor, and a computer program stored in the memory and operable on the processor, when the processor executes the computer program Steps for implementing the information forgery method or the information recovery method. The processor may be a central processing unit (Central Processing Unit, CPU), or other general-purpose processors, digital signal processors (Digital Signal Processor, DSP), application specific integrated circuits (Application Specific Integrated Circuit, ASIC), off-the-shelf programmable gate arrays (Field-Programmable Gate Array, FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc.
本发明采用逐像素点纹理合成的方法来产生含密纹理,含密纹理图像是逐点生成而不是纹理小块拼接生成,所以避免了基于缝合线算法的块拼接生成式信息隐藏存在的固有拼接痕迹并减少了重复模式的产生,安全性更高,且不易引起攻击者的怀疑。有效解决了传统基于块拼接纹理合成的信息隐藏方法中由于含密纹理图像采用缝合线算法来对重叠区域的纹理进行拼接,不可避免地会产生缝合痕迹与重复纹理模式,从而不能对秘密信息进行掩盖的问题。通过密钥产生的密钥图坐标来表达秘密信息,含密掩体图中嵌入的是秘密信息在密钥图中的坐标信息而不是秘密信息,避免了秘密信息的直接信道传输,且秘密信息的嵌入和提取过程完全依赖于密钥,具有较高的安全性。有效解决了现有基于块拼接纹理合成的信息隐藏方法由于使用样本小块编码秘密信息,秘密信息在信道中传输,安全性不高的问题。本发明引入了基于多备份和区间扩展的认证策略,在嵌密时嵌入多份秘密信息,在提取时,将多份秘密信息全部提取出来,然后对比多份秘密信息,将秘密信息相同最多份的秘密信息作为正确提取出的秘密信息,若都不相同则取均值作为秘密信息,该策略可有效地提高了提取秘密信息的抗攻击能力。有效解决了现有基于块拼接纹理合成的信息隐藏方法由于缺少认证信息,若含密掩体图遭受攻击之后无法确定提取出的秘密信息是否为正确的秘密信息的问题。The present invention adopts the pixel-by-pixel texture synthesis method to generate dense texture, and the dense texture image is generated point by point instead of splicing small texture blocks, so it avoids the inherent splicing existing in the block splicing generative information hiding based on the suture line algorithm Traces and reduce the generation of repeated patterns, higher security, and less likely to arouse the suspicion of attackers. It effectively solves the problem that in the traditional information hiding method based on block splicing texture synthesis, because the dense texture image uses the seam algorithm to stitch the texture of the overlapping area, it will inevitably produce stitching traces and repeated texture patterns, so that the secret information cannot be hidden. cover up the problem. The secret information is expressed through the coordinates of the key map generated by the key, and the coordinate information of the secret information in the key map is embedded in the secret bunker map instead of the secret information, which avoids the direct channel transmission of the secret information, and the secret information The process of embedding and extracting completely depends on the key, which has high security. It effectively solves the problem that the existing information hiding method based on block splicing texture synthesis is not high in security due to the use of small sample blocks to encode secret information, and the secret information is transmitted in the channel. The present invention introduces an authentication strategy based on multi-backup and interval expansion. When embedding multiple secret information, when extracting, all multiple secret information are extracted, and then compared with multiple secret information, the secret information is the same at most The secret information is taken as the correctly extracted secret information, and if they are not the same, the average value is taken as the secret information. This strategy can effectively improve the anti-attack ability of extracting secret information. It effectively solves the problem that the existing information hiding method based on block splicing texture synthesis lacks authentication information, and it is impossible to determine whether the extracted secret information is correct secret information if the secret bunker map is attacked.
以上内容仅为说明本发明的技术思想,不能以此限定本发明的保护范围,凡是按照本发明提出的技术思想,在技术方案基础上所做的任何改动,均落入本发明权利要求书的保护范围之内。The above content is only to illustrate the technical ideas of the present invention, and cannot limit the protection scope of the present invention. Any changes made on the basis of the technical solutions according to the technical ideas proposed in the present invention shall fall within the scope of the claims of the present invention. within the scope of protection.
Claims (10)
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910711927.9A CN110430335B (en) | 2019-08-02 | 2019-08-02 | A method, device and storage medium for information disguise and recovery |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910711927.9A CN110430335B (en) | 2019-08-02 | 2019-08-02 | A method, device and storage medium for information disguise and recovery |
Publications (2)
Publication Number | Publication Date |
---|---|
CN110430335A true CN110430335A (en) | 2019-11-08 |
CN110430335B CN110430335B (en) | 2021-05-11 |
Family
ID=68412323
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201910711927.9A Active CN110430335B (en) | 2019-08-02 | 2019-08-02 | A method, device and storage medium for information disguise and recovery |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN110430335B (en) |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN112235291A (en) * | 2020-10-13 | 2021-01-15 | 陕西师范大学 | Pixel-by-pixel texture generative information hiding and restoration method, device and medium |
CN113992327A (en) * | 2021-11-16 | 2022-01-28 | 陕西师范大学 | Lossless approximate shared storage recovery method and system based on prime number decomposition |
CN118233570A (en) * | 2024-05-16 | 2024-06-21 | 华侨大学 | Method and device for generating anti-counterfeiting image based on microscopic geometric texture |
Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2004079980A2 (en) * | 2003-03-05 | 2004-09-16 | Xsides Corporation | System and method for data encryption |
CN106998471A (en) * | 2017-03-16 | 2017-08-01 | 中国人民武装警察部队工程大学 | A kind of video hidden method and video extraction method for changing predictive mode |
CN107613304A (en) * | 2017-09-11 | 2018-01-19 | 西安电子科技大学 | Mobile terminal video stream stealth transmission method based on Android platform |
CN107846530A (en) * | 2017-09-28 | 2018-03-27 | 四川长虹电器股份有限公司 | Digital watermarking algorithm |
CN108537049A (en) * | 2018-03-14 | 2018-09-14 | 中山大学 | A kind of adaptive steganographic algorithm based on bianry image |
CN108898537A (en) * | 2018-04-03 | 2018-11-27 | 宁波大学 | A kind of digital picture steganography method |
-
2019
- 2019-08-02 CN CN201910711927.9A patent/CN110430335B/en active Active
Patent Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2004079980A2 (en) * | 2003-03-05 | 2004-09-16 | Xsides Corporation | System and method for data encryption |
CN106998471A (en) * | 2017-03-16 | 2017-08-01 | 中国人民武装警察部队工程大学 | A kind of video hidden method and video extraction method for changing predictive mode |
CN107613304A (en) * | 2017-09-11 | 2018-01-19 | 西安电子科技大学 | Mobile terminal video stream stealth transmission method based on Android platform |
CN107846530A (en) * | 2017-09-28 | 2018-03-27 | 四川长虹电器股份有限公司 | Digital watermarking algorithm |
CN108537049A (en) * | 2018-03-14 | 2018-09-14 | 中山大学 | A kind of adaptive steganographic algorithm based on bianry image |
CN108898537A (en) * | 2018-04-03 | 2018-11-27 | 宁波大学 | A kind of digital picture steganography method |
Non-Patent Citations (2)
Title |
---|
毛炳华等: "基于DCT域相关性的非对称JPEG隐写", 《计算机科学》 * |
潘琳等: "基于构造纹理图像的数字隐写", 《应用科学学报》 * |
Cited By (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN112235291A (en) * | 2020-10-13 | 2021-01-15 | 陕西师范大学 | Pixel-by-pixel texture generative information hiding and restoration method, device and medium |
CN112235291B (en) * | 2020-10-13 | 2023-04-07 | 陕西师范大学 | Pixel-by-pixel texture generation type information hiding and recovering method, equipment and medium |
CN113992327A (en) * | 2021-11-16 | 2022-01-28 | 陕西师范大学 | Lossless approximate shared storage recovery method and system based on prime number decomposition |
CN113992327B (en) * | 2021-11-16 | 2023-10-20 | 陕西师范大学 | Lossless approximate split-memory recovery method and system based on prime number decomposition |
CN118233570A (en) * | 2024-05-16 | 2024-06-21 | 华侨大学 | Method and device for generating anti-counterfeiting image based on microscopic geometric texture |
CN118233570B (en) * | 2024-05-16 | 2024-07-26 | 华侨大学 | Method and device for generating anti-counterfeiting image based on micro-geometric texture |
Also Published As
Publication number | Publication date |
---|---|
CN110430335B (en) | 2021-05-11 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN108648133B (en) | Non-embedded camouflage method combining block rotation and mosaic | |
CN104200424B (en) | Difference conversion based (K, N) meaningful image sharing and recovering method | |
CN101452569B (en) | Processing method of image latent writing based on auxiliary pixel | |
CN110430336B (en) | Method, apparatus and storage medium for image hiding and restoring | |
CN110430335B (en) | A method, device and storage medium for information disguise and recovery | |
CN103413269A (en) | Image steganography method and secret information extraction method | |
CN106408495B (en) | A High PSNR Fragile Watermarking Method Based on Chaos Theory | |
CN106600517A (en) | An EMD-3-based multi-carrier dense image sharing and reconstruction method | |
CN110430337A (en) | Method, equipment and the storage medium that image camouflage and image restore | |
Ye et al. | Research on reversible image steganography of encrypted image based on image interpolation and difference histogram shift | |
CN103020496A (en) | Digital watermark encryption realization method | |
CN103996163B (en) | A digital watermark embedding and extraction method, embedding and extraction device and system | |
Lin et al. | Applying projection and B-spline to image authentication and remedy | |
CN109447886B (en) | Binding to EMD-2 1 Embedded multi-carrier secret map separate storage method with recovery | |
CN113014742A (en) | Image tampering detection positioning and self-recovery method based on fragile watermark | |
CN112288617A (en) | Mosaic-based information hiding and recovery method, device and medium | |
CN104702814B (en) | (K, N) Image of Meaningful based on triple backups point is deposited and restoration methods | |
CN114979402B (en) | Shared image storage method based on matrix coding embedding | |
CN112184841B (en) | Block replacement generation type information hiding and recovering method, equipment and medium | |
CN108171665B (en) | A Multi-version Backup and Restricted Two-Factor Authentication Master Key (t,s,k,n) Image Sharing Method | |
CN117201695A (en) | Generative camouflage, recovery method and system for stone paintings combined with Bezier curves | |
CN110430037A (en) | A kind of image encryption method and terminal | |
CN113032807B (en) | Authenticatable (2,3) secret image sharing method and device based on mixed fractal matrix | |
Zhang et al. | Two-level QR code scheme based on region matrix image secret sharing algorithm | |
CN112235291B (en) | Pixel-by-pixel texture generation type information hiding and recovering method, equipment and medium |
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 | ||
TR01 | Transfer of patent right |
Effective date of registration: 20231214 Address after: No. 546, Luoyu Road, Hongshan District, Wuhan, Hubei Province, 430000 Patentee after: HUBEI CENTRAL CHINA TECHNOLOGY DEVELOPMENT OF ELECTRIC POWER Co.,Ltd. Address before: 710119 No. 620 West Chang'an Street, Chang'an District, Xi'an City, Shaanxi Province Patentee before: Shaanxi Normal University |
|
TR01 | Transfer of patent right |