- Open Access
Block-based image hashing with restricted blocking strategy for rotational robustness
© Xiang and Yang; licensee Springer. 2012
Received: 1 July 2011
Accepted: 4 April 2012
Published: 4 April 2012
Image hashing is a potential solution for image content authentication (a desired image hashing algorithm should be robust to common image processing operations and various geometric distortions). In the literature, researchers pay more attention to block-based image hashing algorithms due to their robustness to common image processing operations (such as lossy compression, low-pass filtering, and additive noise). However, the block-based hashing strategies are sensitive to rotation processing operations. This indicates that the robustness of the block-based hashing methods against rotation operations is an important issue. Towards this direction, in this article we propose a restricted blocking strategy by investigating effect of two rotation operations on an image and its blocks in both theoretical and experimental ways. Furthermore, we apply the proposed blocking strategy for the recently reported non-negative matrix factorization (NMF) hashing. Experimental results have demonstrated the validity of the block-based hashing algorithms with restricted blocking strategy for rotation operations.
With the development of the Internet and multimedia processing techniques, more and more digital media products become available through different online services and easy to distribute illegal copies. Recently, multimedia hashing functions [1, 2] have been introduced as a potential solution for tracing the unauthorized use of digital media files since the traditional cryptography hash functions (such as MD5, SHA-1) cannot satisfy the requirements of multimedia content authentication because the cryptographic hash is sensitive to every single bit of input. In the literature, the techniques used for image authentication can be classified into two categories: (1) watermark based [3–6] and (2) media hash based [7, 8]. The main difference between a watermark (robust , reversible , fragile  and semi-fragile ) and a hash is that the embedding process of the former requires the content of the media to change. Robustness of media hashing is a desired aspect. Robustness means that the hash should be resistant to content-preserving signal processing operations, e.g., image hashing should be insensitive to those common geometric deformation, lossy compression and filtering operations, which do distort the image but preserve its visual quality.
Media hashing can be broadly classified into audio hashing [9, 10], video hashing [11, 12] and image hashing [7, 8, 13–21] according to the diversity of media dimensionality space. In this article, we are focusing on image hashing. In the literature, there are a lot robust image hash functions. In , Fridrich and Goljan addressed a robust image hash for tamper control problem by mapping image blocks into key-based template. In , a robust image hash was used for indexing and database searching by using the statistic property of wavelet coefficients of image block. Perceptual image hashing was also used for content-dependent key generation in video watermarking . The hash methods proposed in [13, 14] were aiming to coping with common image processing operations. With another consideration of coping with geometric distortions, some researchers presented a few special image hash functions, such as in [16–21]]. In , the authors introduced an iterative geometric image hash method by quantizing the low-frequency components of an image into a binary image, which is further filtered by iterative filter in order to obtain a stable geometric shape to generate the hash with resistance to geometric distortion. In , the authors proposed two robust hashing schemes based on the invariance of Fourier-Mellin transform to affine transform, and later the schemes were improved by considering both security and robustness . In , Lu and Hsu addressed a mesh-based image hashing method by using the mesh insensitivity to geometric distortions. Monga and Mihçak addressed a robust and secure image hashing function in , which provides robustness to affine transforms since the effect of geometric attacks on image blocks in the spatial domain manifests (approximately) as independent and identically distributed noise on non-negative matrix factorization vectors. By using the insensitivity of histogram in shape to geometric attacks, Xiang et al. proposed a histogram-based image hashing algorithm for various geometric distortions in . In , a key-dependent JPEG2000-based robust hashing method was addressed for secure image authentication. Considering various attacks, Liu et al.  introduced Fast Johnson-Lindenstrauss Transform and content-based fingerprint, to combine different features together.
From the above introduction, we can see that the strategy to divide an image into blocks for hashing is often used (such as [13, 14, 20]). Usually, block-based image hashing algorithms can provide an inherent ability to tamper control problem and are robust to common image processing operations. However, image block-based hash functions are very sensitive to rotation operations since the rotation will make the content difference between an image block and its rotated versions. Towards this problem, in this article we investigate the effect of rotation operations on an image and its blocks. Our motivation is to find the effect and then propose a new blocking strategy to improve the performance of the block-based image hashing algorithm for rotation operations. There are two kinds of rotation modes: loose based and crop based. The main difference between a loose rotation and a crop rotation is that output images of the former have a bigger size than the rotated image while the later remains the size by cropping the boundaries. By analyzing the two modes of rotation operations in mathematical way, we propose a restricted randomized blocking strategy to eliminate the effect of rotation. The basic idea is to extract the central content of an image for the use of a block-based hashing. In order to measure the effectiveness of the proposed blocking strategy, we take non-negative matrix factorization (NMF) hashing algorithm proposed in  as an example of block-based hashing algorithms to report experimental results. Simulation results show that the hashing algorithm with the proposed blocking strategy can provide a stronger robustness to the two rotational operations.
The remainder of this article is organized as follows. In the following section, we describe the computation process of a NMF hashing algorithm. This is followed by a detailed mathematical analysis on the effect of two image rotation modes on images. By using the new blocking method, we then test the robustness performance of the NMF hashing algorithm for two image rotation operations. Finally, we draw the conclusions.
2. NMF-based image hashing
The NMF is a Matrix decomposition method . It is restricted by the conditions that in the Matrix all elements are nonnegative. The mathematical description is addressed as follows:
2.2. NMF-NMF-SQ hashing algorithm
Given an image, using the private key k 1 to pseudorandomly select sub-images A i ,(A i ∈ R m×m, 1 ≤ i ≤ p).
- 2)Obtain the NMF of each sub-image:(5)
According to the key k 2, randomly rearrange these matrixes to get a matrix J in size m × 2pr 1.
- 4)Compute the NMF of J on the rank r 2,(r 2 ≪ min(m, 2pr 1))(6)
- 5)Making rows of W and columns of H in series to get a vector in length N. Under the control of the secret key k 3, obtaining a weight vector sets , making the inner product between each weight vector and to obtain hash vector of the NMF-NMF-SQ algorithm: (In the following equation the expression 〈a, b〉 indicates the inner product between a and b).(7)
The above hash vector was not quantized. Therefore, each element in the vector is a real number. Similarity of the two hash vectors was measured by using Euclidean distance.
The robustness principle of the NMF hashing algorithm proposed in  can be summarized as follows: (1) Divide an image into blocks and then calculate the hash, in such a way that the hash is able to trace tampering and locate; (2) The hash value is a low rank decomposition by using NMF mathematical method after an image is divided into blocks,a therefore the algorithm has a good robustness for lossy compression, low-pass filtering and additive noise operations; (3) Since the hash is computed after an image size normalization step, the hash value is resistant to cropping and scaling operations. However, the algorithm is sensitive to a rotation manipulation since it will modify the content of a block.
3. Restricted blocking strategy for rotation
In this article, we observe the influence of two rotation operations on the NMF image hashing algorithm , that is, an image rotation operation will modify the content of an image block in two aspects: (1) pixel magnitude distortion due to the interpolation in the rotation  and (2) phase change. The NMF hashing algorithm  can overcome the magnitude distortion since the distortion in amplitude can be taken as an additive noise, but it is very sensitive to the phase change due to the rotation because the image block in content has been modified. The bigger rotation angle is performed, the more distortion in the block will be introduced. Towards the effect, in this section we will analyze the impact of a rotation processing operation on an image and its blocks in both theoretical and experimental ways. Furthermore, we propose a restricted random blocking strategy for the algorithm  so as to improve the rotational robustness while remaining its resistance to other attacks.
3.1. An image after rotation
There are two different modes of image rotation processing operations: 'loose' based and 'crop' based . For the loose-based rotation mode, output images have a bigger size but the original image content in size remains unchanged; In crop-based rotation mode, output images have the same size as input image, but include only the central portion of the rotated image. The influence factors of the two rotation modes on an image are described as follows.
3.1.1. Rotation with the loose mode
In order to eliminate the effect of the padded pixels (caused by the loose rotation) on image blocks, our strategy is to apply only the central content of an candidate image for block-based hashing, such as the circled region marked in Figure 2d. In such a way, we can avoid the effect of the resulted redundant pixels. For the rotated images as plotted in Figure 2e,f, only the central part in the blue circle is chosen for hashing.
For a clear description, in this article we denote the circle radius in Figure 2d as the radius of Effective Block Region (EBR), in length R. According to the principle of geometry mathematics, the R value can be derived from the following Equations (8) and (9).
So since the line in length is shorter than .
We can see from Figure 3 and the R expression that for overcoming the impact of the redundant pixels caused by the rotation, we should select the central content of an image for block-based hashing. For the different rotation angle, the central content is different. Supposed the rotation angle θ is between zero and 45° (for other rotation angles, the analysis is similar). The bigger rotation angle is, the EBR radius (R) should be smaller so as to guarantee the block-based hash value resistant to the loose rotation operation.
3.1.2. Rotation with the crop mode
3.2. An block after rotation
In the Section 1, we have analyzed the effect of rotation with two different modes on an image. Furthermore, in this section we are going to investigate the effect of the two rotation processing operations on an image block.
From the above analysis regarding the crop rotation mode, we have known that the rotation operation modifies the phase of pixels in the EBR (The amplitude distortion due to the interpolation is minor ). Therefore, there are existing public pixels before and after the rotation. A public pixel means that a pixel is still fallen into the same block under the rotation. It is worth noting that the ratio of these public pixels to the pixels in a block has an important role for the robustness of the NMF-based hashing algorithm . This has been fully proven in Section 4 with extensive testing.
In order to find a better way to block an image for hashing, in theoretical way we are going to measure the ratio of public pixels in an image block after a rotation operation. The image blocks can be divided into two categories: (1) the image center in the block and 2) the center not in the block. The effect of the rotation on a block is respectively discussed as follows.
3.2.1. Case 1: image center in the block
where : , , when .
3.2.2. Case 2: image center not in the block
According to the geometric expressions: , we have . So, we conclude that the line is the bisector of the angle ∠JOK.
where , , and .
where , ,
where the length of the lines can be calculated from Equations (17), (18), (19), and (20).
Referring to Figures 6 and 7, from the above theoretical analysis results formulated in Equations (14) and (21) we can conclude that, the ratio of public pixels after the rotation is related to the distance between the block center and the image center, the block size and the rotation angle. The smaller distance between a block and the image center is, or the smaller the rotation angle is, or the larger the block size is, so the bigger the ratio of public pixels after the rotation is, as a result the stronger rotational robustness can be achieved from a block-based hashing algorithm. The above mathematical analysis results regarding the ratio of public pixels against the rotation is beneficial to improving the rotational robustness of those block-based hashing algorithms. The strategy is to choose a desired region (the central part of an image), and then divide the region into blocks in an ideal size. The region and the block in size can be computed in advance by referring to the rotation angle that an image may suffer from. In such a way, the effect of the rotation operations will be significantly reduced. Especially, the blocking strategy is useful for those image hashing schemes based on local statistical characteristics of an image, such as the NMF-based hashing algorithm proposed in . For an image block, the more public pixels are staying in this block after a rotation operation, the better the statistical characteristics will be kept. In this article, we denote the blocking strategy as Restricted Blocking Strategy.
4. Experimental results
In order to measure the effectiveness of the proposed blocking strategy, we apply the blocking strategy for the NMF-NMF-SQ hashing algorithm proposed in  to estimate its contribution for rotational robustness. The testing results are reported as below.
In this section, we tested the performance of the NMF-NMF-SQ algorithm with the proposed blocking strategy. The parameters are set as: p = 10, m = 100, r1 = 1, r2 = 1, M = 64. The test data set is composed of four hundred 256 × 256 grey images, each image rotated in both loose and crop modes at the angle of 4, 8, 12, and 16°. Rotational robustness performance of the hashing algorithm (with the restricted blocking strategy) against the algorithm  (without the restricted blocking strategy) is as follows.
4.1. Robustness to the loose rotation mode
4.2. Robustness to the crop rotation mode
4.3. Influence of the distance between block center and image center
Corresponding to the analysis in Section 2, we have known that the ratio of public pixels to the pixels in a block is related to the distance between the block center and the image center, rotated angle and the block size used. Below, we modify the distance to measure its influence on the rotational robustness of the hashing algorithm with the restricted blocking strategy.
4.4. Influence of the block size
We can see from this figure that as the block size increases, the ratio of the public pixels increases. When the block size is 100× 100, the algorithm with the new blocking strategy obtains the best robustness performance (the ratio of the public pixels is over 89%). It is worth noting that the robustness performance in the block size of 40 × 40 is better than that of 60 × 60, which can be explained as follows. Though the larger block size can increase the ratio of public pixels for the rotational robustness improvement, in the testing we have applied the same rank for NMF decomposition in such a way that the bigger the block size is, the more feature information extracted from the NMF processing operation will be lost. As a result, the uniqueness will be reduced. Therefore, a rational block size is a trade-off between the robustness and uniqueness. For NMF-based hashing algorithm, we propose to apply the blocks of size 100× 100 for hashing.
From the above experimental analysis, we can see that the NMF hashing algorithm with the restricted blocking strategy can provide stronger performance than the recently reported NMF hashing algorithm  in the presence of rotation with the loose and crop modes while keeping the robustness to other attacks.
5. Conclusions and remarks
We investigate the effect of the rotation operations with the two modes (loose and crop) on an image and its blocks in both theoretical and experimental ways. As a result, we propose a restricted blocking strategy so that the redundant pixels caused by the rotation can be excluded for blocking. Experimental testing shows that this blocking strategy can improve the stability of a block for the rotation.
We discuss the effect of the block size on the NMF hashing algorithm. The bigger block size is, the hashing algorithm is more resistant to rotation since a bigger block will include the more public pixels for the same rotation angle.
We perform a lot of testing to measure the hashing algorithm (with the restricted blocking method) against the previous NMF hashing algorithm . Experimental results show that the use of the restricted blocking strategy can effectively improve the performance of the NMF hashing algorithm for the rotation operations.
In this study, our motivation is to analyze and improve the rotational performance of the block-based NMF hashing algorithm. In the future study, one of our considerations is to apply the restricted blocking strategy for other block-based hashing and watermarking algorithms (such as DCT-based image hashing [13, 14], DWT-based image watermarking [26, 27]) against the loose and crop rotation operations.
This work was supported in part by NSFC (No. 60903177), in part supported by the Fundamental Research Funds for the Central Universities (No. 21611408), Ph.D. Programs Foundation of Ministry of Education of China (No. 200805581048), and Guangzhou Municipal Science and Technology Program (No. 11C42070443).
aFeature vectors of NMF low-rank decomposition represent the information in the low-frequency.
- Mihçak MK, Koval O, Voloshynovskiy S: Robust perceptual hashing of multimedia content. EURASIP 2007., (Special):Google Scholar
- Wacha07 Special Issue: What kind of security does perceptual hashing offer? [Online].[http://wacha07.irisa.fr/Wacha07-call.pdf]
- Leung HY, Cheng LM: Robust watermarking scheme using wave atoms. EURASIP Journal on Advances in Signal Processing 2011, 2011: 9. Article ID 184817View ArticleGoogle Scholar
- Sachnev V, Kim HJ, Suresh S, Shi YQ: Reversible Watermarking Algorithm with Distortion Compensation. EURASIP Journal on Advances in Signal Processing 2010, 2010: 12. Article ID 316820View ArticleGoogle Scholar
- Barkat B, Sattar F: Time-frequency and time-scale-based fragile watermarking methods for image authentication. EURASIP Journal on Advances in Signal Processing 2010, 2010: 14. Article ID 408109View ArticleMATHGoogle Scholar
- Liu H, Yao X, Huang J: Semi-Fragile Zernike Moment-Based Image Watermarking for Authentication. EURASIP Journal on Advances in Signal Processing 2010, 2010: 17. Article ID 341856Google Scholar
- Laimer G, Uhl A: Key-dependent JPEG2000-based robust hashing for secure image authentication. EURASIP Journal on Information Security 2008, 2008: 18. Article ID 895174View ArticleGoogle Scholar
- Lv X, Wang ZJ: An extended image hashing concept: content-based fingerprinting using FJLT. EURASIP Journal on Information Security 2009, 2009: 16. Article ID 859859View ArticleGoogle Scholar
- Mihc¸ak MK, Venkatesan R: A perceptual audio hashing algorithm: a tool for robust audio identification and information hiding. IH2001, Lecture Notes in Computer Science 2001, 2137: 51-65.View ArticleMATHGoogle Scholar
- Özer H, Sankur B, Memon N, Anarim E: Perceptual audio hashing functions. EURASIP J Appl Signal Process 2005, 12: 1780-1793.View ArticleGoogle Scholar
- Dittmann J, Steinmetz A, Steinmetz R: Content-based digital signature for motion pictures authentication and content-fragile watermarking. In Proc IEEE Int Conf Multimedia Computing and Systems. Volume 2. Florence, Italy; 1999:209-213.View ArticleGoogle Scholar
- Coskun B, Sankur B, Memon N: Spatio-temporal transform based video hashing. IEEE Trans Multimedia 2006, 8(6):1190-1208.View ArticleGoogle Scholar
- Fridrich J, Goljan M: Robust hash functions for digital watermarking. In Proc IEEE Int Conf Information Technology: Coding Computing. Las Vegas, NV , USA; 2000:178-183.Google Scholar
- Venkatesan R, Koon SM, Jakubowski MH, Moulin P: Robust image hashing. In Proc IEEE Int Conf Image Processing. Vancouver, BC, Canada; 2000:664-666.Google Scholar
- Mihçak MK, Venkatesan R: Video watermarking using image hashing. Microsoft Research Tech Rep 2001.Google Scholar
- Mihçak MK, Venkatesan R: New iterative geometric methods for robust perceptual image hashing. DRM2001, Lecture Notes in Computer Sciences 2002, 2320: 178-183.MATHGoogle Scholar
- Swaminathan A, Mao Y, Wu M: Image hashing resilient to geometric and filtering operations. In Proc IEEE Workshop on Multimedia Signal Processing. Siena, Italy; 2004:355-358.Google Scholar
- Swaminathan A, Mao Y, Wu M: Robust and secure image hashing. IEEE Trans Inf Forensics Secur 2006, 1(2):215-230.View ArticleGoogle Scholar
- Lu S, Hsu CY: Geometric distortion-resilient image hashing scheme and its applications on copy detection and authentication. Multimedia Syst 2005, 11(2):159-173.View ArticleGoogle Scholar
- Monga V, Mihçak MK: Robust and secure image hashing via non-negative matrix factorizations. IEEE Trans Inf Forensics Secur 2007, 2(3):376-390.View ArticleGoogle Scholar
- Xiang S, Kim HJ, Huang J: Histogram-based image hashing scheme robust against geometric deformations. In Proc 9th ACM Multimedia and Security Workshop. Dallas, Texas, USA; 2007:121-128.Google Scholar
- Lee DD, Seung HS: Algorithms for non-negative matrix factorization. In Neural Information Processing Systems. Volume 13. MIT Press, Cambridge, MA; 2000:556-562.Google Scholar
- Xiang S, Kim HJ, Huang J: Invariant image watermarking based on statistical features in the low-frequency domain. IEEE Trans Circ Syst Video Technol 2008, 18(6):777-790.View ArticleGoogle Scholar
- Image Processing Toolbox imroate function [http://www.mathworks.cn/help/toolbox/images/ref/imrotate.html]
- Lefevre S, Dixon C, Jeusse C, Vincent N: A local approach for fast line detection. In Proc IEEE Int Conf Digital Signal Process. Santorini, Greece; 2002:1109-1112.Google Scholar
- Cox IJ, Kilian J, Leighton T, Shamoon T: Secure spread spectrum watermarking for multimedia. IEEE Trans Image Proccess 1997, 6(6):1673-1687.View ArticleGoogle Scholar
- Yeo IK, Kim HJ: Generalized patchwork algorithm for image watermarking. Multimedia Syst 2003, 9(3):261-265.View ArticleGoogle Scholar
This article is published under license to BioMed Central Ltd. This is an Open Access article distributed under the terms of the Creative Commons Attribution License (http://creativecommons.org/licenses/by/2.0), which permits unrestricted use, distribution, and reproduction in any medium, provided the original work is properly cited.