# Robust and Secure Zero-Watermarking Algorithm for Medical Images Based on Harris-SURF-DCT and Chaotic Map

Authors: Cheng Gong; Jingbing Li; Uzair Aslam Bhatti; Ming Gong; Jixin Ma; Mengxing Huang
Journal: Security and Communication Networks
 (2021)

---

## Abstract

To protect the patient information in medical images, this article proposes a robust watermarking algorithm for medical images based on Harris-SURF-DCT. First, the corners of the medical image are extracted using the Harris corner detection algorithm, and then, the previously extracted corners are described using the method of describing feature points in the SURF algorithm to generate the feature descriptor matrix. Then, the feature descriptor matrix is processed through the perceptual hash algorithm to obtain the feature vector of the medical image, which is a binary feature vector with a size of 32 bits. Secondly, to enhance the security of the watermark information, the logistic map algorithm is used to encrypt the watermark before embedding the watermark. Finally, with the help of cryptography knowledge, third party, and zero-watermarking technology, the algorithm can embed the watermark without modifying the medical image. When extracting the watermark, the algorithm can extract the watermark from the test image without the original image. In addition, the algorithm has strong robustness to conventional attacks and geometric attacks. Especially under geometric attacks, the algorithm performs better.


---

## Body

## 1. Introduction

With the rapid development of information technology and medical imaging technology, the number of medical images is increasing at an alarming rate [1–3]. Many medical imaging systems generate and store medical images in different ways, such as ultrasound, computed tomography, magnetic resonance imaging, positron emission tomography, and other techniques [1, 2, 4]. With the wide application of wireless communication systems, especially for the fifth-generation (5G) network, the update speed of the Internet of things (IoT) technology is getting faster and faster [5], and the application of wearable IoT sensors to track patients’ vital signs information is increasing day by day [6]. Most of the traditional medical systems have turned to electronic medical systems [7]. Patient data such as current and past disease information, medical images, and drug information can be stored in electronic medical records (EMR) [8]. The sharing of patients’ medical data is possible through the Internet, and they can be used for services such as disease identification and remote diagnosis [9–11]. However, sharing medical images through the Internet has a high risk. The medical images may be leaked and tampered with, which will endanger the lives and property of patients [1]. Due to these growing threats, the protection of digital medical images is becoming more and more important [2].At present, medical image watermarking (MIW) technology is one of the main methods to solve the abovementioned problems. Digital watermarking, a technology that embeds an identification code into the data to protect the copyright or integrity of the data, has been developed for decades. However, in the medical field, the requirements for the quality of the patient’s pathological images are so strict that anything that affects the doctor’s diagnosis is not allowed [9, 10]. The traditional digital watermarking method that embeds the watermark in the whole medical image has a great influence on the quality of the image and cannot meet the requirements of the medical field. Therefore, MIW is still an important research field.In recent years, experts and scholars at home and abroad have done a lot of research on MIW. In general, medical images can be divided into regions of interest (ROI) and regions of noninterest (RONI) [12]. ROI refers to the area that has a significant impact on the doctor’s diagnosis of the patient’s condition, whereas RONI refers to the area that has no or little impact on the doctor’s diagnosis of the patient’s condition [13]. To avoid losing diagnostic information, some researchers have embedded watermarks into RONI [14–16]. However, the size of the RONI limits the embedding capacity of the watermark [17], and all the information in the RONI can be destroyed by replacing the RONI in space [18]. To solve the problem that embedding watermarks in the ROI affects the doctor’s diagnosis, some researchers have made the ROI reversible [19, 20], also claiming that the ROI is lossless [21]. The characteristic of this kind of algorithm is that the ROI can be completely restored when extracting the watermark. However, it is difficult to classify ROI well and may need to be determined by a doctor [13]. Therefore, some researchers have embedded the reversible watermark into the whole image, which can not only restore the medical image without loss when extracting the watermark but also do not need to divide ROI and RONI [18]. For example, Lei et al. [22] proposed a reversible watermarking algorithm based on wavelet transform, singular value decomposition (SVD), and recursive dither modulation (RDM). The algorithm embeds medical information into medical images through the RDM algorithm, and the embedding strength of the watermark is automatically selected by the differential evolution algorithm; Parah et al. [23] used Pixel to Block (PTB) transformation technology to replace the traditional interpolation technique used for overlay image generation. They use Intermediate Significant Bit Substitution (ISBS) to embed information such as patient’s medical data and can effectively avoid LSB replacement attacks; Balasamy and Ramakrishnan [24] proposed a reversible watermarking algorithm based on wavelet transform and particle swarm optimization (PSO). The algorithm uses the PSO algorithm to obtain the best wavelet coefficients for watermark embedding. The above watermarking algorithms all have a common problem that their robustness is not strong. The watermarking algorithm based on RONI is not strong against watermarking attacks, whereas the reversible watermarking algorithm is not strong against geometric attacks. Therefore, finding an MIW algorithm that does not affect doctors' diagnosis and has good robustness is a problem that has long plagued researchers.Combining the above problems, a new robust watermarking algorithm for medical images is proposed in this study. This scheme uses Harris-SURF transform and perceptual hash algorithm to extract the features of medical images. Meanwhile, in order to protect the security of patient data, the logistic map algorithm is used to encrypt the watermark. Finally, a key is generated by combining zero-watermark technology and cryptographic knowledge, and the watermark is embedded and extracted through the key. The algorithm not only ensures the integrity of medical images but also has strong resistance to conventional attacks and geometric attacks. The watermarking algorithm we proposed has the following advantages.(1)
The proposed watermarking algorithm is a zero-watermarking technology. It can ensure the content integrity of the original medical image and will not affect the doctor’s diagnosis.(2)
The algorithm has strong robustness to conventional attacks and geometric attacks. Especially under geometric attacks, the algorithm performs better.(3)
The algorithm combines the chaotic encryption and the concept of a third party to ensure that the watermark containing patient information will not be easily leaked. It has high security.(4)
This method can be easily applied to a variety of watermark algorithms and only needs to generate a corresponding key for each watermark. Moreover, even if multiple watermarks are added, the running time of the algorithm will not increase too much.This remainder of this article is organized as follows. First, we introduce the main methods used in the proposed algorithm in Section2. Next, we present the details of the proposed watermarking algorithm in Section 3. Then, in Section 4, we conducted multiple attack experiments to test the robustness of the proposed algorithm and compared it with other algorithms. Finally, we tested the running time and effectiveness of each module of the algorithm in Section 5.


## 2. Materials and Methods

The main theories involved in the proposed algorithm are Harris corner detection, SURF (speeded up robust features) feature descriptor, 2D-DCT (two-dimensional discrete cosine transform), and logistic map.


### 2.1. Harris Corner Detection

Harris is one of the most classic corner detection algorithms. It has the characteristics of simple calculation, insensitivity to changes in brightness and contrast, and rotation invariance. The basic principle of the algorithm is that according to the judgment of people on the corner points, if the gray level of a certain point changes significantly in all directions in a certain area of the image, the point is regarded as a corner point. The approximate implementation process is as follows [25]:


#### 2.1.1. Calculate the Autocorrelation MatrixMx,y

(1)Mx,y=IX2∗wIXIY∗wIXIY∗wIY2∗w=ACCB,wu,v=exp−u2+v22σ2IX=Ix,y∗−1,0,1IY=Ix,y∗−1,0,1T,where w is the Gaussian window function, IX and IY are the gradients of the image I in the X-axis and Y-axis directions, respectively.


#### 2.1.2. Calculate the Corner Response FunctionRx,y

(2)Rx,y=DetMx,y−k×Trace2Mx,y,DetMx,y=AB−C2TraceMx,y=A+B,where k is a constant, usually taken between 0.04 and 0.06.


#### 2.1.3. Extract Corner Points

The corner point responseRx,y is compared with the set threshold T. When Rx,y is greater than the threshold T, the point x,y is the corner point.


### 2.2. SURF Feature Descriptor

SURF is a local feature extraction algorithm proposed by Bay et al. [26] in 2006, which has the characteristics of rotation invariance, scale invariance, and strong real-time performance. It is proposed to solve the problem of the poor real-time performance of SIFT algorithm, which is several times faster than SIFT. The algorithm includes two parts: feature point detection and feature descriptor generation. The general process of generating feature descriptor is as follows:


#### 2.2.1. Determine the Main Direction of the Feature Point

In a circle with a feature point as the center and a radius of 6 s (s as the corresponding scale of the feature point), a sector with a central angle of 60° is used to scan the circular area. The schematic diagram is shown in Figure1. In the scanning process, the horizontal and vertical Haar filters are used to filter, and the filter responses of all points in the sector are accumulated. The sector with the largest sum of responses is selected, and its corresponding direction is the main direction of the feature point.Figure 1
Determine the main direction of the feature point.


#### 2.2.2. Generate Feature Descriptor

The square region is constructed with the feature point as the center and its main direction as theY-axis. The region contains 16 subblocks, each with a size of 5 s × 5 s. Then, 2 s × 2 s Haar filters are used to filter the X-axis and Y-axis directions of each subblock, so that each subblock gets a 1 × 4 feature vector ∑dx,∑dx,∑dy,∑dy. Thus, each feature point is described as a vector of size of 1 × 64. The schematic diagram of the process is shown in Figure 2.Figure 2
Describe the feature points.


### 2.3. Logistic Map

Logistic map is a chaotic map that has been studied extremely extensively at present, and it can be used to generate ideal encryption sequences. The mathematical definition of a one-dimensional logistic map is as follows:(3)XK+1=μ⋅XK⋅1−XK.Among them,XK is between 0 and 1 and μ∈0,4. The logistic mapping enters the chaotic state when μ>3.5699456.


## 2.1. Harris Corner Detection

Harris is one of the most classic corner detection algorithms. It has the characteristics of simple calculation, insensitivity to changes in brightness and contrast, and rotation invariance. The basic principle of the algorithm is that according to the judgment of people on the corner points, if the gray level of a certain point changes significantly in all directions in a certain area of the image, the point is regarded as a corner point. The approximate implementation process is as follows [25]:


### 2.1.1. Calculate the Autocorrelation MatrixMx,y

(1)Mx,y=IX2∗wIXIY∗wIXIY∗wIY2∗w=ACCB,wu,v=exp−u2+v22σ2IX=Ix,y∗−1,0,1IY=Ix,y∗−1,0,1T,where w is the Gaussian window function, IX and IY are the gradients of the image I in the X-axis and Y-axis directions, respectively.


### 2.1.2. Calculate the Corner Response FunctionRx,y

(2)Rx,y=DetMx,y−k×Trace2Mx,y,DetMx,y=AB−C2TraceMx,y=A+B,where k is a constant, usually taken between 0.04 and 0.06.


### 2.1.3. Extract Corner Points

The corner point responseRx,y is compared with the set threshold T. When Rx,y is greater than the threshold T, the point x,y is the corner point.


## 2.1.1. Calculate the Autocorrelation MatrixMx,y

(1)Mx,y=IX2∗wIXIY∗wIXIY∗wIY2∗w=ACCB,wu,v=exp−u2+v22σ2IX=Ix,y∗−1,0,1IY=Ix,y∗−1,0,1T,where w is the Gaussian window function, IX and IY are the gradients of the image I in the X-axis and Y-axis directions, respectively.


## 2.1.2. Calculate the Corner Response FunctionRx,y

(2)Rx,y=DetMx,y−k×Trace2Mx,y,DetMx,y=AB−C2TraceMx,y=A+B,where k is a constant, usually taken between 0.04 and 0.06.


## 2.1.3. Extract Corner Points

The corner point responseRx,y is compared with the set threshold T. When Rx,y is greater than the threshold T, the point x,y is the corner point.


## 2.2. SURF Feature Descriptor

SURF is a local feature extraction algorithm proposed by Bay et al. [26] in 2006, which has the characteristics of rotation invariance, scale invariance, and strong real-time performance. It is proposed to solve the problem of the poor real-time performance of SIFT algorithm, which is several times faster than SIFT. The algorithm includes two parts: feature point detection and feature descriptor generation. The general process of generating feature descriptor is as follows:


### 2.2.1. Determine the Main Direction of the Feature Point

In a circle with a feature point as the center and a radius of 6 s (s as the corresponding scale of the feature point), a sector with a central angle of 60° is used to scan the circular area. The schematic diagram is shown in Figure1. In the scanning process, the horizontal and vertical Haar filters are used to filter, and the filter responses of all points in the sector are accumulated. The sector with the largest sum of responses is selected, and its corresponding direction is the main direction of the feature point.Figure 1
Determine the main direction of the feature point.


### 2.2.2. Generate Feature Descriptor

The square region is constructed with the feature point as the center and its main direction as theY-axis. The region contains 16 subblocks, each with a size of 5 s × 5 s. Then, 2 s × 2 s Haar filters are used to filter the X-axis and Y-axis directions of each subblock, so that each subblock gets a 1 × 4 feature vector ∑dx,∑dx,∑dy,∑dy. Thus, each feature point is described as a vector of size of 1 × 64. The schematic diagram of the process is shown in Figure 2.Figure 2
Describe the feature points.


## 2.2.1. Determine the Main Direction of the Feature Point

In a circle with a feature point as the center and a radius of 6 s (s as the corresponding scale of the feature point), a sector with a central angle of 60° is used to scan the circular area. The schematic diagram is shown in Figure1. In the scanning process, the horizontal and vertical Haar filters are used to filter, and the filter responses of all points in the sector are accumulated. The sector with the largest sum of responses is selected, and its corresponding direction is the main direction of the feature point.Figure 1
Determine the main direction of the feature point.


## 2.2.2. Generate Feature Descriptor

The square region is constructed with the feature point as the center and its main direction as theY-axis. The region contains 16 subblocks, each with a size of 5 s × 5 s. Then, 2 s × 2 s Haar filters are used to filter the X-axis and Y-axis directions of each subblock, so that each subblock gets a 1 × 4 feature vector ∑dx,∑dx,∑dy,∑dy. Thus, each feature point is described as a vector of size of 1 × 64. The schematic diagram of the process is shown in Figure 2.Figure 2
Describe the feature points.


## 2.3. Logistic Map

Logistic map is a chaotic map that has been studied extremely extensively at present, and it can be used to generate ideal encryption sequences. The mathematical definition of a one-dimensional logistic map is as follows:(3)XK+1=μ⋅XK⋅1−XK.Among them,XK is between 0 and 1 and μ∈0,4. The logistic mapping enters the chaotic state when μ>3.5699456.


## 3. The Proposed Algorithm

This algorithm is a zero-watermarking scheme suitable for the medical image field. It is based on Harris-SURF transformation and perceptual hashing, and it meets the requirements of “blind extraction.” Compared with traditional watermarking schemes, it has strong resistance to geometric attacks. The algorithm consists of five parts: feature extraction, watermark encryption, encrypted watermark embedding, encrypted watermark extraction, and watermark decryption. The algorithm description is shown in Figure3.Figure 3
The process of the proposed algorithm.


### 3.1. Feature Extraction

The purpose of feature extraction is to extract a feature vector from a medical image (128 pixels × 128 pixels), and the feature extraction process is shown in Figure4.(1)
Use Harris corner detection algorithm to extract the corner points of the medical image.(2)
Use the method of describing feature points in the SURF algorithm to process the previously extracted corner points to obtain the feature descriptor matrixEi,j. Ei,j represents the j-th coefficient of the feature descriptor of the i-th corner point.(3)
The feature descriptor matrixEi,j is transformed by 2D-DCT and then 32 coefficients in the upper left corner of the coefficient matrix are selected by Z-scan method to form the vector Ai. The Z-scan method is shown in Figure 5.(4)
ProcessAi according to equation (4) to generate a 32-bit binary sequence Vi. Vi is the feature vector of the medical image.(4)Vi=0,Ai≥μ1,Ai<μ,μ=132∑i=031Ai.Figure 4
The flow of the feature extraction.Figure 5
TheZ-scan method.If the extracted feature vector is to be used for watermark embedding, it must meet the requirement that the feature vectors of different images are as different as possible. To measure the similarity of two feature vectors, this article adopts the Pearson correlation coefficient. When the correlation coefficient is greater than 0.5, they are considered similar; otherwise, they are not similar. We used the above method to extract feature vectors from a large number of medical images and calculated the correlation coefficients between them. Figure6 shows some test medical images, and the correlation coefficients between them are recorded in Table 1. As can be seen from the data, the correlation coefficients values between different images are less than 0.50, and the correlation coefficients values between themselves are 1.00. Thus, the feature vector extracted by this algorithm can be used for watermark embedding.Figure 6
Some test medical images: (a) Brain. (b) Lung. (c) Spine. (d) Abdomen. (e) Elbow. (f) Orbits. (g) Knee. (h) Coronary Artery. (i) Wrist.
(a)(b)(c)(d)(e)(f)(g)(h)(i)Table 1
The value of correlation coefficients between different images.
ImageBrainLungSpineAbdomenElbowOrbitsKneeCoronary arteryWristBrain1.000.190.390.280.250.350.280.250.31Lung0.191.000.120.380.450.37−0.050.170.15Spine0.390.121.000.230.370.330.410.190.46Abdomen0.280.380.231.000.180.170.070.180.12Elbow0.250.450.370.181.000.300.330.130.39Orbits0.350.370.330.170.301.000.170.300.39Knee0.28−0.050.410.070.330.171.000.180.28Coronary artery0.250.170.190.180.130.300.181.000.39Wrist0.310.150.460.120.390.390.280.391.00


### 3.2. Watermark Encryption

Because the watermark contains information about the patient, it must be encrypted before embedding the watermark. We use logistic map to encrypt the binary watermark (32 pixels × 32 pixels), and the encryption process is shown in Figure7. The specific implementation process is as follows:(1)
Use logistic map to generate a chaotic sequenceXi with a length of 1024 and set the initial value X0=0.2, μ=4.(2)
When the threshold is 0.5, the chaotic sequenceXi is binarized and arranged into a 32 × 32 matrix. In this way, we get the binary encryption matrix Ki,j.(3)
Encrypt the binary watermarkWi,j according to equation (5) to obtain the encrypted watermark EWi,j.(5)EWi,j=Ki,j⊕Wi,j.Figure 7
The flow of the watermark encryption.


### 3.3. Encrypted Watermark Embedding

After the feature vectorVi of the image and the encrypted watermark EWi,j are obtained, the watermark can be embedded. We construct a matrix Vi of the same size as the encrypted watermark EWi,j, and each row of it is equal to the feature vector Vi. Finally, the watermark is embedded through equation (6), and a key Keyi,j is obtained at the same time. Figure 8 illustrates this process.(6)Keyi,j=EWi,j⊕Vmi,j.Figure 8
The flow of the watermark embedding.The keyKeyi,j needs to be saved on the third-party platform. Only by applying for the key from a third party can the encrypted watermark be extracted, so as to achieve the purpose of protecting medical images.


### 3.4. Encrypted Watermark Extraction

First, use the method in Section3.1 to extract the feature vector V′i of the test image, and similarly, use it to construct the feature vector matrix Vm′i,j. Then, apply for the key Keyi,j from a third party. Finally, the encrypted watermark EW′i,j is extracted through equation (7).(7)EW′i,j=Vm′i,j⊕Keyi,j.The watermark extraction algorithm is a blind extraction algorithm, which means that the original image is not required for extraction, and only the key applied from a third party is required. Figure9 illustrates the process.Figure 9
The flow of the watermark extraction.


### 3.5. Watermark Decryption

First, use the method in Section3.2 to obtain the same chaotic sequence Xi, and similarly, use it to construct the binary matrix Ki,j. Finally, the extracted watermark EW′i,j is decrypted according to equation (8), and the unencrypted watermark W′i,j is obtained. Figure 10 shows this process.(8)W′i,j=Ki,j⊕EW′i,j.Figure 10
The flow of the watermark decryption.


## 3.1. Feature Extraction

The purpose of feature extraction is to extract a feature vector from a medical image (128 pixels × 128 pixels), and the feature extraction process is shown in Figure4.(1)
Use Harris corner detection algorithm to extract the corner points of the medical image.(2)
Use the method of describing feature points in the SURF algorithm to process the previously extracted corner points to obtain the feature descriptor matrixEi,j. Ei,j represents the j-th coefficient of the feature descriptor of the i-th corner point.(3)
The feature descriptor matrixEi,j is transformed by 2D-DCT and then 32 coefficients in the upper left corner of the coefficient matrix are selected by Z-scan method to form the vector Ai. The Z-scan method is shown in Figure 5.(4)
ProcessAi according to equation (4) to generate a 32-bit binary sequence Vi. Vi is the feature vector of the medical image.(4)Vi=0,Ai≥μ1,Ai<μ,μ=132∑i=031Ai.Figure 4
The flow of the feature extraction.Figure 5
TheZ-scan method.If the extracted feature vector is to be used for watermark embedding, it must meet the requirement that the feature vectors of different images are as different as possible. To measure the similarity of two feature vectors, this article adopts the Pearson correlation coefficient. When the correlation coefficient is greater than 0.5, they are considered similar; otherwise, they are not similar. We used the above method to extract feature vectors from a large number of medical images and calculated the correlation coefficients between them. Figure6 shows some test medical images, and the correlation coefficients between them are recorded in Table 1. As can be seen from the data, the correlation coefficients values between different images are less than 0.50, and the correlation coefficients values between themselves are 1.00. Thus, the feature vector extracted by this algorithm can be used for watermark embedding.Figure 6
Some test medical images: (a) Brain. (b) Lung. (c) Spine. (d) Abdomen. (e) Elbow. (f) Orbits. (g) Knee. (h) Coronary Artery. (i) Wrist.
(a)(b)(c)(d)(e)(f)(g)(h)(i)Table 1
The value of correlation coefficients between different images.
ImageBrainLungSpineAbdomenElbowOrbitsKneeCoronary arteryWristBrain1.000.190.390.280.250.350.280.250.31Lung0.191.000.120.380.450.37−0.050.170.15Spine0.390.121.000.230.370.330.410.190.46Abdomen0.280.380.231.000.180.170.070.180.12Elbow0.250.450.370.181.000.300.330.130.39Orbits0.350.370.330.170.301.000.170.300.39Knee0.28−0.050.410.070.330.171.000.180.28Coronary artery0.250.170.190.180.130.300.181.000.39Wrist0.310.150.460.120.390.390.280.391.00


## 3.2. Watermark Encryption

Because the watermark contains information about the patient, it must be encrypted before embedding the watermark. We use logistic map to encrypt the binary watermark (32 pixels × 32 pixels), and the encryption process is shown in Figure7. The specific implementation process is as follows:(1)
Use logistic map to generate a chaotic sequenceXi with a length of 1024 and set the initial value X0=0.2, μ=4.(2)
When the threshold is 0.5, the chaotic sequenceXi is binarized and arranged into a 32 × 32 matrix. In this way, we get the binary encryption matrix Ki,j.(3)
Encrypt the binary watermarkWi,j according to equation (5) to obtain the encrypted watermark EWi,j.(5)EWi,j=Ki,j⊕Wi,j.Figure 7
The flow of the watermark encryption.


## 3.3. Encrypted Watermark Embedding

After the feature vectorVi of the image and the encrypted watermark EWi,j are obtained, the watermark can be embedded. We construct a matrix Vi of the same size as the encrypted watermark EWi,j, and each row of it is equal to the feature vector Vi. Finally, the watermark is embedded through equation (6), and a key Keyi,j is obtained at the same time. Figure 8 illustrates this process.(6)Keyi,j=EWi,j⊕Vmi,j.Figure 8
The flow of the watermark embedding.The keyKeyi,j needs to be saved on the third-party platform. Only by applying for the key from a third party can the encrypted watermark be extracted, so as to achieve the purpose of protecting medical images.


## 3.4. Encrypted Watermark Extraction

First, use the method in Section3.1 to extract the feature vector V′i of the test image, and similarly, use it to construct the feature vector matrix Vm′i,j. Then, apply for the key Keyi,j from a third party. Finally, the encrypted watermark EW′i,j is extracted through equation (7).(7)EW′i,j=Vm′i,j⊕Keyi,j.The watermark extraction algorithm is a blind extraction algorithm, which means that the original image is not required for extraction, and only the key applied from a third party is required. Figure9 illustrates the process.Figure 9
The flow of the watermark extraction.


## 3.5. Watermark Decryption

First, use the method in Section3.2 to obtain the same chaotic sequence Xi, and similarly, use it to construct the binary matrix Ki,j. Finally, the extracted watermark EW′i,j is decrypted according to equation (8), and the unencrypted watermark W′i,j is obtained. Figure 10 shows this process.(8)W′i,j=Ki,j⊕EW′i,j.Figure 10
The flow of the watermark decryption.


## 4. Results and Discussion

The robustness of digital watermarking has always been an important performance indicator. To test the robustness of our proposed watermarking algorithm, we tested its ability to resist conventional attacks and geometric attacks and compared it with other algorithms. For ease of explanation, although we used all the images in Figure6 throughout the experiment, we only use Figure 6(a) to illustrate the test results. In addition, the hardware and software environment of the experimental equipment are shown in Table 2.Table 2
The hardware and software environment of the experimental equipment.
The hardware and softwareEnvironment configurationCPUIntel(R) Core(TM) i5-6300HQ CPU @ 2.30 GHzMemory8 GB (2133 MHz)Operating systemWindows 10 homeProgramming softwareMATLAB R2016bThe method to evaluate the robustness of the proposed watermarking algorithm is to measure the similarity between the original watermark image and the watermark image extracted from the attacked image, that is, to calculate the correlation coefficient between them. The correlation coefficient (NC) between two images both of sizeM pixels × N pixels is defined as follows:(9)dAi,j=IAi,j−IA¯dBi,j=IBi,j−IB¯,IA¯=1MN∑i,jIAi,jIB¯=1MN∑i,jIBi,j,NC=∑i∑jdAi,jdBi,j∑i∑jdA2i,j∑i∑jdB2i,j.Among them, the pixel values of the imageIA and the image IB at the point i,j are represented by IAi,j and IBi,j, respectively.


### 4.1. Conventional Attacks

To test the ability of the proposed algorithm to resist conventional attacks, different levels and types of conventional attacks are performed in medical images with watermarks. The test results are recorded in Table3. It can be seen from Table 3 that even when the attack intensity is strong, the watermark can still be extracted well, and the NC value is still greater than 0.5. For example, when a median filter with a size of 7 × 7 is used and the filtering is repeated 20 times, the image is severely blurred, but the NC value can still reach 0.61. Figure 11 shows some attacked medical images and extracted watermarks. Therefore, the proposed algorithm can resist conventional attacks well.Table 3
The test data under conventional attacks.
Conventional attacksIntensityPSNR (dB)NCGaussian noise1%21.520.925%14.980.8315%10.890.7530%8.800.61JPEG compression75%48.801.0035%28.630.9010%24.340.795%22.390.90Median filter (3 × 3)5 times22.500.7910 times21.800.7920 times21.290.71Median filter (5 × 5)5 times19.020.7410 times18.410.5820 times17.860.63Median filter (7 × 7)5 times17.260.5810 times17.060.6320 times16.970.63Figure 11
Some attacked medical and extracted watermarks under conventional attacks: (a) Gaussian Noise 30%. (b) JPEG compression 5%. (c) Median filter 7 × 7, 20 times.
(a)(b)(c)


### 4.2. Geometrical Attacks

Different degrees and types of geometric attacks are carried out on medical images with watermarks, and the test results are recorded in Table4. It can be seen from Table 4 that as the attack intensity increases, the NC value generally shows a downward trend. In addition, even in the case of strong attack intensity, the NC value is still greater than 0.5. For example, when rotating 44° clockwise, the NC value can still reach 0.64. Figure 12 shows some test images and the extracted watermarks. Thus, the proposed algorithm can resist geometric attacks well.Table 4
The test data under geometric attacks.
Geometric attacksIntensityPSNR (dB)NCRotation (clockwise)4°17.400.9019°12.520.8944°11.080.64Rotation (counterclockwise)4°17.411.0021°12.420.9046°10.970.64Scaling0.3—0.540.5—0.680.8—0.881.2—1.002.0—0.813.4—0.66Translation (left)3%12.391.0017%8.400.8938%6.200.90Translation (up)3%13.051.0016%9.650.8838%7.570.81Cropping (X-axis)8%—1.0016%—1.0030%—0.79Cropping (Y-axis)10%—1.0024%—1.0038%—0.90Figure 12
Some attacked medical and extracted watermarks under geometric attacks: (a) Rotation clockwise 44°. (b) Rotation counterclockwise 46°. (c) Scaling 3.4. (d) Scaling 0.3. (e) Translation left 31%. (f) Translation up 31%. (g)X-axis cropping 30%. (h) Y-axis cropping 31%.
(a)(b)(c)(d)(e)(f)(g)(h)Although the method of describing feature points in SURF has scale invariance, the Harris corner detection algorithm does not have scale invariance. Therefore, the proposed algorithm does not have scale invariance. This also explains why the ability of the proposed algorithm to resist scaling attacks is not as strong as that of other geometric attacks.


### 4.3. Comparison with Other Algorithms

We compared the proposed algorithm with two other zero-watermark algorithms, which are based on DCT and DTCWT-DCT [27], respectively. The comparison results are shown in Table 5. It can be seen from the table that for conventional attacks, the overall performance of the proposed algorithm is not as good as the other two algorithms. However, in some cases, the performance of the proposed algorithm is similar to the DTCWT-DCT algorithm. For geometric attacks, except for scaling attack, the performance of the proposed algorithm is significantly better than the other two algorithms.Table 5
The NC value of the proposed algorithm is compared with other algorithms.
Type of attacksIntensityNCDCTDTCWT-DCT [27]ProposedGaussian noise5%0.900.910.8325%0.710.780.65JPEG compression4%0.890.820.908%1.000.910.90Median filter (10 times)3 × 31.000.910.797 × 70.880.630.63Rotation (clockwise)5°0.790.870.9020°0.620.780.81Scaling0.30.790.710.541.21.001.001.00Translation (down)8%0.710.811.0022%0.100.521.00Cropping (Y-axis)2%0.891.001.0040%0.360.650.90


### 4.4. Running Time Analysis

Running time is also an important indicator to measure the performance of an algorithm. In this regard, we tested the time T1 for extracting features, T2 for watermark encryption, T3 for embedding encrypted watermark, T4 for extracting encrypted watermark, and T5 for watermark decryption. The test results are shown in Table6. To get more accurate results, each item was run multiple times, and the average was taken as the result.Table 6
The running time of each part in the proposed algorithm.
TimesDescriptionRunning time (ms)T1The time it takes to extract the features of Figure6(a). The process is shown in Figure 4.9.91T2The time it takes to encrypt the watermark image. The process is shown in Figure7.0.02T3The time it takes to embed an encrypted watermark in Figure6(a). The process is shown in Figure 8.10.64T4The time it takes to extract the encrypted watermark from the attacked Figure6(a). The process is shown in Figure 9.10.23T5The time it takes to decrypt the extracted encrypted watermark. The process is shown in Figure10.0.03According to Table6, it takes 10.66 ms (T2 + T3) to embed a watermark in an image, and 10.26 ms (T4 + T5) to extract a watermark from an attacked image.


### 4.5. Module Analysis

The watermarking algorithm proposed in this article is based on Harris-SURF-DCT. In order to analyse the effectiveness of each part, we divide Harris-SURF-DCT into three modules, namely, module 1 Harris, module 2 SURF, and module 3 DCT.The SURF algorithm includes two parts: feature point detection and feature descriptor generation. In the process of generating feature descriptors, feature points can be expressed as feature descriptors. However, when calculating the main direction of the feature point, because this process has a large dependence on the gradient direction of the neighbourhood pixels of the feature point, it sometimes causes the obtained main direction to be inaccurate and affects the subsequent feature point description process. In addition, the principle of Harris algorithm to extract corner points is to find points with obvious gradient changes in various directions, so the neighbourhood pixels of these corner points have a certain degree of similarity. Therefore, it is guessed that the corner points extracted by Harris algorithm may be more suitable for the feature descriptor generation part of SURF algorithm. In this regard, we tested the robustness of these two watermarking algorithms, and the test results are shown in Table7. The first algorithm is to use Harris to replace the feature point detection part in SURF, which is the watermark algorithm based on Harris-SURF-DCT proposed in this paper. The other algorithm does not replace the feature point detection part in SURF and calls it a watermarking algorithm based on SURF-DCT. According to Table 7, the proposed algorithm is obviously better than the watermarking algorithm based on SURF-DCT. Therefore, using module 1 to replace the feature point detection part of the SURF algorithm can achieve better results.Table 7
The NC value of the proposed algorithm is compared with the algorithm based on SURF-DCT.
Type of attacksIntensityNCSURF-DCTProposedGaussian noise5%0.710.8325%0.630.63JPEG compression4%0.810.908%0.720.90Median filter (10 times)3 × 30.630.797 × 70.810.63Rotation (clockwise)5°0.740.9044°0.570.64Scaling0.50.340.682.00.420.81Translation (down)8%0.811.0038%0.720.81Cropping (Y-axis)2%0.901.0038%0.720.90Bold values show the best data.Modules 1 and 2 work together to extract the geometric features of the input image. Compared with module 3 directly processing the input image (DCT-based watermarking algorithm), module 3 processing these geometric features (the proposed algorithm) can obtain feature vectors that are more robust to geometric attacks. This is because these geometric features contain important information of the input image; they are rotation invariant and insensitive to changes in brightness and contrast. We compared these two algorithms through experiments, and the comparison results are shown in Table5. According to Table 5, in addition to scaling attacks, the proposed algorithm is significantly stronger against geometric attacks than the DCT-based watermarking algorithm. Therefore, adding module 1 and module 2 in front of module 3 can improve the performance of the algorithm.


## 4.1. Conventional Attacks

To test the ability of the proposed algorithm to resist conventional attacks, different levels and types of conventional attacks are performed in medical images with watermarks. The test results are recorded in Table3. It can be seen from Table 3 that even when the attack intensity is strong, the watermark can still be extracted well, and the NC value is still greater than 0.5. For example, when a median filter with a size of 7 × 7 is used and the filtering is repeated 20 times, the image is severely blurred, but the NC value can still reach 0.61. Figure 11 shows some attacked medical images and extracted watermarks. Therefore, the proposed algorithm can resist conventional attacks well.Table 3
The test data under conventional attacks.
Conventional attacksIntensityPSNR (dB)NCGaussian noise1%21.520.925%14.980.8315%10.890.7530%8.800.61JPEG compression75%48.801.0035%28.630.9010%24.340.795%22.390.90Median filter (3 × 3)5 times22.500.7910 times21.800.7920 times21.290.71Median filter (5 × 5)5 times19.020.7410 times18.410.5820 times17.860.63Median filter (7 × 7)5 times17.260.5810 times17.060.6320 times16.970.63Figure 11
Some attacked medical and extracted watermarks under conventional attacks: (a) Gaussian Noise 30%. (b) JPEG compression 5%. (c) Median filter 7 × 7, 20 times.
(a)(b)(c)


## 4.2. Geometrical Attacks

Different degrees and types of geometric attacks are carried out on medical images with watermarks, and the test results are recorded in Table4. It can be seen from Table 4 that as the attack intensity increases, the NC value generally shows a downward trend. In addition, even in the case of strong attack intensity, the NC value is still greater than 0.5. For example, when rotating 44° clockwise, the NC value can still reach 0.64. Figure 12 shows some test images and the extracted watermarks. Thus, the proposed algorithm can resist geometric attacks well.Table 4
The test data under geometric attacks.
Geometric attacksIntensityPSNR (dB)NCRotation (clockwise)4°17.400.9019°12.520.8944°11.080.64Rotation (counterclockwise)4°17.411.0021°12.420.9046°10.970.64Scaling0.3—0.540.5—0.680.8—0.881.2—1.002.0—0.813.4—0.66Translation (left)3%12.391.0017%8.400.8938%6.200.90Translation (up)3%13.051.0016%9.650.8838%7.570.81Cropping (X-axis)8%—1.0016%—1.0030%—0.79Cropping (Y-axis)10%—1.0024%—1.0038%—0.90Figure 12
Some attacked medical and extracted watermarks under geometric attacks: (a) Rotation clockwise 44°. (b) Rotation counterclockwise 46°. (c) Scaling 3.4. (d) Scaling 0.3. (e) Translation left 31%. (f) Translation up 31%. (g)X-axis cropping 30%. (h) Y-axis cropping 31%.
(a)(b)(c)(d)(e)(f)(g)(h)Although the method of describing feature points in SURF has scale invariance, the Harris corner detection algorithm does not have scale invariance. Therefore, the proposed algorithm does not have scale invariance. This also explains why the ability of the proposed algorithm to resist scaling attacks is not as strong as that of other geometric attacks.


## 4.3. Comparison with Other Algorithms

We compared the proposed algorithm with two other zero-watermark algorithms, which are based on DCT and DTCWT-DCT [27], respectively. The comparison results are shown in Table 5. It can be seen from the table that for conventional attacks, the overall performance of the proposed algorithm is not as good as the other two algorithms. However, in some cases, the performance of the proposed algorithm is similar to the DTCWT-DCT algorithm. For geometric attacks, except for scaling attack, the performance of the proposed algorithm is significantly better than the other two algorithms.Table 5
The NC value of the proposed algorithm is compared with other algorithms.
Type of attacksIntensityNCDCTDTCWT-DCT [27]ProposedGaussian noise5%0.900.910.8325%0.710.780.65JPEG compression4%0.890.820.908%1.000.910.90Median filter (10 times)3 × 31.000.910.797 × 70.880.630.63Rotation (clockwise)5°0.790.870.9020°0.620.780.81Scaling0.30.790.710.541.21.001.001.00Translation (down)8%0.710.811.0022%0.100.521.00Cropping (Y-axis)2%0.891.001.0040%0.360.650.90


## 4.4. Running Time Analysis

Running time is also an important indicator to measure the performance of an algorithm. In this regard, we tested the time T1 for extracting features, T2 for watermark encryption, T3 for embedding encrypted watermark, T4 for extracting encrypted watermark, and T5 for watermark decryption. The test results are shown in Table6. To get more accurate results, each item was run multiple times, and the average was taken as the result.Table 6
The running time of each part in the proposed algorithm.
TimesDescriptionRunning time (ms)T1The time it takes to extract the features of Figure6(a). The process is shown in Figure 4.9.91T2The time it takes to encrypt the watermark image. The process is shown in Figure7.0.02T3The time it takes to embed an encrypted watermark in Figure6(a). The process is shown in Figure 8.10.64T4The time it takes to extract the encrypted watermark from the attacked Figure6(a). The process is shown in Figure 9.10.23T5The time it takes to decrypt the extracted encrypted watermark. The process is shown in Figure10.0.03According to Table6, it takes 10.66 ms (T2 + T3) to embed a watermark in an image, and 10.26 ms (T4 + T5) to extract a watermark from an attacked image.


## 4.5. Module Analysis

The watermarking algorithm proposed in this article is based on Harris-SURF-DCT. In order to analyse the effectiveness of each part, we divide Harris-SURF-DCT into three modules, namely, module 1 Harris, module 2 SURF, and module 3 DCT.The SURF algorithm includes two parts: feature point detection and feature descriptor generation. In the process of generating feature descriptors, feature points can be expressed as feature descriptors. However, when calculating the main direction of the feature point, because this process has a large dependence on the gradient direction of the neighbourhood pixels of the feature point, it sometimes causes the obtained main direction to be inaccurate and affects the subsequent feature point description process. In addition, the principle of Harris algorithm to extract corner points is to find points with obvious gradient changes in various directions, so the neighbourhood pixels of these corner points have a certain degree of similarity. Therefore, it is guessed that the corner points extracted by Harris algorithm may be more suitable for the feature descriptor generation part of SURF algorithm. In this regard, we tested the robustness of these two watermarking algorithms, and the test results are shown in Table7. The first algorithm is to use Harris to replace the feature point detection part in SURF, which is the watermark algorithm based on Harris-SURF-DCT proposed in this paper. The other algorithm does not replace the feature point detection part in SURF and calls it a watermarking algorithm based on SURF-DCT. According to Table 7, the proposed algorithm is obviously better than the watermarking algorithm based on SURF-DCT. Therefore, using module 1 to replace the feature point detection part of the SURF algorithm can achieve better results.Table 7
The NC value of the proposed algorithm is compared with the algorithm based on SURF-DCT.
Type of attacksIntensityNCSURF-DCTProposedGaussian noise5%0.710.8325%0.630.63JPEG compression4%0.810.908%0.720.90Median filter (10 times)3 × 30.630.797 × 70.810.63Rotation (clockwise)5°0.740.9044°0.570.64Scaling0.50.340.682.00.420.81Translation (down)8%0.811.0038%0.720.81Cropping (Y-axis)2%0.901.0038%0.720.90Bold values show the best data.Modules 1 and 2 work together to extract the geometric features of the input image. Compared with module 3 directly processing the input image (DCT-based watermarking algorithm), module 3 processing these geometric features (the proposed algorithm) can obtain feature vectors that are more robust to geometric attacks. This is because these geometric features contain important information of the input image; they are rotation invariant and insensitive to changes in brightness and contrast. We compared these two algorithms through experiments, and the comparison results are shown in Table5. According to Table 5, in addition to scaling attacks, the proposed algorithm is significantly stronger against geometric attacks than the DCT-based watermarking algorithm. Therefore, adding module 1 and module 2 in front of module 3 can improve the performance of the algorithm.


## 5. Conclusions

Aiming at the problem that the existing MIW methods are weak against geometric attacks, this article proposes a robust zero-watermarking algorithm based on Harris-SURF-DCT, which is suitable for the medical image field. The zero-watermark technology guarantees the content integrity of the original medical image and will not affect the doctor’s diagnosis. When embedding the watermark, there is no need to select the area of interest. When extracting the watermark, the original image is not required, only the key requested from a third party is needed. Moreover, the proposed algorithm has better security by encrypting the watermark through logistic mapping and saving the key on the third-party platform. The experimental results show that the proposed algorithm is highly resistant to geometric attacks. In addition, this method can be easily applied to multiple watermark algorithms, and it only needs to generate a corresponding key for each watermark. It is worth noting that even if multiple watermarks are added, the running time of the proposed algorithm will not increase much, unlike the traditional watermarking algorithm, which increases the running time exponentially.



---

*Source: 3084153-2021-11-03.xml*