CN111030819A - Authentication method, system, terminal and storage medium based on encryption and decryption algorithm - Google Patents

Authentication method, system, terminal and storage medium based on encryption and decryption algorithm Download PDF

Info

Publication number
CN111030819A
CN111030819A CN202010099176.2A CN202010099176A CN111030819A CN 111030819 A CN111030819 A CN 111030819A CN 202010099176 A CN202010099176 A CN 202010099176A CN 111030819 A CN111030819 A CN 111030819A
Authority
CN
China
Prior art keywords
encryption
character string
decryption
algorithm
consistent
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.)
Pending
Application number
CN202010099176.2A
Other languages
Chinese (zh)
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.)
Shenzhen Xinrongdian Technology Co ltd
Original Assignee
Shenzhen Xinrongdian Technology 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 Shenzhen Xinrongdian Technology Co ltd filed Critical Shenzhen Xinrongdian Technology Co ltd
Priority to CN202010099176.2A priority Critical patent/CN111030819A/en
Publication of CN111030819A publication Critical patent/CN111030819A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/08Key distribution or management, e.g. generation, sharing or updating, of cryptographic keys or passwords
    • H04L9/0861Generation of secret information including derivation or calculation of cryptographic keys or passwords
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/08Key distribution or management, e.g. generation, sharing or updating, of cryptographic keys or passwords
    • H04L9/0861Generation of secret information including derivation or calculation of cryptographic keys or passwords
    • H04L9/0869Generation of secret information including derivation or calculation of cryptographic keys or passwords involving random numbers or seeds
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/32Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials
    • H04L9/3226Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials using a predetermined code, e.g. password, passphrase or PIN
    • H04L9/3228One-time or temporary data, i.e. information which is sent for every authentication or authorization, e.g. one-time-password, one-time-token or one-time-key

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Storage Device Security (AREA)

Abstract

The invention relates to a verification method based on an encryption and decryption algorithm, which comprises the following steps: encrypting the label of the commodity through an encryption algorithm based on the confusion formula, and storing the encrypted data; when the authenticity of the commodity is checked, the encrypted data is reversely decrypted; if the comparison numbers which are decrypted successfully are consistent, the label is real and legal, and if the comparison numbers which are decrypted are not consistent, the label is illegal; the confusion type encryption algorithm is adopted for encryption and decryption, so that a user can really calculate an encryption result and ensure that an encryption method is not identified, and the uniqueness and confidentiality and legitimacy of a number design are ensured.

Description

Authentication method, system, terminal and storage medium based on encryption and decryption algorithm
Technical Field
The invention relates to the technical field of verification methods, in particular to a verification method, a verification system, a verification terminal and a storage medium based on an encryption and decryption algorithm.
Background
In the commodity or data interaction process, the front data and the back data are public, the verification of the corresponding relation of the front data and the back data is easy to crack in a conventional mode, and a verification method and a verification system which can ensure that a user can really calculate an encryption result and can ensure that an encryption method is not identified are needed.
Disclosure of Invention
The technical problem to be solved by the present invention is to provide a verification method, system, terminal and storage medium based on encryption and decryption algorithm, aiming at the above-mentioned defects in the prior art.
The technical scheme adopted by the invention for solving the technical problems is as follows:
a verification method based on an encryption and decryption algorithm is constructed, and the realization method comprises the following steps:
the first step is as follows: encrypting the label of the commodity through an encryption algorithm based on the confusion formula, and storing the encrypted data;
the second step is that: when the authenticity of the commodity is checked, the encrypted data is reversely decrypted;
the third step: if the comparison numbers which are decrypted successfully are consistent, the label is true and legal, and if the comparison numbers which are decrypted are not consistent, the label is illegal.
The invention discloses a verification method based on an encryption and decryption algorithm, wherein the encryption algorithm comprises the following steps:
encrypting the data A by using a public encryption algorithm N to obtain an encrypted character string B;
generating an M-bit random number X, M > =6 according to a preset numerical value M;
taking the M-Z digit number in the random number as K, wherein Z is an arbitrary number from 0 to 9;
taking M digits from the K-1 digit of the character string B, and marking the character string with the M digits as Q when the M digits are less than the M digits;
and carrying out confusion type combination on the Q and the random number X to form a password A, wherein a combination mode Y can be customized and delivered to a decryption party.
The authentication method based on the encryption and decryption algorithm, disclosed by the invention, comprises the following steps of:
acquiring an encryption algorithm N, a preset numerical value M and a combination mode Y provided by an encryption data issuing party;
obtaining a character string B according to the data A and the encryption algorithm N;
taking out the character string Q from the password A according to the combination mode Y;
and comparing the character string B with the character string Q to determine whether the character string B is consistent with the character string Q, if so, determining that the character string B is legal, and otherwise, determining that the character string B is illegal.
The invention discloses a verification method based on an encryption and decryption algorithm, wherein a random number X is randomly generated during encryption.
A verification system based on encryption and decryption algorithm, according to the verification method based on encryption and decryption algorithm, comprises an encryption unit, a decryption unit and a verification unit;
the encryption unit is used for encrypting the label of the commodity through an encryption algorithm based on an obfuscation formula and storing the encrypted data;
the decryption unit is used for reversely decrypting the encrypted data when the authenticity of the commodity is checked;
and the verification unit is used for comparing whether the numbers successfully decrypted are consistent or not, judging that the label is true and legal if the numbers are consistent, and judging that the label is illegal if the numbers are not consistent.
The invention relates to a verification system based on an encryption and decryption algorithm, wherein the encryption algorithm comprises the following steps of:
encrypting the data A by using a public encryption algorithm N to obtain an encrypted character string B;
generating an M-bit random number X, M > =6 according to a preset numerical value M;
taking the M-Z digit number in the random number as K, wherein Z is an arbitrary number from 0 to 9;
taking M digits from the K-1 digit of the character string B, and marking the character string with the M digits as Q when the M digits are less than the M digits;
and carrying out confusion type combination on the Q and the random number X to form a password A, wherein a combination mode Y can be customized and delivered to a decryption party.
The authentication system based on the encryption and decryption algorithm, provided by the invention, comprises the following steps when the decryption unit executes decryption:
acquiring an encryption algorithm N, a preset numerical value M and a combination mode Y provided by an encryption data issuing party;
obtaining a character string B according to the data A and the encryption algorithm N;
and taking out the character string Q from the password A according to the combination mode Y.
The verification unit compares the character string B with the character string Q, if the character string B is consistent with the character string Q, the label is judged to be real and legal, and if the character string B is not consistent with the character string Q, the label is judged to be illegal.
An apparatus for plausibility testing comprising a memory, a processor and a computer program stored in said memory and executable on said processor, characterized in that said processor implements the steps of the method as described above when executing said computer program.
A computer-readable storage medium, in which a computer program is stored, which, when being executed by a processor, carries out the steps of the method as described above.
The invention has the beneficial effects that: the confusion type encryption algorithm is adopted for encryption and decryption, so that a user can really calculate an encryption result and ensure that an encryption method is not identified, and the uniqueness and confidentiality and legitimacy of a number design are ensured.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the present invention will be further described with reference to the accompanying drawings and embodiments, wherein the drawings in the following description are only part of the embodiments of the present invention, and for those skilled in the art, other drawings can be obtained without inventive efforts according to the accompanying drawings:
FIG. 1 is a flow chart of a verification method based on encryption and decryption algorithm according to a preferred embodiment of the present invention;
FIG. 2 is a flow chart of the obfuscated encryption algorithm based on the authentication method of the encryption and decryption algorithm according to the preferred embodiment of the present invention;
FIG. 3 is a flowchart of a decryption comparison method of a verification method based on an encryption/decryption algorithm according to a preferred embodiment of the present invention;
fig. 4 is a schematic block diagram of a verification system based on encryption and decryption algorithms according to a preferred embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present invention clearer, the following will clearly and completely describe the technical solutions in the embodiments of the present invention, and it is obvious that the described embodiments are some embodiments of the present invention, but not all embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments of the present invention without inventive step, are within the scope of the present invention.
The authentication method based on encryption and decryption algorithm of the preferred embodiment of the present invention is shown in fig. 1, and also refer to fig. 2 and fig. 3, and the implementation method is as follows:
s01: encrypting the label of the commodity through an encryption algorithm based on the confusion formula, and storing the encrypted data;
s02: when the authenticity of the commodity is checked, the encrypted data is reversely decrypted;
s03: if the comparison numbers which are decrypted successfully are consistent, the label is real and legal, and if the comparison numbers which are decrypted are not consistent, the label is illegal;
the confusion type encryption algorithm is adopted for encryption and decryption, so that a user can really calculate an encryption result and ensure that an encryption method is not identified, and the uniqueness and confidentiality and legitimacy of a number design are ensured.
Preferably, the encryption algorithm comprises the steps of:
s10: encrypting the data A by using a public encryption algorithm N to obtain an encrypted character string B;
s11: generating an M-bit random number X, M > =6 according to a preset numerical value M;
s12: taking the M-Z digit number in the random number as K, wherein Z is an arbitrary number from 0 to 9;
s13: taking M digits from the K-1 digit of the character string B, and marking the character string with the M digits as Q when the M digits are less than the M digits;
s14: and carrying out confusion type combination on the Q and the random number X to form a password A, wherein a combination mode Y can be customized and delivered to a decryption party.
Preferably, in the second step and the third step, the method for reverse decryption and number comparison comprises the following steps:
s20: acquiring an encryption algorithm N, a preset numerical value M and a combination mode Y provided by an encryption data issuing party;
s21: obtaining a character string B according to the data A and the encryption algorithm N;
s22: taking out the character string Q from the password A according to the combination mode Y;
s23: and comparing the character string B with the character string Q to determine whether the character string B is consistent with the character string Q, if so, determining that the character string B is legal, and otherwise, determining that the character string B is illegal.
Preferably, the random number X is randomly generated each time it is encrypted.
A true verification system based on encryption and decryption algorithm, according to the true verification method based on encryption and decryption algorithm, the true verification system comprises an encryption unit 1, a decryption unit 2 and a verification unit 3;
the encryption unit 1 is used for encrypting the label of the commodity through an encryption algorithm based on an obfuscation formula and storing the encrypted data;
the decryption unit 2 is used for reversely decrypting the encrypted data when the authenticity of the commodity is checked;
the verification unit 3 is used for comparing whether the numbers successfully decrypted are consistent or not, judging that the label is real and legal if the numbers are consistent, and judging that the label is illegal if the numbers are not consistent;
the confusion type encryption algorithm is adopted for encryption and decryption, so that a user can really calculate an encryption result and ensure that an encryption method is not identified, and the uniqueness and confidentiality and legitimacy of a number design are ensured.
The invention discloses a verification system based on an encryption and decryption algorithm, wherein the encryption algorithm comprises the following steps of:
encrypting the data A by using a public encryption algorithm N to obtain an encrypted character string B;
generating an M-bit random number X, M > =6 according to a preset numerical value M;
taking the M-Z digit number in the random number as K, wherein Z is an arbitrary number from 0 to 9;
taking M digits from the K-1 digit of the character string B, and marking the character string with the M digits as Q when the M digits are less than the M digits;
and carrying out confusion type combination on the Q and the random number X to form a password A, wherein a combination mode Y can be customized and delivered to a decryption party.
The invention discloses a verification system based on an encryption and decryption algorithm, wherein a decryption unit executes decryption and comprises the following steps:
acquiring an encryption algorithm N, a preset numerical value M and a combination mode Y provided by an encryption data issuing party;
obtaining a character string B according to the data A and the encryption algorithm N;
and taking out the character string Q from the password A according to the combination mode Y.
The verification unit compares the character string B with the character string Q, if the character string B is consistent with the character string Q, the label is judged to be real and legal, and if the character string B is not consistent with the character string Q, the label is judged to be illegal.
An authentication device comprising a memory, a processor and a computer program stored in the memory and executable on the processor, characterized in that the processor implements the steps of the method as described above when executing the computer program.
A computer-readable storage medium, in which a computer program is stored, which, when being executed by a processor, carries out the steps of the method as described above.
It will be understood that modifications and variations can be made by persons skilled in the art in light of the above teachings and all such modifications and variations are intended to be included within the scope of the invention as defined in the appended claims.

Claims (10)

1. A verification method based on encryption and decryption algorithm is characterized in that the realization method is as follows:
the first step is as follows: encrypting the label of the commodity through an encryption algorithm based on the confusion formula, and storing the encrypted data;
the second step is that: when the authenticity of the commodity is checked, the encrypted data is reversely decrypted;
the third step: if the comparison numbers which are decrypted successfully are consistent, the label is true and legal, and if the comparison numbers which are decrypted are not consistent, the label is illegal.
2. The authentication method based on encryption and decryption algorithm according to claim 1, wherein the encryption algorithm comprises the following steps:
encrypting the data A by using a public encryption algorithm N to obtain an encrypted character string B;
generating an M-bit random number X, M > =6 according to a preset numerical value M;
taking the M-Z digit number in the random number as K, wherein Z is an arbitrary number from 0 to 9;
taking M digits from the K-1 digit of the character string B, and marking the character string with the M digits as Q when the M digits are less than the M digits;
and carrying out confusion type combination on the Q and the random number X to form a password A, wherein a combination mode Y can be customized and delivered to a decryption party.
3. The authentication method based on encryption and decryption algorithm according to claim 2, wherein the second and third steps, the method of reverse decryption and number comparison comprises the following steps:
acquiring an encryption algorithm N, a preset numerical value M and a combination mode Y provided by an encryption data issuing party;
obtaining a character string B according to the data A and the encryption algorithm N;
taking out the character string Q from the password A according to the combination mode Y;
and comparing the character string B with the character string Q to determine whether the character string B is consistent with the character string Q, if so, determining that the character string B is legal, and otherwise, determining that the character string B is illegal.
4. A method of authentication based on a cryptographic algorithm as claimed in claim 2 or 3, wherein the random number X is generated randomly at each encryption.
5. An authentication system based on an encryption and decryption algorithm, the authentication method based on the encryption and decryption algorithm according to any one of claims 1 to 4, characterized by comprising an encryption unit, a decryption unit and a verification unit;
the encryption unit is used for encrypting the label of the commodity through an encryption algorithm based on an obfuscation formula and storing the encrypted data;
the decryption unit is used for reversely decrypting the encrypted data when the authenticity of the commodity is checked;
and the verification unit is used for comparing whether the numbers successfully decrypted are consistent or not, judging that the label is true and legal if the numbers are consistent, and judging that the label is illegal if the numbers are not consistent.
6. The authentication system based on encryption and decryption algorithm according to claim 5, wherein the encryption algorithm comprises the following steps when encrypting:
encrypting the data A by using a public encryption algorithm N to obtain an encrypted character string B;
generating an M-bit random number X, M > =6 according to a preset numerical value M;
taking the M-Z digit number in the random number as K, wherein Z is an arbitrary number from 0 to 9;
taking M digits from the K-1 digit of the character string B, and marking the character string with the M digits as Q when the M digits are less than the M digits;
and carrying out confusion type combination on the Q and the random number X to form a password A, wherein a combination mode Y can be customized and delivered to a decryption party.
7. The authentication system according to claim 6, wherein said decryption unit performs decryption by the following steps:
acquiring an encryption algorithm N, a preset numerical value M and a combination mode Y provided by an encryption data issuing party;
obtaining a character string B according to the data A and the encryption algorithm N;
and taking out the character string Q from the password A according to the combination mode Y.
8. The authentication system based on the encryption and decryption algorithm according to claim 7, wherein the authentication unit compares the character string B with the character string Q, and determines that the tag is authentic and legal if the character strings are consistent and illegal if the character strings are not consistent.
9. An apparatus for plausibility testing comprising a memory, a processor and a computer program stored in the memory and executable on the processor, characterized in that the processor implements the steps of the method according to any one of claims 1 to 4 when executing the computer program.
10. A computer-readable storage medium, in which a computer program is stored which, when being executed by a processor, carries out the steps of the method according to any one of claims 1 to 4.
CN202010099176.2A 2020-02-18 2020-02-18 Authentication method, system, terminal and storage medium based on encryption and decryption algorithm Pending CN111030819A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010099176.2A CN111030819A (en) 2020-02-18 2020-02-18 Authentication method, system, terminal and storage medium based on encryption and decryption algorithm

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010099176.2A CN111030819A (en) 2020-02-18 2020-02-18 Authentication method, system, terminal and storage medium based on encryption and decryption algorithm

Publications (1)

Publication Number Publication Date
CN111030819A true CN111030819A (en) 2020-04-17

Family

ID=70199345

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010099176.2A Pending CN111030819A (en) 2020-02-18 2020-02-18 Authentication method, system, terminal and storage medium based on encryption and decryption algorithm

Country Status (1)

Country Link
CN (1) CN111030819A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114826695A (en) * 2022-04-07 2022-07-29 广州腾粤信息科技有限公司 Privacy protection system of transaction data based on block chain

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105959265A (en) * 2016-04-25 2016-09-21 上海众人网络安全技术有限公司 Electronic form filling system and method thereof
WO2017078626A1 (en) * 2015-11-04 2017-05-11 Jing King Tech Holdings Pte. Ltd. Method and system for generating ciphertext by pin entry device
CN107017997A (en) * 2017-06-01 2017-08-04 国网江苏省电力公司电力科学研究院 A kind of auth method, reader and label
CN107920088A (en) * 2017-12-21 2018-04-17 深圳市四面信息科技有限公司 A kind of encipher-decipher method
CN108737346A (en) * 2017-04-21 2018-11-02 珠海格力电器股份有限公司 A kind of method of password authentication and its device, server, communication system
CN110474766A (en) * 2019-07-30 2019-11-19 河南兄弟科技发展有限公司 Random cipher generation method, device and auth method

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2017078626A1 (en) * 2015-11-04 2017-05-11 Jing King Tech Holdings Pte. Ltd. Method and system for generating ciphertext by pin entry device
CN105959265A (en) * 2016-04-25 2016-09-21 上海众人网络安全技术有限公司 Electronic form filling system and method thereof
CN108737346A (en) * 2017-04-21 2018-11-02 珠海格力电器股份有限公司 A kind of method of password authentication and its device, server, communication system
CN107017997A (en) * 2017-06-01 2017-08-04 国网江苏省电力公司电力科学研究院 A kind of auth method, reader and label
CN107920088A (en) * 2017-12-21 2018-04-17 深圳市四面信息科技有限公司 A kind of encipher-decipher method
CN110474766A (en) * 2019-07-30 2019-11-19 河南兄弟科技发展有限公司 Random cipher generation method, device and auth method

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
吕岩: "基于020的便民支付交易平台的设计与实现", 《中国优秀硕士学位论文全文数据库 信息科技辑》 *

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114826695A (en) * 2022-04-07 2022-07-29 广州腾粤信息科技有限公司 Privacy protection system of transaction data based on block chain

Similar Documents

Publication Publication Date Title
US7770018B2 (en) Setting up a security access system
AU2013101034B4 (en) Registration and authentication of computing devices using a digital skeleton key
US9646161B2 (en) Relational database fingerprinting method and system
JP5306465B2 (en) Pre-calculation of message authentication code applied to secure memory
US9043610B2 (en) Systems and methods for data security
AU2010318058B2 (en) A method of assigning a secret to a security token, a method of operating a security token, storage medium and security token
CN110710155A (en) Progressive key encryption algorithm
US8995653B2 (en) Generating a secret key from an asymmetric private key
EP1846830B1 (en) Access keys
KR100702499B1 (en) System and method for guaranteeing software integrity
CN111614467B (en) System backdoor defense method and device, computer equipment and storage medium
CN108494783A (en) The guard method of high in the clouds data
CN111739200B (en) Fingerprint electronic lock and encryption and decryption authentication method thereof
CN110855667A (en) Block chain encryption method, device and system
CN111125456A (en) Virtual password comparison method and system and intelligent lock
CN115168813A (en) Firmware signature and processor boot method and apparatus
CN114741704A (en) Privacy protection method, device, equipment and medium based on marriage and love dating
CN111030819A (en) Authentication method, system, terminal and storage medium based on encryption and decryption algorithm
CN105809494A (en) method and system for invoice generation and invoice verification
CN108574578A (en) A kind of black box data protection system and method
CN111385083B (en) Key protection method and key protection system
CN114329614A (en) Data desensitization method and system based on character string confusion
CN114462088A (en) Method and device for de-identifying shared data
CN114297673A (en) Password verification method, solid state disk and upper computer
JP2015026892A (en) Information processing system

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