Electronic bidding document tamper-proofing method based on improved DCT (Discrete Cosine Transform) algorithm
By improving the combination of DCT algorithm and Arnold transformation algorithm, the concealment and tampering of electronic bid information is achieved, and the problems of the existing technology winning bid information is easily tampered with and the security measures are not concealed enough, which improves the security and reliability of electronic bid documents.
Patent Information
- Application Number
- CN202411665410.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-20
- Publication Date
- 2025-03-11
AI Technical Summary
The existing electronic bidding system has security challenges in its tamper-proof, especially the bidding information is easily tampered with by criminals, and the existing security measures are not concealed enough and are easily cracked.
The improved DCT algorithm is adopted to encrypt the main information image of the bid through the Arnold transformation algorithm and embed it in the original picture to generate the DCT algorithm image tampering positioning model, calculate the probability that the DCT algorithm block is tampered with, locate the tampering area, and confirm whether it has been tampered with through secondary identification.
It realizes the highly concealed and tamper-proof of electronic bid information, provides the advantages of immutable and fair anti-counterfeiting, improves the security and reliability of electronic bids, and facilitates to serve as a credible inspection basis in procurement compliance inspection.
Smart Images

Figure CN119599876A_ABST
Abstract
Description
Technical Field
[0001] The invention relates to the technical field of electronic tender documents, and in particular to an electronic tender document tamper-proof method based on an improved DCT algorithm. Background Art
[0002] In the context of digital transformation, electronic bidding and tendering (e-tendering) has become a common method used in government procurement, large corporate procurement, and international projects. The use of electronic tenders simplifies the bidding process, improves efficiency, reduces human errors, and helps enhance transparency and fairness. However, like any technical solution, the electronic tender system also faces security challenges, one of the most serious problems of which is the tampering of electronic tenders.
[0003] Electronic bid tampering can be carried out by insiders or external hackers, and its purpose is usually to illegally gain competitive advantage or commit economic fraud. Attackers may try to change bid prices, company information, technical specifications or other key data to make a specific bidder appear more attractive or directly exclude other competitors. This behavior not only violates the law, but also undermines the fair competition environment in the market and harms the interests of all participants.
[0004] This patent aims to prevent the collected electronic bids from being tampered with during procurement compliance analysis and review. Many electronic bidding platforms have adopted advanced security measures, such as blockchain, encryption technology, access control and audit tracking. Despite these protective measures, the security of electronic bids remains an ongoing challenge, because these technologies have a common problem that they are not hidden enough and can be easily identified and cracked by criminals. Therefore, for all organizations and individuals participating in procurement compliance reviews, there is an urgent need for an undetectable anti-tampering method. To this end, this application proposes an electronic bid anti-tampering method based on an improved DCT algorithm to solve the above problem. Summary of the invention
[0005] 1. Technical issues to be solved
[0006] In view of the deficiencies in the prior art, the present invention provides an electronic tender document anti-tampering method based on an improved DCT algorithm, which solves the technical problems raised in the above background, such as tender document information being easily tampered by lawless elements and security measures not being concealed enough.
[0007] (II) Technical solution
[0008] To achieve the above objectives, the technical solution adopted by the present invention is: an electronic tender document tamper-proof method based on an improved DCT algorithm, the method comprising the following steps:
[0009] Step S1: extract multiple images containing the main information of the tender document, numbering them 1 to n in sequence;
[0010] Step S2: The main information images of the tender document are sequentially scrambled and encrypted using the Arnold transform algorithm, and the scrambled images are embedded into the original images of the tender document;
[0011] Step S3: Generate a DCT algorithm image tampering location model;
[0012] Step S4: using the DCT algorithm geometric distribution probability formula of S3 to evaluate the impact of other influencing factors on modification detection;
[0013] Step S5: Calculate the probability of different DCT algorithm blocks being tampered with, and locate the tampered area of the tender document image data through comparative analysis.
[0014] Step S6: Use the DCT algorithm to convert the picture embedded with the encrypted image in blocks, then obtain the embedded data by referring to the embedding coefficients, and splice the signals to obtain a scrambled image containing the main information of the bid. Whether the original bid image can be obtained through Arnold transformation of the image is used to perform a secondary identification to determine whether it has been tampered with.
[0015] Preferably, the processing of the main information image of the tender document specifically includes:
[0016] (1): Before embedding the carrier image containing the main information of the tender document, this algorithm first uses a reasonable Arnold scrambling period, denoted as T, to perform T / 2 cat face transformations on the watermark image containing the main information of the tender document. This preprocessing method improves the confidentiality of the watermark. The transformed watermark data is denoted as M'.
[0017] (2): Decompose the carrier image S containing the main information of the bid into 8×8 blocks. The pixel size of the carrier image is P×Q, and it is decomposed into (P / 8)×(Q / 8) blocks in total, denoted as BS(x, y);
[0018] (3): Then the watermark image M' (pixel size M×N) after Arnold transformation is also decomposed into (P / 8)×(Q / 8) blocks of (8M / P)×(8N / Q) size, denoted as BM(x, y);
[0019] (4): The DCT algorithm is used to transform the bid carrier image into blocks in sequence, denoted as DBS(x, y))'=DCT(BS(x, y)). The DCT transformation algorithm coefficient F of all the pixel points inside the bid carrier block must be calculated using formulas 3.1 and 3.2, where: 0≤u, v<8, a(v)=a(u), and an 8×8 DCT transformation algorithm coefficient matrix is obtained.
[0020] (5): Select the embedding strength as P, and select two points X and Y with similar positions in the coefficient matrix as the coefficient change points. When the embedded data is 1, add the value of point X to the value of P, and change the value of the other point Y to 0; when the embedded data is 0, add the value of point Y to the value of P, and change the value of the other point X to 0.
[0021]
[0022] It is worth noting that the input data g(x, y) in (4) is a square data matrix with a side length of 8. After a series of calculations, the result is still an 8×8 data matrix, denoted as G(u, v). The coordinates of the point (0, 0) in the result matrix are marked as G(0, 0). Because when u and v of this point are both 0, the result of the cosine function calculation is also 0, so the DC coefficient is the coordinate value of this point, and the AC coefficient is the coordinate value of the remaining points. The calculation result is the product of the input matrix and a(u)×a(v)×1 / 4, that is, one eighth. Because YUV has three data inputs, a total of three discrete cosine transform algorithms need to be performed.
[0023] Preferably, the carrier image containing the main information of the bid document needs to be in JPEG format.
[0024] Preferably, the probability distribution of the DCT algorithm calculation coefficient probability tampering model of the tender document carrier image in step S3 is expressed as formula 3-1:
[0025] P{X=x}=β1P1+β2P2,x∈Z
[0026] Formula 3-1
[0027] β1 represents the percentage of the image area that has been modified, and β2 represents the percentage of the image area that has not been modified. The sum of the two is 1. P1 and P2 are the probability distributions of the first quantization DCT transform algorithm coefficients and the second quantization DCT transform algorithm coefficients, respectively, as shown in formulas 3-2 and 3-3:
[0028]
[0029] The Laplacian distribution model parameters corresponding to the tampered area and the non-tampered area are denoted by λ0 and λ1; the quantization step sizes of the first quantization and the second quantization are denoted by S1 and S2; the unquantized DCT transform algorithm coefficient value is denoted by x0.
[0030] Preferably, in step S4, a graph cut algorithm should be used to minimize the forensic energy function.
[0031] Preferably, the use of a graph cut algorithm to minimize the forensic energy function includes: first, extracting discrete cosine transform algorithm coefficients on different discrete cosine transform algorithm blocks in the same frequency domain to construct a graph structure; then, using the graph cut algorithm to solve the minimum cut of the graph to achieve minimization of the forensic energy function and obtain a preliminary positioning result of the tampered area; finally, averaging the positioning results corresponding to the first N lowest-frequency discrete cosine transform algorithm coefficients in a discrete cosine transform algorithm block to obtain the probability that the discrete cosine transform algorithm block has been tampered with, and performing thresholding processing on it to obtain the final positioning result of the tampered area.
[0032] Preferably, the probability model of calculating the discrete cosine transform algorithm coefficients being tampered with in step S5 can be expressed by formula 4-1:
[0033]
[0034] where y i Indicates whether the i-th discrete cosine transform algorithm block has been tampered with, x i is the value of the discrete cosine transform algorithm coefficient at a certain frequency in the ith discrete cosine transform algorithm block, P(x) is the probability that the discrete cosine transform algorithm coefficient at the corresponding frequency in the ith discrete cosine transform algorithm block is x after a quantization, P(x i ) is the probability that the discrete cosine transform algorithm coefficient at the corresponding frequency in the ith discrete cosine transform algorithm block takes the value x after two quantizations.
[0035] Preferably, S5 specifically comprises the following two steps:
[0036] Step S5.1: defining a forensic energy function based on the probability distribution of the block discrete cosine transform algorithm coefficients of a certain DCT transform algorithm of the image to be tested and the prior knowledge of the tampered area;
[0037] Step S5.2: Minimize the forensic energy function to obtain a final positioning result of the tampered area in the image to be tested.
[0038] (III) Beneficial effects
[0039] The beneficial effects of the present invention are:
[0040] This electronic tender document anti-tampering method based on the improved DCT algorithm assists in locating the image tampering area through the coefficients of the improved DCT algorithm. By using the method proposed in the present invention, the information in the electronic tender document can be made tamper-proof and fair to prevent counterfeiting, and reliable electronic tender document data embedded with highly concealed anti-tampering security measures can be obtained, which is convenient for judging whether the bidding data can be used as a reliable detection basis in procurement compliance detection, thereby improving supervision and reducing costs. When a dispute occurs, evidence and tracing also become clearer and easier, solving the problem of tampering of tender document data. BRIEF DESCRIPTION OF THE DRAWINGS
[0041] Figure 1 The image group of important information of the tender document extracted by the present invention;
[0042] Figure 2 A picture group used as a watermark after Arnold transformation in the present invention;
[0043] Figure 3 It is a complete flow chart of the electronic tender document tamper-proof method based on the improved DCT algorithm of the present invention;
[0044] Figure 4 is a schematic diagram of a tamper detection algorithm of the present invention;
[0045] Figure 5 This is an example diagram of the result of locating the tampered area of the image to be tested using the method of the present invention;
[0046] Figure 6 It is a non-tampered watermark extraction map of the image group of the present invention;
[0047] Figure 7 This is the watermark image extracted from the image group that has been tampered with by the present invention. DETAILED DESCRIPTION
[0048] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0049] like Figure 1-7 As shown, the present invention provides a technical solution: an electronic tender document anti-tampering method based on an improved DCT algorithm, the method comprising the following steps:
[0050] Step S1: extract multiple images containing the main information of the tender document, numbering them 1 to n in sequence;
[0051] Step S2: The main information images of the tender document are sequentially scrambled and encrypted using the Arnold transform algorithm, and the scrambled images are embedded into the original images of the tender document;
[0052] Step S3: Generate a DCT algorithm image tampering location model;
[0053] Step S4: using the DCT algorithm geometric distribution probability formula of S3 to evaluate the impact of other influencing factors on modification detection;
[0054] Step S5: Calculate the probability of different DCT algorithm blocks being tampered with, and locate the tampered area of the tender document image data through comparative analysis.
[0055] Step S6: Use the DCT algorithm to convert the picture embedded with the encrypted image in blocks, then obtain the embedded data by referring to the embedding coefficients, and splice the signals to obtain a scrambled image containing the main information of the bid. Whether the original bid image can be obtained through Arnold transformation of the image is used to perform a secondary identification to determine whether it has been tampered with.
[0056] The processing of the main information images of the tender documents specifically includes:
[0057] (1): Before embedding the carrier image containing the main information of the tender document, this algorithm first uses a reasonable Arnold scrambling period, denoted as T, to perform T / 2 cat face transformations on the watermark image containing the main information of the tender document. This preprocessing method improves the confidentiality of the watermark. The transformed watermark data is denoted as M'.
[0058] (2): Decompose the carrier image S containing the main information of the bid into 8×8 blocks. The pixel size of the carrier image is P×Q, and it is decomposed into (P / 8)×(Q / 8) blocks in total, denoted as BS(x, y);
[0059] (3): Then the watermark image M' (pixel size M×N) after Arnold transformation is also decomposed into (P / 8)×(Q / 8) blocks of (8M / P)×(8N / Q) size, denoted as BM(x, y);
[0060] (4): The DCT algorithm is used to transform the bid carrier image into blocks in sequence, denoted as DBS(x, y))'=DCT(BS(x, y)). The DCT transformation algorithm coefficient F of all the pixel points inside the bid carrier block must be calculated using formulas 3.1 and 3.2, where: 0≤u, v<8, a(v)=a(u), and an 8×8 DCT transformation algorithm coefficient matrix is obtained.
[0061] (5): Select the embedding strength as P, and select two points X and Y with similar positions in the coefficient matrix as the coefficient change points. When the embedded data is 1, add the value of point X to the value of P, and change the value of the other point Y to 0; when the embedded data is 0, add the value of point Y to the value of P, and change the value of the other point X to 0.
[0062]
[0063] It is worth noting that the input data g(x, y) in (4) is a square data matrix with a side length of 8. After a series of calculations, the result is still an 8×8 data matrix, denoted as G(u, v). The coordinates of the point (0, 0) in the result matrix are marked as G(0, 0). Because when u and v of this point are both 0, the result of the cosine function calculation is also 0, so the DC coefficient is the coordinate value of this point, and the AC coefficient is the coordinate value of the remaining points. The calculation result is the product of the input matrix and a(u)×a(v)×1 / 4, that is, one eighth. Because YUV has three data inputs, a total of three discrete cosine transform algorithms need to be performed.
[0064] The carrier image containing the main information of the tender document must be in JPEG format;
[0065] The probability distribution of the DCT algorithm calculation coefficient probability tampering model of the tender document carrier image in step S3 is expressed as formula 3-1:
[0066] P{X=x}=β1P1+β2P2,x∈Z
[0067] Formula 3-1
[0068] β1 represents the percentage of the image area that has been modified, and β2 represents the percentage of the image area that has not been modified. The sum of the two is 1. P1 and P2 are the probability distributions of the first quantization DCT transform algorithm coefficients and the second quantization DCT transform algorithm coefficients, respectively, as shown in formulas 3-2 and 3-3:
[0069]
[0070] The Laplacian distribution model parameters corresponding to the tampered area and the non-tampered area are denoted by λ0 and λ1; the quantization step sizes of the first quantization and the second quantization are denoted by S1 and S2; the unquantized DCT transform algorithm coefficient value is denoted by x0;
[0071] In step S4, the forensic energy function should be minimized using a graph cut algorithm;
[0072] Minimizing the forensic energy function by using the graph cut algorithm includes: first, extracting discrete cosine transform algorithm coefficients on different discrete cosine transform algorithm blocks in the same frequency domain to construct a graph structure; then, using the graph cut algorithm to solve the minimum cut of the graph, realizing the minimization of the forensic energy function, and obtaining a preliminary positioning result of the tampered area; finally, averaging the positioning results corresponding to the first N lowest-frequency discrete cosine transform algorithm coefficients in a discrete cosine transform algorithm block to obtain the probability that the discrete cosine transform algorithm block has been tampered with, and thresholding it to obtain the final positioning result of the tampered area;
[0073] The probability model of calculating the discrete cosine transform algorithm coefficients being tampered with in step S5 can be expressed by formula 4-1:
[0074]
[0075] where y i Indicates whether the i-th discrete cosine transform algorithm block has been tampered with, x i is the value of the discrete cosine transform algorithm coefficient at a certain frequency in the ith discrete cosine transform algorithm block, P(x) is the probability that the discrete cosine transform algorithm coefficient at the corresponding frequency in the ith discrete cosine transform algorithm block is x after a quantization, P(x i ) is the probability that the discrete cosine transform algorithm coefficient at the corresponding frequency in the ith discrete cosine transform algorithm block takes the value x after two quantizations;
[0076] Step S5 specifically includes the following two steps:
[0077] Step S5.1: defining a forensic energy function based on the probability distribution of the block discrete cosine transform algorithm coefficients of a certain DCT transform algorithm of the image to be tested and the prior knowledge of the tampered area;
[0078] Step S5.2: Minimize the forensic energy function to obtain a final positioning result of the tampered area in the image to be tested.
[0079] In the description of the present invention, it is necessary to understand that the indicated orientation or positional relationship is based on the orientation or positional relationship shown in the accompanying drawings, and is only for the convenience of describing the present invention and simplifying the description, rather than indicating or implying that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore cannot be understood as a limitation on the present invention.
[0080] In the present invention, unless otherwise clearly stipulated and limited, for example, it can be a fixed connection, a detachable connection, or an integrated one; it can be a mechanical connection or an electrical connection; it can be directly connected or indirectly connected through an intermediate medium, it can be the internal connection of two elements or the interaction relationship between two elements. Unless otherwise clearly defined, for ordinary technicians in this field, the specific meanings of the above terms in the present invention can be understood according to the specific circumstances.
[0081] Although embodiments of the present invention have been shown and described, it will be appreciated by those skilled in the art that various changes, modifications, substitutions and variations may be made to the embodiments without departing from the principles and spirit of the present invention, and that the scope of the present invention is defined by the appended claims and their equivalents.
Claims
1. An electronic tender document anti-tampering method based on an improved DCT algorithm, characterized in that: The method comprises the following steps: Step S1: extract multiple images containing the main information of the tender document, numbering them 1 to n in sequence; Step S2: The main information images of the tender document are sequentially scrambled and encrypted using the Arnold transform algorithm, and the scrambled images are embedded into the original images of the tender document; Step S3: Generate a DCT algorithm image tampering location model; Step S4: using the DCT algorithm geometric distribution probability formula of S3 to evaluate the impact of other influencing factors on modification detection; Step S5: Calculate the probability of different DCT algorithm blocks being tampered with, and locate the tampered area of the tender image data through comparative analysis; Step S6: Use the DCT algorithm to convert the picture embedded with the encrypted image in blocks, then obtain the embedded data by referring to the embedding coefficients, and splice the signals to obtain a scrambled image containing the main information of the bid. Whether the original bid image can be obtained through Arnold transformation of the image is used to perform a secondary identification to determine whether it has been tampered with.
2. According to claim 1, the electronic tender document anti-tampering method based on the improved DCT algorithm is characterized in that: The processing of the main information image of the tender document specifically includes: (1): Before embedding the carrier image containing the main information of the tender document, this algorithm first uses a reasonable Arnold scrambling period, denoted as T, to perform T / 2 cat face transformations on the watermark image containing the main information of the tender document. This preprocessing method improves the confidentiality of the watermark. The transformed watermark data is denoted as M'; (2): Decompose the carrier image S containing the main information of the bid into 8×8 blocks. The pixel size of the carrier image is P×Q, and it is decomposed into (P / 8)×(Q / 8) blocks in total, denoted as BS(x, y); (3): Then the watermark image M' (pixel size M×N) after Arnold transformation is also decomposed into (P / 8)×(Q / 8) blocks of (8M / P)×(8N / Q) size, denoted as BM(x, y); (4): The bid carrier image is transformed into blocks by DCT algorithm, recorded as DBS(x, y))'=DCT(BS(x, y)), and all the pixels inside the bid carrier block are required to calculate their DCT transformation algorithm coefficients F through formulas 3.1 and 3.2, where: 0≤u, v<8, a(v)=a(u), and an 8×8 DCT transformation algorithm coefficient matrix is obtained; (5): Select the embedding strength as P, and select two points X and Y with similar positions in the coefficient matrix as the coefficient change points. When the embedded data is 1, add the value of point X to the value of P, and change the value of the other point Y to 0; when the embedded data is 0, add the value of point Y to the value of P, and change the value of the other point X to 0. It is worth noting that the input data g(x, y) in (4) is a square data matrix with a side length of 8. After a series of calculations, the result is still an 8×8 data matrix, denoted as G(u, v). The coordinates of the point (0, 0) in the result matrix are marked as G(0, 0). Because when u and v of this point are both 0, the result of the cosine function calculation is also 0, so the DC coefficient is the coordinate value of this point, and the AC coefficient is the coordinate value of the remaining points. The calculation result is the product of the input matrix and a(u)×a(v)×1 / 4, that is, one eighth. Because YUV has three data inputs, a total of three discrete cosine transform algorithms need to be performed.
3. The electronic tender document anti-tampering method based on the improved DCT algorithm according to claim 1 is characterized in that: The carrier image containing the main information of the tender document must be in JPEG format.
4. The electronic tender document anti-tampering method based on the improved DCT algorithm according to claim 1 is characterized in that: The probability distribution of the DCT algorithm calculation coefficient probability tampering model of the tender document carrier image in step S3 is expressed as formula 3-1: P{X=x}=β1P1+β2P2,x∈Z Formula 3-1 β1 represents the percentage of the image area that has been modified, and β2 represents the percentage of the image area that has not been modified. The sum of the two is 1. P1 and P2 are the probability distributions of the first quantization DCT transform algorithm coefficients and the second quantization DCT transform algorithm coefficients, respectively, as shown in formulas 3-2 and 3-3: The Laplacian distribution model parameters corresponding to the tampered area and the non-tampered area are denoted by λ0 and λ1; the quantization step sizes of the first quantization and the second quantization are denoted by S1 and S2; the unquantized DCT transform algorithm coefficient value is denoted by x0.
5. The electronic tender document tamper-proof method based on the improved DCT algorithm according to claim 1 is characterized in that: In step S4, the forensic energy function should be minimized using a graph cut algorithm.
6. The electronic tender document anti-tampering method based on the improved DCT algorithm according to claim 1 is characterized in that: The method of minimizing the forensic energy function by using a graph cut algorithm includes: first, extracting discrete cosine transform algorithm coefficients on different discrete cosine transform algorithm blocks in the same frequency domain to construct a graph structure; then, using a graph cut algorithm to solve the minimum cut of the graph to achieve minimization of the forensic energy function and obtain a preliminary positioning result of the tampered area; finally, averaging the positioning results corresponding to the first N lowest-frequency discrete cosine transform algorithm coefficients in a discrete cosine transform algorithm block to obtain the probability that the discrete cosine transform algorithm block has been tampered with, and performing thresholding processing on it to obtain a final positioning result of the tampered area.
7. The electronic tender document tamper-proof method based on the improved DCT algorithm according to claim 1 is characterized in that: The probability model of calculating the discrete cosine transform algorithm coefficients being tampered with in step S5 can be expressed by formula 4-1: where y i Indicates whether the i-th discrete cosine transform algorithm block has been tampered with, x i is the value of the discrete cosine transform algorithm coefficient at a certain frequency in the ith discrete cosine transform algorithm block, P(x) is the probability that the discrete cosine transform algorithm coefficient at the corresponding frequency in the ith discrete cosine transform algorithm block is x after a quantization, P(x i ) is the probability that the discrete cosine transform algorithm coefficient at the corresponding frequency in the ith discrete cosine transform algorithm block takes the value x after two quantizations.
8. The electronic tender document tamper-proof method based on the improved DCT algorithm according to claim 1 is characterized in that: The step S5 specifically comprises the following two steps: Step S5.1: defining a forensic energy function based on the probability distribution of the block discrete cosine transform algorithm coefficients of a certain DCT transform algorithm of the image to be tested and the prior knowledge of the tampered area; Step S5.2: Minimize the forensic energy function to obtain a final positioning result of the tampered area in the image to be tested.