Disclosure of Invention
The invention aims to provide a block chain technology-based payment substituting method which can effectively avoid the risk defect in the conventional order system. By utilizing the characteristic of the block chain distributed account book, a monitoring mechanism can monitor all transactions in the system in real time, and the problems of secondary clearing and the like are avoided.
In order to achieve the purpose, the invention adopts the following technical scheme:
a block chain technology-based payment method comprises the following steps:
s1, the user inputs the information of payment and initiates a request of payment: the user inputs own information and generates a payment request;
s2, the merchant system submits a payment request: the merchant order system submits the payment-substituting request to any node of the block chain, and at the moment, the node forms a receiving node;
s3, block chain processing step: after the block chain verifies the payment substituting request, the verified payment substituting request is blocked by a consensus algorithm, so that the payment substituting request is recorded on the block chain;
s4, monitoring and paying instead: the method comprises the steps that a first known system monitors a payment request on a block chain of a node matched with the first known system, and sends the payment request to a payment channel; the payment channel processes the payment request and returns a payment result to the prior system; the system returns the payment result to the block chain through the matched block chain link point;
s5, a payment result processing step: after the generation payment result is blocked by a consensus algorithm, the generation payment result is recorded on a block chain and is notified to an order system of a merchant; the whole process of payment generation is completed;
and S6, ending the payment of the generation.
Further, the block chain processing step (S3) is specifically:
s3.1, the receiving node receives the payment substituting request, verifies the payment substituting request, broadcasts the payment substituting request to other nodes of the block chain if the verification is successful, and simultaneously stores the payment substituting request into a transaction pool of the node, and then the step S3.2 is carried out; if the verification fails, directly discarding the payment request and ending the payment;
s3.2, after receiving the broadcasted payment-on-behalf request, other nodes of the block chain respectively carry out verification, if the verification is successful and the payment-on-behalf request is received for the first time, the other nodes broadcast the payment-on-behalf request and simultaneously store the payment-on-behalf request into a transaction pool of the node, otherwise, the node directly discards the payment-on-behalf request;
and S3.3, after the preset time, blocking the payment agency request through a consensus algorithm, and recording the block chain.
Further, the step of monitoring and payment for others (S4) is specifically:
s4.1, the surname system monitors the payment-on-behalf request on the block chain of the matched node, verifies the payment-on-behalf request, if the verification is successful, the payment-on-behalf request is sent to a payment channel, and the step S4.2 is carried out, if the verification is failed, the payment-on-behalf request is discarded, and the payment-on-behalf is finished;
s4.2, processing the payment request by the payment channel to generate a payment result;
s4.3, the payment channel sends the result of successful payment by generation to a prior knowledge system, the prior knowledge system verifies the successful payment by generation, and if the verification is successful, the result of payment by generation is written into the block link point matched with the result of payment by generation; and if the verification fails, discarding the payment result without recording.
Further, the substitute payment result processing step (S5) is specifically:
s5.1, the block chain link point matched with the prior-known system receives the payment substituting result written by the prior-known system, verifies the payment substituting result, and if the verification is successful, sends the payment substituting result to other nodes of the block chain, and simultaneously stores the payment substituting result into a transaction pool of the node; if the verification fails, directly discarding the payment result of the agent;
s5.2, after receiving the broadcasted payment-on-behalf result, other nodes respectively carry out verification, if the verification is successful and the payment-on-behalf result is received for the first time, the payment-on-behalf result is broadcasted, and meanwhile, the payment-on-behalf result is stored in a transaction pool of the nodes; otherwise, directly discarding the payment result;
s5.3, after the preset time, recording the payment withholding result on a block chain after the payment withholding result is blocked by a consensus algorithm;
and S5.4, the node which receives the request earliest returns the payment substituting result on the block chain to the merchant order system.
Further, the substitute payment result processing step (S5) further includes:
and S5.5, after the merchant order system receives the payment substituting result, displaying the payment substituting result.
Further, the payment data of the verification failure is processed by an error checking and processing system connected with the blockchain, wherein the payment data of the payment data comprises data of a payment request, a payment response, a payment result and a settlement result.
Detailed Description
The method for making a payment over a block chain technology according to the present invention is further explained and illustrated with reference to the drawings and the specific embodiments.
Example 1
The block chain technology-based payment-on-behalf specific transaction flow is as follows:
the user inputs the payment information and initiates a payment request: the user inputs own information and generates a payment request;
the merchant system submits a payment request: the merchant order system submits the payment-substituting request to any node on the block chain;
the block chain broadcasts a payment request for the agent and forms blocks: the node receives the request of the merchant, verifies the request of the merchant, sends the request to other nodes of the block chain after the verification is successful, and simultaneously stores the payment-substituting request into a transaction pool of the node; if the verification fails, the payment-on-behalf request is discarded directly. After receiving the broadcasted payment-on-behalf request, other nodes respectively carry out verification, if the verification is successful and the payment-on-behalf request is received for the first time, the other nodes broadcast the payment-on-behalf request and store the payment-on-behalf request into a transaction pool of the nodes; otherwise, the payment request is directly discarded. After a certain time, the payment-by-proxy request is packed onto the blockchain according to consensus rules.
The precursor system monitors for a payment request: the first known system monitors the payment request on the block chain of the matched node and verifies the transaction;
the precursor system sends a payment withholding request: after the verification is successful, the first known system sends a payment request to a payment channel;
the payment channel returns a payment result: the payment channel processes the request of paying for the next generation and returns the result of paying for the next generation to the prior known system;
the precursor system returns a payment result: after the pre-known system receives the payment substituting result, the payment substituting result is sent to the matched node;
and broadcasting the payment result by the block chain and blocking: the node receives the result of the prior known system, verifies the result, sends the result to other nodes of the block chain after the result is verified successfully, and simultaneously stores the payment result into a transaction pool of the node; if the verification fails, the payment result of the generation is directly discarded. After receiving the broadcasted payment-on-behalf result, other nodes respectively carry out verification, if the verification is successful and the payment-on-behalf result is received for the first time, the other nodes broadcast the payment-on-behalf result and store the payment-on-behalf result into a transaction pool of the nodes; otherwise, directly discarding the payment result. After a certain time, the payment result is packed to a block chain according to the consensus regulation;
block chain return payment results: the node which receives the request earliest returns the payment substituting result on the block chain to the merchant order system;
the merchant displays the payment result: after receiving the payment-on-behalf result, the order system of the merchant displays the payment-on-behalf result to the user;
example 2
The block chain technology-based payment method comprises the following steps:
s1, the user inputs the information of payment and initiates a request of payment: the user inputs own information and generates a payment request;
s2, the merchant system submits a payment request: the merchant order system submits the payment-substituting request to any one node on the block chain, and at the moment, the node forms a receiving node;
s3, block chain processing step: after the block chain verifies the payment substituting request, the verified payment substituting request is blocked by a consensus algorithm, so that the payment substituting request is recorded on the block chain;
s4, monitoring and paying instead: the method comprises the steps that a first known system monitors a payment request on a block chain of a node matched with the first known system, and sends the payment request to a payment channel; the payment channel processes the payment request and returns a payment result to the prior system; the system returns the payment result to the block chain through the matched block chain link point;
s5, a payment result processing step: after the generation payment result is blocked by a consensus algorithm, the generation payment result is recorded on a block chain and is notified to an order system of a merchant; completing the whole process of the payment substitute;
and S6, ending the payment of the generation.
Further, the block chain processing step (S3) is specifically:
s3.1, the receiving node receives the payment substituting request, verifies the payment substituting request, broadcasts the payment substituting request to other nodes of the block chain if the verification is successful, and simultaneously stores the payment substituting request into a transaction pool of the node, and then the step S3.2 is carried out; if the verification fails, directly discarding the payment request and ending the payment;
s3.2, after receiving the broadcasted payment-on-behalf request, other nodes of the block chain respectively carry out verification, if the verification is successful and the payment-on-behalf request is received for the first time, the other nodes broadcast the payment-on-behalf request and simultaneously store the payment-on-behalf request into a transaction pool of the node, otherwise, the node directly discards the payment-on-behalf request;
and S3.3, after the preset time, blocking the payment agency request through a consensus algorithm, and recording the block chain.
Further, the step of monitoring and payment for others (S4) is specifically:
s4.1, the surname system monitors the payment-on-behalf request on the block chain of the matched node, verifies the payment-on-behalf request, if the verification is successful, the payment-on-behalf request is sent to a payment channel, and the step S4.2 is carried out, if the verification is failed, the payment-on-behalf request is discarded, and the payment-on-behalf is finished;
s4.2, processing the payment request by the payment channel to generate a payment result;
s4.3, the payment channel sends the result of successful payment by generation to a prior knowledge system, the prior knowledge system verifies the successful payment by generation, and if the verification is successful, the result of payment by generation is written into the block link point matched with the result of payment by generation; and if the verification fails, discarding the payment result without recording.
Further, the substitute payment result processing step (S5) is specifically:
s5.1, the block chain link point matched with the prior-known system receives the payment substituting result written by the prior-known system, verifies the payment substituting result, and if the verification is successful, sends the payment substituting result to other nodes of the block chain, and simultaneously stores the payment substituting result into a transaction pool of the node; if the verification fails, directly discarding the payment result of the agent;
s5.2, after receiving the broadcasted payment-on-behalf result, other nodes respectively carry out verification, if the verification is successful and the payment-on-behalf result is received for the first time, the payment-on-behalf result is broadcasted, and meanwhile, the payment-on-behalf result is stored in a transaction pool of the nodes; otherwise, the node discards the payment result;
s5.3, after the preset time, recording the payment withholding result on a block chain after the payment withholding result is blocked by a consensus algorithm;
and S5.4, the node which receives the request earliest returns the payment substituting result on the block chain to the merchant order system.
Further, the substitute payment result processing step (S5) further includes:
and S5.5, after the merchant order system receives the payment substituting result, displaying the payment substituting result.
Further, the payment data of the verification failure is processed by an error checking and processing system connected with the blockchain, wherein the payment data comprises data of a payment request, a payment result and a settlement result.
Example 3
The block chain technology-based payment method only comprises the following steps:
s1, the user inputs the information of payment and initiates a request of payment: the user inputs own information and generates a payment request;
s2, the merchant system submits a payment request: the merchant order system submits the payment-substituting request to any one node on the block chain payment system, and at the moment, the node forms a receiving node;
s3, block chain processing step: after the block chain verifies the payment substituting request, the verified payment substituting request is blocked by a consensus algorithm, so that the payment substituting request is recorded on the block chain;
s4, monitoring and paying instead: the method comprises the steps that a first known system monitors a payment request on a block chain of a node matched with the first known system, and sends the payment request to a payment channel; the payment channel processes the payment request and returns a payment result to the prior system; the system returns the payment result to the block chain through the matched block chain link point;
s5, a payment result processing step: after the generation payment result is blocked by a consensus algorithm, the generation payment result is recorded on a block chain and is notified to an order system of a merchant; completing the whole payment process;
and S6, ending the payment of the generation.
In addition, in the invention, after other nodes of the block chain receive the broadcast, the node discards the payment data by itself, which means that the payment data is discarded at only the node with the verification failure, but not all the nodes, and the payment data also exists in a certain node or some nodes of the block chain.
According to the transaction flow and blockchain features of the present invention, all nodes will have a complete non-tampered book. Therefore, the supervising mechanism can supervise all transactions through the account book of the node, and risk transactions are prevented from occurring.
The present invention is not limited to the above-described embodiments, and variations, modifications, additions and substitutions which can be made by those skilled in the art within the spirit of the invention are also within the scope of the invention.