CN106156823B - A kind of colorful number sequence two dimensional code and its method for anti-counterfeit - Google Patents
A kind of colorful number sequence two dimensional code and its method for anti-counterfeit Download PDFInfo
- Publication number
- CN106156823B CN106156823B CN201610474326.7A CN201610474326A CN106156823B CN 106156823 B CN106156823 B CN 106156823B CN 201610474326 A CN201610474326 A CN 201610474326A CN 106156823 B CN106156823 B CN 106156823B
- Authority
- CN
- China
- Prior art keywords
- code
- dimensional code
- sequence
- pattern
- colorful
- 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.)
- Active
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06K—GRAPHICAL DATA READING; PRESENTATION OF DATA; RECORD CARRIERS; HANDLING RECORD CARRIERS
- G06K19/00—Record carriers for use with machines and with at least a part designed to carry digital markings
- G06K19/06—Record carriers for use with machines and with at least a part designed to carry digital markings characterised by the kind of the digital marking, e.g. shape, nature, code
- G06K19/06009—Record carriers for use with machines and with at least a part designed to carry digital markings characterised by the kind of the digital marking, e.g. shape, nature, code with optically detectable marking
- G06K19/06037—Record carriers for use with machines and with at least a part designed to carry digital markings characterised by the kind of the digital marking, e.g. shape, nature, code with optically detectable marking multi-dimensional coding
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06K—GRAPHICAL DATA READING; PRESENTATION OF DATA; RECORD CARRIERS; HANDLING RECORD CARRIERS
- G06K17/00—Methods or arrangements for effecting co-operative working between equipments covered by two or more of main groups G06K1/00 - G06K15/00, e.g. automatic card files incorporating conveying and reading operations
Landscapes
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Editing Of Facsimile Originals (AREA)
Abstract
The invention discloses a kind of colorful number sequence two dimensional code and its method for anti-counterfeit, colorful number sequence two dimensional code includes the pattern area for printing pattern in 2 D code, there is the check code area for printing two dimensional code sequence number below the pattern area, the two dimensional code sequence number is divided into several groups number, every group of number is printed using different colors, obtain colorful number sequence, when anti-fake, barcode scanning is carried out by barcode scanning equipment, it is compared two dimensional code is swept with the two dimensional code of client push and colorful number sequence, it discerns the false from the genuine, if the two mismatches, then swept two dimensional code is imitated imitative code.The present invention passes through the printed color two dimensional code sequence number below pattern in 2 D code, wherein the color sequence of color 2 D code sequence number is calculated by color sequence algorithm, therefore, by a known two dimensional code, it can not derive the pattern and colorful number sequence of another two dimensional code, the problem of two dimensional code is solved by the imitated of batch, the true and false can not be differentiated.
Description
Technical field
The invention belongs to two-dimension code anti-counterfeit technical fields, are related to a kind of colorful number sequence two dimensional code, specifically a kind of coloured silk
Color Serial No. two dimensional code and its method for anti-counterfeit.
Background technique
Two dimensional code is the figure between the item being distributed in the plane according to certain rule with certain specific geometric figure, Kongxiang
To record data symbol information.Two dimensional code includes high reliablity (reading accuracy rate considerably beyond manual record), high-efficient (reading
Take speed quickly, be equivalent to 40 characters per second) the advantages that.
Wherein, QR Code bar code is a kind of matrix two-dimensional barcode (present invention meaning developed by Japanese Eenso company
Two dimensional code, that is, QR Code bar code), as shown in Figure 1, it remove have information capacity possessed by two-dimensional bar code big, high reliablity,
It can indicate that Chinese character and image much information, security and antiforge purpose are strong, moreover it is possible to effectively indicate therefore Chinese character, kanji push away
Wide application speed quickly, is widely used in the fields such as automatic industrial manufacturing line management.
When two dimensional code identifies, (black and white is generally used, respectively table by scanning the two-dimensional code dark in pattern and light color
Show binary one and binary zero) region, obtain corresponding character code information.The soil resistance of two dimensional code is especially good, as long as guaranteeing
Three identification points and 70% figure readable ensure that data are not lost.
Currently used is black two dimensional code.The content of two dimensional code is that have certain format, as long as pressing this format
The two dimensional code of printing can not differentiate the true and false, and there are two dimensional codes to be copied illegally, copies, or even the problem copied in batches.
In view of this, the prior art has much room for improvement and improves.
Summary of the invention
In view of the deficiencies in the prior art, it is an object of that present invention to provide a kind of colorful number sequence two dimensional code and its anti-fake sides
Method.Aim to solve the problem that existing two dimensional code by batch the problem of copying, the true and false can not be differentiated.
The purpose of the present invention can be achieved through the following technical solutions:
A kind of colorful number sequence two dimensional code, including the pattern area for printing pattern in 2 D code, under the pattern area
Side has the check code area for printing two dimensional code sequence number, and the two dimensional code sequence number is divided into several groups number, every group of number
Word is printed using different colors, obtains colorful number sequence.
Further, the colorful number sequence combined by two dimensional code sequence number with corresponding color sequence and
At the color sequence is obtained by carrying out color sequence algorithm to two dimensional code sequence number.
A kind of colorful number sequence dimension code anti-counterfeit method, comprising the following steps:
Step S1: the production of two dimensional code, the specific method is as follows:
S11, it is needed that two-dimensional code data is generated pattern in 2 D code using two-dimension code generator according to user;
S12, from two-dimensional code data extract two dimensional code sequence number, and using color sequence algorithm to two dimensional code sequence number into
Row calculates, and obtains corresponding color sequence, by color sequence in conjunction with corresponding two dimensional code sequence number, obtains colorful number sequence
Column;
S13, it is printed, is passed through using pattern in 2 D code and colorful number sequence number of the two dimensional code spray code spraying apparatus to generation
Black code spraying head sprays the pattern in 2 D code of black, sprays colorful number below the pattern in 2 D code by colored code spraying head
Sequence;
Step S2: the recognition of two dimensional code, the specific method is as follows:
S21, pattern in 2 D code to be detected is scanned using barcode scanning equipment, obtains two-dimensional code data therein, and according to obtaining
The two-dimensional code data taken generates pattern in 2 D code;
S22, from two-dimensional code data extract two dimensional code sequence number, and using color sequence algorithm to two dimensional code sequence number into
Row calculates, and obtains corresponding color sequence, by color sequence in conjunction with corresponding two dimensional code sequence number, obtains colorful number sequence
Column;
S23, it is shown using pattern in 2 D code and colorful number sequence of the server-side to generation;
Step S3: the pattern in 2 D code and coloured silk that pattern in 2 D code to be detected and colorful number sequence and server-side are shown
Color Serial No. compares, if the two mismatches, two dimensional code to be detected is imitated imitative code.
Further, specific step is as follows for the color sequence algorithm:
A, a dictionary table is defined first;
B, ask two dimensional code sequence number divided by 1000000 remainders, result balance;
C, everybody of balance is obtained respectively, is followed successively by p1, p2, p3, p4, p5, p6 from left to right;
D, the value of ((p1+p5) %10) * 100+ ((p2+p4) %10) * 10+ ((p3+p6) %10), as a result conduct are calculated
key1;
E, the value of ((p2+p3) %10) * 100+ ((p1+p6) %10) * 10+ ((p4+p5) %10), as a result conduct are calculated
key2;
F, XOR operation is carried out to key1 and 0x41, is as a result used as key1;
G, XOR operation is carried out to key2 and 0x14, is as a result used as key2;
H, the value for calculating key1-500, takes absolute value, and is as a result used as key1;
I, the value of (kye2+800) %1000 is calculated, key2 is as a result used as;
J, the value of key1%20 is calculated, key1 is as a result used as;
K, the value of key2%24 is calculated, key2 is as a result used as;
It l, is row number by line number, key2 of key1, queries dictionary table obtains color sequence value.
Beneficial effects of the present invention: the present invention passes through the printed color two dimensional code sequence number below pattern in 2 D code, two dimension
Code sequence number is divided into several groups number, and every group is printed using different colors, obtains colorful number sequence, wherein color sequence is
It is calculated by color sequence algorithm, after barcode scanning equipment barcode scanning, server-side presses same algorithm, should show completely the same
Two dimensional code, completely the same with the color sequence of the two dimensional code, lower section swept, if the two mismatches, swept two dimensional code is imitated
Imitative code.Therefore, by a known two dimensional code, the pattern and colorful number sequence of another two dimensional code can not be derived, solved
The problem of two dimensional code determined by the imitated of batch, the true and false can not be differentiated.
Detailed description of the invention
Present invention is further described in detail in the following with reference to the drawings and specific embodiments.
Fig. 1 is the schematic diagram of the two dimensional code of the prior art.
Fig. 2 is the schematic diagram of two dimensional code of the present invention.
Fig. 3 is the flow chart of method for anti-counterfeit of the present invention.
Specific embodiment
The present invention provides a kind of colorful number sequence two dimensional code and its method for anti-counterfeit, to make the purpose of the present invention, technology
Scheme and effect are clearer, clear, and the present invention is described in more detail below.It should be appreciated that described herein specific
Embodiment is only used to explain the present invention, is not intended to limit the present invention.
Referring to Fig. 2, a kind of colorful number sequence two dimensional code, including the pattern area 1 for printing pattern in 2 D code, pattern
There is the check code area 2 for printing two dimensional code sequence number, two dimensional code sequence number is printed using the technology of color variable below area 1
Below two dimensional code, two dimensional code sequence number is divided into several groups number, and every group is printed using different colors, obtains colorful number sequence
Column, colorful number sequence is calculated by color sequence algorithm, therefore, by a known two dimensional code, can not be derived
The pattern of another two dimensional code and colorful number sequence out solve two dimensional code by the imitated of batch, can not differentiate asking for the true and false
Topic.
Referring to Fig. 3, a kind of colorful number sequence dimension code anti-counterfeit method, comprising the following steps:
Step S1: the production of two dimensional code, the specific method is as follows:
S11, it is needed that two-dimensional code data is generated pattern in 2 D code using two-dimension code generator according to user;
S12, from two-dimensional code data extract two dimensional code sequence number, and using color sequence algorithm to two dimensional code sequence number into
Row calculates, and obtains corresponding color sequence, by color sequence in conjunction with corresponding two dimensional code sequence number, obtains colorful number sequence
Column;
S13, it is printed, is passed through using pattern in 2 D code and colorful number sequence number of the two dimensional code spray code spraying apparatus to generation
Black code spraying head sprays the pattern in 2 D code of black, sprays colorful number below the pattern in 2 D code by colored code spraying head
Sequence;
Step S2: the recognition of two dimensional code, the specific method is as follows:
S21, pattern in 2 D code to be detected is scanned using barcode scanning equipment, obtains two-dimensional code data therein, and according to obtaining
The two-dimensional code data taken generates pattern in 2 D code;
S22, from two-dimensional code data extract two dimensional code sequence number, and using color sequence algorithm to two dimensional code sequence number into
Row calculates, and obtains corresponding color sequence, by color sequence in conjunction with corresponding two dimensional code sequence number, obtains colorful number sequence
Column;
S23, it is shown using pattern in 2 D code and colorful number sequence of the server-side to generation.
Step S3: the pattern in 2 D code and coloured silk that pattern in 2 D code to be detected and colorful number sequence and server-side are shown
Color Serial No. compares, if the two mismatches, two dimensional code to be detected is imitated imitative code.
Specific step is as follows for the color sequence algorithm:
A, a dictionary table is defined first;
B, ask two dimensional code sequence number divided by 1000000 remainders, result balance;
C, everybody of balance is obtained respectively, is followed successively by p1, p2, p3, p4, p5, p6 from left to right;
D, the value of ((p1+p5) %10) * 100+ ((p2+p4) %10) * 10+ ((p3+p6) %10), as a result conduct are calculated
key1;
E, the value of ((p2+p3) %10) * 100+ ((p1+p6) %10) * 10+ ((p4+p5) %10), as a result conduct are calculated
key2;
F, XOR operation is carried out to key1 and 0x41, is as a result used as key1;
G, XOR operation is carried out to key2 and 0x14, is as a result used as key2;
H, the value for calculating key1-500, takes absolute value, and is as a result used as key1;
I, the value of (kye2+800) %1000 is calculated, key2 is as a result used as;
J, the value of key1%20 is calculated, key1 is as a result used as;
K, the value of key2%24 is calculated, key2 is as a result used as;
It l, is row number by line number, key2 of key1, queries dictionary table obtains color sequence value.
Illustrate how real above-mentioned colorful number sequence dimension code anti-counterfeit method is below by a specific embodiment
Existing.
When user needs to spray corresponding two dimensional code on product, respective two-dimensional is inputted in two-dimension code generator first
Code data, generate corresponding pattern in 2 D code by two-dimension code generator.The format of two-dimensional code data is http://im.e-
Tag.cc/m/p/176816516532, wherein 176816516532 be the sequence number of two dimensional code, length is not fixed, by 12 two
The sequence number of dimension code is divided into 4 groups, every group of 3 numbers.
Then two dimensional code sequence number is calculated by color sequence algorithm:
1, six, respectively p1=5, p2=1, p3=6, p4=5, p5=3, p6=2 after taking 176816516532 first;
2, the value for calculating ((p1+p5) %10) * 100+ ((p2+p4) %10) * 10+ ((p3+p6) %10), obtains key1=
868;
3, the value for calculating ((p2+p3) %10) * 100+ ((p1+p6) %10) * 10+ ((p4+p5) %10), obtains key2=
778;
4, XOR operation is carried out to key1 and 0x41, obtains key1=805;
5, XOR operation is carried out to key2 and 0x14, obtains key2=798;
6, the value for calculating key1-500, takes absolute value, obtains key1=305;
7, the value for calculating (kye2+800) %1000, obtains key2=598;
8, the value for calculating key1%20, obtains key1=5;
9, the value for calculating key2%24, obtains key2=22;
It then, is row number by line number, key2 of key1, the 5th row the 22nd of queries dictionary table column obtain corresponding color sequence,
By color sequence in conjunction with corresponding two dimensional code sequence number, different colours are assigned to each group number according to obtained color sequence,
Obtain colorful number sequence.Finally carried out using pattern in 2 D code and colorful number sequence number of the two dimensional code spray code spraying apparatus to generation
Printing is sprayed the pattern in 2 D code of black by black code spraying head, is sprayed below the pattern in 2 D code by colored code spraying head
Apply colorful number sequence.
When anti-fake, using the pattern in 2 D code on barcode scanning equipment scanning product, two-dimensional code data therein, server-side are obtained
Pattern in 2 D code is generated according to the two-dimensional code data of acquisition;Meanwhile server-side uses color sequence algorithm to two dimensional code sequence number
It is calculated, obtains corresponding color sequence, by color sequence in conjunction with corresponding two dimensional code sequence number, generate colorful number sequence
Column;Finally, by pattern in 2 D code and the pattern in 2 D code that shows of colorful number sequence and server-side and colorful number on product
Sequence compares, if the two mismatches, which is imitated imitative code.
The present invention is divided into several groups by the printed color two dimensional code sequence number below pattern in 2 D code, two dimensional code sequence number
Number, every group is printed using different colors, obtains colorful number sequence, wherein color sequence is by color sequence algorithm meter
Obtain, after barcode scanning equipment barcode scanning, server-side press same algorithm, should show completely the same two dimensional code, with swept two
It is completely the same to tie up code, the color sequence of lower section, if the two mismatches, swept two dimensional code is imitated imitative code.Therefore, by one
Known two dimensional code can not derive the pattern and colorful number sequence of another two dimensional code, solve two dimensional code by batch
The problem of copying, the true and false can not be differentiated.
Above content is only to structure of the invention example and explanation, affiliated those skilled in the art couple
Described specific embodiment does various modifications or additions or is substituted in a similar manner, without departing from invention
Structure or beyond the scope defined by this claim, is within the scope of protection of the invention.
Claims (1)
1. a kind of colorful number sequence dimension code anti-counterfeit method, it is characterised in that: the following steps are included:
Step S1: the production of two dimensional code, the specific method is as follows:
S11, it is needed that two-dimensional code data is generated pattern in 2 D code using two-dimension code generator according to user;
S12, two dimensional code sequence number is extracted from two-dimensional code data, and two dimensional code sequence number is counted using color sequence algorithm
It calculates, obtains corresponding color sequence, by color sequence in conjunction with corresponding two dimensional code sequence number, obtain colorful number sequence;
S13, it is printed using pattern in 2 D code and colorful number sequence number of the two dimensional code spray code spraying apparatus to generation, passes through black
Code spraying head sprays the pattern in 2 D code of black, and colorful number sequence is sprayed below the pattern in 2 D code by colored code spraying head
Column;
Step S2: the recognition of two dimensional code, the specific method is as follows:
S21, pattern in 2 D code to be detected is scanned using barcode scanning equipment, obtains two-dimensional code data therein, and according to acquisition
Two-dimensional code data generates pattern in 2 D code;
S22, two dimensional code sequence number is extracted from two-dimensional code data, and two dimensional code sequence number is counted using color sequence algorithm
It calculates, obtains corresponding color sequence, by color sequence in conjunction with corresponding two dimensional code sequence number, obtain colorful number sequence;
S23, it is shown using pattern in 2 D code and colorful number sequence of the server-side to generation;
Step S3: the pattern in 2 D code and colored number that pattern in 2 D code to be detected and colorful number sequence and server-side are shown
Word sequence compares, if the two mismatches, two dimensional code to be detected is imitated imitative code;
Specific step is as follows for the color sequence algorithm:
A, a dictionary table is defined first;
B, ask two dimensional code sequence number divided by 1000000 remainders, result balance;
C, everybody of balance is obtained respectively, is followed successively by p1, p2, p3, p4, p5, p6 from left to right;
D, the value of ((p1+p5) %10) * 100+ ((p2+p4) %10) * 10+ ((p3+p6) %10) is calculated, key1 is as a result used as;
E, the value of ((p2+p3) %10) * 100+ ((p1+p6) %10) * 10+ ((p4+p5) %10) is calculated, key2 is as a result used as;
F, XOR operation is carried out to key1 and 0x41, is as a result used as key1;
G, XOR operation is carried out to key2 and 0x14, is as a result used as key2;
H, the value for calculating key1-500, takes absolute value, and is as a result used as key1;
I, the value of (kye2+800) %1000 is calculated, key2 is as a result used as;
J, the value of key1%20 is calculated, key1 is as a result used as;
K, the value of key2%24 is calculated, key2 is as a result used as;
It l, is row number by line number, key2 of key1, queries dictionary table obtains color sequence value.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610474326.7A CN106156823B (en) | 2016-06-23 | 2016-06-23 | A kind of colorful number sequence two dimensional code and its method for anti-counterfeit |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610474326.7A CN106156823B (en) | 2016-06-23 | 2016-06-23 | A kind of colorful number sequence two dimensional code and its method for anti-counterfeit |
Publications (2)
Publication Number | Publication Date |
---|---|
CN106156823A CN106156823A (en) | 2016-11-23 |
CN106156823B true CN106156823B (en) | 2019-03-22 |
Family
ID=57349756
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201610474326.7A Active CN106156823B (en) | 2016-06-23 | 2016-06-23 | A kind of colorful number sequence two dimensional code and its method for anti-counterfeit |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN106156823B (en) |
Families Citing this family (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN108682285A (en) * | 2018-06-22 | 2018-10-19 | 孙涵 | Label and preparation method thereof with light beam color changeable effect |
CN110610219B (en) * | 2019-08-12 | 2020-11-06 | 上海交通大学 | Color annular two-dimensional code and generation and decoding method thereof |
CN113052287B (en) * | 2021-04-06 | 2024-02-09 | 深圳市沃客非凡科技有限公司 | One-object one-code commodity anti-counterfeiting and tracing system based on digital watermark two-dimension code |
CN114580589B (en) * | 2022-02-23 | 2024-03-08 | 复旦大学 | Dual-channel two-dimensional code and control method for preventing copying and information hiding |
Citations (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN105574570A (en) * | 2015-12-21 | 2016-05-11 | 广州市宝绅纸塑有限公司 | Generation method, system, label, and anti-counterfeiting method of spiral color codes |
Family Cites Families (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP4567151B2 (en) * | 2000-07-03 | 2010-10-20 | 日本金銭機械株式会社 | 2D code creation method and paper with 2D code |
-
2016
- 2016-06-23 CN CN201610474326.7A patent/CN106156823B/en active Active
Patent Citations (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN105574570A (en) * | 2015-12-21 | 2016-05-11 | 广州市宝绅纸塑有限公司 | Generation method, system, label, and anti-counterfeiting method of spiral color codes |
Also Published As
Publication number | Publication date |
---|---|
CN106156823A (en) | 2016-11-23 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN106204058B (en) | A kind of colorful number matrix two-dimensional code and its method for anti-counterfeit | |
CN106156823B (en) | A kind of colorful number sequence two dimensional code and its method for anti-counterfeit | |
CN105095935B (en) | A kind of low-density having merged Chaos Encryption Technology, high coding capacity dot matrix Quick Response Code | |
CN106782035B (en) | Sawtooth code anti-counterfeiting method | |
CN103310344B (en) | CCQR (Colorful Coded Quick Response) anti-counterfeiting method | |
CN103700000A (en) | Code printing-free type fiber anti-counterfeiting method | |
CN105216470A (en) | A kind of method manufacturing anti-fake identification mark | |
CN106960352A (en) | A kind of method for anti-counterfeit based on picture uniqueness | |
CN107330499A (en) | Bilingual Quick Response Code and its analytic method | |
CN104616049B (en) | Colored anti-fake label and the method for realizing product false proof | |
CN112001467A (en) | Commodity anti-counterfeiting code generation and identification method based on picture encryption and decryption | |
CN103247229A (en) | Manufacture method of multiple anti-counterfeit labels | |
CN106185014B (en) | A kind of bottled drinking water traceability system and method for anti-counterfeit based on Quick Response Code | |
CN104156750B (en) | A kind of generation method of anti-fake label and its anti-fake label of generation | |
CN108960387A (en) | A kind of anti-counterfeiting two dimensional code and its generation and recognition methods | |
CN105894182A (en) | Method for detecting identification code tagging quality of large-breadth printing material | |
CN106886811A (en) | A kind of constructive method and reading method of mobile phone commodity false proof mark | |
CN105574570B (en) | Generation method, system, label and the method for anti-counterfeit of spiral coloured silk code | |
CN103106460A (en) | Multi-parametric-variable gradient hierarchical gradient polynary encryption anti-fake storage trademark | |
CN105005905A (en) | Generating and examination method and system for printing product with traceable anti-counterfeit medallion plate texture | |
CN108009616A (en) | One kind is new to have anti-fraud functional bar figure code and application process | |
CN103794134A (en) | Mark formed by dot matrixes and electronic supervision code and generation and identification method of mark | |
CN107729789A (en) | A kind of express delivery list based on Cultural Differences color makes and bar code positioning identifying method | |
CN106934756A (en) | The method and system of embedding information in a kind of monochromatic or spot color figure | |
CN107844820A (en) | A kind of dimension code anti-counterfeit method for metalwork |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |