Image tampering protection method based on steganography technology
By embedding associated information in the image and comparing the steganographic information using the steganographic analysis module, the problem of difficult to identify image tampering in the prior art is solved, and a higher image and data tampering resistance is achieved.
Patent Information
- Application Number
- CN202510282008.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-11
- Publication Date
- 2025-06-06
AI Technical Summary
It is difficult for the prior art to effectively identify whether images or data have been tampered with, especially in industries such as financial leasing. How to ensure the authenticity of images and related information has become a challenge.
Using an image tamper protection method based on steganography technology, by marking key areas in the image, embedding associated information into the image, and extracting steganography information from the transmitted image through the steganography analysis module for comparison, we judge whether the image has been tampered with.
Through the steganography technology, the tampering situation can be judged by the difference in the steganography information when the image is tampered, which improves the tampering ability of the image and data and ensures the reliability of the information.
Smart Images

Figure CN120111248A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of image processing, and in particular relates to an image tampering protection method based on steganography technology. Background Art
[0002] Images are generally used as the basis for operations in multiple industries in online processes. Therefore, online platforms focus on the authenticity of images uploaded by users or on-site staff. For example, in the field of financial leasing, the content information of paper documents such as bill contracts and the status information of on-site leased items are often sent to the platform data center by collecting images and entering related data (such as text descriptions of content information and status information, related parameter data, etc.). Therefore, how to ensure the reliability and authenticity of images and related information data has become the research focus of related technologies.
[0003] Due to technological advances, it is becoming increasingly difficult to detect tampering of images and their associated data using artificial intelligence technology. As a result, existing manual review or simple image analysis methods can no longer guarantee the authenticity of relevant data. Therefore, how to improve the anti-tampering capabilities of image information and its related data information, so that the platform can more effectively obtain relevant information while identifying whether images or data have been tampered with, has become a technical problem to be solved. Summary of the invention
[0004] The purpose of the present invention is to provide an image tampering protection method based on steganography technology, which is used to solve the technical problem that the prior art cannot obtain relevant information while more reliably identifying whether an image or data has been tampered with.
[0005] The image tampering protection method based on steganography technology comprises the following steps:
[0006] S1, collecting images and entering relevant information, marking key areas on the images to obtain an initial image, wherein the key areas are areas containing key information;
[0007] S2, the initial image is divided into a key area image and a non-key image and then input into a steganographic module, the steganographic module embeds the associated information into the key area image and the non-key image respectively through the steganographic technology, and then merges the key area image and the non-key image into a transmission image;
[0008] S3, the transmission image is sent to the platform by the terminal. The platform decomposes the transmission image through the steganalysis module to obtain the steganalysis information located in the key area image and the non-key image respectively, compares the difference between the steganalysis information in different positions, and decodes the steganalysis information for identification. It determines whether the transmission image has been tampered with based on the difference value and the identification result.
[0009] Preferably, in step S1, an image is captured by an image capture module of the terminal, and associated information associated with the image is input through the terminal at the same time. Then, the area containing key information in the image is marked on the terminal by manual marking or artificial intelligence recognition, and the associated information is encoded as stego information to be input into the stego module.
[0010] Preferably, in step S2, the steganographic module uses a filter group to perform frequency domain decomposition on the input image to be steganographic, and the coefficients of each filter in the filter group are combined with the corresponding decomposition results to form the overall frequency domain of the entire filter group; the image to be steganographic is converted into a frequency spectrum corresponding to the overall frequency domain.
[0011] Preferably, in step S2, F k represents the frequency domain decomposition result of the kth filter in the filter bank, then the following formula is obtained: k =B k ·G, where G represents the frequency band vector, G=(g 1 ,g 2 ,…,g i ,…,g n ), where n is the number of filters, g i represents the fundamental mode of the ith frequency band decomposed by the filter. k is the frequency domain decomposition result of the kth filter. For the frequency band coefficient vector of the kth filter, we have B k =(b 1k ,b 2k ,…,b ik ,…,b nk ), where b ik represents the coefficient of the i-th frequency band decomposed by the k-th filter. Thus, the frequency band coefficient matrix B decomposed in the frequency domain can be obtained as follows: 1 ,B 2 ,…,B k ,…,B m ), and further obtain the frequency band coefficient column vector B corresponding to each frequency band i , and there is B i =(b i1 ,b i2 ,…,b ik ,…,b im ).
[0012] Preferably, in step S2, the frequency domain decomposition results of the filter are summed to obtain the overall frequency domain, and F I Representing the overall frequency domain, we have the following formula:
[0013]
[0014] Among them, bik represents the coefficient of the i-th frequency band decomposed by the k-th filter, g i Represents the basis mode of the ith frequency band decomposed by this filter.
[0015] Preferably, in step S2, the energy value of each frequency band under each channel in the spectrum diagram is calculated, and the weight of the frequency band under the corresponding channel is assigned based on the energy value. The larger the energy value, the smaller the weight value. The distortion function is constructed based on the calculated weight value and the base mode of the corresponding frequency band.
[0016] Preferably, the energy value of each frequency band is calculated first: Among them, E i Indicates energy value, g i represents the fundamental mode of the ith frequency band decomposed by the filter, a pq Represents the element in the pth row and qth column of the filter bank; the energy value in the spectrum obtained in the overall frequency domain is fitted to obtain the corresponding energy function f E (E i ), the energy function reflects the law of energy value changing with frequency, and it is combined with the energy value of each frequency band to calculate the weight value. The corresponding formula is:
[0017]
[0018] Among them, ω i represents the weight value of the i-th frequency band, E i represents the energy value, c represents an adjustable parameter, and c < 0. The weight value calculated by the weight function decreases as the energy value increases.
[0019] Preferably, a distortion function K used for steganography is formed based on the weight value of each frequency band and the base pattern corresponding to the frequency band:
[0020]
[0021] Among them, I m Represents an image; the steganographic information is embedded into the key area image and the non-key image respectively through the distortion function.
[0022] Preferably, the steganalysis module adopts a spatial domain steganalysis rich model to perform steganalysis, and the spatial domain steganalysis rich model adopts the same filter group as the steganalysis module to perform frequency domain decomposition, and extracts features from the obtained spectrum map, and after the steganalysis information is identified and separated by a trained classifier, the obtained spectrum map is converted into a carrier image with the steganalysis information removed; thereby, the steganalysis module outputs a carrier image and steganalysis information, and the steganalysis information includes at least two groups of steganalysis information respectively obtained from a key area in the transmission image and a non-key area other than the key area, and when there are multiple key areas, there are multiple groups of steganalysis information.
[0023] Preferably, each group of stego information is then compared. If the difference between the stego information at different positions is less than a threshold, the stego information is further decoded; if the difference between the stego information at different positions is greater than the threshold, an alarm message is issued; the stego information is decoded and the decoded information is identified. If it can be identified normally, it is determined that the transmitted image has not been tampered with; if it cannot be identified, it is determined that the transmitted image has been tampered with and a warning is issued.
[0024] The present invention has the following advantages: the method provided by the present invention converts the associated information of an image into stego information, divides the image into a key area image and a non-key image, and embeds the stego information into the key area image and the non-key image respectively through the steganographic technology, so that the associated information is secretly transmitted through the image to prevent the associated information from being stolen or tampered with. At the same time, since the image contains multiple pieces of associated information, it is possible to compare the stego information extracted from the two different areas of the key area image and the non-key image that are easily tampered with, so as to determine whether the image tampering occurs. In addition, it is possible to better judge whether the image tampering occurs by identifying the stego information.
[0025] At the same time, the present invention adopts the frequency domain transformation method to embed the steganographic information, and in the embedding method, the distortion function adopts the method of adjusting the weight by frequency band, while taking into account the changes in frequency band and corresponding energy value, so that the steganographic information can be more reasonably embedded in the original image, thereby improving the security of information transmission while reducing image distortion. BRIEF DESCRIPTION OF THE DRAWINGS
[0026] Figure 1 It is a basic flow chart of an image tampering protection method based on steganography technology of the present invention.
[0027] Figure 2 It is a flow chart of the steps of embedding steganographic information in step S2 of the present invention. DETAILED DESCRIPTION
[0028] The specific implementation modes of the present invention will be further explained in detail below by describing the embodiments with reference to the accompanying drawings, so as to help those skilled in the art to have a more complete, accurate and in-depth understanding of the inventive concept and technical solution of the present invention.
[0029] like Figure 1 and 2 As shown, the present invention provides an image tampering protection method based on steganography technology, which includes the following steps.
[0030] S1, collecting images and entering relevant information, marking key areas on the images to obtain an initial image, wherein the key areas are areas containing key information.
[0031] In this step, the image is collected by the image acquisition module of the terminal, and the associated information associated with the image is input through the terminal at the same time. Then, the area containing key information in the image is marked on the terminal by manual marking or artificial intelligence recognition. For example, the damaged part of the equipment in the image, the key clauses or signature information in the contract, etc.; thus, the initial image to be input into the steganography module is obtained. The associated information is encoded as stego information and is ready to be input into the steganography module.
[0032] S2, the initial image is divided into a key area image and a non-key image and then input into a steganographic module, the steganographic module embeds the associated information into the key area image and the non-key image respectively through steganographic technology, and then merges the key area image and the non-key image into a transmission image.
[0033] In this step, the steganographic module uses a filter bank to perform frequency domain decomposition on the input image to be steganographic. Frequency domain decomposition can be performed using DCT transform (discrete cosine transform), DFT transform (discrete Fourier transform) or DWT transform (discrete wavelet transform). The coefficients of each filter in the filter bank are combined with the corresponding decomposition results to form the overall frequency domain of the entire filter bank. The image to be steganographic is converted into a spectrum corresponding to the overall frequency domain.
[0034] F k represents the frequency domain decomposition result of the kth filter in the filter bank, then the following formula is obtained: k =B k ·G, where G represents the frequency band vector, G=(g 1 ,g 2 ,…,g i ,…,g n ), where n is the number of filters, g i represents the basis mode of the ith frequency band decomposed by the filter, and the corresponding basis mode is selected according to the different frequency domain transformation methods adopted. k is the frequency domain decomposition result of the kth filter. Therefore, for different filters, there are also several frequency band coefficient vectors, which are expressed in turn by B 1 ,B 2 ,…,B k ,…,B m It means that for the frequency band coefficient vector of the kth filter, there is B k =(b 1k ,b 2k ,…,b ik ,…,b nk ), where b ik represents the coefficient of the i-th frequency band decomposed by the k-th filter. Thus, the frequency band coefficient matrix B decomposed in the frequency domain can be obtained as follows: 1 ,B 2 ,…,B k,…,B m ), and further obtain the frequency band coefficient column vector B corresponding to each frequency band i , and there is B i =(b i1 ,b i2 ,…,b ik ,…,b im ).
[0035] The sum of the frequency domain decomposition results of the filter can get the overall frequency domain, and F I Representing the overall frequency domain, we have the following formula:
[0036]
[0037] Among them, b ik represents the coefficient of the i-th frequency band decomposed by the k-th filter, g i Represents the basis mode of the ith frequency band decomposed by this filter.
[0038] Then, the energy value of each frequency band under each channel in the spectrum diagram is calculated, and the weight of the frequency band under the corresponding channel is assigned based on the energy value. The larger the energy value, the smaller the weight value. The distortion function is constructed based on the calculated weight value and the base mode of the corresponding frequency band.
[0039] First, calculate the energy value of each frequency band: Among them, E i Indicates energy value, g i represents the fundamental mode of the ith frequency band decomposed by the filter, a pq Represents the element in the pth row and qth column of the filter bank. Fit the energy value in the spectrum obtained in the overall frequency domain to obtain the corresponding energy function f E (E i ), the energy function reflects the law of energy value changing with frequency, and it is combined with the energy value of each frequency band to calculate the weight value. The corresponding formula is:
[0040]
[0041] Among them, ω i represents the weight value of the i-th frequency band, E i represents the energy value, c represents an adjustable parameter, and c < 0. The weight value calculated by the weight function decreases as the energy value increases.
[0042] The distortion function K used for steganography is formed based on the weight value of each frequency band and the base pattern corresponding to the frequency band:
[0043]
[0044] Among them, I mRepresents an image; the steganographic information is embedded into the key area image and the non-key image respectively through the distortion function.
[0045] S3, the transmission image is sent to the platform by the terminal. The platform decomposes the transmission image through the steganalysis module to obtain the steganalysis information located in the key area image and the non-key image respectively, compares the difference between the steganalysis information in different positions, and decodes the steganalysis information for identification. It determines whether the transmission image has been tampered with based on the difference value and the identification result.
[0046] The steganalysis module can use a spatial domain steganalysis rich model to perform steganalysis. The spatial domain steganalysis rich model uses the same filter group as the steganalysis module to perform frequency domain decomposition, and extracts features from the obtained spectrum map. After the steganalysis information is identified and separated by the trained classifier, the obtained spectrum map is converted into a carrier image from which the steganalysis information is removed. The steganalysis module thus outputs a carrier image and steganalysis information, and the steganalysis information includes at least two groups of steganalysis information obtained from the key area and the non-key area other than the key area in the transmission image. When there are multiple key areas, there are multiple groups of steganalysis information.
[0047] Then, each group of stego information is compared. If the difference between the stego information at different positions is less than the threshold, it means that the stego information remains basically consistent during the transmission process, and the possibility of the key area containing the key information being tampered with is small, and the stego information can be further decoded; if the difference between the stego information at different positions is greater than the threshold, it means that the stego information has undergone a significant change during the transmission process, and the key area may be tampered with. At this time, the platform will issue an alarm message and can require the customer or on-site staff to check and re-upload the image.
[0048] The difference between the stego information at different positions is less than the threshold, and then the stego information is decoded and the decoded information is identified. After the decoded information is obtained, it is identified to obtain the associated information associated with the image. If it can be identified normally, it is judged that the transmitted image has not been tampered with, and the carrier image is considered to be basically consistent with the initial image. The carrier and the identified associated information are associated and stored in the system for subsequent processes; otherwise, it means that the associated information is distorted so that its content cannot be identified normally. At this time, the platform administrator can participate in manual identification. If it cannot be identified, it is judged that the transmitted image has been tampered with. The platform issues a warning and requires the customer or on-site staff to check and re-upload the image.
[0049] The present invention is described above by way of example in conjunction with the accompanying drawings. It is obvious that the specific implementation of the present invention is not limited to the above-mentioned method. As long as various non-substantial improvements are made using the inventive concept and technical solution of the present invention, or the inventive concept and technical solution are directly applied to other occasions without improvement, they are all within the protection scope of the present invention.
Claims
1. A method for protecting against image tampering based on steganography, characterized in that: The following steps are involved: S1, collecting images and entering relevant information, marking key areas on the images to obtain an initial image, wherein the key areas are areas containing key information; S2, the initial image is divided into a key area image and a non-key image and then input into a steganographic module, the steganographic module embeds the associated information into the key area image and the non-key image respectively through the steganographic technology, and then merges the key area image and the non-key image into a transmission image; S3, the transmission image is sent to the platform by the terminal. The platform decomposes the transmission image through the steganalysis module to obtain the steganalysis information located in the key area image and the non-key image respectively, compares the difference between the steganalysis information in different positions, and decodes the steganalysis information for identification. It determines whether the transmission image has been tampered with based on the difference value and the identification result.
2. According to claim 1, the image tampering protection method based on steganography technology is characterized in that: In step S1, an image is captured by an image capture module of the terminal, and at the same time, associated information associated with the image is input through the terminal. Then, the area containing key information in the image is marked on the terminal by manual marking or artificial intelligence recognition, and the associated information is encoded as stego information to be input into the stego module.
3. According to claim 2, the image tampering protection method based on steganography technology is characterized in that: In step S2, the steganographic module uses a filter bank to perform frequency domain decomposition on the input image to be steganographic, and the coefficients of each filter in the filter bank are combined with the corresponding decomposition results to form the overall frequency domain of the entire filter bank; the image to be steganographic is converted into a frequency spectrum corresponding to the overall frequency domain.
4. The image tampering protection method based on steganography technology according to claim 3 is characterized in that: In step S2, F k represents the frequency domain decomposition result of the kth filter in the filter bank, then the following formula is obtained: k =B k ·G, where G represents the frequency band vector, G = (g1, g2, ..., g i ,…,g n ), where n is the number of filters, g i represents the fundamental mode of the ith frequency band decomposed by the filter. k is the frequency domain decomposition result of the kth filter. For the frequency band coefficient vector of the kth filter, we have B k =(b 1k ,b 2k ,…,b ik ,…,b nk ), where b ik represents the coefficient of the i-th frequency band decomposed by the k-th filter. Thus, the frequency band coefficient matrix B=(B1, B2,…, B k ,…,B m ), and further obtain the frequency band coefficient column vector B corresponding to each frequency band i , and there is B i =(b i1 ,b i2 ,…,b ik ,…,b im ).
5. The image tampering protection method based on steganography technology according to claim 4 is characterized in that: In step S2, the frequency domain decomposition results of the filter are summed to obtain the overall frequency domain, which is expressed as F I Representing the overall frequency domain, we have the following formula: Among them, b ik represents the coefficient of the i-th frequency band decomposed by the k-th filter, g i Represents the basis mode of the ith frequency band decomposed by this filter.
6. The image tampering protection method based on steganography technology according to claim 5 is characterized in that: In step S2, the energy value of each frequency band under each channel in the spectrum diagram is calculated, and the weight of the frequency band under the corresponding channel is assigned based on the energy value. The larger the energy value, the smaller the weight value. The distortion function is constructed based on the calculated weight value and the base mode of the corresponding frequency band.
7. The image tampering protection method based on steganography technology according to claim 6 is characterized by: First, calculate the energy value of each frequency band: Among them, E i Indicates energy value, g i represents the fundamental mode of the ith frequency band decomposed by the filter, a pq Represents the element in the pth row and qth column of the filter bank; the energy value in the spectrum obtained in the overall frequency domain is fitted to obtain the corresponding energy function f E (E i ), the energy function reflects the law of energy value changing with frequency, and it is combined with the energy value of each frequency band to calculate the weight value. The corresponding formula is: Among them, ω i represents the weight value of the i-th frequency band, E i represents the energy value, c represents an adjustable parameter, and c < 0. The weight value calculated by the weight function decreases as the energy value increases.
8. The image tampering protection method based on steganography technology according to claim 7 is characterized in that: The distortion function K used for steganography is formed based on the weight value of each frequency band and the base pattern corresponding to the frequency band: Among them, I m Represents an image; the steganographic information is embedded into the key area image and the non-key image respectively through the distortion function.
9. The image tampering protection method based on steganography technology according to claim 8 is characterized in that: The steganalysis module adopts a spatial domain steganalysis rich model to perform steganalysis. The spatial domain steganalysis rich model adopts the same filter group as the steganalysis module to perform frequency domain decomposition, and extracts features from the obtained spectrum map. After the steganalysis information is identified and separated by the trained classifier, the obtained spectrum map is converted into a carrier image with the steganalysis information removed. The steganalysis module thus outputs a carrier image and steganalysis information, and the steganalysis information includes at least two groups of steganalysis information respectively obtained from the key area and the non-key area other than the key area in the transmitted image. When there are multiple key areas, there are multiple groups of steganalysis information.
10. The image tampering protection method based on steganography technology according to claim 9 is characterized in that: Then, each group of stego information is compared. If the difference between the stego information at different positions is less than the threshold, the stego information is further decoded; if the difference between the stego information at different positions is greater than the threshold, an alarm message is issued; the stego information is decoded and the decoded information is identified. If it can be identified normally, it is determined that the transmitted image has not been tampered with; if it cannot be identified, it is determined that the transmitted image has been tampered with and a warning is issued.
Citation Information
Cited By
Brain tissue slice image sharing system
CN122245652A