├── 0-测试数据-0 ├── Average_bpp_BOSSbase.m ├── Average_bpp_BOW2OrigEp3.m ├── Average_bpp_UCID.m ├── bpp_BOSSbase.mat ├── bpp_BOWS2OrigEp3.mat ├── bpp_UCID.mat ├── len_BOSSbase.mat ├── len_BOWS2OrigEp3.mat ├── len_UCID.mat ├── num_BOSSbase.mat ├── num_BOWS2OrigEp3.mat ├── num_UCID.mat ├── over_BOSSbase.mat ├── over_BOWS2OrigEp3.mat ├── over_UCID.mat ├── room_BOSSbase.mat ├── room_BOWS2OrigEp3.mat └── room_UCID.mat ├── BinaryConversion_10_2.m ├── BinaryConversion_2_10.m ├── BitPlanes_Compress.m ├── BitPlanes_Embed.m ├── BitPlanes_Extract.m ├── BitPlanes_Rearrange.m ├── BitPlanes_Recover.m ├── BitStream_Compress.m ├── BitStream_DeCompress.m ├── Data_Embed.m ├── Data_Encrypt.m ├── Data_Extract.m ├── GetHis.m ├── Image_ReShuffle.m ├── Image_Recover.m ├── Image_Shuffle.m ├── Main.m ├── Main_BOSSbase.m ├── Main_BOWS2OrigEp3.m ├── Main_UCID.m ├── PSNR.m ├── Prediction_Error.m ├── README.md ├── Vacate_Encrypt.m ├── Vacate_Room.m ├── bpp_BOSSbase.mat ├── len_BOSSbase.mat ├── num_BOSSbase.mat ├── over_BOSSbase.mat ├── room_BOSSbase.mat └── 测试图像 └── Lena.tiff /0-测试数据-0/Average_bpp_BOSSbase.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/0-测试数据-0/Average_bpp_BOSSbase.m -------------------------------------------------------------------------------- /0-测试数据-0/Average_bpp_BOW2OrigEp3.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/0-测试数据-0/Average_bpp_BOW2OrigEp3.m -------------------------------------------------------------------------------- /0-测试数据-0/Average_bpp_UCID.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/0-测试数据-0/Average_bpp_UCID.m -------------------------------------------------------------------------------- /0-测试数据-0/bpp_BOSSbase.mat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/0-测试数据-0/bpp_BOSSbase.mat -------------------------------------------------------------------------------- /0-测试数据-0/bpp_BOWS2OrigEp3.mat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/0-测试数据-0/bpp_BOWS2OrigEp3.mat -------------------------------------------------------------------------------- /0-测试数据-0/bpp_UCID.mat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/0-测试数据-0/bpp_UCID.mat -------------------------------------------------------------------------------- /0-测试数据-0/len_BOSSbase.mat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/0-测试数据-0/len_BOSSbase.mat -------------------------------------------------------------------------------- /0-测试数据-0/len_BOWS2OrigEp3.mat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/0-测试数据-0/len_BOWS2OrigEp3.mat -------------------------------------------------------------------------------- /0-测试数据-0/len_UCID.mat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/0-测试数据-0/len_UCID.mat -------------------------------------------------------------------------------- /0-测试数据-0/num_BOSSbase.mat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/0-测试数据-0/num_BOSSbase.mat -------------------------------------------------------------------------------- /0-测试数据-0/num_BOWS2OrigEp3.mat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/0-测试数据-0/num_BOWS2OrigEp3.mat -------------------------------------------------------------------------------- /0-测试数据-0/num_UCID.mat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/0-测试数据-0/num_UCID.mat -------------------------------------------------------------------------------- /0-测试数据-0/over_BOSSbase.mat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/0-测试数据-0/over_BOSSbase.mat -------------------------------------------------------------------------------- /0-测试数据-0/over_BOWS2OrigEp3.mat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/0-测试数据-0/over_BOWS2OrigEp3.mat -------------------------------------------------------------------------------- /0-测试数据-0/over_UCID.mat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/0-测试数据-0/over_UCID.mat -------------------------------------------------------------------------------- /0-测试数据-0/room_BOSSbase.mat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/0-测试数据-0/room_BOSSbase.mat -------------------------------------------------------------------------------- /0-测试数据-0/room_BOWS2OrigEp3.mat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/0-测试数据-0/room_BOWS2OrigEp3.mat -------------------------------------------------------------------------------- /0-测试数据-0/room_UCID.mat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/0-测试数据-0/room_UCID.mat -------------------------------------------------------------------------------- /BinaryConversion_10_2.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/BinaryConversion_10_2.m -------------------------------------------------------------------------------- /BinaryConversion_2_10.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/BinaryConversion_2_10.m -------------------------------------------------------------------------------- /BitPlanes_Compress.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/BitPlanes_Compress.m -------------------------------------------------------------------------------- /BitPlanes_Embed.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/BitPlanes_Embed.m -------------------------------------------------------------------------------- /BitPlanes_Extract.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/BitPlanes_Extract.m -------------------------------------------------------------------------------- /BitPlanes_Rearrange.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/BitPlanes_Rearrange.m -------------------------------------------------------------------------------- /BitPlanes_Recover.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/BitPlanes_Recover.m -------------------------------------------------------------------------------- /BitStream_Compress.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/BitStream_Compress.m -------------------------------------------------------------------------------- /BitStream_DeCompress.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/BitStream_DeCompress.m -------------------------------------------------------------------------------- /Data_Embed.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/Data_Embed.m -------------------------------------------------------------------------------- /Data_Encrypt.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/Data_Encrypt.m -------------------------------------------------------------------------------- /Data_Extract.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/Data_Extract.m -------------------------------------------------------------------------------- /GetHis.m: -------------------------------------------------------------------------------- 1 | function P=GetHis(I) 2 | P=zeros(1,256); 3 | for i=1:numel(I) 4 | P(I(i)+1)=P(I(i)+1)+1; 5 | end 6 | % plot(P); -------------------------------------------------------------------------------- /Image_ReShuffle.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/Image_ReShuffle.m -------------------------------------------------------------------------------- /Image_Recover.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/Image_Recover.m -------------------------------------------------------------------------------- /Image_Shuffle.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/Image_Shuffle.m -------------------------------------------------------------------------------- /Main.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/Main.m -------------------------------------------------------------------------------- /Main_BOSSbase.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/Main_BOSSbase.m -------------------------------------------------------------------------------- /Main_BOWS2OrigEp3.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/Main_BOWS2OrigEp3.m -------------------------------------------------------------------------------- /Main_UCID.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/Main_UCID.m -------------------------------------------------------------------------------- /PSNR.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/PSNR.m -------------------------------------------------------------------------------- /Prediction_Error.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/Prediction_Error.m -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Reversible Data Hiding in Encrypted Images Based on Pixel Prediction and Bit-plane Compression 2 | 3 | This code is the implementation of the paper "Reversible Data Hiding in Encrypted Images Based on Multi-MSB Prediction and Huffman Coding". 4 | 5 | [Paper Link](https://ieeexplore.ieee.org/abstract/document/9178468) 6 | 7 | ## Abstract 8 | 9 | Reversible data hiding in encrypted images (RDHEI) receives growing attention because it protects the content of the original image while the embedded data can be accurately extracted and the original image can be reconstructed losslessly. To make full use of the correlation of the adjacent pixels, this paper proposes an RDHEI scheme based on pixel prediction and bit-plane compression. Firstly, the original image are divided into the blocks of equal size and the prediction error of the original image is calculated. Then, the 8 bit-planes of prediction error are executed rearrangement and bit-stream compression, respectively. Finally, the image after vacating room is encrypted by a stream cipher and the additional data is embedded in the vacated room by multi-LSBs (Least Significant Bits) substitution. Experimental results show that the embedding capacity of the proposed method outperforms the state-of-the-art methods. 10 | 11 | ## 摘要 12 | 密文域可逆信息隐藏(RDHEI)受到越来越多的关注,因为它可以保护原始图像的内容,同时可以准确地提取嵌入的数据,并且可以无损地重建原始图像。 为了充分利用相邻像素的相关性,本文提出了一种基于像素预测和位平面压缩的RDHEI方案。 首先,将原始图像分成相等大小的块,并计算原始图像的预测误差。 然后,分别执行8个预测误差的位平面的重排和位流压缩。 最后,通过流密码对腾出空间后的图像进行加密,并通过多LSB(最低有效位)替换将附加数据嵌入到腾出的空间中。 实验结果表明,该方法的嵌入能力优于现有方法。 13 | 14 | ## How to cite our paper 15 | 16 | @article{yin2020reversible, 17 | title={Reversible Data Hiding in Encrypted Images Based on Pixel Prediction and Bit-plane Compression}, 18 | author={Yin, Zhaoxia and Peng, Yinyin and Xiang, Youzhi}, 19 | journal={IEEE Transactions on Dependable and Secure Computing}, 20 | year={2020}, 21 | publisher={IEEE} 22 | } 23 | -------------------------------------------------------------------------------- /Vacate_Encrypt.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/Vacate_Encrypt.m -------------------------------------------------------------------------------- /Vacate_Room.m: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/Vacate_Room.m -------------------------------------------------------------------------------- /bpp_BOSSbase.mat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/bpp_BOSSbase.mat -------------------------------------------------------------------------------- /len_BOSSbase.mat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/len_BOSSbase.mat -------------------------------------------------------------------------------- /num_BOSSbase.mat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/num_BOSSbase.mat -------------------------------------------------------------------------------- /over_BOSSbase.mat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/over_BOSSbase.mat -------------------------------------------------------------------------------- /room_BOSSbase.mat: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/room_BOSSbase.mat -------------------------------------------------------------------------------- /测试图像/Lena.tiff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/edu-yinzhaoxia/Reversible-Data-Hiding-in-Encrypted-Images-Based-on-Pixel-Prediction-and-Bit-plane-Compression/bba6f0e178d9c6d69de83248c1c3ed38696b31f5/测试图像/Lena.tiff --------------------------------------------------------------------------------