JOURNAL OF INFORMATION SCIENCE AND ENGINEERING 22, 701-712 (2006)
Short Paper_________________________________________________ Semi-fragile Image Authentication Using Real Symmetric Matrix CHING-TANG HSIEH, YEH-KUANG WU, CHYI-JANG LEE* AND HONG-YU CHEN Department of Electrical Engineering Tamkang University Tamsui, 251 Taiwan E-mail:
[email protected] * Department of Industry and Business Management The Open University of Kaohsiung Kaohsiung, 812 Taiwan In order to improve the detection of malicious tampering of images, it is necessary to decrease the fragility of hidden watermarks, even for digital images which have been distorted incidentally. In this paper, we propose a new semi-fragile digital watermarking technique based on eigenvalues and eigenvectors of real symmetric matrix generated by the pair of four pixels. A signature bit for detecting malicious tampering of an image is generated using the dominant eigenvector. The dominant eigenvalue can reduce the sensitivity of quantization based watermarking. The experimental results show that this algorithm can resist high quality (70 or more) JPEG compression, and improve the detection performance of various malicious alterations. Keywords: digital watermark, semi-fragile watermark, real symmetric matrix, eigenvalue, image authentication
1. INTRODUCTION Due to advances in digital technologies, most data are digitized and can be easily copied and edited. Such a situation hinders the popularization of digital technologies. Image watermarking provides a solution for protecting the copyright of digital contents. Watermarking used to protect copyright is called robust watermarking. Some researchers [1, 2] have focused on robust digital watermarking. Another type of watermarking scheme, used for image authentication, is called fragile watermarking. Fragile watermarking ideally should detect even a single bit change in a digital image. Fragile digital watermarking is essential for addressing the problem of data integrity. However, most fragile digital watermarks are very fragile even for slight altering. It cannot resist any processing even some valid processing such as high quality JPEG compression (lossy Received March 1, 2004; revised July 19, 2004 & January 20, 2005; accepted April 7, 2005. Communicated by Ja-Ling Wu.
701
702
CHING-TANG HSIEH, YEH-KUANG WU, CHYI-JANG LEE AND HONG-YU CHEN
compression) and is not suitable for factual application. The goal of semi-fragile digital watermarking is to detect unacceptable image manipulations [1, 3-5]. Typical approaches of semi-fragile digital watermarking can be categorized as signature-based or watermark-based or a combination of both. Kundur and Hatzinakos [1] embedded a watermark value by modulating a selected wavelet coefficient into the quantized interval determined by the corresponding watermark value. However, they did not provide a mechanism to detect the combination of malicious tampering and incident distortion. Lin and Chang [3] store the correlation of DCT coefficients at all pairs of two random 8x8 blocks as the digital signature. Their method can detect malicious tampering under JPEG compression, but the digital signature based method cannot detect the tampered region clearly or some special tampers, such as those with the background changed to pure white, and cannot be used for multipurpose watermarking [6]. Lossy compression, such as JPEG or JPEG 2000, quantizes by noticeably degrading high frequencies and slightly degrading low frequencies. Maeno and Sun [4] used random-bias and non-uniform quantization to detect special tampers, such as object extraction. They [7] developed a generic semi-fragile image authentication watermark framework by combining ECC and PKI security infrastructure. The watermark does not restrict the use of any specific invariant feature. Fridrich [8] proposed a multi-watermarking system by embedding fragile watermarks on top of robust watermarks. The fragile watermarking detects all the tampers and the robust watermarks can distinguish malicious and innocuous changes in the images. The method makes a valuable tool for authentication of images and detection of all types of tampering. In this paper, we propose a new semi-fragile digital watermarking technology based on the dominant eigenvalue and its corresponding eigenvector for real symmetric matrices. The proposed method is abbreviated EVRSM. Because of the orthogonality property of real symmetric matrix, we combine both superiority of watermark-based and signature-based semi-fragile watermarking technology for image authentication in our method to improve the robustness against malicious tampering and also resist high quality JPEG compression processing. In section 2, we will describe how to embed and extract digital watermarks and analyze the details of semi-fragile digital watermarking. The experimental results and the evaluation of the proposed algorithm are presented in section 3. Finally, section 4, concludes the paper.
2. EVRSM 2.1 Eigenvectors and Eigenvalues of Real Symmetric Matrices A real symmetric matrix R is defined by R = AT ⋅ A, A = [axy] x, y = 1, 2, …, k − 1,
l if f p (i, j ) − f q (i, j ) + Bij ≥ 0 axy = i, j = 0, 1, …, n − 1, m if f p (i, j ) − f q (i, j ) + Bij < 0
(1)
SEMI-FRAGILE IMAGE AUTHENTICATION USING REAL SYMMETRIC MATRIX
703
k≤n where AT is the transpose of matrix A, fp(i, j) and fq(i, j) are the DCT coefficients of blocks p and q, respectively, and Bi is a random bias. fp and fq are selected at the same frequency in different non-overlap p in q blocks. The values of blocks p and q are close and will serve as a secret key. k is the dimension of the matrix. The experimental results will not close to original point since the random bias Bi is added to fp and fq [4]. The quantized divergence and accuracy of watermark detection are dependent on the value of “l” and “m.” Instead of directly defining the signature bit by the value of “l” or “m” [4], it is defined by the eigenvalues and its corresponding eigenvectors from the real symmetric matrix. In our experiments, “l” is generally set to one and “m” is set to two to avoid the quantizing divergence. The relation between the embedding and extracting strategy must be one to one correspondence and the real symmetric matrix possesses this property. Eigenvectors of the real symmetric matrix are mutually orthogonal and provide multi-positions to embed signature bits. Eigenvalues are corresponding to eigenvectors with different directions when the system is non-orthogonal. The largest eigenvalues are called dominant eigenvalues and their corresponding eigenvectors are called dominant eigenvectors. The dominant eigenvector with the main direction is located in the first quadrant and the remaining eigenvectors are located in the fourth quadrant. The dominant eigenvalue λ and its corresponding eigenvector of the real symmetric matrix R will be evaluated. For eigenvector [c, d]T, the direction θ of the dominant eigenvector is defined by c d
θ = tan −1 ( ) where 0 ≤ θ ≤ 90. The two different matrices, such as {(1, 1), (1, 1)} and {(4, 4), (4, 4)}, may have the same eigenvector, but they have the different eigenvalue. The corresponding table between signature bits and direction of dominant eigenvector is defined in Table 1. The sixteen real symmetric matrices will be mapped to seven independent directions of the eigenvectors presented by three bits as signature bits. Table 1. Signature bits and direction of dominant eigenvector. (The dimension of the real symmetric matrix is 2 × 2) Signature bits
001
010
011
100
26.56P
31.71P
37.98P
Signature bits
101
110
111
o
o
52.01P
o
o
58.28P
o
45Po
63.43Po
2.2 Embedding Algorithm We divide a given image into several blocks of 8 × 8 pixels. Each block is transformed with Discrete Cosine Transform (DCT). We divide frequency domain into DC
704
CHING-TANG HSIEH, YEH-KUANG WU, CHYI-JANG LEE AND HONG-YU CHEN
part and AC part, that is, the DCTDC_Value of DCT coefficients belongs to DC part and DCTAC_Value belongs to the AC part. In Eq. (2), the quantized DCTDC coefficient is calculated by division by the eigenvalue λ and rounding down. Each DCTAC coefficient is divided by the fixed quantization table Qi. The quantization functions Qλ and QV are defined as:
DCTDC _ Value Qλ = λ
(2)
DCTAC _ Value QV = Qi
(3)
i is the floor function. In order to avoid noise and artifact in JPEG compression, Kunder et al. [1] proposed the watermarking to reduce the noise completely, but significant information may be ignored by the constant quantizer. According to the above reasoning, an adaptive quantization model incorporating the eigenvalue of the real symmetric matrix as the quantization table is proposed. The adaptive quantization table is determined according to the significance of the host image. If the watermarked image is altered with malicious tampering, the watermarking method is robust since the quantization table will change according to the tampering. The watermark-based embedding function DCTDC_Value and the signature based embedding function DCTAC_Value are given in Eqs. (4) and (5), respectively. W is a binary sequence. The value of r (Eq. (6)) is checked to embed one bit at the pair of blocks. If r is equal to the bit of watermark sequence W, the DCT coefficient is remain unchanged. (Q − 1) × λ , if r ≠ W and Qλ ≥ 0 ′ _ Value = λ DCTDC (Qλ + 1) × λ , if r ≠ W and Qλ < 0
(4)
(Q − 1) × Qi , if r ≠ 0, r ≠ 1 and Qv ≥ 0 ′ _ Value = v DCTAC (Qv + 1) × Qi , if r ≠ 0, r ≠ 1 and Qv < 0
(5)
0, if Q is even r= Q = Qv or Qλ. 1, if Q is odd
(6)
The flow chart of watermark embedding method is given in Fig. 1. The embedding algorithm is: (a) The original image is transformed by the 8 × 8 block DCT. (b) We use Eq. (2) to embed the watermark (W). (c) We determine the corresponding signature bits of θ and embed the signature bits of θ by Eq. (3). (d) Through the IDCT, we can obtain the watermarked image.
SEMI-FRAGILE IMAGE AUTHENTICATION USING REAL SYMMETRIC MATRIX
705
Embedding Signature bits Original image
8*8 Block DCT
Real Symmetric Matrix Determination
IDCT
Watermarked Image
Embedding Watermark
Watermark
Fig. 1. Block diagram of digital watermark embedding using EVRSM.
2.3 Extraction Algorithm
The procedures for watermark and signature bit extraction, shown in Fig. 2, are similar to the embedding method. The extraction algorithm is as follows: (a) The watermarked image is transformed by the 8 × 8 block DCT. (b) We use Eq. (4) to extract watermark (W*) and the signature bits of θ from the watermarked image. (c) Compare extracted watermark (W*) and the original watermark (W) to confirm the copyright. (d) Extracte the new signature bits of θˆ by repeating the embedding process based on the watermarked image. Compare the extracted signature bits of θ and the new signature bits of θˆ . (e) Combine the results of (c) and (d). Only when these are the same, the watermarked image has not been tampered with. (f) Authenticate the input image. Extracting Reference Signature bits
Watermarked image
8*8 Block DCT
Real Symmetric Matrix Determination
Extracting Authenticating Signature bits
Authentication
Extracting Watermark
Watermark Verification
Result
Original Watermark
Fig. 2. Block diagram of digital watermark extraction using EVRSM.
The value of r, defined in Eq. (4), should be equal to the value of the watermark sequence W and signature bit θ from the watermarked image without any attacks. Why should we use the constant quantization table for the AC part of the DCT coefficient and use the adaptive quantization table for the DC part of the DCT coefficient? We embed the watermark in the DC part and embed the signature bits, generated by the direction θ of the eigenvector, in the AC part. Even if θ is changed, the embedded signature bits will not be changed. If we change eigenvalue λ, the extracted watermarked image will be
706
CHING-TANG HSIEH, YEH-KUANG WU, CHYI-JANG LEE AND HONG-YU CHEN
changed. Thus we can detect malicious tampering of the image even if it has been incidentally distorted.
3. EXPERIMENTAL RESULTS We use the Lenna, Baboon, Pepper and a natural image with 256 × 256 pixels for testing in our experiments. And the size of digital watermark is 32 × 32 pixels and the watermark is a binary sequence in 0’s and 1’s. We embed the watermark with the mask of an 8 × 8 block. 3.1 Image Quality and Dimension Decision of the Real Symmetric Matrix The PSNR of the watermarked test image is evaluated as the perceptual quality measure, and PSNR is given by PSNR[dB] = 10 log10
MSE =
1
255
2
(7)
MSE
MN
∑ (orgi − embi )2
(8)
MN i =1
where MSE is the mean square error of the image, orgi is the ith coefficient of the original image, and embi is the ith coefficient of the embedded image. M, N are the length and width of the image. Fig. 3 shows the Lenna image before and after watermark insertion. The PSNR value of watermarked image is given in Table 2.
(a) (b) Fig. 3. (a) Original Lenna image; (b) Watermarked Lenna image.
Table 2. PSNR values with different dimensions of the real symmetric matrix. PSNR
Lenna
Baboon
Peppers
2×2
39.42
40.00
39.51
3×3
38.22
39.98
38.42
SEMI-FRAGILE IMAGE AUTHENTICATION USING REAL SYMMETRIC MATRIX
707
The dimension of the real symmetric matrix is one of the main features of our system. The capacity of the image watermarking is proportional to the dimension of the real symmetric matrix and inversely proportional to the quality of watermarking image. Table 3 shows the quality of the watermarked image with different dimensions of the real symmetric matrix. In Table 3, we find that the bit error rate dose not decrease with an increase in the real symmetric matrix’s dimension. Table 3. Bit error rate of extracted watermark under different quality of JPEG compression. Dimension of real symmetric matrix 2×2 3×3
JPEG Quality
bit error rate 80 70 65 55 50
0 0 0.0004 0.0029 0.0097
0 0 0.0004 0.0034 0.0122
The bit error rate is given by Bit error rate = (watermark bit error rate + signature bit error rate)/2 Watermark bit error rate =
org watermark ⊕ newwatermark ( M × N ) /(8 × 8)
(9)
K −1
∑ (org sig ⊕ newsig )
Signature bit error rate =
i =0
K × ( M × N ) /(8 × 8)
(10)
where orgwatermark is the original watermark, newwatermark is the extracted watermark, orgsig is the original signature bits, and newsig is the extracted signature bits. K is the length of the signature bits, and ⊕ is the Exclusive-Or operator. According to the above experiments, the dimension of the real symmetric matrix is 2 × 2. 3.2 Comparison
The extracted watermark and signature bits are expected to be the same as the original ones with a reasonable amount of image compression. Table 4 gives the bit error rate of the watermarked image compression with JPEG. We can extract the whole watermarks when the JPEG quality is 70. Some bit errors will occur if the JPEG quality is below 60. In Table 5, the value of PSNR given by
708
CHING-TANG HSIEH, YEH-KUANG WU, CHYI-JANG LEE AND HONG-YU CHEN
Table 4. Bit error rate of proposed extracting method under different quality of JPEG compression. JPEG Quality 100 90 80 70 60
Lenna 0 0 0 0 0.0063
Baboon 0 0 0 0 0.0019
Peppers 0 0 0 0.0014 0.0053
Table 5. The PSNR value of watermarked image. PSNR Proposed method Lin [3] method
Lenna 39.42 40.55
Baboon 40.00 41.07
Peppers 39.51 40.81
Table 6. Bit error rate of extracting watermark under different quality of JPEG compression. JPEG Quality 100 90 80 70 60
Lenna 0 0 0 0 0.0126
Baboon 0 0 0 0 0.0039
Peppers 0 0 0 0.0029 0.0088
Table 7. Bit error rate for various embedding algorithms. JPEG quality
Proposed method
Kunder’s method (l = 2)
Kunder’s method (l = 3)
Lin’s method
80 70 65 55 50
0 0 0.0010 0.0117 0.0537
0.1355 0.2749 0.3643 0.4265 0.4453
0.0615 0.0732 0.1357 0.1455 0.1729
0 0 0.0010 0.0273 0.1138
Lin’s method is similar to ours, and it is difficult to distinguish between the two methods visually. But in Table 7, it is oblivious that the bit error rate of watermark detection using our method is less than for Lin’s. Table 6 gives the bit error rate of the extracted watermark according to Eq. (9). We can extract the whole watermarks when JPEG quality is 70, and the bit error rate is small, even though the JPEG quality is below 60. Table 7 gives a comparison between our method and Kunder’s. In Kunder’s method the value of l is the decomposition level of the wavelet transform. The proposed method
SEMI-FRAGILE IMAGE AUTHENTICATION USING REAL SYMMETRIC MATRIX
709
outperforms Kunder’s method for the various values l. The performance of malicious tampers detection decreases when the value of l increases. Our proposed method gives high performance of malicious tampering detection and a lower bit error rate. 3.3 Image Authentication
For image authentication, we run two simulations, one for image authentication of artificial manipulations, and the other for image processing manipulations. Figs. 4 to 6 compare image authentication of the artificial manipulations using our method and Lin’s method [3]. In the experiment, the modified “Pepper,” “Lenna,” and “Baboon” images are shown in Fig. 4 (a), Fig. 5 (a), and Fig. 6 (a). In Fig. 4 (b), Fig. 5 (b) and Fig. 6 (b), all the modified areas are detected by our algorithm, which are marked in black. Some modified areas are not detected by Lin’s method as shown in Fig. 4 (c), Fig. 5 (c), and Fig. 6 (c). The extracted watermarks or signature bits will be changed in any block. We can detect the modified areas, since we embed watermarks and signature bits in all blocks.
(a)
(b)
(c)
Fig. 4. (a) Modified Pepper image. (b) Modified areas detected by proposed method. (c) Modified areas detected by Lin [3] method.
(a)
(b)
(c)
Fig. 5. (a) Modified Lenna image. (b) Modified areas detected by proposed method. (c) Modified areas detected by Lin [3] method.
710
CHING-TANG HSIEH, YEH-KUANG WU, CHYI-JANG LEE AND HONG-YU CHEN
(a)
(b)
(c)
Fig. 6. (a) Modified Baboon image. (b) Modified areas detected by proposed method. (c) Modified areas detected by Lin [3] method.
(a)
(b)
(c)
(d)
Fig. 7. (a) Watermarked natural image. (b) Modified natural image. (c) Modified areas detected by proposed method. (d) Modified areas detected by Lin [3] method.
In Fig. 7 show the results of authentication for some quite general kinds of image processing manipulations which include: (A) Delete (fill background textures) (C) Add a line drawing (E) Paste other contents (G) Change Hue
(B) Delete Background textures (D) Delete (fill background textures) (F) Reduce color saturation (H) Delete
SEMI-FRAGILE IMAGE AUTHENTICATION USING REAL SYMMETRIC MATRIX
(I) Move (K) Delete light colored contents (M) Skew
711
(J) Replace by computer generated texts (L) Add an extra limb (N) Copy
Fig. 7 (a) is a natural image with fragile watermarks, and Fig. 7 (b) shows the modified Figs. 7 (c) and (d) show the result of authentication using the proposed method and Lin’s method, respectively. As seen in Fig.7 (c), we detect all the modified areas and mark them in black, which in Fig. 7 (d) some of the modified areas are not be detected by the Lin’s method, such as (A) deleting, (B) deleting background area, and (L) adding an extra limb.
4. CONCLUSION In this paper, we successfully put forward a semi-fragile digital watermark based on the eigenvectors and eigenvalues of a real symmetric matrix. The experimental results show that this algorithm can resist high quality (70 or higher) JPEG compression, avoid malicious attacks and detect malicious tampering correctly.
REFERENCES 1. D. Kundur and D. Hatzinakos, “Digital watermarking for telltale tamper proofing and authentication,” in Proceedings of IEEE, Vol. 87, 1999, pp. 1167-1180. 2. E. T. Lin and E. J. Delp, “A review of fragile image watermarks,” in Proceedings of the ACM Multimedia and Security Workshop, 1999, pp. 25-29. 3. C. Y. Lin and S. F. Chang, “Semi-fragile watermarking for authenticating JPEG visual content,” in Proceeding of the SPIE International Conference on Security and Watermarking of Multimedia Contents, 2000, pp. 140-151. 4. K. Maeno, Q. Sun, S. F. Chang, and M. Suto, “New semi-fragile image authentication watermarking techniques using random bias and non-uniform quantization,” in Proceedings of the SPIE International Conference on Security and Watermarking of Multimedia Contents, 2002, pp. 659-670. 5. Y. Nakai, “Multivalued semi fragile watermarking,” in Proceeding of the SPIE International Conference on Security and Watermarking of Multimedia Contents, 2002, pp. 671-678. 6. C. S. Lu and H. Y. M. Liao, “Multipurpose watermarking for image authentication and protection,” IEEE Transactions on Image Processing, Vol. 10, 2001, pp. 1579-1592. 7. Q. Sun, S. F. Chang, K. Maeno, and M. Suto, “A new semi-fragile image authentication framework combining ECC and PKI infrastructures,” in Proceedings of the IEEE Circuits and Systems, 2002, pp. 440-443. 8. J. Fridrich, “A hybrid watermark for tamper detection in digital images,” in Proceedings of the Signal Processing and Its Applications, 1999, pp. 301-304. 9. P. W. Wong. “A public key watermark for image verification and authentication.” in Proceedings of the IEEE International Conference on Image Processing, Vol. 1, 1998, pp. 425-429.
712
CHING-TANG HSIEH, YEH-KUANG WU, CHYI-JANG LEE AND HONG-YU CHEN
10. D. Coppersmith, F. Mintzer, C. Tresser, C. W. Wu, and M. M. Yeung, “Fragile imperceptible digital watermark with privacy control” in Proceedings of the SPIE International Conference on Security and Watermarking of Multimedia Contents, 1999, pp. 79-84. 11. J. Dittmann, A. Steinmetz, and R. Steinmetz, “Content-based digital signature for motion picture authentication and content-fragile watermarking,” in Proceedings of the IEEE Multimedia Computing and Systems, Vol. 2, 1999, pp. 209-213. 12. R. B. Wolfgang and E. J. Delp, “Fragile watermarking using the VW2D watermark,” in Proceedings of the SPIE International Conference on Security and Watermarking of Multimedia Contents, 1999, pp. 204-213. 13. P. Yin and H. H. Yu, “A semi-fragile watermarking system for MPEG video authentication,” in Proceedings of the IEEE International Conference on Acoustics, Speech, and Signal Processing, 2002, pp. 3461-3464. 14. T. Chen, J. Wang, and Y. Zhou, “Combined digital signature and digital watermark scheme for image authentication,” in Proceedings of the International Conference on Info-Tech and Infor-Net, 2001, pp. 78-82. 15. G. J. Yu, C. S. Lu, H. Y. M. Liao, and J. P. Sheu, “Mean quantization blind watermarking for image authentication,” in Proceedings of the IEEE International Conference on Image Processing, 2000, pp. 706-709.
Ching-Tang Hsieh (謝景棠) is an Professor of Electrical Engineering at Tamkang University, Taiwan, R.O.C. He received the M.S. and Ph.D. degrees in 1985 and 1988, respectively, from the Tokyo Institute of Technology, Japan. From 1990 to 1996, he acted as the Chairman of the Department of Electrical Engineering. His current research interests include speech analysis, speech recognition, image processing, neural networks, fuzzy systems, and watermarking.
Yeh-Kuang Wu (吳業寬) received the B.S. and M.S. degrees in Electrical Engineering from Tamkang University, Taiwan, in 1999 and 2002, respectively. Currently he is a Ph.D. candidate in the Department of Electrical Engineering at Tamkang University. His research interests include image processing and watermarking.
Chyi-Jang Lee (李奇璋) was born in Taipei, Taiwan, 1971. He received the B.S. and M.S. degrees from the Department of Computer Science and Information Engineering, Tamkang University, Taiwan, in 1992 and 1998, respectively. Currently, he is a Ph.D. candidate in the Department of Computer Science and Information Engineering at Tamkang University. His major research interests include wireless networks, ad hoc routing, mobile communication, data warehouse, and knowledge management.
Hong-Yu Chen (陳鴻宇) received the M.S. degree in Electrical Engineering from Tamkang University, Taiwan, in 2004. His research interests include image processing and watermarking.