Adaptive Partial Image Secret Sharing

: In contrast to encrypting the full secret image in classic image secret sharing (ISS), partial image secret sharing (PISS) only encrypts part of the secret image due to the situation that, in general, only part of the secret image is sensitive or secretive. However, the target part needs to be selected manually in traditional PISS, which is human-exhausted and not suitable for batch processing. In this paper, we introduce an adaptive PISS (APISS) scheme based on salience detection, linear congruence, and image inpainting. First, the salient part is automatically and adaptively detected as the secret target part. Then, the target part is encrypted into n meaningful shares by using linear congruence in the processing of inpainting the target part. The target part is decrypted progressively by only addition operation when more shares are collected. It is losslessly decrypted when all the n shares are collected. Experiments are performed to verify the efﬁciency of the introduced scheme.


Introduction
An image secret sharing (ISS) scheme encrypts a secret image into n shares and distributes them to n related participants. The secret image is decrypted when collecting any k or more shares. Thus, the ISS technique has been applied to distributed storage in the cloud, block chain, digital watermarking, and access control [1][2][3][4]. Now the widely studied principles of ISS techniques include visual secret sharing (VSS), also known as, visual cryptography (VC) [4,5] and polynomial [6][7][8][9][10][11][12].
VSS for a (k, n)-threshold [11,[13][14][15][16][17], usually outputs n shares printed onto transparent films, which are then also distributed to n participants. The advantage of VSS is that the secret can be recognized by the naked human eye when simply superposing any k or more shares. However, the traditional VSS approaches often have the disadvantages of large pixel expansion and poor image quality.
In order to decrypt a secret image with high resolution, the (k, n) threshold secret sharing scheme based on polynomial was proposed by Shamir [6]. By constructing a random (k − 1)-degree polynomial, when any k or more shares are obtained, the high-resolution secret image can be decrypted by Lagrange interpolation. Some other enhanced polynomial-based ISS schemes [18][19][20][21] with admirable properties have been developed inspired by Shamir's work. The significance of ISS based on polynomial is that the decrypted secret image has no pixel expansion and is of high quality. However, this kind of technique requires large decryption computation, i.e., Lagrange interpolation, and is time-exhausted.
Linear congruence (LC)-based ISS [22] can decrypt the secret image by using only addition operation. It balances decryption complexity and image quality.
However, the above-mentioned ISS schemes encrypt the whole secret image, ignoring the potential situation that in general only part of the secret image is sensitive or secretive. Recently, a partial ISS (PISS) scheme for a (k, n)-threshold was proposed by Yan et al. [23] based on LC and image inpainting, which only encrypts part of the secret image. However, the target part requires manual selection in their PISS, which is labor-intensive and not conducive to batch processing.
The purpose of this paper is to introduce a PISS scheme that can select the target part automatically and decrypt the secret image progressively by outputting meaningful shares. The key challenge of the work is how to perform the image processing operations and simultaneously realize the ISS procedure, because the encrypting method of an ISS principle in general entails the use of a mathematical function, which is dramatically sensitive to any slight change in the ISS output. Figure 1 further illustrates the motivation of this work.  In this paper, we introduce an adaptive PISS (APISS) scheme based on salience detection, LC, and image inpainting. First, the salient part is automatically and adaptively detected as the secret target part. Then, the target part is encrypted into n meaningful shares by using LC in the processing of inpainting the target part, where each output share looks like a natural image. The target part is decrypted progressively by only addition operation when more shares are collected. It is losslessly decrypted when all the n shares are collected. The validity of the scheme is verified by experiments.
The rest of the paper is organized as follows. Section 2 is devoted to some basic preliminaries for the introduced scheme. In Section 3, the introduced scheme is described in detail. Section 4 gives experiments. Finally, Section 5 concludes this paper.

Preliminaries
In this section, we will present some basic preliminaries for the introduced scheme. An original secret image S is encrypted into n shares, and the decrypted secret image S is recovered when any t (k ≤ t ≤ n, t ∈ Z + ) shares are collected.

Salience Detection
Saliency detection is used to discover the saliency on the target image. It follows the law of the visually salient stimuli in the image, which is thus useful for distinguishing salient object. In general, the salient object (part) is the important part, thus the salient part is severed as the secret target part in this paper. Saliency detection method in [24] will be adopted in this paper, which mainly includes the following steps to detect the saliency on any single image.
For each cluster, compute the contrast cue and spatial cue and combine the two saliency cues by multiplication. Herein, the contrast cue can represent the visual feature uniqueness and the contrast operator can simulate the human visual receptive fields; spatial cue is considered because of the "central bias rule" in single image saliency detection, also known as, the regions near the image center draw more attention than the other regions in human visual system.

3.
For each pixel, obtain the final saliency map by summing the joint saliency over all clusters.
Please refer to the work in [24] for detail. By using the saliency detection method, the secret target part of the input secret image can be detected automatically and adaptively. Figure 2

Image Inpainting
According to the image inpainting techniques proposed in the literature, the widely used approach of Criminisi et al. [26,27] is adopted in our scheme. We will describe it in detail. As in Figure 3c, a region Ω means the secret target part with arbitrary size and shape, part Φ denotes the untouched part, and ∂Ω represents the edge of the two parts. The design significance of this method lies in the selection of patch priority in the process of region filling. The patch with the highest priority will be preferentially filled. After each filling, the priorities will be updated until all the whole target is inpainted completely in the same manner. The chief inpainting process is as follows.

1.
Select a target part Ω to be inpainted, and Φ = S − Ω, where S indicates the whole image.

2.
Determine the size of the template window by using the image texture feature, denoted by Ψ p , where any p ∈ ∂Ω denotes the center of the template window. In addition, the size of the window should be larger than the largest texture element.

3.
Calculate patch priorities by using Equation (1), i.e., the product of the data term and the confidence term.
where C(p) and D(p) mean the data term and the confidence term, respectively, defined as where ψ p means the area of ψ p and a denotes a normalization factor. At point p, ∇S ⊥ p and n p ,respectively, denote the isophote direction and the normal vector direction.
The data term represents the difference between the direction of isophote and the direction of the normal vector. In the template window the confidence term is used to measure the amount of reliable information. In other words, if the difference between the normal vector direction and the isophote direction is smaller and the information contained in the template window is greater, the priority of patch will be higher.

4.
Findp according to Equation (4), and the block ψq ∈ Φ with the highest matching in the source image with the template window as specified in Equation (5), where the sum of squared differences (SSD) is utilized as the evaluation standard. Finally, the highest matching block replaces the patch of the current window.

6.
Repeat the above steps 3-5 until the image is inpainted completely.
As an example, Figure 3 shows the result of a inpainted image using the approach of Criminisi et al. Another visually plausible image is obtained, and therefore image inpainting will be adopted in the introduced scheme to obtain meaningful shares.

Linear Congruence-Based Iss
Equations (6) and (7) are the basic equations for LC-based ISS, by which the (k, k) threshold ISS can be easily achieved, where P is a number larger than the biggest pixel value, such as P = 256 for grayscale image, and s and x i represent the secret pixel and the i-th shared pixel, respectively. According to Equation (6), a one-to-many mapping between s and x i is established; therefore, the secret can be losslessly decrypted when collecting all the k shared values. However, the method is secure, as there is no such mapping with less than k shared value. In such a way, Equation (6) guarantees the security and feasibility of precise decryption, which is thus adopted in the introduced scheme. In addition, Equation (7) ensures that there are no duplicate pixel values in the first k shared pixel values.
According to Figure 4, LC-based ISS can be easily extended to support (k, n) threshold [22].
In the decryption phase, the remaining shared values x i 1 , x i 2 , · · · , x i t are used to decrypt the secret value s by using Equation (8) after removing the duplicate shared values. Figure 5 shows an example of applying the LC-based ISS for (3, 3) threshold to encrypt the secret target directly. Here, S 1,2 denotes the secret image decrypted with SC 1 and SC 2 . For the sake of saving pages, only the decrypted results by the first tth shares are given. Only when the corresponding target part of each share is collected can the secret target part be losslessly decrypted. As the corresponding target part of each share is noise-like, it will increase the suspicion of the encryption.
In the decrypting phase, to decode the secret image, we only need to iterate t pixels and perform the operations of less than t − 1 times addition and one time module. Thus, the time complexity is smaller.
To be equal to distinct one of 1 2 , ,

The Introduced Apiss Scheme
In this section, we will introduce an APISS scheme based on salience detection, LC, and image inpainting. The original secret image S and the selected target part Ω of the cover image will be encrypted to output n meaningful shares SC 1 , SC 2 , · · · SC n . Our generation steps are described in Algorithm 1.
In Algorithm 1, we note the following.

1.
In Step 1, the salient part is adaptively detected and removed by salience detection method and Otsu's threshold operation, thus the introduced scheme can achieve automatic processing. Moreover, the salient target part may include a single object or multiple objects. 2.
In Step 3, each share has its own filling order, i.e.,p i . To inpaint synchronously, the highest priority is selected from the n candidate orders as the the adopted order for all of the n shares.

Algorithm 1:
The introduced APISS scheme for the (k, n) threshold. Input: The threshold parameters (k, n) and a color secret image S with size H × W. Output: n color shares SC 1 , SC 2 , · · · SC n .
Step 1: Utilize salience detection method on S and Otsu's threshold operation to automatically obtain the target part Ω.
Remove Ω with green color from S to obtain C i , for i = 1, 2, · · · n, where SC i = C i denotes the input un-inpainted cover image.
Step 2: Use the method in Section 2.2 to determine the size of the template window, denoted by Ψ p * .
Step 4: For each cover image, by usingp i and Equation (5), search for the most matching block to gain ψq i , and then, replace the patch of the current window by the most matching block, for i = 1, 2, · · · n.
Step 5: (H 2 , W 2 ) denote the coordinates of the current processing template window, repeat Step 6.
Step 7: Renew the confidence terms after each filling process C(q i ) = C(p i ) for any q i ∈ ψp i ∩ Ω, i = 1, 2, · · · n.
Step 8: Repeat Steps 3-7 until each cover image is completely inpainted.

In
Step 6, the values of SC 1 (h, w), SC 2 (h, w), · · · SC n (h, w) are updated in the processing of encrypting S(h, w) by LC-based ISS.

4.
After the patch of the current window for each share is replaced by the most matching block in Step 4, the secret block of the current window is encrypted into n corresponding updated blocks with close values based on LC-based ISS to replace the patch of the current window in Step 4. Then, the modified patches of the current window for each share will be the basis for the next subsequent inpainting processing. Although the ISS sharing processing will introduce slight modification into the shares, the already inpainted block with the slight noise will be the input of the next inpainting round. Based on the current input, the next order and the most matching block will be selected. In such a way, meaningful shares can be obtained in a visually plausible way.
The secret decrypting of the introduced scheme is the same as LC-based ISS based on addition when any k or more shares are collected after removing the duplicate shared values.

Experimental Results and Analyses
In this section, experiments are performed to verify the efficiency of the introduced scheme.

Image Illustration
The simulated results by the introduced APISS scheme for case (3,4) are shown in Figure 6, where Figure 6c-f presents the outputted four shares SC 1 , SC 2 , SC 3 , and SC 4 and the decrypted results obtained by addition with any two or more shares are illustrated in Figure 6g-i. The shares in Figure 6 corresponding to the target part are meaningful, and thus they look reasonable to the human eyes. When any three or more shares are collected, secret images with high quality are obtained. When all the four shares are collected, the secret image is losslessly decrypted. However, no information on the content of the secret image is decrypted when fewer than three shares are collected but with shape leakage. Decreasing the artifacts will be our future work. Additionally, the simulated results for (3, 3)-threshold are given in Figure 7, and it is observed that the results are similar to the results described above.
Based on the above-observed results, we know the following.

1.
The target part is automatically and adaptively detected, and then is successfully inpainted into the visually plausible shares.

2.
Each share looks reasonable to the human eye, and thus is meaningful.

3.
We cannot decrypt the secret when any t < k shares are collected; when any t = k or more shares are collected, the secret image is progressively decrypted; when all the n shares are collected, the secret image is losslessly decrypted.

4.
An APISS for the (k, n) threshold is achieved by the introduced scheme. (c-e) three shares SC 1 , SC 2 , and SC 3 ; (f-g) decrypted results by any two or more shares.

Image Quality
According to Equation (6), when the other factors are fixed, the threshold value of k reflects the ratio of the difference (noise or error) covered by every shared pixel x i , i = 1, 2, · · · k. Specifically, a larger value of k will lead to a better image quality of the shares.
n plays a less important role than k in image quality of the shares. As n changes, the image quality of the share and that of the decrypted target will change slowly.
The image quality will be evaluated using the peak signal-to-noise-ratio (PSNR) defined in Equation (9) and the structural similarity index measure (SSIM) [28] defined in Equation (11). The same secret image in Figure 6a is employed to perform the experiments. where σ y , and σ xy denote the local means, standard deviations, and cross-covariance for the two images x and y. In this paper, we set C 3 = C 2 2 , α = β = γ = 1. For the automatically selected target area and (k, n) ( 2 ≤ k ≤ n, 2 ≤ n ≤ 4 ) threshold, the average PSNR and SSIM between SC i and DC i on the target area, for i = 1, 2, · · · , n, are presented in Table 1.
From Table 1, when the value of n is fixed, a larger value of k results in better image quality of the share because of Equation (6); when k is fixed, as the value of n changes, the image quality of the share keeps steadily.

Comparisons with Related Schemes
We compare our APISS with the scheme of Yan et al. [23], where the same secret image as in Figure 8a and the (3,4) threshold are used. It is selected for comparison because the scheme of Yan et al. also achieves partial ISS.
Yan et al. [23] proposed a PISS scheme for the (k, n)-threshold, which can recover the full secret image including the secret target part when collecting any k or more shares. We use the same parameters as Yan et al. [23] to perform the comparisons shown in Figures 8 and 9, where k = 3, n = 4. Figure 9 shows the experimental results obtained using the scheme of Yan et al. [23]. Figure 8 illustrates the experimental results obtained using our scheme. According to Figures 8 and 9, both the scheme of Yan et al. and our scheme obtain meaningful shares and decrypt the secret image losslessly. However, the differences between the scheme of Yan et al. and ours are analyzed as follows.

1.
Yan et al.'s scheme needs to select the target part manually, which is human-exhausted, especially for the target with irregular shape, and is therefore not suitable for batch processing. However, our scheme automatically and adaptively detects and removes the secret target part, which is thus suitable for the processing of large-scale images.

2.
The selected target part of our scheme is less precise than that of Yan et al.'s scheme, because they select the target part manually. This weakness of our scheme can be enhanced through combining salience detection and object segmentation. (b) the same input cover image through automatically selecting and removing the secret target part with green color from S using salience detection method on S and Otsu's threshold operation; (c-f) four shares SC 1 , SC 2 , SC 3 , and SC 4 ; (g-i) decrypted results by any two or more shares.
(i) S 1,2,3,4 Figure 9. Experimental results of the scheme of Yan et al. [23] for the (k, n) threshold, where k = 3, n = 4. (a) The secret image S; (b) the same input cover image through manually selecting and removing the secret target part with green color from S; (c-f) four shares SC 1 , SC 2 , SC 3 , and SC 4 ; (g-i) decrypted results by any two or more shares.

1.
The important information of the input image can be selected by other techniques according to practical requirements, such as edge detection and object segmentation.

2.
Salience detection on multiple secret images with close content can be utilized to improve the salience detection accuracy. 3.
Some other inpainting methods, such as the PDE-based method, can also be applied to the introduced scheme.

4.
We can adopt different ISS schemes, different filling order selection methods, or different (k, n) threshold extension methods to achieve different features.

5.
Our method can be applied to grayscale image. If a binary image inpainting algorithm is employed, our method may be applied to binary image as well. 6.
We can use more images to test the scheme. The advantage of adaptive PISS and the effectiveness of saliency detection are dependent on the adopted saliency detection algorithm if the images have multiple objects or more complex background.

Conclusions
This paper introduces a method for outputting meaningful partial image secret sharing (PISS) based on salience detection, linear congruence, and image inpainting. Experiments confirm the efficiency of the introduced scheme. The PSNR of the outputted share is more than 20, which means that acceptable image quality of the meaningful share is achieved. Comparisons with related typical scheme show the advantages of the introduced scheme. Our scheme is more suitable for batch processing with medium precision of automatically selecting target part. Decreasing the artifacts; improving the image quality through applying follow-up improved image inpainting, salience detection, and ISS methods; and including more sample images with different contrast distribution and with more objects to demonstrate the generalization of the suggested method will be our future works.