Authentication Method Using a Discrete Wavelet Transform for a Digital Moving Image

Recently, several digital watermarking techniques have been proposed for hiding data in the frequency domain of moving image files to protect their copyrights. However, in order to detect the water marking sufficiently after heavy compression, it is necessary to insert the watermarking with strong intensity into a moving image, and this results in visible deterioration of the moving image. We previously proposed an authentication method using a discrete wavelet transform for a digital static image file. In contrast to digital watermarking, no additional information is inserted into the original static image in the previously proposed method, and the image is authenticated by features extracted by the wavelet transform and characteristic coding. In the present study, we developed an authentication method for a moving image by using the previously proposed method for astatic image and a newly proposed method for selecting several frames in the moving image. No additional information is inserted into the original moving image by the newly proposed method or into the original static image by the previously proposed method. The experimental results show that the proposed method has a high tolerance of authentication to both compressions and vicious attacks.


Introduction
Recent progress in digital media technology and distribution systems, such as the Internet and cellular phones, has enabled consumers to easily access, copy, and modify digital content, which includes electric documents, images, audio, and video.Therefore, techniques to protect the copyrights for digital data and to prevent unauthorized duplication or tampering are urgently needed.
Digital watermarking (DW) is a promising method for copyright protection of digital data.Several studies have developed a method in which 1) the DW can be sufficiently extracted from the watermarked digital data, even after compression, and 2) the quality of the digital data remains high after the DW is embedded [1]- [8].However, a tradeoff generally exists between these two properties.Two important properties of the DW for digital data are imperceptibility of DW-introduced distortion, and robustness to signal processing methods, such as compressions and vicious attacks.However, the data rate and complexity of the DW have attracted attention when discussing the DW performance.
For overcoming the issue of performance, we previously developed authentication methods for digital audio [9] and a static image [10] without inserting a DW into them by using a discrete wavelet transform (DWT).In contrast to the DW, no additional information is inserted into the original digital data by the previous method [10], and the digital data are authenticated by features extracted by the DWT and characteristic coding [10].
In the present study, we developed an authentication method for a digital moving image to protect the copy rights by using the previously proposed method [10] for a static image and our newly proposed method for selecting several frames in the moving image.No additional information is inserted into the original moving image by the proposed method or into the original static image by the previously proposed method [10].The digital moving image is authenticated by features extracted by the DWT and characteristic coding of the proposed method.This paper presents the method and also an analysis of its performance, including the tolerance of authentication to both compressions and vicious attacks.

Wavelet Transform
In the present study, we use the authentication method for a static image [10] to authenticate a moving image.First, we briefly describe the procedure of the DWT used in the authentication for a static image.
The original image ( ) , F u v , which is used as the level-0 wavelet decomposition coefficient sequence ( ) 0 , u v s , is decomposed into the multi-resolution representation (MRR) and the coarsest approximation by repeatedly applying the DWT.The wavelet decomposition coefficient matrix ( )   , j u v s at level j is decomposed into four wavelet decomposition coefficient matrices at the level 1 j + by using (1), ( 2), (3), and (4).
, , where u and v denote the horizontal and vertical directions, respectively, and k p and k q denote the scaling and wavelet sequences, respectively.In addition, ( )  2), (3), and (4) from 0 j = to 1 j J = − .In this method, the image must be a square composed of ( ) For example, the image is decomposed by the DWT to level 3, as shown in Figure 1, where the original image ( )

Authentication Algorithm for Static Image
It is known that the histogram of wavelet coefficients of each domain at MRR parts has a distribution in which the center is almost 0 when the DWT is performed on a natural image (Figure 2) [4].Exploiting this phenomenon, we developed an authentication method for a static image [10].

Coding
For coding the image, we obtain the histogram of wavelet coefficients V at the selected level of an MRR sequence (Figure 3).As with the DW techniques for images [10] and digital audio [9], we set the following coding parameters.
The values of Th(minus) and Th(plus) in Figure 3 are chosen such that the non-positive wavelet coefficients ( m S in total frequency) are equally divided into two groups by Th(minus), and the positive wavelet coefficients ( p S in total frequency) are equally divided into two groups by Th(plus).Next, the values of 1 T , 2 T , 3 T , and 4 T , which are the parameters for controlling the authentication precision, are chosen to satisfy the following conditions: 1) 2) The value of S S are set to 0.25, which was determined experi- mentally.
To prepare the coding for authentication, the procedure separates the wavelet coefficients V of an MRR sequence into five sets (hereinafter referred to as A, B, C, D, and E), as shown in Figure 4, by using the following criteria: where V sc is the set of wavelet coefficients in the original image file.The wavelet coefficients of an MRR sequence are coded according to the following rules, in which i V denotes   one of the wavelet coefficients: When i V C ∈ , flag i f is set to 1, and bit i b is set to 0. When ( ) , flag i f is set to 0, and bit i b is set to 0.5.For authentication of the digital image, we use a code C (hereinafter referred to as an original code), which is the sequence of i b defined above.For coding and authentication, we assign a sequence number and a flag for each wavelet coefficient.The flag for the coding.The flag 0 i f = for i V means that i V is not assigned a bit of 0 or 1: i b is externally set to 0.5 as an arbitrary constant, and the value of i b does not influence the performance of the proposed method described in Section 3.2.The coding with the exclusion of all i V belonging to sets B and D, where the magnitudes of i V are intermediate, is a novel feature of our previously reported studies [9] [10].

Authentication
We authenticate not only an original digital image file but also a signal-processed version.Compression, which is one example of signal processing, is often applied to a digital image for the purposes of distribution via the Internet or for saving on a computer.Through the same coding procedure described in Section 3.1, we applied the DWT to a digital image and obtained a histogram of wavelet coefficients V ′ at the same level of the DWT as that coded for the original image file, as described in Section 3.1.Then, we set the authentication parameters as follows.
The values of ( ) ( ) plus Th′ (Figure 5) are chosen such that the non-positive wavelet coefficients ( m S′ in total frequency) are equally divided into two groups by , and the positive wavelet coefficients ( p S′ in total frequency) are equally divided into two groups by ( ) T ′ , and 4 T ′ , the parameters for controlling the authentication precision, are chosen to satisfy the following conditions: 1) 3) The value of  ( ) In the present study, the values of both In preparation of the coding for authentication, the procedure separates the wavelet coefficients V ′ of an MRR sequence into three sets (hereinafter referred to as F, G, and H), shown in Figure 5, by using the following criteria: where is the set of wavelet coefficients of the target image file for making the code for authentication.The wavelet coefficients of an MRR sequence are coded according to the following rules, in which i V ′ de- notes one of the wavelet coefficients: When , bit i b′ is set to be 1.When 0 i f = , bit i b′ is set to 0.5.When 0 i f = , i b′ is externally set to 0.5 as an arbitrary constant, and the value of i b does not influence the performance of the proposed method described below.
For authentication of the digital image, we use the code ′ C (hereinafter referred to as an authentication code), which is the sequence of i b′ defined above.The authentication ratio AR (%) is defined by the follow- ing: ( ) where N is the number of wavelet coefficients assigned flags in the coding for the original image file, described in Section 3.1.According to (5), the values of neither i b nor i b′ influence the value of AR in the case that 0 i f = , which means the corresponding i V is not assigned a bit of 0 or 1 in the coding for the original image file.
To use the proposed method, we need to store flags i f and the original code C of each image file having a copyright we want to protect.In calculating (5) for the authentication of an original image file, we do not use an original image file; instead, we use the flags i f and the original code C of the original image file.

Coding
We obtain 10 pieces of coding per moving image, which is assumed to have 13 or more frames, in a database as follows.
Step A .Give the initial condition as [ ] Then, go to Step 3.
Step 3: If 2 Step 6: Overwrite the array as :  [ ]( ) . Then finish.According to our experience, several consecutive frames including the first or the last frame of a moving image have black for almost all pixels or white for almost all pixels.If such a frame is selected for coding despite that it is neither a representative nor a unique frame for the moving image, the code of the frame might be very detrimental to the authentication of the moving image.Therefore, in Step 1, as the objects for coding, we exclude the first and last 10% of the frames.

Authentication
The selection of frames is performed for test moving images with the same method described in Section 4.1.Assuming that the codes and the flags for selective coding for selected frames of moving images in a database were obtained by using the methods described in Section 4.1, the authentication ratios of each selected frame of a test moving image to each selected frame of the moving image in the database are calculated with the method described in Section 3.2.The authentication ratio of a test moving image to a moving image in a database is defined as the highest among all values of authentication ratios of selected frames of the test moving image to selected frames of the moving image in the database.Then, the moving image having the highest authentication ratio among all moving images in the database is found.

Experiment
In this section, we describe computer experiments and the results for evaluating the performance of the proposed method.

Method
The experiment was performed in the following computational environment: the personal computer was a DELL OPTIPLEX3020 (CPU: Intel(R) Core(TM) i5-4570 3.20 GHz, memory: 4.0 GB); the OS was Microsoft Windows 7 Professional; the development language was Microsoft Visual C++6.0.
The process of the experiment was as follows.Obtain 100 sets of codes consisting of ten codes for the Y components, which are obtained by the conversion from RGB components into YCrCb components per moving image from the original 100 MPEG-1 files of MUSCLE-VCD-2007 [11].Use these sets for the authentication among themselves.Convert three target files, which are selected according to the recording time of the shortest (No. 31: 17 s), the closest to the average recording time (No. 49: 34 min 56 s), and the longest (No. 47: 1 hour 55 min 46 s) among the moving images in the database into MPEG-2 and MPEG-4, followed by the authentication to the converted files.Investigate the tolerance of the authentication ratios to the frame rate of three target files after converting their file format from MPEG-1 with the frame rate of 25 fps to MPEG-4 with the frame rate of 5 to 60 fps.Investigate the tolerance of the authentication ratios to the compression of three selected files by using libjpeg [12] to change the values of the quality of the images obtained from the selected frames and by using FFmpeg [13] to generate moving images with the images modified by libjpeg, Investigate the authentication ratios to the frames whose frame distance from a selected frame of a target file is within 5.
We used FFmpeg to output a BMP file having 24 bits as the gray level and 256 × 256 pixels from the moving image.For the DWT, we use Daubechies wavelets.The 4LH components obtained from the DWT up to Level 4 were chosen for coding and authentication, based on the analysis in the preliminary experiments.Figure 6 shows ten image examples consisting of one frame per moving image.
Several consecutive frames having black for almost all pixels or white for almost all pixels are sometimes inserted in a moving image because they can be useful for scene transitions.If such a frame is selected for coding despite that it is neither a representative nor a unique frame for the moving image, the code of the frame might be very harmful for authentication of the moving image.Therefore, in addition to the exclusion of frames as the objects of coding described in Step 1 in Section 4.1, we used only the frames having an average gray level of α to 250 for the Y component, which has a gray level range of 0 to 255.The value of α was decided to be 11.1 by trial and error.However, when we did not obtain ten frames with α set to 11.1, we changed the value of α to 5 and were able to obtain ten frames for coding.

Authentication for MPEG-1 Files
The purpose of authentication is to protect the copyrights on moving image data.In the ten moving images listed in Table 1, when the moving image file targeted for authentication was different from that used for making the code of the original moving image file, the average authentication ratio was 60.2% (more precisely, in the range 40.9% to 81.1%), which was much smaller than the authentications ratios when authenticating the same moving image file as the original moving image file (100% in all cases in this experiment; see Table 1).An authentication ratio of 50% corresponds to the value in the case that randomly generated bits are used for i b and/or i b′ in (5).Accordingly, the proposed method distinguished the original moving image file from each of the other nine shown in Table 1.When all moving images in the database [11] were authenticated by using all moving images in the database [11], the average authentication ratios between each pair of different moving images was 66.0% (more precisely, in the range 34.1% to 94.1%), which was fairly smaller than the authentications ratios when authenticating the same moving image file as the original moving image file (100% in all cases in this experiment) [14].In other words, we could identify all moving image files in the database [11] by using all moving image files in the database [11].When authenticating the No. 59 moving image file with the codes of the No. 73 moving image file as the original moving image file, the authentication ratio was 94.1%.The high authentication ratio was caused by the pair of similar frames shown in Figure 7 [14].

Robustness to Conversion into MPEG-2 or MPEG-4
When the three moving images of Nos.31, 47, and 49, converted from MPEG-1 to MPEG-2 or MPEG-4, were authenticated by using 100 moving images (MPEG-1) in the database [11], the authentication ratios was between each pair of different moving images (in the range 43.9% to 79.5%), and were much smaller than the authentications ratios when authenticating the same moving image file as the original moving image file (100% in all cases in this experiment).Therefore, we could conclude that the proposed method has excellent robustness to conversion to MPEG-2 or MPEG-4.Table 2 shows several authentication ratios from this experiment.

Robustness to Frame Rate
Table 3 shows the robustness of the proposed method according to the frame rate.In the cases of Nos. 31 and 47 moving image files, the authentication ratios were kept at 100% for 5 to 60 fps of the file authenticated when authenticating the moving image file with 5 to 60 fps by using the original moving image file with 25 fps.Moreover, in the case of the No. 49 moving image file, the authentication ratios were kept to 100% only for 20 and 25 fps of the file authenticated when authenticating in the same manner (Table 3).The frame rate of the moving image file could be changed to avoid the copyright protection by the proposed method; it was effectively    more beneficial to use the higher authentication ratio between the authentication ratio obtained by using the raw frame rate of the authenticated file and that obtained by converting the frame rate of the authenticated file into the same value as that in the database (Tables 3-5).

Robustness to Compression Rate
Figure 8 illustrates the flow for generating new MPEG-1 files from JPEG files with several compression rates.When the moving image file targeted for authentication was different from that used for making the code of the original moving image file, the average authentication ratio was 68.9% (more precisely, in the range 62.9% to 75.0%), which was fairly smaller than the authentications ratios when authenticating the same moving image file as the original moving image file (100% in almost all cases with the JPEG quality of 0 to 100 in this experiment; see Table 6).The image obtained with very low JPEG quality had a very poor appearance (see the left figure in Figure 9).Therefore, we could conclude that the proposed method has excellent robustness to the compression rate when keeping a good image appearance.

Robustness to Frame Exclusion
Table 7 shows authentication ratios for frames near each selected frame.When authenticating the frame near the selected one in the same moving image file by using the code of the selected frame of the original moving image file, the authentication ratio was100% in most cases (Table 7).However, in some cases, the attack of frame extraction effectively avoided the copyright protection by using the proposed method (see the three cases of frames from the bottom of the No. 49 moving image file in Table 7).The three frames in the No. 49 moving image file were within continual frames under the conditions of both rapid rotation and fairly dark appearance.Therefore, the robustness of the proposed method to frame extraction for authentication might be effectively improved by      selecting frames that do not have a dark appearance, which could be judged by using the information of its gray levels.

Conclusions
We have proposed an authentication method for a moving image by using our previously proposed method for a static image and a newly developed method for selecting several frames in the moving image.No additional information is inserted into the original moving image by the proposed method or in the previously proposed method for the original static image.The experimental results show that the proposed method has high tolerance of authentication to both compressions and vicious attacks.
To use the proposed method, we need to store in a database 1) flags used for selective coding, and 2) an original code for several selected frames of each moving image file whose copyright we want to protect.In calculating the authentication ratio for authentication of an original moving image file, we do not need moving image file, but we do need 1) the flags, and 2) the original code for several selected frames of the original moving image file.
coefficient obtained by operating the scaling function in the direction of the horizontal axis and the wavelet in the vertical axis; ( ) coefficient obtained by operating the wavelet in the direction of the horizontal axis and the scaling function in the vertical axis, and; coefficient obtained by operating the wavelet in the direction of both the horizontal and vertical axes.The development coefficients at level J are obtained by repeatedly using (1), (

Figure 4 .
Figure 4. Five sets (A, B, C, D, and E) of the histogram of wavelet coefficients V of an MRR sequence for the assignment of a bit [9].
to 0.25, which is the same setting used for coding of the original image file, as described in Section 3.1.

Figure 5 .
Figure 5. Three sets (F, G, and H), indicated on the histogram, of MRR wavelet coefficients used for authentication [9].

4 :
to Step 8. Otherwise, go to Step 4. Step Overwrite the image of frame No. k on that of 2 B k − as the BMP file.Store the gray levels of frame No. k in array B. Calculate the total sum T of the squares with a gray level difference at each pixel between frame Nos. 1 k − and k.Update the value of k as : 1 k k = + .Then, go to Step 5. Step 5: If 10 count < , update the value of count as : 1 count count = + and go to Step 6.Otherwise, go to Step 7.
 as BMP files.Obtain the codes and flags used for selective coding by using the method described in Section 3.1.Output the codes, the flags,

Figure 6 .
Figure 6.Ten image examples consisting of one frame per moving image of the specified number.

Figure 7 .
Figure 7. Images of a pair of similar frames; left figure: selected from No. 73 moving image, right figure: selected from No. 59 moving image [14].

Figure 8 .
Figure 8. Flow for generating new MPEG-1 files from an original MPEG-1 file through JPEG files, corresponding to all frames of an original MPEG-1 file.The JPEG files have several compression rates.

Figure 9 .
Figure 9. Example of compressed image of moving image No. 31; left figure: quality 5, right figure: quality 100.

Table 1 .
Authentication ratios in 100 combinations of original moving images expressed by file No. for columns and by authentication targets expressed by file No. for rows.

Table 2 .
Authentication ratios of target files with MPEG-2 or MPEG-4 formats.

Table 3 .
Tolerance of authentication ratio to frame rate of target file having a MPEG-4 format.

Table 5 .
Highest authentication ratios of those in Table3 and Table 4.

Table 6 .
Tolerance of authentication ratios to compression of target file.
Original file No.Quality value of JPG compression for each frame of target file No. 31

Table 7 .
Authentication ratios for frames near each selected one.