CN111612476A - Secondary check anti-counterfeiting method, device, equipment and storage medium - Google Patents

Secondary check anti-counterfeiting method, device, equipment and storage medium Download PDF

Info

Publication number
CN111612476A
CN111612476A CN202010387690.6A CN202010387690A CN111612476A CN 111612476 A CN111612476 A CN 111612476A CN 202010387690 A CN202010387690 A CN 202010387690A CN 111612476 A CN111612476 A CN 111612476A
Authority
CN
China
Prior art keywords
counterfeiting
code
value
code value
dimensional code
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202010387690.6A
Other languages
Chinese (zh)
Other versions
CN111612476B (en
Inventor
张志强
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Asyun Anti Counterfeiting Technology Fujian Co ltd
Original Assignee
Asyun Anti Counterfeiting Technology Fujian Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Asyun Anti Counterfeiting Technology Fujian Co ltd filed Critical Asyun Anti Counterfeiting Technology Fujian Co ltd
Priority to CN202010387690.6A priority Critical patent/CN111612476B/en
Publication of CN111612476A publication Critical patent/CN111612476A/en
Application granted granted Critical
Publication of CN111612476B publication Critical patent/CN111612476B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q30/00Commerce
    • G06Q30/018Certifying business or products
    • G06Q30/0185Product, service or business identity fraud
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06KGRAPHICAL DATA READING; PRESENTATION OF DATA; RECORD CARRIERS; HANDLING RECORD CARRIERS
    • G06K17/00Methods or arrangements for effecting co-operative working between equipments covered by two or more of main groups G06K1/00 - G06K15/00, e.g. automatic card files incorporating conveying and reading operations
    • G06K17/0022Methods or arrangements for effecting co-operative working between equipments covered by two or more of main groups G06K1/00 - G06K15/00, e.g. automatic card files incorporating conveying and reading operations arrangements or provisious for transferring data to distant stations, e.g. from a sensing device
    • G06K17/0025Methods or arrangements for effecting co-operative working between equipments covered by two or more of main groups G06K1/00 - G06K15/00, e.g. automatic card files incorporating conveying and reading operations arrangements or provisious for transferring data to distant stations, e.g. from a sensing device the arrangement consisting of a wireless interrogation device in combination with a device for optically marking the record carrier
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06KGRAPHICAL DATA READING; PRESENTATION OF DATA; RECORD CARRIERS; HANDLING RECORD CARRIERS
    • G06K7/00Methods or arrangements for sensing record carriers, e.g. for reading patterns
    • G06K7/10Methods or arrangements for sensing record carriers, e.g. for reading patterns by electromagnetic radiation, e.g. optical sensing; by corpuscular radiation
    • G06K7/14Methods or arrangements for sensing record carriers, e.g. for reading patterns by electromagnetic radiation, e.g. optical sensing; by corpuscular radiation using light without selection of wavelength, e.g. sensing reflected white light
    • G06K7/1404Methods for optical code recognition
    • G06K7/1408Methods for optical code recognition the method being specifically adapted for the type of code
    • G06K7/14172D bar codes

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Business, Economics & Management (AREA)
  • Theoretical Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Accounting & Taxation (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Toxicology (AREA)
  • General Health & Medical Sciences (AREA)
  • Electromagnetism (AREA)
  • General Engineering & Computer Science (AREA)
  • Health & Medical Sciences (AREA)
  • Entrepreneurship & Innovation (AREA)
  • Artificial Intelligence (AREA)
  • Development Economics (AREA)
  • Economics (AREA)
  • Finance (AREA)
  • Marketing (AREA)
  • Strategic Management (AREA)
  • General Business, Economics & Management (AREA)
  • Storage Device Security (AREA)

Abstract

The invention discloses a secondary check anti-counterfeiting method, a device, equipment and a storage medium, wherein the method comprises two parts of a secondary check anti-counterfeiting code generation algorithm and an anti-counterfeiting check algorithm: the secondary verification anti-counterfeiting code generation algorithm is used for generating a secondary verification anti-counterfeiting two-dimensional code which is difficult to copy in batches for each commodity; the secondary verification anti-counterfeiting two-dimensional code comprises three elements, namely a code value, a two-dimensional code and an offset value, which are generated according to a specific algorithm; the anti-counterfeiting check algorithm checks the code value sent after the client scans the anti-counterfeiting two-dimensional code through secondary check. According to the technical scheme, the secondary verification anti-counterfeiting code which is difficult to copy and the anti-counterfeiting verification algorithm corresponding to the secondary verification anti-counterfeiting code are generated, so that the counterfeiting cost is greatly increased, and the anti-counterfeiting strength is enhanced; meanwhile, the security of the anti-counterfeiting check algorithm is improved, the anti-counterfeiting check algorithm is not easy to break, and the robustness of the anti-counterfeiting check algorithm is improved.

Description

Secondary check anti-counterfeiting method, device, equipment and storage medium
Technical Field
The invention relates to the field of information processing, in particular to a secondary verification anti-counterfeiting method, a secondary verification anti-counterfeiting device, secondary verification anti-counterfeiting equipment and a storage medium.
Background
At present, the anti-counterfeiting identification method for the commodity is usually realized by a user scanning an anti-counterfeiting two-dimensional code attached to the commodity through a mobile phone, wherein the anti-counterfeiting two-dimensional code comprises a group of anti-counterfeiting codes consisting of characters or numbers and a common two-dimensional code. The anti-counterfeiting working principle is that the back-end server compares the anti-counterfeiting codes sent after the mobile phone scans the codes to identify the authenticity of the commodities and sends a verification result to the mobile phone of the user.
However, the biggest problem of this method is that after the anti-counterfeiting code is revealed, batch copying can be realized at very low cost, so that the anti-counterfeiting defense means is limited; moreover, the checking algorithm is easy to be cracked by reverse derivation.
Disclosure of Invention
The embodiment of the invention provides a secondary verification anti-counterfeiting method, a secondary verification anti-counterfeiting device, equipment and a storage medium, and aims to solve the problems that the existing anti-counterfeiting codes are easy to copy in batches, and a verification algorithm is fragile.
A secondary check anti-counterfeiting method comprises a secondary check anti-counterfeiting code generation algorithm and an anti-counterfeiting check algorithm, wherein the secondary check anti-counterfeiting code generation algorithm comprises the following steps:
according to a preset code value generation algorithm, allocating a unique code value with a preset length for each commodity;
after encrypting and checking the code value, carrying out residue taking to obtain offset values corresponding to the code value one by one;
synthesizing the code value and a two-dimensional code picture generated by a preset two-dimensional code generation algorithm to obtain a two-dimensional code vector diagram;
embedding the offset value into a preset position in the two-dimensional code vector diagram;
positioning the corresponding position of the code value according to the offset value, and marking the corresponding position to obtain a secondary verification anti-counterfeiting two-dimensional code;
the anti-counterfeiting verification algorithm comprises the following steps:
searching the code value sent after the secondary verification anti-counterfeiting two-dimensional code is scanned by the client, if the code value exists, determining that the commodity is true, and if the code value does not exist, determining that the commodity is false;
encrypting the code value, performing checksum operation, and then taking the remainder to obtain a target offset value; and sending the target offset value to the client.
The utility model provides a secondary check-up anti-fake device, includes secondary check-up anti-fake code generation module and anti-fake check-up module, secondary check-up anti-fake code generation module includes:
the global unique code generation module is used for distributing a unique code value with a preset length to each commodity according to a preset code value generation algorithm;
the offset value generating module is used for encrypting the code value, checking and calculating, and then taking the rest to obtain the offset values corresponding to the code value one by one;
the two-dimensional code production module is used for synthesizing the code value and a two-dimensional code picture generated by a preset two-dimensional code generation algorithm to obtain a two-dimensional code vector diagram;
the synthesis module is used for embedding the deviation value into a preset position in the two-dimensional code vector diagram;
the offset value positioning image processing module is used for positioning the corresponding position of the code value according to the offset value and marking the corresponding position to obtain a secondary verification anti-counterfeiting two-dimensional code;
the anti-counterfeiting check module comprises:
the code value retrieval module is used for retrieving the code value sent after the secondary check anti-counterfeiting two-dimensional code is scanned by the client;
the first counterfeit identification module is used for determining that the commodity is false if the code value is not searched;
the second counterfeit identification module is used for encrypting, checking and operating the code value and then taking the remainder to obtain a target offset value if the code value is searched; and sending the target offset value to the client.
A computer device comprises a memory, a processor and a computer program which is stored in the memory and can run on the processor, wherein the processor executes the computer program to realize the secondary verification anti-counterfeiting method.
A computer-readable storage medium, which stores a computer program, which, when executed by a processor, implements the above-described double-check anti-counterfeiting method.
The secondary verification anti-counterfeiting method, the device, the equipment and the storage medium comprise two parts of generating a secondary verification anti-counterfeiting two-dimensional code different from a common two-dimensional code and verifying the secondary verification anti-counterfeiting two-dimensional code, wherein the two parts respectively correspond to a secondary verification anti-counterfeiting code generation algorithm and an anti-counterfeiting verification algorithm.
The secondary verification anti-counterfeiting code generation algorithm firstly distributes a code value with a preset length and only for each commodity through a preset code value generation algorithm; carrying out encryption, checksum operation and remainder operation in sequence on the basis of the code value to obtain an offset value corresponding to the code value; that is, the offset value is derived from the code value and corresponds to the id of the code value; in the verification process, the authenticity of the commodity can be determined only by verifying the code value and the deviant through the anti-counterfeiting verification algorithm, the anti-counterfeiting strength is increased, and the problem that the detection algorithm is fragile and easy to crack is solved. Meanwhile, the two-dimensional code vector graph contains code values which are clear at a glance and accord with the habit of identifying the fake by scanning the code by a user; more importantly, the offset value is embedded into a preset position of the two-dimensional code vector diagram, and a corresponding position of the code value positioned through the offset value is also marked to obtain a secondary verification anti-counterfeiting two-dimensional code, so that the secondary verification anti-counterfeiting two-dimensional code is different from a common two-dimensional code and has high identifiability; even if the code values are leaked, a counterfeiter cannot obtain the offset value corresponding to each code value, and the secondary verification anti-counterfeiting two-dimensional codes are difficult to copy in batches in production, so that the anti-counterfeiting strength is greatly improved.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings needed to be used in the description of the embodiments of the present invention will be briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and it is obvious for those skilled in the art that other drawings can be obtained according to these drawings without inventive labor.
FIG. 1 is a schematic diagram of an application environment of a secondary verification anti-counterfeiting method according to an embodiment of the present invention;
FIG. 2 is a flow chart of a secondary verification anti-counterfeit code generation algorithm in an embodiment of the present invention;
FIG. 3 is a schematic diagram of a secondary verification anti-counterfeit code according to an embodiment of the present invention;
FIG. 4 is a flow chart of an anti-counterfeit verification algorithm in one embodiment of the present invention;
FIG. 5 is a flowchart of a preset code value generation algorithm according to an embodiment of the present invention;
FIG. 6 is a flow chart of determining the authenticity of a product based on the number of searches in accordance with an embodiment of the present invention;
FIG. 7 is a schematic view of a secondary verification anti-counterfeiting device in an embodiment of the present invention;
FIG. 8 is a schematic diagram of a computer device in an embodiment of the invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are some, not all, embodiments of the present invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
The secondary verification anti-counterfeiting method provided by the invention can be applied to an application environment as shown in fig. 1, wherein the secondary verification anti-counterfeiting two-dimensional code can be attached to a sold commodity in a label form, so that a user can conveniently scan the code and identify the fake; the client is intelligent terminal equipment such as a mobile phone, a tablet personal computer and the like capable of performing code scanning operation; the server is a computer server or a server cluster used for generating the secondary verification anti-counterfeiting two-dimensional code and performing verification; the secondary verification anti-counterfeiting two-dimensional code and the server for verification can be the same physical host or independent hosts. The secondary verification anti-counterfeiting method provided by the embodiment of the invention is applied to a server.
In an embodiment, as shown in fig. 2, a secondary verification anti-counterfeiting code generation algorithm in a secondary verification anti-counterfeiting method is provided, and a specific implementation flow includes the following steps:
s1: and according to a preset code value generation algorithm, allocating a unique code value with a preset length to each commodity.
Code values are a set of strings of numbers or characters, or a combination of both, such as 201039c485960 a; the length of the bit can be flexibly determined according to the requirements of practical application, for example, 12-36 bits. The code value is used to uniquely identify each item. The preset code value generation algorithm is a code value generation method that can be flexibly selected according to actual needs, for example, a random numerical value of a server memory is used as a code value.
S2: and after the code values are encrypted and subjected to checksum operation, the offset values corresponding to the code values one to one are obtained by taking the remainder.
The offset value is a value derived from the code value, usually 0 to 9; the offset value is the re-identification of the code value, and in the verification process, the code value and the offset value need to be verified simultaneously to determine the authenticity of the commodity. Obtaining the offset value comprises three steps of encryption, checksum operation and remainder, wherein the code value is encrypted firstly, and the encryption can adopt various modes, such as an MD5 algorithm and the like; then, carrying out checksum operation on the encryption result, such as CRC (cyclic redundancy check) and the like, and converting the encryption result into a numerical value of a fixed bit number; and finally, carrying out remainder calculation on the numerical value of the fixed digit to obtain the offset value. For example, when 3456676 is obtained after the checksum operation, the bits are added to 37 and the remainder is taken to obtain an offset of 7.
S3: and synthesizing the code value and the two-dimensional code picture generated by a preset two-dimensional code generation algorithm to obtain a two-dimensional code vector diagram.
The preset two-dimensional code generation algorithm can be a two-dimensional code vector diagram generated after code values are input based on a two-dimensional code open source diagram library generation algorithm. The two-dimensional code vector map contains link information with code values, for example, https:// abc.com/test.php? id 1234567. Wherein, the '1234567' is the code value; and after the code is scanned by the user, the authenticity of the commodity can be verified by requesting the server through the link information. Meanwhile, the code value is placed below the two-dimensional code of the two-dimensional code vector diagram (as shown in fig. 3). It is understood that the code values can be placed on the upper side or both sides, and determined according to the actual typesetting requirements.
S4: and embedding the offset value into a preset position in the two-dimensional code vector diagram.
The preset position in the two-dimensional code vector diagram can be flexibly determined according to actual needs, and the conventional offset value can be placed at the center of the two-dimensional code area, so that the user can conveniently identify the two-dimensional code.
S5: and positioning the corresponding position of the code value according to the offset value, and marking the corresponding position to obtain the secondary verification anti-counterfeiting two-dimensional code.
Taking the offset value as 6 as an example, the corresponding position of the code value may be from the first bit to the 6 th bit on the right side of the code value; alternatively, the code value is ordered from the first bit to the 6 th bit on the left side. It is understood that the corresponding position can also be a position in the order or the inverse from any bit of the code value. Namely, the complexity of the check algorithm can be increased by multiple choices, and the robustness of the check algorithm is improved.
The marking processing refers to image processing of the two-dimensional code vector image, and marks corresponding positions of code values located by the offset values so as to achieve recognition. The marking processing mode is various and can be distinguished by adopting the differences of colors, fonts and the like. A typical double-check anti-counterfeit two-dimensional code is shown in fig. 3, in which the offset value is 6, and the "1" corresponding to the 6 th ordinal digit on the right side of the code value is marked in bold.
The secondary verification anti-counterfeiting code generation algorithm is used for generating a secondary verification anti-counterfeiting two-dimensional code which is difficult to copy in batches, and is different from a common two-dimensional code.
In the verification process, as shown in fig. 4, the anti-counterfeiting verification algorithm in the secondary verification anti-counterfeiting method specifically realizes a flow, and includes the following steps:
s6: and retrieving the code value sent after the secondary verification anti-counterfeiting two-dimensional code is scanned by the client.
The code value is attached to the link information of the secondary verification anti-counterfeiting two-dimensional code, when the client initiates a verification request to the server, the server analyzes the received information, retrieves the obtained code value, and the retrieval can occur in a local server or a server cluster.
S7: and if the code value is not detected to exist, determining that the commodity is false.
That is, if the server cannot retrieve the code value matching the code value transmitted by the client, the product is false.
S8: if the code value exists, encrypting the code value, performing checksum operation, and then taking the remainder to obtain a target offset value; and sends the target offset value to the client.
If the server retrieves the code value matching the code value sent by the client, the offset value of the code value needs to be further verified. Namely, the step of obtaining the offset value in the secondary check anti-counterfeiting code generation method is repeated, the code value is encrypted, subjected to checksum operation and subjected to residue taking to obtain a target offset value, and the target offset value is sent to the client. The user can check whether the target deviation value is consistent with the value embedded in the secondary verification anti-counterfeiting two-dimensional code or not and the mark bits different from other bits in the code value by himself to determine the authenticity of the commodity. As another implementation, the server may also directly send the result of matching the target offset value to the client.
The anti-counterfeiting verification algorithm is used for identifying authenticity of the commodity attached with the secondary verification anti-counterfeiting two-dimensional code, namely, the code value and the deviant are verified twice to ensure that the commodity to be verified is not a counterfeit product, and compared with a common verification algorithm, the anti-counterfeiting verification algorithm is higher in safety.
Further, in an embodiment, as shown in fig. 5, a specific implementation flow of the preset code value generation algorithm includes the following steps:
s11: a random number is generated based on the current timestamp.
The current time is the local time of the server, and specifically, the server can be used as an input seed at present and call a random function to generate a random number.
S12: and combining the random number with the unique identification of each distributed node of the back-end server and the preset user identification information to generate a code value.
Each distributed node of the back-end Server, that is, the back-end Server, is a distributed network composed of a plurality of servers, each node corresponds to one Server, and the Server ID of the node is the unique identifier in the distributed network, for example, Server 01.
The preset user identification information includes the name of the user, the commodity type, the generated batch and other related information, for example, clientA _ book _ 11.
Specifically, the random number, the unique identifier, and the preset user identifier information may be sequentially arranged, for example, the code value is Server01_ clientA _ book _11_ 18224795323; or, any bit character in the three is extracted for splicing, and the like.
In the embodiment, the code value is generated by combining the random number, the server identifier and the preset user information, so that the uniqueness of the code value is further ensured, and repeated collision is avoided.
Further, in an embodiment, the encrypting and checksum operation on the code value includes the steps of:
s21: and carrying out AES encryption on the code value, and carrying out CRC checksum operation on the encryption result according to bits.
AES encryption, i.e., advanced encryption standard, symmetric encryption algorithm; CRC is a cyclic redundancy check code.
In the embodiment, the offset value obtained from the code value has higher security and is not easy to be cracked reversely by AES encryption and bit-by-bit CRC checksum operation.
Further, in an embodiment, the marking process for the corresponding position includes the steps of:
s51: and highlighting or reversing the corresponding position.
Highlighting and reverse processing, namely, highlighting the color of the numerical value at the corresponding position in an image processing mode so as to distinguish the color from other numerical values in the code value.
In this embodiment, the corresponding position in the code value is easier to be visually recognized by the user after the highlight or reverse color processing is performed.
Further, in an embodiment, after step S6 and before step S7, that is, after retrieving the code value sent after the code scanning is performed on the anti-counterfeit two-dimensional code twice verified by the client, and before determining that the commodity is false if the code value is not retrieved, the method further includes the following steps:
s9: storing and recording the retrieval times;
that is, the number of times each retrieved code value is requested to be authenticated is recorded. For example, when the code value a is searched for 3 times, the code value a and the number of searches 3 are recorded.
Step S7 further includes the steps of:
s71: and if the retrieval times are larger than a preset threshold value, determining that the commodity is false.
The preset threshold is used to define whether the number of times of search exceeds the standard, and taking the preset threshold as 5 as an example, if the number of times of search exceeds 5, it represents that there is a possibility of being counterfeited, and thus it is determined that the product is false.
S72: if the code value exists in the searched state and the searching times are less than or equal to the preset threshold value, the code value is encrypted, checked and calculated, and then the remainder is obtained to obtain a target offset value; and sends the target offset value to the client.
And based on the limit of the retrieval times, after the code value is retrieved to exist, further comparing the retrieval times with a preset threshold value. And if the retrieval times are less than or equal to the preset threshold, sequentially encrypting, checking and calculating the code value, and then taking the remainder to obtain a target offset value, sending the target offset value to the client, and automatically judging whether the target offset value is equal to the value marked in the secondary check anti-counterfeiting two-dimensional code by the user.
It should be understood that, the sequence numbers of the steps in the foregoing embodiments do not imply an execution sequence, and the execution sequence of each process should be determined by its function and inherent logic, and should not constitute any limitation to the implementation process of the embodiments of the present invention.
In an embodiment, a secondary verification anti-counterfeiting device is provided, and the secondary verification anti-counterfeiting device corresponds to the secondary verification anti-counterfeiting method in the embodiment one to one. As shown in fig. 7, the secondary verification anti-counterfeiting device comprises a secondary verification anti-counterfeiting code generation module 7001 and an anti-counterfeiting verification module 7002. The functional modules are explained in detail as follows:
the secondary check anti-counterfeiting code generation module comprises:
the global unique code generating module 71 is configured to allocate a unique code value of a preset length to each commodity according to a preset code value generating algorithm;
the offset value generation module 72 is configured to encrypt, check and sum the code value, and then obtain the offset values corresponding to the code value one by one;
the two-dimensional code production module 73 is configured to synthesize the code value with a two-dimensional code picture generated by a preset two-dimensional code generation algorithm to obtain a two-dimensional code vector diagram;
a synthesizing module 74, configured to embed the offset value into a preset position in the two-dimensional code vector diagram;
the offset value positioning image processing module 75 is configured to position a corresponding position of the code value according to the offset value, and mark the corresponding position to obtain a secondary verification anti-counterfeiting two-dimensional code;
the anti-counterfeiting check module comprises:
the code value retrieval module 76 is used for retrieving the code value sent after the anti-counterfeiting two-dimensional code is scanned by the client for the second time;
a first counterfeit detection module 77, configured to determine that the commodity is false if the code value is not found;
the second counterfeit identification module 78 is configured to, if the code value is found to exist, encrypt, check and sum the code value, and then take the remainder to obtain a target offset value; and sends the target offset value to the client.
Further, the globally unique code generating module 71 further includes:
a random number generation submodule 711 for generating a random number according to the current timestamp;
and an information combining submodule 712, configured to combine the random number with the unique identifier of each distributed node of the back-end server and preset user identifier information, so as to generate a code value.
Further, the offset value generating module 72 further includes:
and the symmetric encryption check operation submodule 721 is configured to perform AES encryption on the code value, and perform CRC checksum operation on an encryption result by bit.
Further, the offset value positioning image processing module 75 further includes:
and a color difference processing sub-module 751 for highlighting or reversing the corresponding position.
Further, the anti-counterfeiting check module further comprises:
a verification frequency recording module 79 for storing and recording the retrieval frequency;
the second authentication module 78 further comprises:
the verification frequency judgment first sub-module 781 is used for determining that the commodity is false if the retrieval frequency is greater than a preset threshold;
the verification frequency judgment second sub-module 782, configured to, if the code value is found, and the retrieval frequency is smaller than or equal to the preset threshold, encrypt, check and sum the code value, and then take the remainder to obtain a target offset value; and sends the target offset value to the client.
For specific limitations of the secondary verification anti-counterfeiting device, reference may be made to the above limitations of the secondary verification anti-counterfeiting method, which are not described herein again. All or part of each module in the secondary verification anti-counterfeiting device can be realized through software, hardware and a combination thereof. The modules can be embedded in a hardware form or independent from a processor in the computer device, and can also be stored in a memory in the computer device in a software form, so that the processor can call and execute operations corresponding to the modules.
In one embodiment, a computer device is provided, which may be a server, and its internal structure diagram may be as shown in fig. 8. The computer device includes a processor, a memory, a network interface, and a database connected by a system bus. Wherein the processor of the computer device is configured to provide computing and control capabilities. The memory of the computer device comprises a nonvolatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program, and a database. The internal memory provides an environment for the operation of an operating system and computer programs in the non-volatile storage medium. The network interface of the computer device is used for communicating with an external terminal through a network connection. The computer program is executed by a processor to realize a secondary verification anti-counterfeiting method.
In one embodiment, a computer device is provided, which includes a memory, a processor, and a computer program stored in the memory and executable on the processor, and the processor executes the computer program to implement the steps of the secondary verification anti-counterfeit method in the above embodiments, such as steps S1 to S8 shown in fig. 2 and 3. Or, the processor implements the functions of each module/unit of the secondary verification anti-counterfeiting device in the above embodiments when executing the computer program. To avoid repetition, further description is omitted here.
In an embodiment, a computer-readable storage medium is provided, on which a computer program is stored, and the computer program is executed by a processor to implement the secondary verification anti-counterfeiting method in the above-mentioned method embodiment, or the computer program is executed by the processor to implement the functions of each module/unit in the secondary verification anti-counterfeiting device in the above-mentioned apparatus embodiment. To avoid repetition, further description is omitted here.
It will be understood by those skilled in the art that all or part of the processes of the methods of the embodiments described above can be implemented by hardware instructions of a computer program, which can be stored in a non-volatile computer-readable storage medium, and when executed, can include the processes of the embodiments of the methods described above. Any reference to memory, storage, databases, or other media used in embodiments provided herein may include non-volatile and/or volatile memory. Non-volatile memory can include read-only memory (ROM), Programmable ROM (PROM), Electrically Programmable ROM (EPROM), Electrically Erasable Programmable ROM (EEPROM), or flash memory. Volatile memory can 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), Double Data Rate SDRAM (DDRSDRAM), Enhanced SDRAM (ESDRAM), Synchronous Link DRAM (SLDRAM), Rambus Direct RAM (RDRAM), direct bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).
It will be apparent to those skilled in the art that, for convenience and brevity of description, only the above-mentioned division of the functional units and modules is illustrated, and in practical applications, the above-mentioned function distribution may be performed by different functional units and modules according to needs, that is, the internal structure of the apparatus is divided into different functional units or modules to perform all or part of the above-mentioned functions.
The above-mentioned embodiments are only used for illustrating the technical solutions of the present invention, and not for limiting the same; although the present invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; such modifications and substitutions do not substantially depart from the spirit and scope of the embodiments of the present invention, and are intended to be included within the scope of the present invention.

Claims (10)

1. A secondary verification anti-counterfeiting method is characterized by comprising a secondary verification anti-counterfeiting code generation algorithm and an anti-counterfeiting verification algorithm, wherein the secondary verification anti-counterfeiting code generation algorithm comprises:
according to a preset code value generation algorithm, allocating a unique code value with a preset length for each commodity;
after encrypting and checking the code value, carrying out residue taking to obtain offset values corresponding to the code value one by one;
synthesizing the code value and a two-dimensional code picture generated by a preset two-dimensional code generation algorithm to obtain a two-dimensional code vector diagram;
embedding the offset value into a preset position in the two-dimensional code vector diagram;
positioning the corresponding position of the code value according to the offset value, and marking the corresponding position to obtain a secondary verification anti-counterfeiting two-dimensional code;
the anti-counterfeiting verification algorithm comprises the following steps:
retrieving the code value sent after the secondary verification anti-counterfeiting two-dimensional code is scanned by the client;
if the code value does not exist in the search, determining that the commodity is false;
if the code value exists, encrypting the code value, performing checksum operation, and then taking the remainder to obtain a target offset value; and sending the target offset value to the client.
2. The secondary verification anti-counterfeiting method according to claim 1, wherein the preset code value generation algorithm comprises:
generating a random number according to the current timestamp;
and combining the random number with the unique identification of each distributed node of the back-end server and preset user identification information to generate the code value.
3. The secondary verification anti-counterfeiting method according to claim 1, wherein the encrypting, checking and calculating the code value comprises:
and carrying out AES encryption on the code value, and carrying out CRC checksum operation on the encryption result according to bits.
4. The secondary verification anti-counterfeiting method according to claim 1, wherein the marking of the corresponding position comprises:
and highlighting or reversing the corresponding position.
5. The secondary verification anti-counterfeiting method according to claim 1, wherein after the code value sent after the code scanning of the secondary verification anti-counterfeiting two-dimensional code by the client is retrieved and before the commodity is determined to be false if the code value is not retrieved, the method further comprises:
storing and recording the retrieval times;
if the code value exists, encrypting the code value, performing checksum operation, and then taking the remainder to obtain a target offset value; and sending the target offset value to the client, including:
if the retrieval times are larger than a preset threshold value, determining that the commodity is false;
if the code value exists in the searched state and the searching times are smaller than or equal to a preset threshold value, carrying out encryption, checksum operation and residue taking on the code value to obtain a target offset value; and sending the target offset value to the client.
6. The utility model provides a secondary check anti-counterfeiting device, its characterized in that, secondary check anti-counterfeiting device includes secondary check anti-counterfeiting code generation module and anti-counterfeiting check module, secondary check anti-counterfeiting code generation module includes:
the global unique code generation module is used for distributing a unique code value with a preset length to each commodity according to a preset code value generation algorithm;
the offset value generating module is used for encrypting the code value, checking and calculating, and then taking the rest to obtain the offset values corresponding to the code value one by one;
the two-dimensional code production module is used for synthesizing the code value and a two-dimensional code picture generated by a preset two-dimensional code generation algorithm to obtain a two-dimensional code vector diagram;
the synthesis module is used for embedding the deviation value into a preset position in the two-dimensional code vector diagram;
the offset value positioning image processing module is used for positioning the corresponding position of the code value according to the offset value and marking the corresponding position to obtain a secondary verification anti-counterfeiting two-dimensional code;
the anti-counterfeiting check module comprises:
the code value retrieval module is used for retrieving the code value sent after the secondary check anti-counterfeiting two-dimensional code is scanned by the client;
the first counterfeit identification module is used for determining that the commodity is false if the code value is not searched;
the second counterfeit identification module is used for encrypting, checking and operating the code value and then taking the remainder to obtain a target offset value if the code value is searched; and sending the target offset value to the client.
7. The double-check anti-counterfeiting device according to claim 6, wherein the globally unique code generating module comprises:
the random number generation submodule is used for generating a random number according to the current timestamp;
and the information combination submodule is used for combining the random number with the unique identifier of each distributed node of the back-end server and preset user identifier information to generate the code value.
8. The double-check anti-counterfeiting device according to claim 6, wherein the offset value generation module comprises:
and the symmetric encryption check submodule is used for carrying out AES encryption on the code value and carrying out CRC checksum operation on an encryption result according to bits.
9. A computer device comprising a memory, a processor and a computer program stored in the memory and executable on the processor, wherein the processor implements the secondary proof method according to any one of claims 1 to 5 when executing the computer program.
10. A computer-readable storage medium, in which a computer program is stored, and the computer program is executed by a processor to implement the secondary verification anti-counterfeiting method according to any one of claims 1 to 5.
CN202010387690.6A 2020-05-09 2020-05-09 Secondary check anti-counterfeiting method, device, equipment and storage medium Active CN111612476B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010387690.6A CN111612476B (en) 2020-05-09 2020-05-09 Secondary check anti-counterfeiting method, device, equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010387690.6A CN111612476B (en) 2020-05-09 2020-05-09 Secondary check anti-counterfeiting method, device, equipment and storage medium

Publications (2)

Publication Number Publication Date
CN111612476A true CN111612476A (en) 2020-09-01
CN111612476B CN111612476B (en) 2023-04-07

Family

ID=72204775

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010387690.6A Active CN111612476B (en) 2020-05-09 2020-05-09 Secondary check anti-counterfeiting method, device, equipment and storage medium

Country Status (1)

Country Link
CN (1) CN111612476B (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113326394A (en) * 2021-06-30 2021-08-31 合肥高维数据技术有限公司 Vector diagram watermark embedding and tracing method and system
CN114298257A (en) * 2021-11-23 2022-04-08 深圳市祯源科技有限公司 Method and device for realizing authenticity query through one-step code scanning
CN114661730A (en) * 2022-05-25 2022-06-24 江苏无痕防伪科技有限公司 Anti-counterfeiting data processing method suitable for printed matter
WO2023248867A1 (en) * 2022-06-20 2023-12-28 三郷コンピュータホールディングス株式会社 Code in which identifier that can be read using reader is printed
CN117745299A (en) * 2023-10-31 2024-03-22 北京国立信科技术有限公司 Two-dimensional code-based anti-counterfeiting method and system

Citations (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101377837A (en) * 2007-08-29 2009-03-04 北京方维银通科技有限公司 Method for generating and checking electronic check two-dimension code credence
CN103605950A (en) * 2013-11-25 2014-02-26 广西大学 Method and system for hiding signature in credible two-dimensional code
CN104751337A (en) * 2013-12-31 2015-07-01 腾讯科技(深圳)有限公司 Product anti-fake method, device and system
US20160350568A1 (en) * 2015-05-27 2016-12-01 Victor Zazzu Two-dimensional (2-d) code generating method, detecting method, detecting apparatus, and anti-counterfeit label
CN106529977A (en) * 2016-11-04 2017-03-22 深圳盛灿科技股份有限公司 Anti-counterfeiting method and system with support of terminal memory based on WeChat public account
CN107169775A (en) * 2017-05-11 2017-09-15 成都水微信息技术有限公司 False proof marketing system and the method for tracing to the source based on wechat
CN107423797A (en) * 2017-07-31 2017-12-01 成都新得利电子有限公司 A kind of security code information generating method
CN107545427A (en) * 2017-09-19 2018-01-05 深圳市光域物联科技有限公司 Light Quick Response Code payment mechanism, system and method
CN107609873A (en) * 2017-09-08 2018-01-19 阿里巴巴集团控股有限公司 A kind of barcode scanning safe checking method and device
WO2018103755A1 (en) * 2016-12-09 2018-06-14 北京大码技术有限公司 Combined two-dimensional code, electronic certificate carrier, and generation and reading apparatus and method
WO2018103756A1 (en) * 2016-12-09 2018-06-14 北京大码技术有限公司 Combined two-dimensional code anti-counterfeiting system and method, combined two-dimensional code and reading apparatus

Patent Citations (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101377837A (en) * 2007-08-29 2009-03-04 北京方维银通科技有限公司 Method for generating and checking electronic check two-dimension code credence
CN103605950A (en) * 2013-11-25 2014-02-26 广西大学 Method and system for hiding signature in credible two-dimensional code
CN104751337A (en) * 2013-12-31 2015-07-01 腾讯科技(深圳)有限公司 Product anti-fake method, device and system
US20160350568A1 (en) * 2015-05-27 2016-12-01 Victor Zazzu Two-dimensional (2-d) code generating method, detecting method, detecting apparatus, and anti-counterfeit label
CN106295755A (en) * 2015-05-27 2017-01-04 东莞文胜鼎电子科技有限公司 Two-dimensional code generation method, detection method, detection device and antifalsification label
CN106529977A (en) * 2016-11-04 2017-03-22 深圳盛灿科技股份有限公司 Anti-counterfeiting method and system with support of terminal memory based on WeChat public account
WO2018103755A1 (en) * 2016-12-09 2018-06-14 北京大码技术有限公司 Combined two-dimensional code, electronic certificate carrier, and generation and reading apparatus and method
CN108229596A (en) * 2016-12-09 2018-06-29 北京大码技术有限公司 Combined two-dimension code, digital certificates carrier, generation, reading device and method
WO2018103756A1 (en) * 2016-12-09 2018-06-14 北京大码技术有限公司 Combined two-dimensional code anti-counterfeiting system and method, combined two-dimensional code and reading apparatus
CN107169775A (en) * 2017-05-11 2017-09-15 成都水微信息技术有限公司 False proof marketing system and the method for tracing to the source based on wechat
CN107423797A (en) * 2017-07-31 2017-12-01 成都新得利电子有限公司 A kind of security code information generating method
CN107609873A (en) * 2017-09-08 2018-01-19 阿里巴巴集团控股有限公司 A kind of barcode scanning safe checking method and device
CN107545427A (en) * 2017-09-19 2018-01-05 深圳市光域物联科技有限公司 Light Quick Response Code payment mechanism, system and method

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
郭淑君: "字符二维码识别***的设计与实现", 《中国优秀硕士学位论文全文数据库》 *

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113326394A (en) * 2021-06-30 2021-08-31 合肥高维数据技术有限公司 Vector diagram watermark embedding and tracing method and system
CN114298257A (en) * 2021-11-23 2022-04-08 深圳市祯源科技有限公司 Method and device for realizing authenticity query through one-step code scanning
CN114661730A (en) * 2022-05-25 2022-06-24 江苏无痕防伪科技有限公司 Anti-counterfeiting data processing method suitable for printed matter
CN114661730B (en) * 2022-05-25 2022-09-09 江苏无痕防伪科技有限公司 Anti-counterfeiting data processing method suitable for printed matter
WO2023248867A1 (en) * 2022-06-20 2023-12-28 三郷コンピュータホールディングス株式会社 Code in which identifier that can be read using reader is printed
CN117745299A (en) * 2023-10-31 2024-03-22 北京国立信科技术有限公司 Two-dimensional code-based anti-counterfeiting method and system

Also Published As

Publication number Publication date
CN111612476B (en) 2023-04-07

Similar Documents

Publication Publication Date Title
CN111612476B (en) Secondary check anti-counterfeiting method, device, equipment and storage medium
US20210211291A1 (en) Registration and verification of biometric modalities using encryption techniques in a deep neural network
CN111612966B (en) Bill certificate anti-counterfeiting detection method and device based on image recognition
US8489901B2 (en) Methods and systems for secure encryption of data
WO2003103217A1 (en) Biometric authentication system
CN110942382B (en) Electronic contract generation method and device, computer equipment and storage medium
CN110224833B (en) Bill data processing method and system
CN110555779A (en) data processing method, data processing device, computer equipment and storage medium
CN111612963B (en) Bill voucher anti-counterfeiting detection method and device based on intelligent equipment
CN116503183B (en) Safety data security encryption method and system
CN114444105B (en) Intelligent audit data reporting safety method
CN115514585B (en) Database security management method and system
CN113988242A (en) Multi-region-based anti-counterfeiting code generation and verification method, system, equipment and medium
US20150379524A1 (en) Method and system for authenticating physical items
CN111124421B (en) Abnormal contract data detection method and device for blockchain intelligent contract
CN110457916B (en) Electronic contract encryption method and device and terminal equipment
CN116680673A (en) Identity verification method and device for display and computer equipment
CN110990410B (en) Information searching method and device in block chain, storage medium and computer equipment
CN116432238A (en) Data storage method and device and storage chip
CN110968275A (en) The anti-counterfeiting tracing system and method for the printed document
CN115859370A (en) Transaction data processing method and device, computer equipment and storage medium
CN115511030A (en) Anti-counterfeiting verification method and device and electronic equipment
CN112307445B (en) Identity management method and device based on block chain
CN110084329A (en) The set code method of centre letter code
CN113901502A (en) Data processing method and device, electronic equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant