Joint image coding and image authentication ... - Semantic Scholar

4 downloads 81981 Views 3MB Size Report
Jan 22, 2013 - In the proposed scheme, the authentication data is generated by using the pseudo ... When the image is to be authenticated, the signature that.
Joint image coding and image authentication based on absolute moment block truncation coding Yu-Chen Hu Chun-Chi Lo Wu-Lin Chen Chia-Hsien Wen

Journal of Electronic Imaging 22(1), 013012 (Jan–Mar 2013)

Joint image coding and image authentication based on absolute moment block truncation coding Yu-Chen Hu Providence University Department of Computer Science and Information Management 200 Chung Chi Road, Taichung 43301, China E-mail: ychu @pu.edu.tw Chun-Chi Lo Providence University Department of Computer Science and Information Engineering 200 Chung Chi Road, Taichung 43301, China Wu-Lin Chen Chia-Hsien Wen Providence University Department of Computer Science and Information Management 200 Chung Chi Road, Taichung 43301, China

Abstract. A joint image coding and image authentication scheme based on absolute moment block truncation coding (AMBTC) is proposed. In the proposed scheme, the authentication data is generated by using the pseudo random sequence. Then, the authentication codes are embedded into the bit maps of AMBTC-compressed image blocks. The embedded bit maps and these quantization levels are further losslessly compressed to cut down the required storage cost. Experimental results demonstrate that the proposed scheme achieves good image quality of the embedded image while keeping good detecting accuracy. © 2013 SPIE and IS&T [DOI: 10.1117/1.JEI .22.1.013012]

1 Introduction Along with the rapid growth of computer hardware and software, the use of digital images becomes more and more popular. Digital images are generally stored in compressed formats because the raw image files require a lot of storage cost. To cut down the storage cost of the digital images, some lossy image coding techniques, such as block truncation coding (BTC),1–4 vector quantization (VQ), sub-band coding, JPEG, and JPEG 2000, had been proposed. In addition, some lossless image coding techniques, such as Huffman coding, arithmetic coding, and JPEG/LS, had been proposed. The lossy compression techniques are often used to compress the general-purpose images. Special-purpose images, such as military images and medical images, are often compressed by using lossless image compression techniques.

Paper 12235 received Jun. 21, 2012; revised manuscript received Nov. 7, 2012; accepted for publication Jan. 2, 2013; published online Jan. 22, 2013. 0091-3286/2013/$25.00 © 2013 SPIE and IS&T

Journal of Electronic Imaging

Basically, BTC has the advantage of requiring very low computational cost for image compression. In addition, the reconstructed image quality of BTC is quite good. The major problem of BTC is that the compression ratio is low compared to state-of-art coding standards such as JPEG and JPEG 2000. Some improved methods3,4 had been proposed to cut down the bit rate of BTC. From the literature, some extended applications based on BTC such as edge detection,5,6 digital watermarking,7–9 and data hiding10,11 have been proposed. In addition to image compression, research toward image integrity protection becomes more and more important in recent decades because digital images can be easily copied and modified by using image processing software. The traditional cryptography methods, such as advanced encryption standard (AES), message-digest algorithm 5 (MD5), and Ron Rivest, Adi Shamir and Leonard Adleman (RSA), can be used to protect the integrity of digital data. However, they are not suitable for the protection of digital images. When the traditional cryptograph method is employed to encrypt the digital image, the encrypted data is meaningless, and any changes from the encrypted data can be detected. Nevertheless, the tamper areas of the image cannot be located. To protect the integrity of digital images, the concept of image authentication12 had been proposed. Generally, image authentication schemes can be classified into two categories: signature-based schemes13–16 and fragile watermark-based schemes.17–24 In a signature-based scheme, the image to be protected is processed by using the hash function and the hashed result is then encoded via the public key cryptosystem to generate the signature of the image. Then the signature of the image is stored with a trusted third party. When the image is to be authenticated, the signature that was stored with a third party is extracted and it is then

013012-1

Jan–Mar 2013/Vol. 22(1)

Hu et al.: Joint image coding and image authentication based on absolute moment. . .

compared to the other signature that is generated from the image to be authenticated to detect the tampered areas. In a fragile watermark-based scheme, the watermark data is embedded into the image to be protected. The watermark data can be generated by using either the random number sequence or the image features extracted from the given image. No extra data are to be stored in a trust third party. When the image is to be authenticated, the watermark data are extracted from the image to verify the image integrity. The image quality of the embedded image and the detection accuracy are the major considerations of the fragile watermark-based approach. In 2001, Lin and Chang proposed a semi-fragile watermarking scheme17 which can be resistant to lossy compression for JPEG images. Wong and Memon proposed the secret and public key image watermarking schemes18 for image authentication and ownership verification in 2001. Lie et al.19 proposed a compression-domain scheme that provides dual protection for JPEG images in 2006. Lee and Lin proposed the dual watermark for both image tamper detection and image recovery22 in 2008. Qi and Xin proposed a quantization-based semi-fragile watermarking scheme23 for image content authentication in 2011. In addition, Chung and Hu proposed an adaptive image authentication scheme for VQ compressed images in 2011.24 Basically, the fragile watermark-based approach cannot provide strong robustness against common image processing attacks. Some published image authentication techniques of this approach provide the robustness analysis against attacks. Some tampering attacks for image authentication are discussed.25 In addition, the analysis and design of secure watermark-based authentication system had been proposed in 2006.26 From the literature, the compressed-domain image authentication schemes often embed the watermark data into the compressed codes of the digital images to protect the image integrity. The image quality may significantly degrade when a great deal of watermark data is embedded into the compressed images. In this paper, we design a joint image compression and image authentication scheme for grayscale images. The authentication data are embedded into the compressed trios of absolute moment block truncation coding (AMBTC) and then the compressed trios are losslessly compressed to cut down the required storage cost. Doing so incurs less image degradation than directly embedding the watermark data into the compressed images. The rest of this paper is organized as follows. We will review some block truncation coding schemes in Sec. 2. Section 3 will present the proposed scheme including the authentication data generation procedure, the secret embedding procedure, the image compression and authentication data embedding procedure, and the tamper detection procedure. The experimental results will be discussed in Sec. 4. Finally, conclusions and discussions will be given in Sec. 5. 2 Review on Block Truncation Coding Delp and Ritcell introduced the block truncation coding scheme in 1979,1 which is also called the moment-preserving block truncation coding (MPBTC) scheme. The BTC scheme has the advantage of requiring very little computational time. In addition, the absolute moment block truncation coding2 that preserves the sample mean and the sample Journal of Electronic Imaging

first absolute central moment had been proposed. In this section, the MPBTC scheme will be described. Next, the AMBTC scheme will be introduced. 2.1 Moment Preservation Block Truncation Coding In MPBTC, each grayscale image to be compressed is first divided into a set of nonoverlapped image blocks of n × n pixels. Each n × n image block can be viewed as an image vector of k dimensions, where k ¼ n × n. Each image vector is sequentially processed in the order of leftto-right and top-to-down. In the image encoding procedure, the mean value (¯x) and the standard deviation (σ) for each block x are calculated. All the pixels in the image block are classified into two groups according to its block mean value x¯ . If the intensity of one pixel is less than or equal to x¯ , it is classified as the first group (G0 ). Otherwise, it is classified as the second group (G1 ). A corresponding bit with value 0 or 1 is stored in the bit map (BM) when this pixel is classified as G0 or G1, respectively. Then, two quantization levels a and b for these two groups are computed according to the following equations, respectively. rffiffiffiffiffiffiffiffiffiffiffi q : a ¼ x¯ −σ× k−q sffiffiffiffiffiffiffiffiffiffiffi k−q : b ¼ x¯ þ σ × q

(1)

(2)

Here, q stands for the number of pixels whose values are greater than or equal to x¯ . In MPBTC, the quantization levels a and b are designed so that the first and the second sample moments of each image block are preserved. Each compressed image block produces a trio (a, b, BM). Each quantization level is stored in 8 bits. A total of (8 þ 8 þ k) bits are needed to store the compressed codes (a, b, BM) of MPBTC. The image decoding procedure of BTC is very simple. After receiving the compressed trio (a, b, BM) of each image block, the corresponding pixel is reconstructed by quantization level a if a corresponding bit valued 0 is found in the bit map. Otherwise, it is recovered by quantization level b. 2.2 Absolute Moment Block Truncation Coding In 1984, Lema and Mitchell proposed the AMBTC scheme for grayscale and color image compression. AMBTC is proved to be the minimal mean squared error BTC scheme when the block mean value is taken as the threshold value to classify the pixels in each image block into two groups. The basic image encoding/decoding procedures of AMBTC are the same as those of MPBTC. The major difference between AMBTC and MPBTC is the calculation of the two quantization levels. The details of the image encoding/decoding procedures of AMBTC are skipped. In AMBTC, two quantization levels a and b for these two groups can be computed according to the following two equations, respectively.

013012-2



X 1 × x: k − q x ≤¯x i

(3)

i

Jan–Mar 2013/Vol. 22(1)

Hu et al.: Joint image coding and image authentication based on absolute moment. . .



1 X × x: q x ≤¯x i

(4)

value rv is then converted to the authentication code (ac) by using the following equation:

i

Here, q denotes the number of pixels whose values are greater than or equal to x¯ . 3 Proposed Scheme The goal of the proposed scheme is to perform both image coding and image authentication based on AMBTC. To protect the image integrity, the authentication data are embedded into the bit map of each AMBTC compressed block. Then, the quantization levels and the bit map of each image block are compressed losslessly. The size of the authentication data for each image block can be selected according to the user requirement to comprise the embedded image quality and the accuracy of tamper detection. To improve the readability, Table 1 lists the abbreviations and the relations of the variables used in the proposed scheme. 3.1 Authentication Data Generation Procedure Suppose the grayscale image of W × H pixels is to be processed. It is divided into n × n nonoverlapping image blocks. A total of w × h image blocks of n × n pixels are divided where w ¼ W∕n and h ¼ H∕n. Let eb denote the embedded bits of authentication data for each compressed image block. A total number of w × h authentication data of eb bits will be generated. To generate the authentication data, the pseudo random number generator (PRNG) with a predefined seed is used to generate w × h random values. Each random

Table 1 Abbreviations and the relations of the variables used in the proposed scheme.

ac ¼ rv mod 2eb :

(5)

Each authentication code will be embedded into the bit map of the corresponding compressed block in the image compression and the authentication data embedding procedure. 3.2 Image Compression and Authentication Data Embedding Procedure The grayscale image of W × H pixels is divided into n × n nonoverlapping image blocks. A total of w × h image blocks of n × n pixels are to be processed. Each image block x is first compressed by AMBTC as mentioned in Sec. 2.2 to generate the compressed trio (a, b, BM). Here, a and b are two quantization levels for these two groups. In addition, BM denotes the bit map of n × n bits. The reason why we choose AMBTC instead of MPBTC is that AMBTC provides better reconstructed image quality than MPBTC. To embed the authentication code ac into BM, the BM is divided into eb equal-sized blocks. To simplify the bit map division process, the eb value is restricted to the factor of n × n. After the bit map BM ¼ ½bm1 ; bm2 ; : : : ; bmn×n  is divided into eb equal-sized blocks, the authentication code of eb bits is to be embedded into the bit map. Each subdivided bit map will be used to embed 1-bit authentication data. Let gsize denote the size of the subdivided bit map where gsize ¼ n × n∕eb. Let SDBMi denote the i’th subdivided bit map where 1 ≤ i ≤ eb. The subdivided bit map SDBMi of size gsize bits can be generated by the following equation: SDBMi ¼ ½bm1þðiþ1Þ×gsize ; bm2þðiþ1Þ×gsize ; : : : ; bmgsizeþðiþ1Þ×gsize :

Abbreviations

(6)

Meaning and relations

rv

Random value

ac

Authentication code of eb bits that is converted from rv

aci

i’th bit of the authentication code ac

eb

Embedded bits of each image block

gsize

Size of the subdivided group where gsize ¼ n × n∕eb

x

The original image block of n × n pixels, where x ¼ fx 1 ; x 2 ; x 3 ; : : : ; x n×n g

xi

i’th pixel in the image block x

BM

Bit map of each compressed block of BTC, where BM ¼ ½bm1 ; bm2 ; : : : ; bmn×n 

bmi

i’th item in the bit map BM

An example to divide the bit map of 4 × 4 bits into two equal-sized blocks is described in the following. The size of each subdivided bit map is 8 bits. In other words, gsize equals 8. The first subdivided bit map SDBM1 ¼ ½bm1 ; bm2 ; : : : ; bm8  can be generated by using Eq. (6). Similarly, the second subdivided bit map SDBM2 ¼ ½bm9 ; bm10 ; : : : ; bm16  can be generated. Let aci denote the i’th bit of the authentication code to be embedded into SDBMi where 1 ≤ i ≤ eb. The parity of SDBMi can be computed according to the following equation: X  gsize bmjþði−1Þ×gsize mod 2: pi ¼ (7) j¼1

SDBMi

i’th subdivided bit map of the original bit map BM

SDIBi

i’th subdivided image block of the original image

Journal of Electronic Imaging

If pi equals aci , SBMi is unchanged. Otherwise, one candidate in SDBMi will be selected and changed so that the parity value of the modified SDBMi will equal aci . To select the best candidate in SDBMi , the incurred squared Euclidean distance for each candidate is computed. Let x ¼ fx1 ; x2 ; x3 ; : : : ; xn×n g denote the original image block of n × n pixels. It can be divided into eb equal-sized blocks of size gsize pixels. Let SDIBi denote the i’th subdivided image block where 1 ≤ i ≤ eb. The subdivided block

013012-3

Jan–Mar 2013/Vol. 22(1)

Hu et al.: Joint image coding and image authentication based on absolute moment. . .

SDIBi of gsize pixels can be generated by the following equation:

Seed

Perform lossless decoding to generate the trio of (a,b,BM)

Generate w×h random values

SDIBi ¼ ½x1þði−1Þ×gsize ; x2þði−1Þ×gsize ; : : : ; xgsizeþði−1Þ×gsize : Divide BM into eb sub-blocks

(8) For the j’th pixel xjþði−1Þ × gsize in SDIBi satisfying that bmjþði−1Þ×gsize equals 0 where 1≤j≤gsize, the incurred distortion to replace bmjþði−1Þ×gsize by 1 can be computed as follows: distj ¼ ½xjþði−1Þ×gsize − b2 − ½xjþði−1Þ×gsize − a2 :

Compute the parity value for each sub-block

(9)

Collect the parity values to form eac

For the j’th pixel xjþði−1Þ×gsize in SDIBi satisfying that bmjþði−1Þ×gsize equals 1, the incurred distortion to replace bmjþði−1Þ×gsize by 0 can be computed as follows: distj ¼ ½xjþði−1Þ×gsize − a2 − ½xjþði−1Þ×gsize − b2 :

Convert each random value to ac

Is eac = ac? No

(10)

Yes

flag = 1

After computing the incurred distortions of these gsize candidates, the candidate with the least distortion is selected and the corresponding grouping information of this candidate is changed to embed aci . After the authentication code is embedded into the bit map of each compressed image block, the compressed code of each image block is a trio of (a, b, BM 0 ). Here, BM 0 denotes the resultant bit map after authentication data embedding. The grouping information recording in the bit map for some pixels in each image block may be changed after the authentication data embedding process is performed. In other words, the original quantization levels may not still be the mean values of these two groups after bit map modification. To improve the image quality of the compressed image block, these two quantization levels are recomputed as follows: a0 ¼

X 1 × x k − q x ∈G i

(11)

1 X × x: q x ∈G i

(12)

i

flag = 0

Collect the flag value of each block

Fig. 1 Flowchart of the tamper detection procedure.

b 0 and a 0 of each compressed image block is computed and collected to form D. The size of D is also of w × h elements. Then, A and D are encoded by the two-stage lossless coding approach consisting of the linear prediction technique and the Huffman coding technique. First, the given data are processed by the linear prediction technique to generate the predicted errors. The following prediction function is used to generate the predicted value for the currently processing value v:

0

fðvÞ ¼ ðl þ uÞ∕1;

(13)

and b0 ¼

i

1

Here, q stands for the number of pixels belonging to G1 . Now, the compressed code of each image block is a trio of (a 0 , b 0 , BM 0 ). To cut down the storage cost of the compressed codes, the compressed trios are further losslessly compressed. Since the quantization levels and the bit maps have different properties, two different lossless approaches are used. To process the quantization levels, all these a 0 values of w × h blocks are collected to form A. In addition, the difference value between

where l and u denote the adjacent left and up values of v, respectively. Then, these prediction errors are compressed by using the Huffman coding technique. The reason why the two-stage lossless approach is employed to encode the quantization levels is that the neighboring elements in both A and D are quite similar. To cut down the storage cost of the bit maps for the compressed image blocks, all the bit maps are collected and then compressed by using the Huffman coding technique. Since the similarity among neighboring bit maps is quite low, the two-stage lossless coding approach for the compression of A and D is not suitable for the compression of the bit maps.

p

p

p

p

(a) Case 1

(b) Case 2

(c) Case 3

(d) Case 4

Fig. 2 Four test cases for tamper refinement.

Journal of Electronic Imaging

013012-4

Jan–Mar 2013/Vol. 22(1)

Hu et al.: Joint image coding and image authentication based on absolute moment. . .

(a) Airplane

(b) Girl

(c) Lenna

(d) Pepper

(e) Tiffany

(f) Zelda

Fig. 3 The testing images.

3.3 Tamper Detection Procedure The goal of the tamper detection procedure is to detect whether the AMBTC compressed image is modified or not. Some system parameters, such as W, H, n, eb, and random seed, should be known. Before the block-based tamper detection process is executed, we need to reconstruct the compressed trio (a, b, BM) of each image block. First, quantization level a of each compressed image block can be reconstructed by performing the Huffman decoding procedure followed by the reverse linear prediction technique on the received compressed codes of A. Similarly, the difference value between the two quantization levels of each compressed image block can be reconstructed by performing the Huffman decoding procedure followed by the reverse linear prediction technique on the received compressed codes of D. Then, quantization level b of each compressed block can be computed. Finally, the bit map BM of each compressed block can be recovered by performing the Huffman decoding procedure on the received compressed codes of bit maps. To determine whether these w × h image blocks are tampered or not, two sets of authentication codes are to be generated. The first set of authentication codes of eb bits is generated by using the random values induced with the random seed. To generate the first set of the authenticated codes, a total number of w × h random values are generated by using the random number seed. Each random value rv is converted into the authentication code ac of eb bits by Eq. (5). The set of the authentication code is the same as that generated by using the authentication data generation procedure as mentioned in Sec. 3.1. The second set of the authentication codes will be generated by using the bit maps. Each bit map of n × n bits is divided into equal-sized blocks of gsize bits where gsize Journal of Electronic Imaging

equals ðn × nÞ∕eb. The parity value of each subdivided image block is computed. These parity values of eb subblocks are collected to form the extracted authentication code (eac) of each image block. When two sets of the authentication codes are available, we can determine whether each image block x is tampered or not. If ac equals eac, each image block x is classified as a clear block. Otherwise, x is classified as a modified block. The flag values 0 and 1 are used to represent the clear and modified blocks, respectively. The flowchart of the block-based tamper detection procedure is shown in Fig. 1.

Table 2 Reconstructed image qualities of AMBTC with different block sizes. 2×2

4×4

8×8

Images

(5 bpp)

(2 bpp)

(1.25 bpp)

Airplane

40.695

33.255

30.137

Girl

41.862

34.751

31.054

Lenna

40.615

33.684

30.245

Pepper

41.404

34.061

30.245

Tiffany

43.110

37.003

33.818

Zelda

44.207

36.737

32.546

Average

41.982

34.915

31.341

Block size

013012-5

Jan–Mar 2013/Vol. 22(1)

Hu et al.: Joint image coding and image authentication based on absolute moment. . .

Table 3 Performance of the embedded images of the proposed scheme when the block size equals 2 × 2. eb  1

eb

eb  2

eb  4

Images

PSNR

Bit rate

PSNR

Bit rate

PSNR

Bit rate

Airplane

35.633

3.178

32.926

3.201

31.692

3.186

Girl

37.540

3.330

35.058

3.365

33.774

3.353

Lenna

38.030

3.284

35.654

3.308

34.077

3.287

Pepper

38.157

3.218

35.644

3.233

34.140

3.211

Tiffany

37.023

3.056

34.106

3.078

33.161

3.068

Zelda

40.507

3.080

37.791

3.102

36.464

3.087

Average

37.815

3.191

35.197

3.215

33.885

3.199

The detected result needs to be further refined because it is possible that some modified bit maps may have the same eb-bit parity values as the original bit maps. The possibility of this condition decreases as the eb value increases. To improve the detecting accuracy, an iterative refinement mechanism is employed to refine the roughly detected image of size w×h In each round, we need to check whether each white pixel will be changed to a black one or not.Here, the white pixels and the black pixels stand for the clear and modified blocks, respectively. Four test cases as shown in Fig. 2 are sequentially checked to decide whether each white pixel will be changed to a black one or not. In Fig. 2, p denotes the selected white pixel to be processed. In the first case in Fig. 2(a), if the adjacent up and down pixels of p are black, p is changed to a black pixel. In the second case in Fig. 2(b), if the adjacent left and right pixels of p are black, p is changed to a black one. Similarly, two additional cases for the 45 deg and 135 deg splay black pixels of p are listed in Fig. 2(c) and 2(d). After checking each white pixel to determine whether it should be changed to a black one or not, the total number of modified pixels in each round is calculated. If the number of

modified pixels is greater than or equal to one, the same refinement process is iterated. Otherwise, the tamper refining process is stopped. The above process does not guarantee to remove the white pixels within the tampered objected. To solve the problem, an additional process to remove the small-sized connected component of white pixels within the tampered area is executed. 4 Experimental Results Our experiments are performed on Windows XP PC with an Intel Core Duo 2.2 GHz CPU and 512 MB RAM. The testing programs are implemented by using Bloodshed Dev C++. In our experiments, six grayscale images of 512×512 pixels, as shown in Fig. 3, are used. Results of the reconstructed image qualities of AMBTC with different block sizes are listed in Table 2. It is shown that the reconstructed image quality decreases with the increase of the block size. Average image qualities of 41.982, 34.915, and 31.341 dB are obtained when the block sizes are set to 2×2, 4×4, and 8×8, respectively. The bit rates of AMBTC equal 5, 2, and 1.25 bpp when the block sizes are set to 2×2, 4×4, and 8×8, respectively. We find that the reconstructed

Table 4 Results of the embedded images of the proposed scheme when the block size equals 4 × 4. eb  1

eb

eb  2

eb  4

Images

PSNR

Bit rate

PSNR

Bit rate

PSNR

Bit rate

Airplane

32.724

1.385

31.794

1.398

29.984

1.427

Girl

34.380

1.364

33.528

1.386

31.931

1.431

Lenna

33.653

1.386

33.156

1.400

31.900

1.429

Pepper

33.960

1.406

33.217

1.419

31.729

1.448

Tiffany

35.689

1.367

34.783

1.378

32.708

1.398

Zelda

36.481

1.337

35.881

1.355

34.496

1.395

Average

34.481

1.374

33.727

1.389

32.125

1.421

Journal of Electronic Imaging

013012-6

Jan–Mar 2013/Vol. 22(1)

Hu et al.: Joint image coding and image authentication based on absolute moment. . .

(a) Girl (eb=1)

(b) Lenna (eb=1)

(c) Pepper (eb=1)

(d) Girl (eb=2)

(e) Lenna (eb=2)

(f) Pepper (eb=2)

Fig. 4 Some embedded images of the proposed scheme when the block size equals 4 × 4.

image quality of AMBTC is poor when the block size is set to 8×8. Table 3 lists the results of the proposed scheme when the block size is set to 2×2. It is shown that the image quality of the embedded image rapidly decreases with the increase of the eb value. Average embedded image qualities of 37.815, 35.197, and 33.885 dB are obtained when the eb values are set to 1, 2, and 4, respectively. Average bit rates of 3.191, 3.215, and 3.199 bpp are achieved when the eb values are set to 1, 2, and 4, respectively. It is suggested that the eb value should be set to 1 when the block size of 2×2 is to be used in the proposed scheme. Table 4 lists the results of the embedded image of the proposed scheme when the block size is set to 4×4. Average embedded image qualities of 34.481, 33.727, and 32.125 dB are obtained when the eb values are set to 1, 2, and 4, respectively. Average bit rates of 1.374, 1.389, and 1.421 bpp are achieved when the eb values are set to 1, 2, 4, 8, and 12, respectively. It is suggested that the eb

(a) Fish

value should be less than or equal to 4. Some embedded images of the proposed scheme when the block size is set to 4×4 are listed in Fig. 4. The visual qualities of these embedding images are quite good. In the simulations, the block size is set to 4×4 and two eb values 1 and 2 are tested. In the first tamper test, a fish as shown in Fig. 5(a) is added on the shoulder of each embedded image. Two tampered images with the eb values equal to 1 and 2 are shown in Fig. 5(b) and 5(c), respectively. In this test, 5660 pixels are modified when the fish is added. A total number of 389 blocks of 4×4 pixels is affected. The pixel difference images and the block difference images for the first tamper test are listed in Fig. 6. The detected results of the proposed tamper detection procedure are listed in Fig. 7. The roughly detected images when the eb values are set to 1 and 2 are shown in Fig. 7(a) and 7(d), respectively. It is shown that the number of the white spots within the modified area decreases when the eb value increases. That is because the probability that

(b) Tampered image (eb=1)

(c) Tampered image (eb=2)

Fig. 5 The first tamper example.

Journal of Electronic Imaging

013012-7

Jan–Mar 2013/Vol. 22(1)

Hu et al.: Joint image coding and image authentication based on absolute moment. . .

(a) Pixel difference image (eb=1)

(b) Pixel difference image (eb=2)

(c) Block difference image (eb=1)

(d) Block difference image (eb=2)

Fig. 6 The difference images for the first tamper test.

(a) Roughly detected image (eb=1)

(b) Detected image (eb=1)

(c) Error image (eb=1)

(d) Roughly detected image (eb=2)

(e) Detected image (eb=2)

(f) Error image (eb=2)

Fig. 7 The detected images for the first tamper test.

Journal of Electronic Imaging

013012-8

Jan–Mar 2013/Vol. 22(1)

Hu et al.: Joint image coding and image authentication based on absolute moment. . .

(a) Rose

(b) Tampered image (eb=1)

(c) Tampered image (eb=2)

Fig. 8 The second tamper example.

the original bit map and the modified bit map have the same eb-bit remainders decreases when the eb value increases. The detected results of the proposed tamper detection procedure with the iterative refinement mechanism when the eb values equal 1 and 2 are shown in Fig. 7(b) and 7(e), respectively. No white spots are found within the modified area in these two detected images. Compared to the difference image as shown in Fig. 6, the tampered area is clearly detected. To understand the performance of the proposed scheme, the error images between the tampered objects and the detected images when the eb values equal 1 and 2 are listed in Fig. 7(c) and 7(f), respectively. It is shown that only these modified blocks in the boundary of the

tampered area cannot be correctly detected by using the proposed tamper detection procedure. In the second tamper test, a rose as shown in Fig. 8(a) is added on the shoulder of each embedded image. Two tampered images with the eb values equal to 1 and 2 are shown in Fig. 8(b) and 8(c), respectively. In this test, 7120 pixels are modified when the rose is added. A total number of 495 blocks of 4×4 pixels is affected. The pixel difference images and the block difference images for the second tamper test are listed in Fig. 9. The detected results of the proposed tamper detection procedure are listed in Fig. 10. The roughly detected images when the eb values are set to 1 and 2 are shown in

(a) Pixel difference image (eb=1)

(b) Pixel difference image (eb=2)

(c) Block difference image (eb=1)

(d) Block difference image (eb=2)

Fig. 9 The difference images for the second tamper test.

Journal of Electronic Imaging

013012-9

Jan–Mar 2013/Vol. 22(1)

Hu et al.: Joint image coding and image authentication based on absolute moment. . .

(a) Roughly detected image (eb=1)

(b) Detected image (eb=1)

(c) Error image (eb=1)

(d) Roughly detected image (eb=2)

(e) Detected image (eb=2)

(f) Error image (eb=2)

Fig. 10 The detected images for the second tamper test.

Fig. 10(a) and 10(d), respectively. Similarly, it is shown that the number of the white spots within the modified area decreases when the eb value increases. The refined results of the proposed tamper detection procedure when the eb values equal 1 and 2 are shown in Fig. 10(b) and 10(d), respectively. The tampered area is clearly detected. The error images between the tampered objects and the detected images when the eb values equal 1 and 2 are listed in Fig. 10(c) and 10(f), respectively. Some modified blocks in the boundary of the tampered area cannot be detected by using the proposed tamper detection procedure. The analysis of the detecting accuracy for these two tamper tests is listed in Table 5. The results of true positive (TP), true negative (TN), false positive (FP), and false negative (FN) are provided for these tests. There are 16,384 image blocks for each 512×512 image when the block size is set to 4×4. Recall that 389 and 495 blocks are affected when

Table 5 Analysis of these two tamper tests (unit: pixel).

Test

First tamper test

Second tamper test

Factors

eb  1

eb  2

eb  1

eb  2

TP

15995

15992

15888

15885

TN

361

373

458

473

FP

26

14

34

19

FN

2

5

4

7

Journal of Electronic Imaging

a fish and a rose are added into the embedded images in the first and second tamper tests, respectively. According to the results, 363 and 378 tampered blocks are detected for the first tamper test when the eb values are set to 1 and 2, respectively. In addition, 462 and 480 tampered blocks are found for the second tamper test when the eb values are set to 1 and 2, respectively. In the first tamper test, 26 and 14 modified blocks are not correctly detected when the eb values are 1 and 2, respectively. According to the error images shown in Fig. 7(c) and 7(f), they exist in the boundary of the tampered object. In addition, two and five clear blocks are mistakenly detected as modified blocks due to the tamper refinement strategy. Similarly, 34 and 19 modified blocks are not correctly detected in the second tamper test when the eb values are 1 and 2, respectively. They are located in the boundary of the tampered object according to the error images in Fig. 10(c) and 10(f). 5 Conclusions and Discussions A joint image coding and tamper detection scheme based on AMBTC is proposed in the paper. In the proposed scheme, the number of embedded bits for each bit map can be determined by users to reach a compromise between the embedded image quality and the detection accuracy in the proposed scheme. From these two tamper tests, the image qualities of the embedded images decrease when the number of the embedded bits increases. The clear shapes of the tampered objects can be detected for the tampered images. To provide good image qualities of the embedded images, we suggest that the number of embedded bits should be set to 1 in the proposed scheme. The proposed scheme can

013012-10

Jan–Mar 2013/Vol. 22(1)

Hu et al.: Joint image coding and image authentication based on absolute moment. . .

be used to detect the tamper areas based on the object insertion. But it is not robust to the common image processing attacks. The reason why the authentication codes are embedded into the bit maps instead of the quantization levels of AMBTC compressed codes is that a slight modification on the quantization levels will cause significant image degradation of the embedded images. The use of the random number sequence induced by the specific random seed to generate the authentication codes is very simple and secure. Without the same random seed, the authentication codes cannot be generated by the illegal users. To be specific, the proposed framework for image authentication can be easily extended to the proposed image coding schemes based on BTC.

20. W. N. Lie, G. S. Lin, and S. L. Chen, “Dual protection of JPEG images based on informed embedding and two-stage watermark extraction techniques,” IEEE Trans. Inf. Foren. Sec. 1(3), 330–341 (2006). 21. S. Jun and M. S. Alam, “Fragility and robustness of binary-phase-onlyfilter-based fragile/semifragile digital image watermarking,” IEEE Trans. Instrum. Meas. 57(3), 595–606 (2008). 22. T. Y. Lee and S. D. Lin, “Dual watermark for image tamper detection and recovery,” Pattern Recognit. 41(11), 3497–3506 (2008). 23. X. Qi and X. Xin, “A quantization-based semi-fragile watermarking scheme for image content authentication,” J. Vis. Commun. Image Represent. 22(2), 187–200 (2011). 24. J. C. Chuang and Y. C. Hu, “An adaptive image authentication scheme for vector quantization compressed image,” J. Vis. Commun. Image Represent. 22(5), 440–449 (2011). 25. C. Gang, Z. Yao, and N. Rongrong, “Tampering attacks on binary phase only filter-based watermarking schemes for image authentication,” Opt. Eng. 50(5), 057004 (2011). 26. C. Fei, D. Kundur, and R. H. Kwong, “Analysis and design of secure watermark-based authentication systems,” IEEE Trans. Inf. Foren. Sec. 1(1), 43–55 (2006).

Acknowledgments This research was supported by Providence University, Taichung, Taiwan, under contract the National Science Council, Taipei, China, under contract NSC 99-2221-E126-004-MY2.

Yu-Chen Hu received his PhD degree in computer science and information engineering from the Department of Computer Science and Information Engineering, National Chung Cheng University, Chiayi, Taiwan, in 1999. Currently, he is a professor in the Department of Computer Science and Information Management, Providence University, Sha-Lu, Taiwan. He is a member of ACM and IEEE. He has served as the editor-in-chief of International Journal of Image Processing since 2009. He is also a member of the editorial boards of several other journals. His research interests include image and signal processing, data compression, information hiding, and data engineering.

References 1. E. J. Delp and O. R. Mitchell, “Image compression using block truncation coding,” IEEE Trans. Commun. 27(9), 1335–1342 (1979). 2. M. D. Lema and O. R. Mitchell, “Absolute moment block truncation coding and its application to color image,” IEEE Trans. Commun. 32(10), 1148–1157 (1984). 3. Y. C. Hu, “Low-complexity and low-bit-rate image compression scheme based on AMBTC,” Opt. Eng. 42(7), 1964–1975 (2003). 4. Y. C. Hu, B. H. Su, and P. Y. Tsai, “Color image coding scheme using absolute moment block truncation coding and block prediction technique,” Imaging Sci. J. 56(5), 254–270 (2008). 5. Y. C. Hu and C. C. Chang, “Edge detection using block truncation coding,” Intern. J. Pattern Recognit. Artif. Intell. 17(6), 951–966 (2003). 6. P. Y. Tsai, C. C. Chang, and Y. C. Hu, “A novel two-stage edge detection scheme for digital color images,” R. Time Imag. 8(4), 329–343 (2002). 7. S. F. Tu and C. S. Hsu, “A BTC-based watermarking scheme for digital images,” Inf. Sec. 15(2), 214–226 (2004). 8. J. M. Guo, M. F. Wu, and Y. C. Kang, “Watermarking in conjugate ordered dither block truncation coding images,” Signal Process. 89(10), 1864–1882 (2009). 9. J. M. Guo and Y. F. Liu, “Joint compression/watermarking scheme using majority-parity guidance and halftoning-based block truncation coding,” IEEE Trans. Image Process. 19(8), 2056–2069 (2010). 10. C. C. Chang, Y. H. Chen, and C. C. Lin, “A data embedding scheme for color images based on genetic algorithm and absolute moment block truncation coding,” Soft Comput. 13(4), 321–331 (2009). 11. C. C. Chang, C. Y. Lin, and Y. H. Fan, “Lossless data hiding for color images based on block truncation coding,” Pattern Recognit. 41(7), 2347–2357 (2008). 12. F. Bartolini et al., “Image authentication techniques for surveillance applications,” Proc. IEEE 89(10), 1403–1418 (2001). 13. L. Xie, G. R. Arce, and R. F. Graveman, “Approximate image message authentication codes,” IEEE Trans. Multimed. 3(2), 242–252 (2001). 14. P. Y. Tsai, Y. C. Hu, and C. C. Chang, “A novel image authentication scheme based on quadtree segmentation,” Imaging Sci. J. 53(3), 149– 162 (2005). 15. C. S. Chan and C. C. Chang, “An efficient image authentication method based on Hamming code,” Pattern Recognit. 40(2), 681–691 (2007). 16. S. Ababneh, R. Ansari, and A. Khokhar, “Iterative compensation schemes for multimedia content authentication,” J. Vis. Commun. Image Represent. 20(5), 303–311 (2009). 17. C. Y. Lin and S. F. Chang, “A robust image authentication method distinguish JPEG compression from malicious manipulation,” IEEE Trans. Circ. Syst. Video Tech. 11(2), 153–168 (2001). 18. P. W. Wong and N. Memon, “Secret and public key image watermarking schemes for image authentication and ownership verification,” IEEE Trans. Image Process. 10(10), 1593–1601 (2001). 19. P. Y. Tsai, Y. C. Hu, and C. C. Chang, “Using set partitioning in hierarchical trees to authenticate digital images,” Signal Process. Image Commun. 18(9), 813–822 (2003).

Journal of Electronic Imaging

Chun-Chi Lo received his BS, MS, and PhD degrees in computer science and information engineering from National Taiwan University, Taipei, Taiwan, China, in 1989, 1991, and 1996, respectively. In 2004, he joined the faculty of the Department of Computer Science and Information Engineering, Providence University, Taiwan. Currently, he is an assistant professor. His research interests include wireless sensor networks, mean-field annealing, and combinatorial optimizations. Wu-Lin Chen is currently an associate professor in the Department of Computer Science and Information Management at Providence University. He received his MS and PhD degrees in the School of Industrial Engineering at Purdue University in 1995 and 1999, respectively. His research interests include operations research, production management, and stochastic models. Chia-Hsien Wen received his BS degree in computer science from Tamkang College, Taipei, Taiwan, in 1976, MS degree in applied mathematics and PhD degree in computer science from National Tsing Hua University, Hsinchu, Taiwan, in 1978 and 1994, respectively. He is currently an associate professor of the Department of Computer Science and Information Management, Providence University, Taiwan. Prior to joining Providence University in 2005, he was the director of the Computing Center at Taichung Veterans General Hospital. His research interests include medical image processing, medical informatics, database management, and machine learning.

013012-11

Jan–Mar 2013/Vol. 22(1)