CN114996766A - Image sharing method and system based on two-dimension code social network and storage medium - Google Patents
Image sharing method and system based on two-dimension code social network and storage medium Download PDFInfo
- Publication number
- CN114996766A CN114996766A CN202210917056.8A CN202210917056A CN114996766A CN 114996766 A CN114996766 A CN 114996766A CN 202210917056 A CN202210917056 A CN 202210917056A CN 114996766 A CN114996766 A CN 114996766A
- Authority
- CN
- China
- Prior art keywords
- image
- final
- participants
- social network
- shares
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
- 238000000034 method Methods 0.000 title claims abstract description 44
- 238000004422 calculation algorithm Methods 0.000 claims abstract description 34
- 238000001514 detection method Methods 0.000 claims abstract description 19
- 230000000007 visual effect Effects 0.000 claims abstract description 10
- 238000004364 calculation method Methods 0.000 claims abstract description 4
- 230000004044 response Effects 0.000 claims abstract description 4
- 238000004590 computer program Methods 0.000 claims description 4
- 230000006870 function Effects 0.000 description 4
- 238000011084 recovery Methods 0.000 description 3
- 241000764238 Isis Species 0.000 description 2
- 238000010586 diagram Methods 0.000 description 2
- 230000004048 modification Effects 0.000 description 2
- 238000012986 modification Methods 0.000 description 2
- 102100029469 WD repeat and HMG-box DNA-binding protein 1 Human genes 0.000 description 1
- 101710097421 WD repeat and HMG-box DNA-binding protein 1 Proteins 0.000 description 1
- 230000001010 compromised effect Effects 0.000 description 1
- 230000000694 effects Effects 0.000 description 1
- 230000009545 invasion Effects 0.000 description 1
- 230000006855 networking Effects 0.000 description 1
- 230000008569 process Effects 0.000 description 1
- 230000007480 spreading Effects 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F21/00—Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
- G06F21/60—Protecting data
- G06F21/62—Protecting access to data via a platform, e.g. using keys or access control rules
- G06F21/6218—Protecting access to data via a platform, e.g. using keys or access control rules to a system of files or objects, e.g. local or distributed file system or database
- G06F21/6245—Protecting personal data, e.g. for financial or medical purposes
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06K—GRAPHICAL DATA READING; PRESENTATION OF DATA; RECORD CARRIERS; HANDLING RECORD CARRIERS
- G06K17/00—Methods or arrangements for effecting co-operative working between equipments covered by two or more of main groups G06K1/00 - G06K15/00, e.g. automatic card files incorporating conveying and reading operations
- G06K17/0022—Methods or arrangements for effecting co-operative working between equipments covered by two or more of main groups G06K1/00 - G06K15/00, e.g. automatic card files incorporating conveying and reading operations arrangements or provisions for transferring data to distant stations, e.g. from a sensing device
- G06K17/0025—Methods or arrangements for effecting co-operative working between equipments covered by two or more of main groups G06K1/00 - G06K15/00, e.g. automatic card files incorporating conveying and reading operations arrangements or provisions for transferring data to distant stations, e.g. from a sensing device the arrangement consisting of a wireless interrogation device in combination with a device for optically marking the record carrier
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06Q—INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
- G06Q50/00—Information and communication technology [ICT] specially adapted for implementation of business processes of specific business sectors, e.g. utilities or tourism
- G06Q50/01—Social networking
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/06—Protocols specially adapted for file transfer, e.g. file transfer protocol [FTP]
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/10—Protocols in which an application is distributed across nodes in the network
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- Computer Networks & Wireless Communication (AREA)
- Health & Medical Sciences (AREA)
- General Health & Medical Sciences (AREA)
- General Physics & Mathematics (AREA)
- Signal Processing (AREA)
- Bioethics (AREA)
- Business, Economics & Management (AREA)
- General Engineering & Computer Science (AREA)
- Medical Informatics (AREA)
- Human Resources & Organizations (AREA)
- Computer Security & Cryptography (AREA)
- Computer Hardware Design (AREA)
- Computing Systems (AREA)
- Databases & Information Systems (AREA)
- Economics (AREA)
- Software Systems (AREA)
- Marketing (AREA)
- Primary Health Care (AREA)
- Strategic Management (AREA)
- Tourism & Hospitality (AREA)
- General Business, Economics & Management (AREA)
- Collating Specific Patterns (AREA)
Abstract
The invention provides an image sharing method, system and storage medium based on a two-dimension code social network.A face in an original image is subjected to region detection to obtain a plurality of salient regions; then, carrying out encryption processing on each detected significant area by using a secret image sharing algorithm based on a polynomial to generate a plurality of initial shares, carrying out exclusive OR operation on a visual secret sharing algorithm based on a random grid and a binary authentication image through a 4-bit least significant bit, obtaining a final share of a participant and a final share of a distributor with authentication capability through combination, then generating a QR (quick response) code by a cloud server according to a storage link of an original background image, generating a cover image of the QR code according to a compressed background image, finally authenticating the final share of the participant and the final share of the distributor, and recovering the image after the authentication is successful. The method and the device can solve the problems that privacy and usability during image sharing cannot be balanced and the calculation complexity is high in the prior art.
Description
Technical Field
The invention relates to the technical field of image processing, in particular to an image sharing method and system based on a two-dimension code social network and a storage medium.
Background
With the increasing popularity of mobile devices, various online social platforms greatly simplify the difficulty of spreading and sharing images. More and more images are transmitted over networks and stored on open source software. For example, more than 10 million new photos are uploaded to Facebook, WeChat, etc. daily. People can share information online in real time, exchange information with each other, and can transmit a large amount of additional information through shared images. Thus, online social networks have become an important part of people's daily life. The sharing of social photos depends on the subjective thoughts of the photo owner (called the publisher), who has their own preferences for the privacy part. Other participants were not informed or given their consent, but had their private information exposed, prior to the release of the photograph containing the information about the other participants.
To ensure privacy, the privacy policy of the image sharing social network is mainly focused on how the service provider explores the participants' information, and by which methods the participants can control the scope of information sharing. Most systems allow participants to manually specify privacy settings. For example: whether the image is public, private, or visible to a designated family or friend. However, since social networking photos are not only a publisher but also possibly some other participants, publishers do not consider privacy security of other participants when sharing photos. If the sharing of such photos is completely controlled by the publisher, the privacy of other related participants may be compromised. This privacy problem can be further explained by the following example. Suppose user a and user B take a photo together, then user B shares the photo on his social platform without telling user a, and user B privacy is set to be visible to all. Sharing photos would violate the privacy of user a if user a were not willing to see the photos by others.
In the above example, this photo is actually common to both user A and user B. When user B shares in the photo, he should either have recourse to user a's consent or be decided by user a himself whether to share. Generally, when a participant shares a photo with others, all relevant participants in the photo will be at risk of privacy disclosure. Therefore, how to avoid privacy invasion during image sharing is a technical problem to be solved by those skilled in the art.
Secret image sharing schemes, such as those based on generating keys to confront a network, may provide solutions to the problem of autonomous privacy control in social networks. The (k, n) threshold secret sharing scheme divides the shared image into n shares, called shares (or shares). According to this scheme, these shares are allocated to the respective n participants. If at least k or more shares out of the n shares are obtained, the original image can be reconstructed. Furthermore, when there are less than k shares of the n shares, no information about the shared image is available, regardless of how powerful the attacker is. However, the existing secret image sharing scheme can cause the image to lose the usability based on the content, and the privacy and the usability during image sharing cannot be balanced.
Disclosure of Invention
In view of the foregoing situation, the main object of the present invention is to provide an image sharing method based on a two-dimensional code social network, wherein the method includes the following steps:
step 3, taking areas except all the salient areas in the original image as original background images, uploading the original background images to a cloud server, generating a QR (quick response) code by the cloud server according to a storage link of the original background images, and generating a cover image of the QR code according to the compressed background images, wherein the image quality of the compressed background images is lower than that of the original background images, and finally, the cloud server issues the generated QR code to a social network;
and 4, when the participant and the dealer scan the QR codes through the code scanning equipment, the participant uploads the final share of the participant to the social network, the dealer uploads the final share of the dealer to the social network, the final share of the participant and the final share of the dealer are authenticated, and the image is restored by using a Lagrangian interpolation method after the authentication is successful.
According to the image sharing method based on the two-dimensional code social network, which is provided by the embodiment of the invention, as the QR code has strong robustness, the QR code generated by the link of the high-quality original background image is published to the social network, so that various damaging operations of the social network on the high-quality image can be effectively avoided: in addition, the low-quality compressed background image is used as the front cover of the QR code, and the privacy and usability of the image can be met to a certain degree. In addition, the secret image sharing algorithm of the polynomial is combined with the visual secret sharing algorithm of the random grid, the autonomous control privacy sharing can be carried out according to the intention of the participants, and the image sharing method is lower in computational complexity compared with the prior art.
The image sharing method based on the two-dimensional code social network is characterized in that in the step 2, an initial threshold value of a secret image sharing algorithm based on a polynomial is (2, 2).
The image sharing method based on the two-dimensional code social network includes the following steps:
step 2.1, setting a binary authentication imageIs of a size ofOf 1 atA significant area is,,Represents the total number of salient regions, willIs divided into the size ofThe initial threshold of the polynomial-based secret image sharing algorithm is set to (2, 2) for the three RGB channels of (1), and the salient region is set toPixel value of each channel inRepeating steps 2.2 to 2.5, wherein,,;
step 2.2, in the secret image sharing algorithm based on the polynomial, and adopting the initial share generated by the following formula:
wherein,to representThe value of the pixel of (a) is,the coefficients of the function are represented by,it is indicated that the remainder operation is performed,the number of the prime numbers is represented,represents the key of the secret key and the secret key,the initial fractions generated are respectivelyAnd,representing an order;
step 2.3, the vision secret image sharing algorithm based on the random grid uses two temporary bits 0 and1, feedingBy encrypting the pixel values ofRepresenting, calculatingAnd so on; when in useWhen it is in use, makeIf at allThen, thenWhereinExpressed as randomly arranged pixel values, which will then beIs randomly assigned to
step 2.4, withRepresenting a pixelAs a result of the xor operation with the 4 least significant bits, for each pixel value in the initial share generated in step 2.2, a decision is first madeIf yes, then determiningAndif the judgment result is true, obtaining the initial share after the exclusive-or operation, and entering the step 2.5, otherwise, returning to the step 2.2;
step 2.5, the initial share obtained in step 2.4 after the XOR operation is calculated asAndin combination with the above, wherein,is shown asA significant area, andfinally, the final share of the participants with authentication ability obtained by the participants is selfAnd other participantsWith authentication obtained by the dealerDealer Final share of capacity as allA combination of (a) and (b).
The image sharing method based on the two-dimensional code social network includes the following steps:
step 4.1, when the participants and the dealers scan the QR codes through the code scanning equipment, the participants upload the final shares of the participants to the social network, the dealers upload the final shares of the dealers to the social network, and the final shares of the participants or the dealers uploaded to the social network are adoptedIt is shown that,is of a size ofThere are two cases according to the number of participants:
first, when only one participant uploads the final share of the participant, the result of the XOR operation is computedStacking the calculated result and the final share of the dealer to obtain a detection imageThen detecting the imageAnd binary authentication imageCarrying out consistency comparison, if the consistency comparison is passed, the authentication is successful, and entering a step 4.2;
second, there are multiple participants uploading their respective final sharesCalculating the result of XOR operation corresponding to the final share of each participantThen, the calculation results are stacked pairwise to obtain a plurality of detection imagesEach detected image is processedAnd binary authentication imageConsistency comparison is carried out, if the consistency comparison is passed, authentication is successful, and the step 4.2 is carried out;
and 4.2, carrying out image restoration on the authenticated final share of the participants and the authenticated final share of the dealers by adopting a Lagrange interpolation method to obtainEach size isIs/are as followsWhereinindicated as the salient region after reconstruction.
The image sharing method based on the two-dimensional code social network specifically comprises the following steps of 1:
and performing region detection on the face in the original image by adopting a face recognition algorithm to obtain a plurality of salient regions.
The image sharing method based on the two-dimensional code social network specifically comprises the following steps of 1:
the original image is divided into R, G, B three channels, and then the face recognition algorithm is adopted to detect the face region in the original image, so as to obtain a plurality of salient regions.
The invention also provides an image sharing system based on the two-dimensional code social network, wherein the system comprises:
a region detection module to:
carrying out region detection on the human face in the original image to obtain a plurality of salient regions;
an encryption processing module to:
carrying out encryption processing on each detected significant region by utilizing a secret image sharing algorithm based on a polynomial to generate a plurality of initial shares, then carrying out XOR operation on the generated initial shares by combining a visual secret sharing algorithm based on a random grid and a binary authentication image through 4-bit least significant bits to obtain initial shares after the XOR operation, finally combining the initial shares after the XOR operation in a preset combination mode to obtain a final share of participants and a final share of a distributor with authentication capability, sharing the final share of the participants to the corresponding participants, and sharing the final share of the distributor to the corresponding distributor;
a link generation module to:
taking areas except all salient areas in the original image as original background images, uploading the original background images to a cloud server, generating a QR code by the cloud server according to a storage link of the original background images, and generating a cover image of the QR code according to a compressed background image, wherein the image quality of the compressed background image is lower than that of the original background image, and finally, the cloud server issues the generated QR code to a social network;
an image restoration module to:
when the participants and the dealers scan the QR codes through the code scanning equipment, the participants upload the final shares of the participants to the social network, the dealers upload the final shares of the dealers to the social network, the final shares of the participants and the final shares of the dealers are authenticated, and the images are restored by using a Lagrange interpolation method after the authentication is successful.
The invention further provides a storage medium on which a computer program is stored, wherein the program is executed by a processor to implement the image sharing method based on the two-dimensional code social network.
Additional aspects and advantages of the invention will be set forth in part in the description which follows and, in part, will be obvious from the description, or may be learned by practice of the invention.
Drawings
Fig. 1 is a flowchart of an image sharing method based on a two-dimensional code social network according to an embodiment of the present invention;
FIG. 2 is a schematic diagram of an exemplary manner of combining shares;
FIG. 3 is a graph comparing peak signal-to-noise ratio (PSNR) for different schemes at threshold (2, 2);
fig. 4 is a schematic structural diagram of an image sharing system based on a two-dimensional code social network according to an embodiment of the present invention.
Detailed Description
Reference will now be made in detail to embodiments of the present invention, examples of which are illustrated in the accompanying drawings, wherein like or similar reference numerals refer to the same or similar elements or elements having the same or similar function throughout. The embodiments described below with reference to the accompanying drawings are illustrative only for the purpose of explaining the present invention, and are not to be construed as limiting the present invention.
These and other aspects of embodiments of the invention will be apparent with reference to the following description and attached drawings. In the description and drawings, particular embodiments of the invention have been disclosed in detail as being indicative of some of the ways in which the principles of the embodiments of the invention may be practiced, but it is understood that the scope of the embodiments of the invention is not limited correspondingly. On the contrary, the embodiments of the invention include all changes, modifications and equivalents coming within the spirit and terms of the claims appended hereto.
Referring to fig. 1, an embodiment of the present invention provides an image sharing method based on a two-dimensional code social network, including steps 1 to 4:
The original image mainly refers to an original image in a social network, and specifically, a face recognition algorithm can be adopted to perform region detection on a face in the original image so as to obtain a plurality of salient regions.
The original image is usually a color image, for the color original image, the original image is firstly divided into R, G, B three channels, then a face recognition algorithm is adopted to carry out region detection on the face in the original image so as to obtain a plurality of salient regions (namely ROIs), each face is a salient region, each ROIS is called a secret image, and the secret image is usedIt is shown that,is shown asA region of one of the salient regions is,,representing the total number of salient regions.
And 2, encrypting each detected salient region by utilizing a secret image sharing algorithm based on a polynomial to generate a plurality of initial shares, then carrying out XOR operation on the generated initial shares by combining a visual secret sharing algorithm based on a random grid and a binary authentication image through 4-bit least significant bits to obtain initial shares after the XOR operation, finally combining the initial shares after the XOR operation in a preset combination mode to obtain a final share of a participant and a final share of a distributor with authentication capability, sharing the final share of the participant to the corresponding participant, and sharing the final share of the distributor to the corresponding distributor.
Wherein the initial threshold of the polynomial-based secret image sharing algorithm is (2, 2).
Specifically, the step 2 includes:
step 2.1, setting a binary authentication imageIs of a size ofFirst, ofA significant region is,,Represents the total number of salient regions, willIs divided into the size ofThe initial threshold of the polynomial-based secret image sharing algorithm is set to (2, 2) for the three RGB channels of (1), and the salient region is set toPixel value of each channel in (1)Repeating steps 2.2 to 2.5, wherein,,;
step 2.2, in the secret image sharing algorithm based on the polynomial, and adopting the initial share generated by the following formula:
wherein,to representThe value of the pixel of (a) is,the coefficients of the function are represented by,it is shown that the remainder operation is performed,the number of the prime numbers is represented,represents the key of the secret key and the secret key,the initial fractions generated are respectivelyAnd,representing an order;
step 2.3, the visual secret image sharing algorithm based on the random grid uses two temporary bits 0 and 1 to provideBy encrypting the pixel values ofRepresenting, calculatingBy analogy, whenWhen it is in use, makeIf, ifThen, thenWhereinExpressed as randomly arranged pixel values, which will then beIs randomly assigned to
step 2.4, withRepresenting a pixelAs a result of the xor operation with the 4 least significant bits, for each pixel value in the initial share generated in step 2.2, a decision is first madeIf yes, then determiningAndif the judgment result is true, obtaining the initial share after the exclusive-or operation, and entering the step 2.5, otherwise, returning to the step 2.2;
step 2.5, the initial share obtained in step 2.4 after XOR operation is divided byAndin combination with the above, wherein,is shown asA significant area, andfinally, the final share of the participants with authentication ability obtained by the participants is selfOf other participantsThe dealer's resulting final share of the dealer with certification capability is allCombinations of (a) and (b).
An exemplary combination of shares is shown in fig. 2, the image has 4 participants, respectively users A, B, C, D, and each ROIs region can obtain two initial shares, namely, two initial shares, after the above steps 2.1 to 2.5 are performed on each detected ROIs region、. Each user can be shared by his own ROIWith other usersThe final share of the combined participants, which the distributor can obtain shared by each ROIsThe combined dealer final share.
And 3, taking the areas outside all the salient areas in the original image as original background images, uploading the original background images to a cloud server, generating a QR (quick response) code by the cloud server according to the storage link of the original background images, generating a cover image of the QR code according to the compressed background images, wherein the image quality of the compressed background images is lower than that of the original background images, and finally, issuing the generated QR code to a social network by the cloud server.
After the encryption in the step 2, the original background image is uploaded to the cloud server, the cloud server generates a QR code according to the storage link of the original background image, and generates a cover image of the QR code according to the compressed background image, wherein the image quality of the compressed background image is lower than that of the original background image. The low-quality compressed background image is used for generating a front cover image of the QR code, and the privacy and the usability of the QR code can be met to a certain extent. And finally, the generated QR code is published to a social network.
And 4, when the participant and the dealer scan the QR codes through the code scanning equipment, the participant uploads the final share of the participant to the social network, the dealer uploads the final share of the dealer to the social network, the final share of the participant and the final share of the dealer are authenticated, and the image is restored by using a Lagrangian interpolation method after the authentication is successful.
In the authentication recovery stage, the image can be recovered by using a Lagrange interpolation method after the authentication is successful by only performing simple stacking operation on the share uploaded to the cloud by the participant and other participants or dealers. The cloud end can combine the ROIs restored and reconstructed with the background image, the link of the QR code is updated and generated, and other users can obtain the lossless reconstructed secret image only by scanning again.
Specifically, step 4 includes:
and 4.1, when the participants and the dealers scan the QR codes through the code scanning equipment, uploading the final shares of the participants to the social network by the participants, uploading the final shares of the dealers to the social network by the dealers, and adopting the final shares of the participants or the final shares of the dealers uploaded to the social networkIt is shown that,is of a size ofThere are two cases according to the number of participants:
first, when only one participant uploads the participant's final share, the XOR operation result is computedAnd will beStacking the calculated result and the final share of the dealer to obtain a detection imageThen detecting the imageAnd binary authentication imageCarrying out consistency comparison, if the consistency comparison is passed, successfully authenticating, and entering a step 4.2, otherwise, unsuccessfully authenticating, marking the participant as a deceptive person and recording the deceptive person by the cloud, and then informing other participants of the information;
secondly, when a plurality of participants upload respective final shares of the participants, calculating the exclusive or operation result corresponding to the final shares of the participantsThen, the calculation results are stacked pairwise to obtain a plurality of detection imagesEach detected image is processedAnd binary authentication imageAnd (4) consistency comparison is carried out, if the consistency comparison is passed, the authentication is successful, the step 4.2 is carried out, otherwise, the authentication is unsuccessful, the cloud records the deceased person, and the information is informed to other participants.
And 4.2, carrying out image restoration on the authenticated final share of the participants and the authenticated final share of the dealers by adopting a Lagrange interpolation method to obtainEach size isIs/are as followsWherein, in the process,represented as a salient region after reconstruction.
An image in the social network is experimentally analyzed by applying the method of the embodiment, and fig. 3 is a comparison graph of peak signal-to-noise ratio (PSNR) of different schemes under a threshold value of (2, 2). Fig. 3 shows that by analyzing peak signal-to-noise ratios (PSNR) of images under different schemes, the PSNR of the social network recovery graph obtained by using the method of the present invention is the highest, and the effect is the best, that is, the method of the present invention can achieve lossless recovery. The method can effectively meet the autonomous privacy control sharing of the social network participants.
In summary, according to the image sharing method based on the two-dimensional code social network provided by the embodiment, because the QR code has strong robustness, the QR code generated by the link of the high-quality original background image is published to the social network, so that various lossy operations of the social network on the high-quality image can be effectively avoided.
Referring to fig. 4, the present invention further provides an image sharing system based on a two-dimensional code social network, wherein the system includes:
a region detection module to:
carrying out region detection on the human face in the original image to obtain a plurality of salient regions;
an encryption processing module to:
carrying out encryption processing on each detected significant region by utilizing a secret image sharing algorithm based on a polynomial to generate a plurality of initial shares, then carrying out XOR operation on the generated initial shares by combining a visual secret sharing algorithm based on a random grid and a binary authentication image through 4-bit least significant bits to obtain initial shares after the XOR operation, finally combining the initial shares after the XOR operation in a preset combination mode to obtain a final share of participants and a final share of a distributor with authentication capability, sharing the final share of the participants to the corresponding participants, and sharing the final share of the distributor to the corresponding distributor;
a link generation module to:
taking areas except all salient areas in the original image as original background images, uploading the original background images to a cloud server, generating a QR code by the cloud server according to a storage link of the original background images, and generating a cover image of the QR code according to a compressed background image, wherein the image quality of the compressed background image is lower than that of the original background image, and finally, the cloud server issues the generated QR code to a social network;
an image restoration module to:
when the participants and the dealers scan the QR codes through the code scanning equipment, the participants upload the final shares of the participants to the social network, the dealers upload the final shares of the dealers to the social network, the final shares of the participants and the final shares of the dealers are authenticated, and the images are restored by using a Lagrangian interpolation method after the authentication is successful.
The invention further provides a storage medium on which a computer program is stored, wherein the program is executed by a processor to implement the image sharing method based on the two-dimensional code social network.
It should be understood that portions of the present invention may be implemented in hardware, software, firmware, or a combination thereof. In the above embodiments, the various steps or methods may be implemented in software or firmware stored in memory and executed by a suitable instruction execution system. For example, if implemented in hardware, as in another embodiment, any one or combination of the following techniques, which are known in the art, may be used: a discrete logic circuit having a logic gate circuit for implementing a logic function on a data signal, an application specific integrated circuit having an appropriate combinational logic gate circuit, a Programmable Gate Array (PGA), a Field Programmable Gate Array (FPGA), or the like.
In the description herein, references to the description of the term "one embodiment," "some embodiments," "an example," "a specific example," or "some examples," etc., mean that a particular feature, structure, material, or characteristic described in connection with the embodiment or example is included in at least one embodiment or example of the invention. In this specification, the schematic representations of the terms used above do not necessarily refer to the same embodiment or example. Furthermore, the particular features, structures, materials, or characteristics described may be combined in any suitable manner in any one or more embodiments or examples.
The above-mentioned embodiments only express several embodiments of the present invention, and the description thereof is more specific and detailed, but not construed as limiting the scope of the present invention. It should be noted that, for a person skilled in the art, several variations and modifications can be made without departing from the inventive concept, which falls within the scope of the present invention. Therefore, the protection scope of the present patent should be subject to the appended claims.
Claims (8)
1. An image sharing method based on a two-dimensional code social network is characterized by comprising the following steps:
step 1, performing region detection on a human face in an original image to obtain a plurality of salient regions;
step 2, carrying out encryption processing on each detected significant region by utilizing a secret image sharing algorithm based on a polynomial to generate a plurality of initial shares, then carrying out XOR operation on the generated initial shares by combining a visual secret sharing algorithm based on a random grid and a binary authentication image through 4-bit least significant bits to obtain initial shares after XOR operation, finally combining the initial shares after XOR operation in a preset combination mode to obtain a final share of a participant and a final share of a distributor with authentication capability, sharing the final share of the participant to the corresponding participant, and sharing the final share of the distributor to the corresponding distributor;
step 3, taking areas except all the salient areas in the original image as original background images, uploading the original background images to a cloud server, generating a QR (quick response) code by the cloud server according to a storage link of the original background images, and generating a cover image of the QR code according to the compressed background images, wherein the image quality of the compressed background images is lower than that of the original background images, and finally, the cloud server issues the generated QR code to a social network;
and 4, when the participant and the dealer scan the QR codes through the code scanning equipment, the participant uploads the final share of the participant to the social network, the dealer uploads the final share of the dealer to the social network, the final share of the participant and the final share of the dealer are authenticated, and the image is restored by using a Lagrangian interpolation method after the authentication is successful.
2. The image sharing method based on the two-dimensional code social network is characterized in that in the step 2, the initial threshold value of the secret image sharing algorithm based on the polynomial is (2, 2).
3. The image sharing method based on the two-dimensional code social network according to claim 2, wherein the step 2 specifically comprises:
step 2.1, setting a binary authentication imageIs of a size ofFirst, ofA significant region is,,Represents the total number of salient regions, willIs divided into the size ofThe initial threshold of the polynomial-based secret image sharing algorithm is set to (2, 2) for the three RGB channels of (1), and the salient region is set toPixel value of each channel inRepeating steps 2.2 to 2.5, wherein,,;
step 2.2, in the secret image sharing algorithm based on the polynomial, and adopting the initial share generated by the following formula:
wherein,to representThe value of the pixel of (a) is,the coefficients of the function are represented by,it is indicated that the remainder operation is performed,the number of the prime numbers is represented,represents the key of the secret key and the secret key,the initial fractions generated are respectivelyAnd,representing an order;
step 2.3, the visual secret image sharing algorithm based on the random grid uses two temporary bits 0 and 1 to provideIs encrypted withRepresenting, calculatingAnd so on; when in useWhen it is in use, makeIf, ifThen, thenWhereinExpressed as randomly arranged pixel values, which will then beIs randomly assigned to
step 2.4, withRepresenting a pixelAs a result of the xor operation with the 4 least significant bits, for each pixel value in the initial share generated in step 2.2, a decision is first madeIf yes, then judgeAndif the result is positive, obtaining the initial share after the XOR operation, and entering the step 2.5, otherwise, returning to the step 2.2;
step 2.5, the initial share obtained in step 2.4 after the XOR operation is calculated asAndin combination with the above, wherein,is shown asA significant area, andfinally, the final share of the participants with authentication ability obtained by the participants is selfAnd other participantsIn combination with (1)The final share of the dealer with certification ability obtained by the dealer is allCombinations of (a) and (b).
4. The image sharing method based on the two-dimensional code social network according to claim 3, wherein the step 4 specifically comprises:
and 4.1, when the participants and the dealers scan the QR codes through the code scanning equipment, uploading the final shares of the participants to the social network by the participants, uploading the final shares of the dealers to the social network by the dealers, and adopting the final shares of the participants or the final shares of the dealers uploaded to the social networkIt is shown that,is of the size ofThere are two cases according to the number of participants:
first, when only one participant uploads the final share of the participant, the result of the XOR operation is computedStacking the calculated result and the final share of the dealer to obtain a detection imageThen detecting the imageAnd binary authentication imageCarrying out consistency comparison, if the consistency comparison is passed, the authentication is successful, and entering a step 4.2;
secondly, when a plurality of participants upload respective final shares of the participants, calculating the exclusive or operation result corresponding to the final shares of the participantsThen, the calculation results are stacked pairwise to obtain a plurality of detection imagesEach detected image is processedAnd binary authentication imageConsistency comparison is carried out, if the consistency comparison is passed, authentication is successful, and the step 4.2 is carried out;
and 4.2, carrying out image restoration on the authenticated final share of the participants and the authenticated final share of the dealers by adopting a Lagrange interpolation method to obtain the final share of the participants and the dealersIs/are as followsWhereinrepresented as a salient region after reconstruction.
5. The image sharing method based on the two-dimensional code social network according to claim 1, wherein the step 1 specifically comprises:
and detecting the regions of the human face in the original image by adopting a human face recognition algorithm to obtain a plurality of salient regions.
6. The image sharing method based on the two-dimensional code social network according to claim 5, wherein the step 1 specifically comprises:
the original image is divided into R, G, B three channels, and then the face recognition algorithm is adopted to detect the face region in the original image, so as to obtain a plurality of salient regions.
7. An image sharing system based on a two-dimensional code social network is characterized in that the system comprises:
a region detection module to:
carrying out region detection on the human face in the original image to obtain a plurality of salient regions;
an encryption processing module to:
carrying out encryption processing on each detected significant region by utilizing a secret image sharing algorithm based on a polynomial to generate a plurality of initial shares, then carrying out XOR operation on the generated initial shares by combining a visual secret sharing algorithm based on a random grid and a binary authentication image through 4-bit least significant bits to obtain initial shares after the XOR operation, finally combining the initial shares after the XOR operation in a preset combination mode to obtain a final share of participants and a final share of a distributor with authentication capability, sharing the final share of the participants to the corresponding participants, and sharing the final share of the distributor to the corresponding distributor;
a link generation module to:
taking areas except all salient areas in the original image as original background images, uploading the original background images to a cloud server, generating a QR code by the cloud server according to a storage link of the original background images, and generating a cover image of the QR code according to a compressed background image, wherein the image quality of the compressed background image is lower than that of the original background image, and finally, the cloud server issues the generated QR code to a social network;
an image restoration module to:
when the participants and the dealers scan the QR codes through the code scanning equipment, the participants upload the final shares of the participants to the social network, the dealers upload the final shares of the dealers to the social network, the final shares of the participants and the final shares of the dealers are authenticated, and the images are restored by using a Lagrangian interpolation method after the authentication is successful.
8. A storage medium having a computer program stored thereon, wherein the computer program is executed by a processor to implement the image sharing method based on the two-dimensional code social network according to any one of claims 1 to 6.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202210917056.8A CN114996766A (en) | 2022-08-01 | 2022-08-01 | Image sharing method and system based on two-dimension code social network and storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202210917056.8A CN114996766A (en) | 2022-08-01 | 2022-08-01 | Image sharing method and system based on two-dimension code social network and storage medium |
Publications (1)
Publication Number | Publication Date |
---|---|
CN114996766A true CN114996766A (en) | 2022-09-02 |
Family
ID=83022770
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202210917056.8A Pending CN114996766A (en) | 2022-08-01 | 2022-08-01 | Image sharing method and system based on two-dimension code social network and storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN114996766A (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN116095245A (en) * | 2023-04-07 | 2023-05-09 | 江西财经大学 | Secret information sharing method, system, terminal and storage medium |
Citations (11)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20130080589A1 (en) * | 2011-09-22 | 2013-03-28 | Walton Advanced Engineering Inc. | Image-based data sharing system and its executive method |
CN103942290A (en) * | 2014-04-11 | 2014-07-23 | 北京金山网络科技有限公司 | Method and equipment used for providing images in webpage in terminal |
US20160078335A1 (en) * | 2014-09-15 | 2016-03-17 | Ebay Inc. | Combining a qr code and an image |
CN106529368A (en) * | 2016-09-29 | 2017-03-22 | 上海正雅齿科科技有限公司 | Method for localizing recognition region of two-dimensional code |
CN207282157U (en) * | 2017-07-20 | 2018-04-27 | 朗昇科技(苏州)有限公司 | A kind of Quick Response Code ultrasonoscopy shared system |
CN110602349A (en) * | 2019-08-27 | 2019-12-20 | 成都信息工程大学 | Method for security protection of associated image content |
CN110751500A (en) * | 2019-09-06 | 2020-02-04 | 中国平安财产保险股份有限公司 | Processing method and device for sharing pictures, computer equipment and storage medium |
WO2020156552A1 (en) * | 2019-01-31 | 2020-08-06 | 北京嘀嘀无限科技发展有限公司 | Two-dimensional code generation and recognition methods and devices |
CN112422767A (en) * | 2020-10-30 | 2021-02-26 | 国家电网有限公司大数据中心 | Secret sharing method and system based on visual effect |
CN112529974A (en) * | 2020-12-03 | 2021-03-19 | 中国科学院深圳先进技术研究院 | Color visual password sharing method and device for binary image |
CN113160944A (en) * | 2021-02-03 | 2021-07-23 | 江西财经大学 | Medical image sharing method based on block chain |
-
2022
- 2022-08-01 CN CN202210917056.8A patent/CN114996766A/en active Pending
Patent Citations (11)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20130080589A1 (en) * | 2011-09-22 | 2013-03-28 | Walton Advanced Engineering Inc. | Image-based data sharing system and its executive method |
CN103942290A (en) * | 2014-04-11 | 2014-07-23 | 北京金山网络科技有限公司 | Method and equipment used for providing images in webpage in terminal |
US20160078335A1 (en) * | 2014-09-15 | 2016-03-17 | Ebay Inc. | Combining a qr code and an image |
CN106529368A (en) * | 2016-09-29 | 2017-03-22 | 上海正雅齿科科技有限公司 | Method for localizing recognition region of two-dimensional code |
CN207282157U (en) * | 2017-07-20 | 2018-04-27 | 朗昇科技(苏州)有限公司 | A kind of Quick Response Code ultrasonoscopy shared system |
WO2020156552A1 (en) * | 2019-01-31 | 2020-08-06 | 北京嘀嘀无限科技发展有限公司 | Two-dimensional code generation and recognition methods and devices |
CN110602349A (en) * | 2019-08-27 | 2019-12-20 | 成都信息工程大学 | Method for security protection of associated image content |
CN110751500A (en) * | 2019-09-06 | 2020-02-04 | 中国平安财产保险股份有限公司 | Processing method and device for sharing pictures, computer equipment and storage medium |
CN112422767A (en) * | 2020-10-30 | 2021-02-26 | 国家电网有限公司大数据中心 | Secret sharing method and system based on visual effect |
CN112529974A (en) * | 2020-12-03 | 2021-03-19 | 中国科学院深圳先进技术研究院 | Color visual password sharing method and device for binary image |
CN113160944A (en) * | 2021-02-03 | 2021-07-23 | 江西财经大学 | Medical image sharing method based on block chain |
Non-Patent Citations (3)
Title |
---|
SONG WAN 等: "Visual Secret Sharing Scheme with (k, n) Threshold Based on QR Codes", 《2016 12TH INTERNATIONAL CONFERENCE ON MOBILE AD-HOC AND SENSOR NETWORKS (MSN)》 * |
WENYING WEN 等: "A novel selective image encryption method based on saliency detection", 《2016 VISUAL COMMUNICATIONS AND IMAGE PROCESSING (VCIP)》 * |
宫庆红: "无损恢复的秘密图像分享关键技术研究", 《中国优秀硕士学位论文全文数据库 信息科技辑》 * |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN116095245A (en) * | 2023-04-07 | 2023-05-09 | 江西财经大学 | Secret information sharing method, system, terminal and storage medium |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN113160944B (en) | Medical image sharing method based on blockchain | |
RU2422901C2 (en) | Information processing device and information processing method | |
CN108563956A (en) | Safe encrypted domain reversible information hidden method based on the prediction of high bit flipping | |
Khupse et al. | An adaptive steganography technique for videos using Steganoflage | |
CN111079573A (en) | Anti-counterfeiting encryption method based on image random scrambling technology | |
EP2139220A2 (en) | Information processing apparatus and information processing method | |
CN114996766A (en) | Image sharing method and system based on two-dimension code social network and storage medium | |
Ye et al. | Noise-free thumbnail-preserving image encryption based on MSB prediction | |
Singh et al. | Images as graphical password: verification and analysis using non-regular low-density parity check coding | |
Zhao et al. | Heterogeneous and customized cost-efficient reversible image degradation for green IoT | |
JP2004007442A (en) | Information processing method and device, computer program and computer readable storage medium | |
Chen et al. | An improved blind watermarking method facing dual color images based on Hadamard transform | |
Sharifzadeh et al. | A new parallel message-distribution technique for cost-based steganography | |
Brindha et al. | Hiding fingerprint in face using scattered LSB embedding steganographic technique for smart card based authentication system | |
Ruchaud et al. | JPEG‐based scalable privacy protection and image data utility preservation | |
Buhan et al. | Secure pairing with biometrics | |
Sun et al. | High‐Capacity Data Hiding Method Based on Two Subgroup Pixels‐Value Adjustment Using Encoding Function | |
Ma et al. | A Novel Image Digital Rights Management Scheme with High‐Level Security, Usage Control and Traceability | |
Sumalatha et al. | Local content based image authentication for tamper localization | |
Rajput et al. | Privacy-preserving smart surveillance using local color correction and optimized elgamal cryptosystem over cloud | |
Mahasree et al. | An improved reversible data hiding for encrypted images over cloud | |
Rupa | Privacy preservation of ROI of medical image using squint pixel and PLSB hiding technique | |
Ogla | Symmetric-Based steganography technique using spiral-searching method for HSV color images | |
Ren et al. | A novel reversible data hiding method in encrypted images using efficient parametric binary tree labeling | |
Umamageswari et al. | Performance analysis of secure medical image communication with digital signature and reversible watermarking |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination |