Methods, equipment and media for generating and verifying anti-counterfeiting electronic vouchers
Patent Information
- Application Number
- CN202610807569.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-06-05
- Publication Date
- 2026-08-18
AI Technical Summary
[0003]本发明提供一种防伪电子凭证生成和验证方法、设备及介质,以解决如何提高电子凭证生成可靠性的技术问题
[0007] Fourthly, a computer-readable storage medium is provided, which stores a computer program that, when executed by a processor, implements the steps of the above-described method for generating anti-counterfeiting electronic certificates.
Smart Images

Figure CN122597147A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of image processing technology, applicable to fintech and medical technology scenarios, and particularly to a method, device, and medium for generating and verifying anti-counterfeiting electronic vouchers. Background Technology
[0002] Traditional methods for generating anti-counterfeiting electronic certificates typically employ physical visual anti-counterfeiting measures such as printing watermarks, adding embossed seals, or applying fluorescent ink. For example, in financial settings, when bank branches issue asset certificates to customers, they generate electronic asset certificates by applying fluorescent ink to pre-printed blank documents and printing a QR code on the certificate. This QR code encodes the asset certificate information (such as customer ID and deposit slip number). During verification, the asset certificate information obtained by scanning the QR code is compared with the content printed on the certificate. In healthcare settings, when medical institutions issue prescriptions, they use special paper with fluorescent anti-counterfeiting fibers and print anti-counterfeiting patterns with fluorescent ink to create anti-counterfeiting prescriptions. An anti-counterfeiting QR code is printed on the prescription, encodeing prescription information (such as drug name, dosage, and patient information). Scanning the QR code verifies whether the prescription was issued by a legitimate institution. However, the visual anti-counterfeiting elements relied upon by this method, such as watermarks, embossed seals, and fluorescent inks, have fixed physical texture characteristics. With the widespread use of high-precision printing equipment, they can be accurately counterfeited, making it difficult for business personnel to distinguish between genuine and counterfeit products. Furthermore, with the development of artificial intelligence image processing technology, image editing software can tamper with the information on electronic vouchers at the pixel level, making it difficult to detect with the naked eye. The digital encoding of QR codes in traditional methods can only prove the existence of electronic vouchers, but cannot prove that the physical paper of the electronic voucher is the original carrier at the time of issuance, resulting in poor reliability of electronic voucher generation. Therefore, how to improve the reliability of electronic voucher generation has become an urgent problem to be solved. Summary of the Invention
[0003] This invention provides a method, device, and medium for generating and verifying anti-counterfeiting electronic vouchers, in order to solve the technical problem of how to improve the reliability of electronic voucher generation.
[0004] Firstly, a method for generating anti-counterfeiting electronic certificates is provided, including: In response to a voucher issuance request, the system obtains the target electronic voucher information and a target paper image for carrying the target business voucher information. Fiber features are extracted from the target paper image to obtain target paper fiber parameter features; wherein, the target paper fiber parameter features are used to characterize the physical identity features of the target paper image; The target electronic voucher information is encrypted to obtain encrypted voucher information; The anti-counterfeiting area of the paper is obtained by performing anti-counterfeiting identification on the target paper image; The watermark embedding strength is determined based on the target paper fiber parameter characteristics and the target electronic voucher information, and the encrypted voucher information is embedded into the paper anti-counterfeiting area according to the watermark embedding strength to obtain the target voucher watermark; Based on the target paper fiber parameter characteristics and the target voucher watermark, a target anti-counterfeiting electronic voucher is generated.
[0005] Secondly, a method for verifying anti-counterfeiting electronic credentials is provided, including: In response to an electronic credential verification request, the current electronic credential is obtained, and the current paper image used to carry the current electronic credential is also obtained; Feature extraction is performed on the current paper image to obtain the current paper fiber parameter features; wherein, the current paper fiber parameter features are used to characterize the physical identity features of the current paper image; Obtain the current voucher watermark of the current electronic voucher, and restore the current voucher watermark to obtain the restored electronic voucher information; The current electronic voucher is verified based on the current paper fiber parameter characteristics, the target paper fiber parameter characteristics, the restored electronic voucher information, and the target electronic voucher information to obtain electronic voucher verification data; wherein, the electronic voucher verification data is used to characterize whether the current electronic voucher is consistent with or inconsistent with the target anti-counterfeiting electronic voucher; wherein, the target paper fiber parameter characteristics, the target electronic voucher information, and the target anti-counterfeiting electronic voucher are obtained by the above-described anti-counterfeiting electronic voucher generation method.
[0006] Thirdly, a computer device is provided, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the steps of the above-described method for generating anti-counterfeiting electronic certificates.
[0007] Fourthly, a computer-readable storage medium is provided, which stores a computer program that, when executed by a processor, implements the steps of the above-described method for generating anti-counterfeiting electronic certificates.
[0008] In the above-mentioned scheme for generating and verifying anti-counterfeiting electronic vouchers, the target electronic voucher information can be obtained in response to a voucher issuance request, and a target paper image for carrying the target business voucher information can be acquired simultaneously. Fiber features are extracted from the target paper image to obtain target paper fiber parameter features that characterize the physical identity of the target paper. The target electronic voucher information is encrypted to obtain encrypted voucher information, and the target paper image is subjected to anti-counterfeiting identification to obtain the paper anti-counterfeiting area. Then, the watermark embedding strength is dynamically determined according to the target paper fiber parameter features and the target electronic voucher information. The encrypted voucher information is embedded into the paper anti-counterfeiting area according to the embedding strength to obtain the target voucher watermark. The target anti-counterfeiting electronic voucher is generated according to the target paper fiber parameter features and the target voucher watermark. In this application, the natural fiber parameter characteristics of the target paper are extracted as the paper's physical identity identifier. The watermark embedding strength is determined based on the paper fiber parameter characteristics and electronic certificate information. The encrypted certificate information is embedded into the paper's anti-counterfeiting area in a way that associates the paper's physical properties with the paper's properties. This makes it impossible for counterfeiters to replicate the paper's micro-fiber structure or maintain the coupling relationship between the watermark and the paper's fiber characteristics after tampering with the certificate information. This effectively avoids the shortcomings of traditional visual anti-counterfeiting elements being easily imitated and QR codes only verifying the existence of the business but not the paper carrier. It significantly improves the anti-counterfeiting and anti-tampering capabilities of electronic certificates, thereby enhancing the reliability of electronic certificate generation. Attached Figure Description
[0009] To more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings used in the description of the embodiments of the present invention will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0010] Figure 1 This is a flowchart illustrating a method for generating anti-counterfeiting electronic certificates according to an embodiment of the present invention; Figure 2 yes Figure 1 A schematic diagram of a specific implementation method for step S102; Figure 3 yes Figure 1 A schematic diagram of a specific implementation of step S105; Figure 4 yes Figure 3 A flowchart illustrating a specific implementation of step S303; Figure 5 This is a flowchart illustrating an anti-counterfeiting electronic certificate verification method according to an embodiment of the present invention; Figure 6 yes Figure 5A schematic diagram of a specific implementation method for step S503; Figure 7 yes Figure 5 A schematic diagram of a specific implementation of step S504; Figure 8 yes Figure 7 A schematic diagram of a specific implementation of step S701; Figure 9 This is a schematic diagram of the structure of a computer device according to an embodiment of the present invention; Figure 10 This is another structural schematic diagram of a computer device according to one embodiment of the present invention. Detailed Implementation
[0011] This application provides a method, device, and medium for generating and verifying anti-counterfeiting electronic vouchers, aiming to solve the technical problem of how to improve the reliability of electronic voucher generation.
[0012] The anti-counterfeiting electronic certificate generation and verification method, device and medium provided in the embodiments of this application are specifically described through the following embodiments. First, the anti-counterfeiting electronic certificate generation method in the embodiments of this application is described.
[0013] The method for generating anti-counterfeiting electronic certificates provided in this application relates to the field of image processing technology. This method can be applied to a terminal, a server, or software running on either a terminal or a server. In some embodiments, the terminal can be a smartphone, tablet, laptop, desktop computer, etc.; the server can be configured as an independent physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server providing basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, CDN, and big data and artificial intelligence platforms; the software can be an application implementing the anti-counterfeiting electronic certificate generation method, but is not limited to the above forms.
[0014] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0015] like Figure 1 As shown, Figure 1A flowchart illustrating the method for generating anti-counterfeiting electronic certificates provided in this embodiment of the invention may include, but is not limited to, steps S101 to S106: Step S101: In response to the voucher issuance request, obtain the target electronic voucher information and obtain the target paper image used to carry the target business voucher information.
[0016] Step S102: Extract fiber features from the target paper image to obtain the target paper fiber parameter features; wherein, the target paper fiber parameter features are used to characterize the physical identity features of the target paper image.
[0017] Step S103: Encrypt the target electronic voucher information to obtain encrypted voucher information.
[0018] Step S104: Perform anti-counterfeiting recognition on the target paper image to obtain the anti-counterfeiting area of the paper.
[0019] Step S105: Determine the watermark embedding strength based on the target paper fiber parameter characteristics and the target electronic voucher information, and embed the encrypted voucher information into the paper anti-counterfeiting area according to the watermark embedding strength to obtain the target voucher watermark.
[0020] Step S106: Generate the target anti-counterfeiting electronic certificate based on the target paper fiber parameter characteristics and the target certificate watermark.
[0021] Steps S101 to S106 as shown in the embodiments of this application involve: responding to a voucher issuance request, acquiring target electronic voucher information and simultaneously acquiring a target paper image for carrying the target business voucher information; extracting fiber features from the target paper image to obtain target paper fiber parameter features that characterize the physical identity of the target paper; encrypting the target electronic voucher information to obtain encrypted voucher information; performing anti-counterfeiting identification on the target paper image to obtain the paper anti-counterfeiting area; dynamically determining the watermark embedding strength based on the target paper fiber parameter features and the target electronic voucher information; embedding the encrypted voucher information into the paper anti-counterfeiting area according to the embedding strength to obtain the target voucher watermark; and generating a target anti-counterfeiting electronic voucher based on the target paper fiber parameter features and the target voucher watermark. In this application, the natural fiber parameter characteristics of the target paper are extracted as the paper's physical identity identifier. The watermark embedding strength is determined based on the paper fiber parameter characteristics and electronic certificate information. The encrypted certificate information is embedded into the paper's anti-counterfeiting area in a way that associates the paper's physical properties with the paper's properties. This makes it impossible for counterfeiters to replicate the paper's micro-fiber structure or maintain the coupling relationship between the watermark and the paper's fiber characteristics after tampering with the certificate information. This effectively avoids the shortcomings of traditional visual anti-counterfeiting elements being easily imitated and QR codes only verifying the existence of the business but not the paper carrier. It significantly improves the anti-counterfeiting and anti-tampering capabilities of electronic certificates, thereby enhancing the reliability of electronic certificate generation.
[0022] In step S101 of some embodiments, specifically, the voucher issuance request refers to the instruction issued by the business system when it needs to generate an electronic voucher, which is used to trigger the anti-counterfeiting electronic voucher generation process.
[0023] Specifically, the target electronic voucher information refers to the business data contained in the voucher to be issued.
[0024] For example, in financial scenarios, the target electronic voucher information can be the customer's name, account number, asset amount, deposit certificate number, etc. on the asset certificate; in medical scenarios, the target electronic voucher information can be the patient's name, drug name, dosage, prescribing physician, etc. on the medical prescription.
[0025] Specifically, the target paper image refers to the original image of the physical paper used to carry the aforementioned electronic voucher information. Specifically, the target paper image can be captured by a camera at the moment of issuing an electronic voucher, in order to obtain a paper image of the microstructure of the target paper surface.
[0026] For example, in financial settings, when a bank teller issues an electronic certificate of assets to a customer, they can simultaneously take a picture of the paper on the certificate using the camera built into the branch printer; in medical settings, when a medical institution prints a prescription, it can take a picture of the prescription using a camera.
[0027] Specifically, in response to a voucher issuance request, the system can extract the electronic voucher information to be issued from the preset business database and determine it as the target electronic voucher information. At the same time, it controls the camera to capture the paper image of the blank paper to be used and associates and stores the captured paper image with the target electronic voucher information.
[0028] In this embodiment, in response to a voucher issuance request, the target electronic voucher information is obtained, and the target paper image used to carry the target business voucher information is also obtained. This allows for the subsequent deep binding of the electronic voucher information with the physical properties of the paper, avoiding the security risks caused by the independence of business information and paper carrier in traditional methods.
[0029] like Figure 2 As shown, in some embodiments, step S102 includes, but is not limited to, steps S201 to S205: Step S201: Extract the fiber mesh from the target paper image to obtain a paper fiber mesh image.
[0030] Step S202: Detect interlacing points in the paper fiber mesh image to obtain the coordinates of the fiber interlacing points.
[0031] Step S203: Detect fiber gaps in the paper fiber grid image to obtain fiber gap data.
[0032] Step S204: Perform fiber optic detection on the paper fiber mesh image to obtain fiber optic data.
[0033] Step S205: Based on the fiber interlacing point coordinates, fiber gap data and fiber optical data, the fiber parameter characteristics of the target paper are obtained by integrating them.
[0034] In step S201 of some embodiments, specifically, the paper fiber mesh image refers to network-like image data that presents the direction, intersection, and distribution of paper fibers.
[0035] Specifically, the target paper image can be preprocessed, such as by denoising and contrast enhancement, to obtain a preprocessed image. Then, an edge detection operator (such as the Canny operator) can be used to perform convolution operations on the preprocessed image to extract pixels with drastic grayscale changes. These pixels are then connected to form continuous fiber lines, ultimately outputting a binary fiber mesh image.
[0036] In step S202 of some embodiments, specifically, the fiber interlacing point coordinates refer to the pixel coordinate positions of the fiber intersection points in the image.
[0037] Specifically, each pixel in the paper fiber mesh image can be traversed. For each foreground pixel (i.e. fiber), the connectivity in the fiber neighborhood is analyzed, and the number of adjacent fiber branches is counted. When the number of branches is greater than or equal to three, the pixel is determined as a candidate intersection point. Non-maximum suppression processing is performed on all candidate intersection points to remove duplicate and neighboring redundant points, thus obtaining the target intersection point. The pixel position of the target intersection point in the paper fiber mesh image is determined as the coordinate of the fiber interlacing point.
[0038] In this embodiment, fiber interlacing points are natural features generated by the random overlapping of fibers during the paper forming process. Their distribution is completely random and unique and cannot be artificially replicated. As one of the core identity identifiers of paper, even if the paper is partially damaged, the distribution of interlacing points in the remaining area can still provide sufficient feature information for paper identification.
[0039] In step S203 of some embodiments, specifically, fiber void data refers to quantitative parameters describing the blank areas surrounded by fibers in the fiber mesh. The fiber void data includes the area, perimeter, shape, and statistical values of the void ratio.
[0040] Specifically, a region connectivity analysis is performed on the paper fiber mesh image. The background pixels (i.e., non-fiber regions) are divided into several connected regions. For each connected region, its area (i.e., number of pixels), the size of the bounding rectangle, the perimeter of the outline, and the circularity and other geometric parameters are calculated. The areas of all connected regions are statistically analyzed to calculate the mean, standard deviation, maximum and minimum values, forming gap data.
[0041] For example, in a financial context, the paper fiber mesh image of an asset certificate is analyzed to identify all closed or semi-closed void areas formed by interwoven fibers. The area of each void and the proportion of the total area of all voids to the image area are calculated to obtain fiber void data.
[0042] In this embodiment, fiber porosity data reflects the density of paper and the density of fiber distribution. Paper from different sources and batches has measurable differences in porosity, which can enhance the uniqueness of the physical feature vector of paper from the spatial distribution dimension.
[0043] In step S204 of some embodiments, specifically, fiber optical data refers to quantitative values describing the reflective properties of paper fibers, including local grayscale values, reflectivity, texture contrast, etc. of the fiber region.
[0044] Specifically, based on the position mask of the fiber grid in the paper fiber grid image, the region where the fiber pixel is located can be selected, and the average gray value, gray variance, texture contrast, and other parameters of the region can be calculated. After normalizing these parameters, fiber optical data can be formed.
[0045] In this embodiment, the optical properties of paper fibers are affected by factors such as fiber material, surface coating, and processing technology. They are relatively stable and difficult to imitate. Incorporating the optical data of this fiber into the target paper fiber parameter features can further enhance the dimension of the physical identity features of the paper, making the distinction between different papers more significant. At the same time, the optical data has a certain tolerance for slight wear on the paper and will not fluctuate drastically due to minor surface changes.
[0046] In step S205 of some embodiments, specifically, the target paper fiber parameter features refer to the vector representation of fiber interlacing point coordinates, fiber gap data, and fiber optical data.
[0047] Specifically, the coordinates of fiber interlacing points can be converted into fixed-dimensional fiber interlacing point vectors using a coordinate histogram. The average void area and void ratio in the fiber void data are then concatenated to obtain the fiber void vector. The average gray value and gray variance in the fiber optical data are concatenated to obtain the fiber optical vector. Finally, the fiber interlacing point vector, fiber void vector, and fiber optical vector are concatenated to obtain the fiber parameter characteristics of the target paper.
[0048] For example, in financial scenarios, the interlacing point coordinates, fiber gap data, and fiber optical data of asset certificate paper can be combined into a target paper fiber parameter feature with a dimension of 512.
[0049] Through steps S201 to S205, by extracting fiber mesh, detecting interlacing points, detecting gaps, and optical detection, the natural physical characteristics of paper fibers in three dimensions—topological structure, spatial distribution, and optical properties—can be transformed into high-dimensional feature vectors, constructing a unique and unreplicable physical identity for the paper. Even if the paper has local wear or stains, it can still be effectively identified based on the remaining area, providing a reliable data foundation for the generation of anti-counterfeiting electronic certificates and fundamentally ensuring the credibility and practicality of the generated anti-counterfeiting electronic certificates.
[0050] In step S103 of some embodiments, specifically, the encrypted credential information refers to the hash value obtained after hashing the target electronic credential information.
[0051] For example, in financial scenarios, sensitive information such as asset amount and customer ID in asset certificates can be encrypted using a hash algorithm to generate an asset certificate hash value, which corresponds one-to-one with the asset amount, customer ID, and other information. In medical scenarios, the drug name, dosage, patient information, and other content on medical prescriptions can be encrypted to generate encrypted credential information, ensuring that the prescription content cannot be directly read or tampered with after being embedded in the paper without being detected.
[0052] Specifically, key fields in the target electronic voucher information can be obtained, and a preset encryption algorithm (such as SHA-256) can be used to calculate the key fields to generate a fixed-length hash value, which is the encrypted voucher information.
[0053] In this embodiment, by encrypting the target electronic voucher information, readable electronic voucher information can be converted into ciphertext, making the electronic voucher information embedded in paper impossible to read directly. Furthermore, any tampering with the original electronic voucher information will lead to a drastic change in the encryption result, which helps to ensure the reliability of the anti-counterfeiting electronic voucher generation.
[0054] In step S104 of some embodiments, specifically, the paper anti-counterfeiting area refers to a specific paper space location used to carry encrypted certificate information. The paper anti-counterfeiting area is usually a location with sufficient space, such as the background texture of the paper, blank areas, or the edge of the seal, which does not affect the reading of the main content of the electronic certificate.
[0055] Specifically, the target paper image can be segmented to obtain paper image blocks. By analyzing the texture, color distribution, and content layout of the paper image blocks, the background area that is distinguishable from the main content (such as text and seals) in the target electronic voucher information can be identified to form the paper anti-counterfeiting area.
[0056] In this embodiment, by performing anti-counterfeiting identification on the target paper image, the anti-counterfeiting area of the paper is obtained, and the area suitable for embedding the watermark can be determined to ensure that the encrypted certificate information can be integrated into the paper background in a concealed manner, which not only does not affect the normal reading and use of the electronic certificate, but also provides a reliable physical carrier for the stable existence of the watermark.
[0057] In step S105 of some embodiments, the watermark embedding strength is determined based on the target paper fiber parameter characteristics and the target electronic voucher information.
[0058] Specifically, watermark embedding strength refers to the ink dot density or micro-dot energy parameter used when converting encrypted credential information into a physical dot matrix.
[0059] For example, in financial scenarios, the size or distribution density of the ink dots in the watermark matrix can be dynamically adjusted based on the fiber density characteristics of the asset certificate paper and the size of the asset certificate data, so as to embed the encrypted information of the asset certificate data into the background of the seal edge in the form of a dot matrix; in medical scenarios, the watermark embedding strength of the prescription paper can be determined based on the fiber interlacing point distribution of the prescription paper and the complexity of the prescription content, and the encrypted prescription information can be embedded into the anti-counterfeiting background of the prescription paper.
[0060] like Figure 3 As shown, in some embodiments, step S105 may include, but is not limited to, steps S301 to S303: Step S301: Convert the encrypted credential information into a sequence of credential geometric coordinates on a preset two-dimensional plane.
[0061] Step S302: Convert the geometric coordinate sequence of the voucher into a preset micro-dot matrix driving signal for the printing device based on the watermark embedding strength.
[0062] Step S303: Drive the printing device according to the micro-dot matrix driving signal to embed the geometric coordinate sequence of the voucher into the anti-counterfeiting area of the paper to obtain the target voucher watermark.
[0063] In step S301 of some embodiments, specifically, the credential geometric coordinate sequence refers to converting the encrypted credential information into a set of coordinate points on a two-dimensional plane, where each coordinate point is composed of x-axis and y-axis values, and the set of coordinate points is arranged in order to form a coordinate sequence.
[0064] Specifically, the encrypted credential information (i.e., the hash value string) can be divided into multiple segments according to the preset slice length. Each segment's hash value string is converted into a decimal integer, and the integer is converted into the horizontal and vertical coordinates of a coordinate point on a preset two-dimensional plane. All coordinate points are arranged in the order of generation to form a sequence of geometric coordinates of the credential.
[0065] In step S302 of some embodiments, specifically, the micro-dot matrix drive signal refers to the geometric coordinate sequence converted into an instruction signal that the printing device can recognize. This signal is used to instruct the printing device to print at a specified position with a specific dot size or energy level.
[0066] Specifically, the ink dot diameter, dot density, or energy level of the micro-dot matrix can be determined based on the watermark embedding intensity. Then, each coordinate point in the geometric coordinate sequence of the voucher is traversed, and the position information of each coordinate point is converted into the position in the coordinate system of the printing device. The printing parameters of each point (such as ink droplet volume, exposure energy, etc.) are generated by combining the watermark embedding intensity. The printing parameters of all points are then summarized to form a complete micro-dot matrix driving signal.
[0067] like Figure 4 As shown, in some embodiments, step S303 includes, but is not limited to, steps S401 to S404: Step S401: Analyze the micro-dot matrix driving signal to obtain ink dot position parameters and ink dot attribute parameters; wherein, the ink dot position parameters are determined by the document coordinate points in the document geometric coordinate sequence; the ink dot attribute parameters include ink dot diameter and ink dot ink volume.
[0068] Step S402: Obtain the embedding position of the voucher in the anti-counterfeiting area of the paper based on the ink dot position parameters.
[0069] Step S403: Based on the ink dot diameter and ink volume, form the target ink dot at the voucher embedding position.
[0070] Step S404: Drive the printing device to embed the geometric coordinate sequence of the voucher into the anti-counterfeiting area of the paper according to the target ink dots to obtain the target voucher watermark.
[0071] In step S401 of some embodiments, specifically, the ink dot position parameter refers to the coordinate data parsed from the micro-dot matrix driving signal used to determine the specific landing position of each ink dot in the anti-counterfeiting area of the paper.
[0072] Specifically, ink dot attribute parameters refer to the set of parameters that control the physical shape of each ink dot, including ink dot diameter and ink volume. The ink dot diameter determines the size of the circular area covered by the ink dot on the target paper, and the ink volume determines the volume of ink droplets or the amount of toner used for that ink dot.
[0073] Specifically, by decoding the micro-dot matrix driving signal, the data segment corresponding to each ink dot in the micro-dot matrix driving signal is separated, and the horizontal coordinate, vertical coordinate, ink dot diameter value and ink volume value of the ink dot are read from it.
[0074] In step S402 of some embodiments, specifically, the credential embedding position refers to the specific landing position of each ink dot determined after mapping the coordinate values represented by the ink dot position parameters to the physical space of the actual paper anti-counterfeiting area.
[0075] Specifically, the coordinate values of each ink dot position parameter can be obtained, and combined with the preset physical position reference point of the anti-counterfeiting area on the paper (such as the coordinates of the upper left corner of the anti-counterfeiting area), the coordinate values are superimposed on the reference point. At the same time, the resolution of the printing device and the coordinate system transformation relationship are taken into account to calculate the absolute physical position of each ink dot on the paper, forming a voucher embedding position list.
[0076] For example, in a financial scenario, the point (100, 200) in the coordinate sequence of the asset certificate can be mapped to a specific location in the background area on the right side of the seal, 10 mm from the top edge of the paper and 50 mm from the left edge.
[0077] In step S403 of some embodiments, specifically, a target ink dot refers to a specific ink dot entity formed on the paper according to ink dot attribute parameters, and each target ink dot has a defined diameter and ink volume.
[0078] For example, in a medical setting, the diameter of the target ink dot (e.g., 15 micrometers) and the amount of ink (e.g., a single ink droplet) form a circular ink dot of the corresponding size at the embedding position on the medical prescription paper, and all the ink dots together constitute a watermark pattern.
[0079] Specifically, the ink droplet diameter and ink volume parameters can be transmitted to the controller of the printing equipment. The controller can then adjust the printhead's ejection orifice control or the size of the laser exposure point based on the ink droplet diameter parameter, and adjust the ink droplet volume or exposure energy based on the ink volume parameter. This allows the ejection or exposure action to be performed at the designated document embedding location, enabling the ink droplet material to precisely adhere to the paper surface and form a target ink droplet with a specified physical shape.
[0080] In step S404 of some embodiments, specifically, the target credential watermark refers to the complete micro-matrix pattern formed by the distribution of all target ink dots according to the geometric coordinate sequence of the credential in the anti-counterfeiting area of the paper. This pattern exists on the paper surface in a microscopic form and carries encrypted credential information.
[0081] For example, in a financial setting, all target ink dots are distributed in the background area at the edge of the seal according to the geometric coordinate sequence of the asset certificate, forming a complete micro-dot matrix watermark that is integrated with the asset certificate paper.
[0082] Specifically, all coordinate points in the geometric coordinate sequence of the voucher can be traversed, and the above-mentioned voucher embedding position recognition and ink dot formation operations can be performed sequentially to ensure that the target ink dot corresponding to each coordinate point is accurately embedded in the corresponding position of the anti-counterfeiting area of the paper. When the target ink dots corresponding to all coordinate points are embedded, a complete target voucher watermark is formed on the paper, and the target voucher watermark, together with the voucher information, seals and other contents on the paper, constitute the final anti-counterfeiting electronic voucher.
[0083] Through steps S401 to S404, the encrypted certificate information can be transformed into a precisely controllable physical ink dot array. The ink dot diameter and ink volume are dynamically adjustable attribute parameters, deeply coupled with the target paper fiber parameter characteristics and electronic certificate information, making the physical form of each ink dot unique. Counterfeiters cannot imitate the watermark by simply copying the dot array position, because even if the coordinate position is copied, the ink dot diameter and ink volume parameters that match the original paper fiber characteristics cannot be restored, thereby effectively improving the anti-counterfeiting capability of the anti-counterfeiting electronic certificate.
[0084] Through steps S301 to S303, counterfeiters are effectively prevented from altering the voucher information without damaging the watermark, and from transferring the watermark completely to another sheet of paper. This effectively solves the problems of visual elements being easily imitated and QR codes being disconnected from paper carriers in traditional anti-counterfeiting technologies, providing robust anti-counterfeiting data support for the generation of anti-counterfeiting electronic vouchers.
[0085] like Figure 5 As shown, Figure 5 A flowchart illustrating the anti-counterfeiting electronic certificate verification method provided in this embodiment of the invention may include, but is not limited to, steps S501 to S504: Step S501: In response to the electronic voucher verification request, obtain the current electronic voucher and obtain the current paper image used to carry the current electronic voucher.
[0086] Step S502: Extract features from the current paper image to obtain the current paper fiber parameter features; wherein, the current paper fiber parameter features are used to characterize the physical identity features of the current paper image.
[0087] Step S503: Obtain the current voucher watermark of the current electronic voucher and restore the current voucher watermark to obtain the restored electronic voucher information.
[0088] Step S504: Verify the current electronic voucher based on the current paper fiber parameter characteristics, the target paper fiber parameter characteristics, the restored electronic voucher information, and the target electronic voucher information to obtain electronic voucher verification data; wherein, the electronic voucher verification data is used to characterize whether the current electronic voucher is consistent with or inconsistent with the target anti-counterfeiting electronic voucher; wherein, the target paper fiber parameter characteristics, the target electronic voucher information, and the target anti-counterfeiting electronic voucher are obtained by the anti-counterfeiting electronic voucher generation method.
[0089] Steps S501 to S504 as shown in the embodiments of this application involve responding to an electronic voucher verification request, acquiring the current electronic voucher and simultaneously acquiring the current paper image used to carry the current electronic voucher, extracting features from the current paper image to obtain the current paper fiber parameter features that characterize the physical identity of the current paper, acquiring the current voucher watermark of the current electronic voucher and restoring it to obtain the restored electronic voucher information, and then verifying the current electronic voucher based on the current paper fiber parameter features, the target paper fiber parameter features, the restored electronic voucher information, and the target electronic voucher information to obtain electronic voucher verification data. In this application, the authenticity of the original paper carrier is verified by comparing the natural fiber parameters of the paper as a physical identifier. At the same time, the integrity of the certificate content is verified by restoring the embedded certificate watermark and comparing it with the original business information. This makes it difficult for counterfeiters to replicate the micro-fiber structure of the paper through physical verification, and also makes it difficult for them to maintain the consistency between the watermark and the original information through certificate content verification after tampering with the certificate information. This effectively avoids the shortcomings of traditional verification methods, such as the easy imitation of visual anti-counterfeiting elements and the fact that QR codes can only verify the existence of business but not the paper carrier. It significantly improves the accuracy and reliability of electronic certificate verification and provides a solid verification guarantee for the security of anti-counterfeiting electronic certificates.
[0090] In step S501 of some embodiments, specifically, the electronic certificate verification request refers to an instruction used to verify the authenticity of the issued target anti-counterfeiting electronic certificate.
[0091] Specifically, the current electronic certificate refers to the anti-counterfeiting electronic certificate to be verified, including electronic certificate information, seal, and embedded current certificate watermark.
[0092] Specifically, the current paper image refers to the microscopic image of the physical paper used to carry the current electronic voucher, which is used to extract the current paper fiber parameter features for paper physical identity comparison.
[0093] For example, in financial scenarios, when reviewing the current asset proof documents submitted by customers, a microscopic image of a region on the current asset proof document can be captured by the camera of the bank's verification terminal, and an electronic image or scanned copy of the current asset proof document can be obtained as the current electronic document; in medical scenarios, when verifying medical prescriptions, a microscopic image of the medical prescription document can be captured by the camera, and an overall image of the medical prescription document can be obtained as the current electronic document for the medical prescription.
[0094] In this embodiment, by responding to the electronic certificate verification request, the current electronic certificate is obtained, and the current paper image used to carry the current electronic certificate is also obtained, providing complete original data support for subsequent anti-counterfeiting electronic certificate verification, so as to ensure that the electronic certificate verification process can be cross-verified simultaneously from two dimensions: physical carrier and image digital content.
[0095] In step S502 of some embodiments, specifically, the current paper fiber parameter feature refers to the fiber feature vector extracted from the currently acquired paper microscopic image. The current paper fiber parameter feature is used to characterize the physical identity features of the current paper image and is compared with the target paper fiber parameter feature stored at the time of issuance to verify whether the current paper is the original.
[0096] Specifically, the current method for extracting paper fiber parameter features is consistent with the generation stage of anti-counterfeiting electronic certificates, including multiple sub-steps such as paper fiber grid extraction, fiber interlacing point detection, fiber gap detection, and fiber optical detection.
[0097] Specifically, the method for extracting features from the current paper image to obtain the current paper fiber parameter features is the same as the method for extracting fiber features from the target paper image to obtain the target paper fiber parameter features, and will not be elaborated here.
[0098] In this embodiment, by extracting features from the current paper image, the current paper fiber parameter features are obtained, which ensures that the extracted paper fiber parameter features are comparable to the target paper fiber parameter features when the electronic voucher is issued, thus effectively ensuring the reliability of the anti-counterfeiting electronic voucher verification.
[0099] like Figure 6 As shown, in some embodiments, step S503 includes, but is not limited to, steps S601 to S604: Step S601: Extract the fine dot matrix from the current voucher watermark to obtain the current fine dot matrix.
[0100] Step S602: Reconstruct the geometric coordinate sequence of the current micro-lattice to obtain the current geometric coordinate sequence.
[0101] Step S603: Convert the current geometric coordinate sequence into the current encrypted credential information.
[0102] Step S604: Decrypt the current encrypted information to obtain the restored electronic certificate information.
[0103] In step S601 of some embodiments, specifically, the current voucher watermark refers to a fine dot matrix pattern embedded in the anti-counterfeiting area of the current electronic voucher paper, which exists in a microscopic form on the surface of the current paper.
[0104] Specifically, the current micro-dot matrix refers to a binary image or set of dot matrix coordinates containing dot matrix information, which corresponds to the micro-dot matrix embedded when the anti-counterfeiting electronic certificate is generated.
[0105] Specifically, a Fast Fourier Transform (FFT) can be performed on the current paper image containing the current voucher watermark area to convert the current paper image from the spatial domain to the frequency domain. In the frequency domain, a bandpass filter is designed to filter out low-frequency components representing complex backgrounds and extremely high-frequency components representing noise, while retaining mid-to-high-frequency components representing fine dot matrix. Then, an Inverse Fourier Transform (IFT) is used to convert the filtered frequency domain signal back to the spatial domain, resulting in an image where the background is significantly suppressed and the dot matrix signal is enhanced. The image is then binarized to divide each dot matrix region into independent foreground pixel blocks, forming the current fine dot matrix.
[0106] In step S602 of some embodiments, specifically, the current geometric coordinate sequence refers to the list of coordinate points obtained after restoration, and this sequence should be consistent with the geometric coordinate sequence of the voucher embedded when the anti-counterfeiting electronic voucher is generated in terms of both value and order.
[0107] Specifically, the connected component labeling can be performed on the current fine dot matrix image, each foreground pixel block in the image can be traversed, the centroid coordinates of each pixel block can be calculated as the precise position of the ink dot, after removing noise points that are too small or too large, the coordinates of all valid ink dots can be sorted according to the sorting rules preset at the time of issuance (such as sorting in ascending order by the ink dot horizontal coordinate as the primary key and the vertical coordinate as the secondary key) to form the current geometric coordinate sequence.
[0108] For example, in a financial scenario, approximately 200 ink dots can be identified from the current fine dot matrix of the asset certificate, the centroid coordinates of each ink dot can be calculated, and the coordinates can be arranged in a coordinate list from left to right and from top to bottom to obtain the current geometric coordinate sequence.
[0109] In step S603 of some embodiments, specifically, the current encrypted certificate information refers to the encrypted data obtained by reverse transformation of the geometric coordinate sequence according to the mapping rules used at the time of issuance. This data should correspond to the encrypted certificate information embedded when the anti-counterfeiting electronic certificate is generated.
[0110] Specifically, the mapping rule parameters used when generating the anti-counterfeiting electronic certificate can be obtained, including the preset width and height range of the two-dimensional plane and the mapping function from coordinates to values. For each coordinate point in the current geometric coordinate sequence, the horizontal and vertical coordinate values of the coordinate point are multiplied by the corresponding conversion coefficients and combined into an integer. Then, all integers are concatenated into a string in order to obtain the current encrypted certificate information.
[0111] For example, in a financial scenario, each point in the coordinate sequence of an asset certificate (such as X=100, Y=200) can be converted into the integer 65536, and the conversion results of all points can be concatenated into a complete hash value string.
[0112] In step S604 of some embodiments, specifically, restoring electronic certificate information refers to the electronic certificate information obtained after decryption.
[0113] For example, in financial scenarios, restoring electronic voucher information can include asset amount, customer ID, etc.; in medical scenarios, restoring electronic voucher information can include plain text prescription content such as drug name, dosage, and patient information on medical prescription slips.
[0114] Specifically, the decryption key and decryption logic corresponding to the encryption algorithm used when generating the anti-counterfeiting electronic certificate can be obtained. The decryption algorithm is then applied to the current encrypted certificate information to convert the ciphertext into plaintext, extract the key business fields, and form the restored electronic certificate information. If the encryption method uses a one-way mapping of a hash algorithm, the restored encrypted certificate information is directly compared with the target electronic certificate information without performing a reverse hash operation.
[0115] For example, in a financial scenario, the current encrypted credential information, i.e., the restored hash value, can be decrypted to obtain the asset amount of 100,000 yuan and the customer ID number; in a medical scenario, the encrypted information of a prescription can be decrypted to obtain prescription information such as amoxicillin and three times a day.
[0116] Through steps S601 to S604, the embedded micro-dot matrix is extracted from the paper background, solving the problem of difficulty in extracting the watermark from the background information such as the voucher information, seal, and background pattern when they are mixed in real-world scenarios. Furthermore, the physical dot matrix is converted into a structured coordinate sequence through geometric coordinate sequence restoration, realizing the transformation from physical form to digital representation. This coordinate sequence is then converted into encrypted voucher information, and the encrypted data is reverse-engineered according to the mapping rules consistent with those used when the anti-counterfeiting electronic voucher was generated. This ensures the accuracy and reversibility of the conversion process, allowing for the decryption process to obtain the restored electronic voucher information. This provides a basis for subsequent consistency verification of the electronic voucher, ensuring that the format of the target electronic voucher information is consistent with that used when the anti-counterfeiting electronic voucher was generated.
[0117] like Figure 7 As shown, in some embodiments, step S504 includes, but is not limited to, steps S701 to S703: Step S701: Perform paper fiber verification based on the current paper fiber parameter characteristics and the target paper fiber parameter characteristics to obtain paper fiber verification data.
[0118] Step S702: Verify the voucher based on the restored electronic voucher information and the target electronic voucher information to obtain voucher information verification data.
[0119] Step S703: Verify the current electronic voucher based on the paper fiber verification data, voucher information verification data, and the target anti-counterfeiting electronic voucher to obtain electronic voucher verification data.
[0120] like Figure 8 As shown, in some embodiments, step S701 includes, but is not limited to, steps S801 to S802: Step S801: Calculate the similarity between the current paper fiber parameter characteristics and the target paper fiber parameter characteristics to obtain the paper fiber similarity.
[0121] Step S802: Fiber parameter verification is performed based on paper fiber similarity and a preset similarity threshold to obtain sheet fiber verification data.
[0122] In step S801 of some embodiments, specifically, paper fiber similarity refers to the degree of similarity between the current paper fiber parameter features and the target paper fiber parameter features. The value is between 0 and 1, and the larger the value, the closer the fiber parameter features of the current paper and the target paper are.
[0123] Specifically, the dot product of the current paper fiber parameter features and the target paper fiber parameter features can be calculated using the cosine similarity algorithm. This involves multiplying the corresponding dimensional values and then summing them. Then, the modulus of the current paper fiber parameter features and the target paper fiber parameter features can be calculated separately, which is the square root of the sum of the squares of the values in each dimension. Finally, the dot product is divided by the product of the two modulus to obtain the paper fiber similarity.
[0124] In step S802 of some embodiments, specifically, the preset similarity threshold refers to a pre-set threshold used to determine whether the similarity of paper fibers meets the requirements for paper fibers to pass the verification. This threshold is usually set according to the actual application scenario, such as 0.85.
[0125] Specifically, paper fiber verification data refers to the data obtained by comparing the current paper fiber parameter characteristics with the target paper fiber parameter characteristics. This data is used to characterize whether the current paper and the target paper are consistent or inconsistent.
[0126] For example, in a financial scenario, if the paper fiber similarity is 0.92 and compared with the preset similarity threshold of 0.85, since 0.92 is greater than 0.85, the paper fiber parameter verification is deemed to have passed, indicating that the current paper and the target paper are consistent; if the paper fiber similarity is 0.67, which is less than the preset similarity threshold of 0.85, the paper fiber parameter verification is deemed to have failed, indicating that the current paper and the target paper are inconsistent.
[0127] Through steps S801 to S802, the natural physical characteristics of paper can be transformed into quantifiable similarity indicators, and combined with thresholds, paper physical identity verification can be achieved, fundamentally solving the problem that physical carriers are easily counterfeited in traditional anti-counterfeiting technologies.
[0128] In step S702 of some embodiments, specifically, the voucher information verification data refers to the comparison data between the restored electronic voucher information and the target electronic voucher information, which is used to characterize whether the restored electronic voucher information and the target electronic voucher information are consistent or inconsistent.
[0129] Specifically, the restored electronic voucher information and the target electronic voucher information can be compared field by field according to a preset field mapping relationship. This includes exact equality judgment for numeric fields and complete matching judgment for character fields. If all fields match, the electronic voucher information is deemed to have passed the verification, indicating that the restored electronic voucher information and the target electronic voucher information are consistent. If any field is different, the electronic voucher information is deemed to have failed the verification, indicating that the restored electronic voucher information and the target electronic voucher information are inconsistent.
[0130] For example, in a financial scenario, if the restored asset certificate amount of 100,000 yuan matches the target asset certificate amount of 100,000 yuan, and the restored customer ID matches the target customer ID, the electronic voucher information verification is deemed successful, indicating that the restored electronic voucher information and the target electronic voucher information are consistent. If the restored amount of 700,000 yuan does not match the target amount, the electronic voucher information verification is deemed unsuccessful, indicating that the restored electronic voucher information and the target electronic voucher information are inconsistent.
[0131] In this embodiment, by verifying the electronic voucher information based on the restored electronic voucher information and the target electronic voucher information, it is possible to effectively detect whether the content of the electronic voucher has been tampered with. Since the information in the watermark is deeply coupled with the paper fiber characteristics, any modification to the voucher content will destroy the integrity of the watermark or cause the restored information to be inconsistent with the original information, thus providing a reliable guarantee for anti-counterfeiting verification.
[0132] In step S703 of some embodiments, specifically, the electronic voucher verification data refers to the data used to compare the target anti-counterfeiting electronic voucher with the current electronic voucher. This electronic voucher verification data is used to characterize whether the current electronic voucher is consistent with or inconsistent with the target anti-counterfeiting electronic voucher.
[0133] For example, in a financial scenario, the paper fiber verification data and the voucher information verification data are combined for judgment. If both pass, the current asset certificate is determined to be consistent with the target anti-counterfeiting electronic voucher, and the current electronic voucher verification is confirmed to be successful. If either verification data fails, the current asset certificate is determined to be inconsistent with the target anti-counterfeiting electronic voucher, and the current electronic voucher verification is confirmed to be unsuccessful. The specific failure message can be "Paper mismatch" or "Voucher information tampered with".
[0134] Through steps S701 to S703, dual security protection for anti-counterfeiting electronic certificates is achieved. Paper fiber verification ensures that the paper carrier is the original, and electronic certificate information verification ensures that the certificate content has not been tampered with. The two are independent of each other and complementary to each other. Any anomaly in any single dimension will lead to the failure of electronic certificate verification, thereby effectively identifying various fraudulent behaviors such as counterfeit paper and tampering with certificate content, effectively improving the accuracy of anti-counterfeiting electronic certificate verification, and thus verifying the anti-counterfeiting reliability of the generated anti-counterfeiting electronic certificates.
[0135] As can be seen, in the above-mentioned anti-counterfeiting electronic certificate generation scheme, in response to the certificate issuance request, the target electronic certificate information is obtained and the target paper image used to carry the target business certificate information is collected simultaneously. The fiber features of the target paper image are extracted to obtain the target paper fiber parameter features that characterize the physical identity of the target paper. The target electronic certificate information is encrypted to obtain encrypted certificate information. The target paper image is then subjected to anti-counterfeiting identification to obtain the paper anti-counterfeiting area. The watermark embedding strength is dynamically determined according to the target paper fiber parameter features and the target electronic certificate information. The encrypted certificate information is embedded into the paper anti-counterfeiting area according to the embedding strength to obtain the target certificate watermark. The target anti-counterfeiting electronic certificate is generated according to the target paper fiber parameter features and the target certificate watermark. In this application, the natural fiber parameter characteristics of the target paper are extracted as the paper's physical identity identifier. The watermark embedding strength is determined based on the paper fiber parameter characteristics and electronic certificate information. The encrypted certificate information is embedded into the paper's anti-counterfeiting area in a way that associates the encrypted certificate information with the paper's physical properties. This makes it impossible for counterfeiters to replicate the paper's micro-fiber structure or maintain the coupling relationship between the watermark and the paper's fiber characteristics after tampering with the certificate information. This effectively avoids the shortcomings of traditional visual anti-counterfeiting elements, which are easily imitated, and QR codes, which only verify the existence of the business but cannot verify the paper carrier. It significantly improves the anti-counterfeiting and anti-tampering capabilities of electronic certificates, thereby improving the reliability of electronic certificate generation and verifying the anti-counterfeiting reliability of the generated anti-counterfeiting electronic certificates.
[0136] Furthermore, in the above-mentioned anti-counterfeiting electronic certificate verification scheme, in response to the electronic certificate verification request, the current electronic certificate is obtained and the current paper image used to carry the current electronic certificate is collected simultaneously. The current paper image is used to extract features to obtain the current paper fiber parameter features that characterize the physical identity of the current paper. The current certificate watermark of the current electronic certificate is obtained and restored to obtain the restored electronic certificate information. Then, the current electronic certificate is verified based on the current paper fiber parameter features, the target paper fiber parameter features, the restored electronic certificate information and the target electronic certificate information to obtain the electronic certificate verification data. In this application, the authenticity of the original paper carrier is verified by comparing the natural fiber parameters of the paper as a physical identifier. At the same time, the integrity of the certificate content is verified by restoring the embedded certificate watermark and comparing it with the original business information. This makes it difficult for counterfeiters to replicate the micro-fiber structure of the paper through physical verification, and also makes it difficult for them to maintain the consistency between the watermark and the original information through certificate content verification after tampering with the certificate information. This effectively avoids the shortcomings of traditional verification methods, such as the easy imitation of visual anti-counterfeiting elements and the fact that QR codes can only verify the existence of business but not the paper carrier. It significantly improves the accuracy and reliability of electronic certificate verification and provides a solid verification guarantee for the security of anti-counterfeiting electronic certificates.
[0137] It should be understood that the sequence number of each step in the above embodiments does not imply the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present invention.
[0138] In one embodiment, a computer device is provided, which may be a server, and its internal structure diagram may be as follows: Figure 9 As shown, the computer device includes a processor, memory, network interface, and database connected via a system bus. The processor provides computing and control capabilities. The memory includes non-volatile and / or volatile storage media and internal memory. The non-volatile storage media stores the operating system, computer programs, and database. The internal memory provides an environment for the operation of the operating system and computer programs stored in the non-volatile storage media. The network interface is used to communicate with external clients via a network connection. When the computer program is executed by the processor, it implements the functions or steps of a server-side method for generating anti-counterfeiting electronic certificates.
[0139] In one embodiment, a computer device is provided, which may be a client, and its internal structure diagram may be as follows: Figure 10As shown, the computer device includes a processor, memory, network interface, display screen, and input devices connected via a system bus. The processor provides computing and control capabilities. The memory includes a non-volatile storage medium and internal memory. The non-volatile storage medium stores the operating system and computer programs. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage medium. The network interface is used to communicate with an external server via a network connection. When the computer program is executed by the processor, it implements the functions or steps on the client side of a method for generating anti-counterfeiting electronic certificates. In one embodiment, a computer device is provided, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to perform the following steps: In response to a voucher issuance request, the system obtains the target electronic voucher information and the target paper image used to carry the target business voucher information. Fiber features are extracted from the target paper image to obtain the target paper fiber parameter features; the target paper fiber parameter features are used to characterize the physical identity features of the target paper image. The target electronic voucher information is encrypted to obtain encrypted voucher information; Anti-counterfeiting identification is performed on the target paper image to obtain the anti-counterfeiting area of the paper; The watermark embedding strength is determined based on the target paper fiber parameter characteristics and the target electronic voucher information. The encrypted voucher information is then embedded into the paper anti-counterfeiting area based on the watermark embedding strength to obtain the target voucher watermark. Based on the target paper fiber parameter characteristics and the target voucher watermark, generate the target anti-counterfeiting electronic voucher.
[0140] In one embodiment, a computer-readable storage medium is provided having a computer program stored thereon, the computer program performing the following steps when executed by a processor: In response to a voucher issuance request, the system obtains the target electronic voucher information and the target paper image used to carry the target business voucher information. Fiber features are extracted from the target paper image to obtain the target paper fiber parameter features; the target paper fiber parameter features are used to characterize the physical identity features of the target paper image. The target electronic voucher information is encrypted to obtain encrypted voucher information; Anti-counterfeiting identification is performed on the target paper image to obtain the anti-counterfeiting area of the paper; The watermark embedding strength is determined based on the target paper fiber parameter characteristics and the target electronic voucher information. The encrypted voucher information is then embedded into the paper anti-counterfeiting area based on the watermark embedding strength to obtain the target voucher watermark. Based on the target paper fiber parameter characteristics and the target voucher watermark, generate the target anti-counterfeiting electronic voucher.
[0141] It should be noted that the functions or steps that can be implemented by the computer-readable storage medium or computer device described above can be referred to the relevant descriptions on the server side and client side in the foregoing method embodiments. To avoid repetition, they will not be described one by one here.
[0142] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium. When executed, the computer program can include the processes of the embodiments of the above methods. Any references to memory, storage, databases, or other media used in the embodiments provided in this application can include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in a variety of forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), dual data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link DRAM (SLDRAM), RAMbus direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), etc.
[0143] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the above-described division of functional units and modules is used as an example. In practical applications, the above functions can be assigned to different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above.
[0144] It should be noted that any AI models, software tools, or components not belonging to this company appearing in the embodiments of this application are merely illustrative examples and do not represent actual use. All user personal information involved in the embodiments of this application has been authorized (with the knowledge and consent) by the relevant parties or has been fully authorized by all parties, and the executing entity may obtain it through various legal and compliant means. The collection, storage, use, processing, transmission, provision, and disclosure of the information, data, and signals involved all comply with relevant laws and regulations and do not violate public order and good morals.
[0145] The above-described embodiments are only used to illustrate the technical solutions of the present invention, and are not intended to limit it. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention, and should all be included within the protection scope of the present invention.
Claims
1. A method for generating anti-counterfeiting electronic vouchers, characterized in that, include: In response to a voucher issuance request, the system obtains the target electronic voucher information and a target paper image for carrying the target business voucher information. Fiber features are extracted from the target paper image to obtain target paper fiber parameter features; wherein, the target paper fiber parameter features are used to characterize the physical identity features of the target paper image; The target electronic voucher information is encrypted to obtain encrypted voucher information; The anti-counterfeiting area of the paper is obtained by performing anti-counterfeiting identification on the target paper image; The watermark embedding strength is determined based on the target paper fiber parameter characteristics and the target electronic voucher information, and the encrypted voucher information is embedded into the paper anti-counterfeiting area according to the watermark embedding strength to obtain the target voucher watermark; Based on the target paper fiber parameter characteristics and the target voucher watermark, a target anti-counterfeiting electronic voucher is generated.
2. The method as described in claim 1, characterized in that, The step of extracting features from the target paper image to obtain the target paper fiber parameter features includes: Fiber mesh extraction is performed on the target paper image to obtain a paper fiber mesh image; Interlacing point detection is performed on the paper fiber mesh image to obtain the coordinates of the fiber interlacing points; Fiber gap detection is performed on the paper fiber mesh image to obtain fiber gap data; Fiber optics detection is performed on the paper fiber mesh image to obtain fiber optic data; The fiber parameter characteristics of the target paper are obtained by integrating the coordinates of the fiber interlacing points, the fiber gap data, and the fiber optical data.
3. The method as described in claim 1, characterized in that, The step of embedding the encrypted certificate information into the paper anti-counterfeiting area according to the watermark embedding strength to obtain the target certificate watermark includes: The encrypted credential information is converted into a sequence of credential geometric coordinates on a preset two-dimensional plane; The geometric coordinate sequence of the voucher is converted into a preset micro-dot matrix driving signal for the printing device based on the watermark embedding strength. The printing device is driven by the micro-dot matrix driving signal to embed the geometric coordinate sequence of the voucher into the anti-counterfeiting area of the paper, thereby obtaining the target voucher watermark.
4. The method as described in claim 3, characterized in that, The step of driving the printing device to embed the geometric coordinate sequence of the voucher into the anti-counterfeiting area of the paper according to the micro-dot matrix driving signal to obtain the target voucher watermark includes: The micro-dot matrix driving signal is analyzed to obtain ink dot position parameters and ink dot attribute parameters; wherein, the ink dot position parameters are determined by the document coordinate points in the document geometric coordinate sequence; the ink dot attribute parameters include ink dot diameter and ink dot ink volume; The document embedding position in the paper's anti-counterfeiting area is obtained based on the ink dot position parameters; Based on the diameter and amount of ink droplet, a target ink droplet is formed at the voucher embedding position; The printing device is driven by the target ink dots to embed the geometric coordinate sequence of the voucher into the anti-counterfeiting area of the paper, thereby obtaining the target voucher watermark.
5. A method for verifying anti-counterfeiting electronic certificates, characterized in that, include: In response to an electronic credential verification request, the current electronic credential is obtained, and the current paper image used to carry the current electronic credential is also obtained; Feature extraction is performed on the current paper image to obtain the current paper fiber parameter features; wherein, the current paper fiber parameter features are used to characterize the physical identity features of the current paper image; Obtain the current voucher watermark of the current electronic voucher, and restore the current voucher watermark to obtain the restored electronic voucher information; The current electronic voucher is verified based on the current paper fiber parameter characteristics, the target paper fiber parameter characteristics, the restored electronic voucher information, and the target electronic voucher information to obtain electronic voucher verification data; wherein, the electronic voucher verification data is used to characterize whether the current electronic voucher is consistent with or inconsistent with the target anti-counterfeiting electronic voucher; wherein, the target paper fiber parameter characteristics, the target electronic voucher information, and the target anti-counterfeiting electronic voucher are obtained by the anti-counterfeiting electronic voucher generation method according to any one of claims 1 to 4.
6. The method as described in claim 5, characterized in that, The process of restoring the current voucher watermark to obtain restored electronic voucher information includes: The current voucher watermark is subjected to fine dot matrix extraction to obtain the current fine dot matrix; The geometric coordinate sequence of the current micro-lattice is restored to obtain the current geometric coordinate sequence; Convert the current geometric coordinate sequence into the current encrypted credential information; The currently encrypted information is decrypted to obtain the restored electronic certificate information.
7. The method as described in claim 5, characterized in that, The step of verifying the current electronic voucher based on the current paper fiber parameter characteristics, the target paper fiber parameter characteristics, the restored electronic voucher information, and the target electronic voucher information to obtain electronic voucher verification data includes: Paper fiber verification is performed based on the current paper fiber parameter characteristics and the target paper fiber parameter characteristics to obtain paper fiber verification data. Based on the restored electronic voucher information and the target electronic voucher information, voucher verification is performed to obtain voucher information verification data; The current electronic voucher is verified based on the paper fiber verification data, the voucher information verification data, and the target anti-counterfeiting electronic voucher to obtain the electronic voucher verification data.
8. The method as described in claim 7, characterized in that, The step of verifying paper fibers based on the current paper fiber parameter characteristics and the target paper fiber parameter characteristics to obtain paper fiber verification data includes: The similarity is calculated based on the current paper fiber parameter features and the target paper fiber parameter features to obtain the paper fiber similarity. The fiber parameters are verified based on the paper fiber similarity and a preset similarity threshold to obtain the paper fiber verification data.
9. A computer device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the computer program, it implements the steps of the anti-counterfeiting electronic certificate generation method as described in any one of claims 1 to 4 and the anti-counterfeiting electronic certificate verification method as described in any one of claims 5 to 8.
10. A computer-readable storage medium storing a computer program, characterized in that, When the computer program is executed by the processor, it implements the steps of the anti-counterfeiting electronic certificate generation method as described in any one of claims 1 to 4 and the anti-counterfeiting electronic certificate verification method as described in any one of claims 5 to 8.