Method for processing two-dimensional code payment based on encryption technology
Technical Field
The invention relates to the technical field of bus payment, merchant scanning payment and personal transfer payment, in particular to a method for processing two-dimensional code payment based on an encryption technology.
Background
Above the present system, unable direct account transfer of code is swept through the two-dimensional code directly to each bank system app, and the consumption need include with the help of other third parties, pays precious, and the code payment mode is swept to believe etc. a little, but this kind of account transfer mode is not real-time enterprise to the account, need through third party payment system's settlement of clearing up to reach the detention of fund, and opaque.
Disclosure of Invention
The invention aims to provide a method for processing two-dimensional code payment based on an encryption technology, so as to solve the problems in the background technology.
In order to achieve the purpose, the invention provides the following technical scheme: the invention discloses a method for processing two-dimensional code payment based on an encryption technology, which comprises the following steps:
s1: encrypting the user information and the timestamp data into a payment code by using an encryption algorithm such as chacha20, and then displaying the content of the payment code by using a two-dimensional code;
s2: the user sends the payment two-dimensional code to the cash register for identification, and the content of the two-dimensional code is obtained, so that the payment code is obtained;
s3: the payment interface is called by the collection equipment, and the background analyzes the payment code to acquire user information;
s4: and performing transfer operation on the user information analyzed in the step of S3 to complete payment operation.
Furthermore, the dynamic two-dimensional code payment is tamper-resistant to enable user information and a time stamp to exist, the user data id is only encrypted with the time stamp, uniqueness is never achieved, and tampering resistance is prevented.
Further, the payment commodity types in the step S2 are limited to public transportation payment, merchant payment and personal code scanning transfer.
Further, the bus hardware is scanned the sign indicating number and is deducted individual expense of taking a bus and support no sign indicating number dynamic loading two-dimensional code, bus hardware is scanned the sign indicating number and is deducted individual expense of taking a bus and is scanned after the sign indicating number obtains the two-dimensional code by the bus, resolve out the dynamic data in the two-dimensional code, wait to resume the network after, bus equipment goes up the cloud with the dynamic data resolved, then the request is deducted the interface of spending to reach real-time deduction and no network delay deduction.
The invention has the beneficial effects that:
1. according to the method and the system, the user information is encrypted, the timestamp data is encrypted into the payment code, the problems of important data leakage and payment code embezzlement can be effectively avoided, the user can pay conveniently and quickly, and meanwhile the safety problem of two-dimensional code payment is effectively solved.
2. The bank card is provided for direct code scanning payment, so that direct point-to-point direct transfer between the bank card and the bank card is achieved, and the fund is not detained.
3. The method supports the non-network dynamic loading of the two-dimensional code, after code hardware is scanned, dynamic data in the two-dimensional code are analyzed through a decryption algorithm, after the network is recovered, the device clouds the analyzed dynamic data, and then requests a fee deduction interface, so that real-time fee deduction and non-network delay fee deduction are achieved.
Drawings
Fig. 1 is a flowchart of a method and a system for processing two-dimensional code payment by using an encryption technology, which is a method for processing two-dimensional code payment by using an encryption technology.
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 only a part of the embodiments of the present invention, and not all embodiments, and all other embodiments obtained by a person of ordinary skill in the art without creative efforts based on the embodiments of the present invention belong to the protection scope of the present invention.
To facilitate an understanding of the invention, the invention will now be described more fully with reference to the accompanying drawings. Several embodiments of the invention are presented in the drawings. This invention may, however, be embodied in many different forms and should not be construed as limited to the embodiments set forth herein. Rather, these embodiments are provided so that this disclosure will be thorough and complete.
It will be understood that when an element is referred to as being "secured to" another element, it can be directly on the other element or intervening elements may also be present. When an element is referred to as being "connected" to another element, it can be directly connected to the other element or intervening elements may also be present. The terms "vertical," "horizontal," "left," "right," and the like as used herein are for illustrative purposes only.
Unless defined otherwise, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this invention belongs. The terminology used in the description of the invention herein is for the purpose of describing particular embodiments only and is not intended to be limiting of the invention. As used herein, the term "and/or" includes any and all combinations of one or more of the associated listed items.
Referring to fig. 1, the present invention provides a technical solution:
a method for processing two-dimensional code payment based on encryption technology comprises the following steps:
s1: encrypting the user information and the timestamp data into a payment code by using an encryption algorithm such as chacha20, and then displaying the content of the payment code by using a two-dimensional code;
s2: the user sends the payment two-dimensional code to the cash register for identification, and the content of the two-dimensional code is obtained, so that the payment code is obtained;
s3: the payment interface is called by the collection equipment, and the background analyzes the payment code to acquire user information;
s4: and performing transfer operation on the user information analyzed in the step of S3 to complete payment operation.
In order to further improve the use function of the method for processing the two-dimensional code payment based on the encryption technology, the dynamic two-dimensional code payment is tamper-resistant, so that the user information and the time stamp exist, the user data id is encrypted only by adding the time stamp, the uniqueness is never reached, and the tamper resistance is realized.
In order to further improve the use function of the method for processing the two-dimensional code payment based on the encryption technology, the payment commodity types in the step S2 are limited to public transportation payment, merchant payment and personal code scanning transfer.
In order to further improve the use function of the method for processing the two-dimensional code payment based on the encryption technology, the bus hardware code scanning deduction of the personal riding cost supports code-free dynamic loading of the two-dimensional code, after the bus hardware code scanning deduction of the personal riding cost obtains the two-dimensional code through bus code scanning, dynamic data in the two-dimensional code is analyzed, after a network is recovered, bus equipment clouds the analyzed dynamic data, and then requests a fee deduction interface, so that real-time fee deduction and network-free delay fee deduction are achieved.
According to the method, the user information and the timestamp data are encrypted into the payment code, so that the problems of important data leakage and payment code embezzlement can be effectively avoided, the user can pay conveniently and quickly, and meanwhile, the safety problem of two-dimensional code payment is effectively solved; providing a bank card for direct code scanning payment, thereby achieving direct point-to-point direct transfer between the bank card and preventing the fund from being detained; the method supports the non-network dynamic loading of the two-dimensional code, after code hardware is scanned, dynamic data in the two-dimensional code are analyzed through a decryption algorithm, after the network is recovered, the device clouds the analyzed dynamic data, and then requests a fee deduction interface, so that real-time fee deduction and non-network delay fee deduction are achieved.
The foregoing illustrates and describes the principles, general features, and advantages of the present invention. It will be understood by those skilled in the art that the present invention is not limited to the embodiments described above, which are described in the specification and illustrated only to illustrate the principle of the present invention, but that various changes and modifications may be made therein without departing from the spirit and scope of the present invention, which fall within the scope of the invention as claimed. The scope of the invention is defined by the appended claims and equivalents thereof.