CN110598457A - Bill processing method, device, processing equipment and computer storage medium - Google Patents

Bill processing method, device, processing equipment and computer storage medium Download PDF

Info

Publication number
CN110598457A
CN110598457A CN201910908338.XA CN201910908338A CN110598457A CN 110598457 A CN110598457 A CN 110598457A CN 201910908338 A CN201910908338 A CN 201910908338A CN 110598457 A CN110598457 A CN 110598457A
Authority
CN
China
Prior art keywords
information
transaction
processing device
digital signature
resource deduction
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
CN201910908338.XA
Other languages
Chinese (zh)
Other versions
CN110598457B (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.)
Tencent Technology Shenzhen Co Ltd
Original Assignee
Tencent Technology Shenzhen 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 Tencent Technology Shenzhen Co Ltd filed Critical Tencent Technology Shenzhen Co Ltd
Priority to CN201910908338.XA priority Critical patent/CN110598457B/en
Publication of CN110598457A publication Critical patent/CN110598457A/en
Application granted granted Critical
Publication of CN110598457B publication Critical patent/CN110598457B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/60Protecting data
    • G06F21/62Protecting access to data via a platform, e.g. using keys or access control rules
    • G06F21/6209Protecting access to data via a platform, e.g. using keys or access control rules to a single file or object, e.g. in a secure envelope, encrypted and accessed using a key, or with access control rules appended to the object itself
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/60Protecting data
    • G06F21/64Protecting data integrity, e.g. using checksums, certificates or signatures
    • 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
    • G06Q40/00Finance; Insurance; Tax strategies; Processing of corporate or income taxes
    • G06Q40/04Trading; Exchange, e.g. stocks, commodities, derivatives or currency exchange
    • 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
    • G06Q40/00Finance; Insurance; Tax strategies; Processing of corporate or income taxes
    • G06Q40/10Tax strategies

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Business, Economics & Management (AREA)
  • Physics & Mathematics (AREA)
  • Accounting & Taxation (AREA)
  • Finance (AREA)
  • General Physics & Mathematics (AREA)
  • Development Economics (AREA)
  • Computer Security & Cryptography (AREA)
  • General Business, Economics & Management (AREA)
  • Technology Law (AREA)
  • Strategic Management (AREA)
  • Marketing (AREA)
  • Health & Medical Sciences (AREA)
  • Bioethics (AREA)
  • General Health & Medical Sciences (AREA)
  • Computer Hardware Design (AREA)
  • Economics (AREA)
  • Software Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Financial Or Insurance-Related Operations Such As Payment And Settlement (AREA)

Abstract

The embodiment of the invention discloses a bill processing method, a bill processing device, bill processing equipment and a computer storage medium, wherein the bill processing method comprises the following steps: receiving first information sent by second processing equipment, wherein the first information comprises transaction information, resource deduction information and a first digital signature, and the resource deduction information comprises resource deduction amount; verifying the first digital signature according to the transaction information and the resource deduction information; if the verification is successful, generating a bill generation request, wherein the bill generation request comprises transaction information, resource deduction information and a first digital signature; and sending a bill generation request to the blockchain network so that the blockchain network verifies the first digital signature according to the transaction information and the resource deduction information, and after the verification is successful, generating a bill comprising the transaction information and the resource deduction amount. By adopting the embodiment of the invention, the bill can be generated after the tax payment is finished, so that the risk that the bill cannot be reimbursed is reduced.

Description

Bill processing method, device, processing equipment and computer storage medium
Technical Field
The invention relates to the technical field of network information processing, in particular to a bill processing method, a bill processing device, bill processing equipment and a computer storage medium.
Background
With the advent of the information age, all industries are implementing informatization. At present, the consumption mode of consumers tends to be networked gradually, and when the online shopping is carried out, the electronic bill is taken as an internet +' product, so that the bill making efficiency is improved, the bill making cost is reduced, and great convenience is brought to the consumers, enterprises and tax authorities. However, at present, the billing and the tax charging of enterprises are separated, and when the bill which is made by a billing party for a receipt party cannot be timely charged with tax, the bill has the risk problem that the bill cannot be reimbursed.
Disclosure of Invention
The embodiment of the invention provides a bill processing method, a bill processing device, bill processing equipment and a computer storage medium, which can reduce the risk that bills cannot be reimbursed.
The first aspect of the embodiments of the present invention provides a bill processing method, including:
receiving first information sent by second processing equipment, wherein the first information comprises transaction information, resource deduction information and a first digital signature, the resource deduction information comprises resource deduction amount deducted by a first user corresponding to the first processing equipment, the resource deduction amount is determined according to the resource amount in the transaction information, and the first digital signature is obtained by the second processing equipment by signing the transaction information and the resource deduction information;
verifying the first digital signature according to the transaction information and the resource deduction information;
if the first digital signature is successfully verified, generating a bill generation request, wherein the bill generation request comprises transaction information, resource deduction information and the first digital signature;
and sending a bill generation request to the blockchain network so that the blockchain network verifies the first digital signature according to the transaction information and the resource deduction information, and after the verification is successful, generating a bill comprising the transaction information and the resource deduction amount.
In the technical scheme, the resource deduction information can be understood as a tax deduction certificate corresponding to the transaction, the resource deduction amount can be understood as a tax deduction amount, and the resource amount can be understood as a resource amount. The first processing device receives first information including resource deduction information, then generates a bill generation request and sends the bill generation request to the blockchain network, so that the blockchain network generates a bill including the transaction information and the resource deduction amount. Based on the scheme, the bill can be generated after the tax payment is finished, so that the risk that the bill cannot be reimbursed is reduced.
As an optional implementation manner, the ticket generation request is signed to obtain a second digital signature; sending a ticket generation request to a blockchain network, comprising:
and sending the bill generation request and the second digital signature to the blockchain network, so that the blockchain network verifies the second digital signature according to the bill generation request, and after verification is successful, verifying the first digital signature according to the transaction information and the resource deduction information.
In the technical scheme, the second digital signature generated by the ticket generation request signature is sent to the block chain network, and based on the optional mode, the security of the ticket generation request can be enhanced.
As an optional implementation manner, before receiving the first information sent by the second processing device, determining a transaction submission time length according to the transaction submission time in the transaction information; detecting whether the transaction submission time reaches a first preset time; if the transaction submitting duration reaches the first preset duration, second information including the transaction information is sent to the second processing equipment, so that the second processing equipment determines the resource deduction amount according to the resource amount in the transaction information, generates first information after the resource deduction amount is deducted from a first user corresponding to the first processing equipment, and sends the first information to the first processing equipment.
In the technical scheme, the specific time for sending the second information can be determined by detecting whether the transaction duration reaches the preset duration.
As an optional implementation manner, before detecting whether the transaction submission time reaches a first preset time, determining a transaction object from the transaction information; acquiring the total transaction times and transaction failure times of a transaction object in a preset time period; determining a first credit level of the transaction object according to the total transaction times and the transaction failure times of the transaction object in a preset time period; determining a first preset time length corresponding to the first credit grade according to the corresponding relation between the preset credit grade and the preset time length; in the corresponding relation between the credit levels and the preset time length, the preset time length corresponding to the first credit level is smaller than the preset time length corresponding to the second credit level, and the first credit level is larger than the second credit level.
In the technical scheme, the first preset time length is determined through the credit level of a trading object. Based on the alternative, the bill can be generated quickly according to the credit level of the user.
As an optional implementation manner, before detecting whether the transaction submission time length reaches a first preset time length, determining a transaction article from the transaction information; determining a first category of the transaction item; and determining a first preset time corresponding to the first category according to the corresponding relation between the preset article category and the preset time.
In the technical scheme, the first preset time length is determined by the category of the transaction item. Based on this alternative, rapid generation of tickets can be achieved according to the category of the transaction item.
As an optional implementation manner, after the first digital signature is successfully verified, an acquisition request is sent to the third processing device, where the acquisition request is used to request to acquire ticket collector information; if the ticket collector information is received from the third processing equipment within a second preset time after the acquisition request is sent to the third processing equipment, the ticket generation request further comprises the ticket collector information, and the ticket generated by the block chain network further comprises the ticket collector information; if the ticket collector information is not received within the second preset time after the acquisition request is sent to the third processing device, the ticket generation request further includes preset ticket collector information, and the ticket generated by the block chain network further includes the preset ticket collector information.
In the technical scheme, ticket collector information is acquired from a third processing device before a ticket generating request is generated; when the acquisition is successful, a bill can be generated for the user according to the requirement of the user; and when the acquisition fails, generating a default preset bill for the user. Based on this alternative, it can be guaranteed that a ticket is generated for each transaction.
As an optional implementation manner, before receiving the first information sent by the second processing device, sending second information including transaction information and resource deduction information to the second processing device, so that the second processing device verifies the resource deduction amount in the resource deduction information according to the transaction information, and after the verification passes, generating first information, and sending the first information to the first processing device.
In this technical solution, since the second information sent by the first processing device includes the resource deduction information, the second processing device only needs to check the resource deduction amount of the resource deduction information, and does not need to perform the deduction operation. Based on this alternative, the operation steps of the second processing device can be reduced, and the load can be reduced.
A second aspect of the embodiments of the present invention provides a bill processing apparatus, including:
the receiving unit is used for receiving first information sent by the second processing device, the first information comprises transaction information, resource deduction information and a first digital signature, the resource deduction information comprises resource deduction amount deducted by a first user corresponding to the first processing device, the resource deduction amount is determined according to the resource amount in the transaction information, and the first digital signature is obtained by signing the transaction information and the resource deduction information by the second processing device;
the verification unit is used for verifying the first digital signature according to the transaction information and the resource deduction information;
the processing unit is further used for generating a bill generation request if the first digital signature is successfully verified, wherein the bill generation request comprises transaction information, resource deduction information and a first digital signature;
and the sending unit is used for sending a bill generation request to the blockchain network so as to enable the blockchain network to verify the first digital signature according to the transaction information and the resource deduction information, and after the verification is successful, generating a bill comprising the transaction information and the resource deduction amount.
For the embodiments and the advantages of the bill processing device to solve the problems, reference may be made to the method and the advantages described in the first aspect, and repeated details are not repeated.
A third aspect of embodiments of the present invention provides a processing device, comprising a processor and a memory, the processor and the memory being connected to each other, wherein the memory is configured to store a computer program, the computer program comprises program instructions, and the processor is configured to call the program instructions to execute the method described in the first aspect. For the embodiments and the advantages of the processing device to solve the problems, reference may be made to the method and the advantages described in the first aspect, and repeated details are not repeated.
A fourth aspect of embodiments of the present invention provides a computer storage medium storing a computer program comprising program instructions that, when executed by a processor, cause the processor to perform the method as described in the first aspect.
By adopting the embodiment of the invention, the first information comprising the resource deduction information is received by the first processing equipment, then the bill generation request is generated, and the bill generation request is sent to the blockchain network, so that the blockchain network generates the bill comprising the transaction information and the resource deduction amount. Based on the scheme, the bill can be generated after the tax payment is finished, so that the risk that the bill cannot be reimbursed is reduced.
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 are briefly introduced below, and it is obvious that the drawings in the following description are some embodiments of the present invention, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without creative efforts.
Fig. 1 is a schematic structural diagram of a block chain according to an embodiment of the present invention;
fig. 2 is a schematic structural diagram of a blockchain network according to an embodiment of the present invention;
FIG. 3 is a schematic flow chart of a bill processing method according to an embodiment of the present invention;
FIG. 4 is a block link point structure according to an embodiment of the present invention;
FIG. 5 is a schematic flow chart of a bill processing method according to an embodiment of the present invention;
FIG. 6 is a schematic flow chart of a bill processing method according to an embodiment of the present invention;
FIG. 7 is a schematic flow chart diagram of a bill processing method according to an embodiment of the present invention;
fig. 8 is an application scenario diagram of a bill processing method according to an embodiment of the present invention;
FIG. 9 is a schematic structural diagram of a bill handling apparatus according to an embodiment of the present invention;
fig. 10 is a schematic structural diagram of a processing apparatus according to an embodiment of the present 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 terms "first," "second," "third," and the like in the description and in the claims, and in the above-described drawings, are used for distinguishing between different objects and not necessarily for describing a particular sequential or chronological order. Furthermore, the terms "comprises" and any variations thereof, are intended to cover non-exclusive inclusions. For example, a process, method, system, article, or apparatus that comprises a list of steps or modules is not limited to the listed steps or modules but may alternatively include other steps or modules not listed or inherent to such process, method, article, or apparatus.
Reference herein to "an embodiment" means that a particular feature, structure, or characteristic described in connection with the embodiment can be included in at least one embodiment of the invention. The appearances of the phrase in various places in the specification are not necessarily all referring to the same embodiment, nor are separate or alternative embodiments mutually exclusive of other embodiments. It is explicitly and implicitly understood by one skilled in the art that the embodiments described herein can be combined with other embodiments.
In order to better understand a bill processing method, a bill processing device, a bill processing apparatus, and a computer storage medium disclosed in the embodiments of the present invention, a system architecture to which the embodiments of the present invention are applicable is first described below.
Referring to fig. 1, as shown in fig. 1, the system architecture includes a first processing device, a second processing device, a third processing device, and a blockchain network. The first processing device may be a device corresponding to the seller. The second processing device may be a tax bureau compliant device. The third processing device may be a device corresponding to the buyer. The first processing device, the second processing device, and the third processing device may be a client or a server, which is not limited in this embodiment of the application. Wherein, the client can be any one of the following: a terminal, a separate Application, an API (Application Programming Interface), or an SDK (Software Development Kit). Among others, the terminal may include but is not limited to: smart phones (such as Android phones, iOS phones, etc.), tablet computers, portable personal computers, Mobile Internet Devices (MID for short), and the like, which are not limited in the embodiments of the present invention.
Wherein the blockchain network comprises a plurality of blockchain nodes. As shown in fig. 2, fig. 2 illustrates an example of a blockchain network including 3 blockchain nodes. The block link point may be a full node. A full node refers to a node that stores a complete blockchain. A full node is typically a high performance computing device. The Block Chain (Block Chain) is a Chain data structure which combines data blocks in a sequential connection mode according to a time sequence and is a distributed book which is cryptographically used for ensuring that the data cannot be tampered and forged. Multiple independent distributed nodes (i.e., blockchain nodes) maintain the same record. The block chain technology realizes decentralization and becomes a foundation for credible resource storage, transfer and transaction. As shown in fig. 2, each block link point includes a block chain therein. The block chain includes 3 blocks, i.e., block 1, block 2, and block 3, although the block chain may also include more than 3 blocks, and fig. 2 illustrates an example in which the block chain includes 3 blocks. When new data needs to be written into the block chain, each block chaining point in the block chain network adds a new block including the new data after the end block 3 of the block chain, and the new block is uplinked. A plurality of transaction records are recorded in each block, and simultaneously the transaction records contain the hash value (hash) of the previous block, all blocks are connected in sequence by storing the information in the previous block, so that a block chain is formed, and the block chain is difficult to tamper.
Referring to fig. 3, fig. 3 is a schematic flow chart of a bill processing method according to an embodiment of the present invention. As shown in FIG. 3, the bill processing method can include parts 301-304. Wherein:
301. the second processing device sends first information to the first processing device, wherein the first information comprises transaction information, resource deduction information and a first digital signature.
Before the second processing device sends the first information to the first processing device, the second processing device signs the transaction information and the resource deduction information to obtain a first digital signature. The second processing device generates first information including transaction information, resource deduction information, and a first digital signature. The resource deduction information includes a resource deduction amount deducted by a first user corresponding to the first processing device, and the resource deduction amount is determined according to the resource amount in the transaction information. Transaction information includes, but is not limited to, transaction submission time, amount of resources, transaction item, and transaction object.
The resource deduction information can be understood as a tax deduction certificate, the resource deduction amount can be understood as a tax deduction amount, and the resource amount can be understood as a transaction amount.
Optionally, the second processing device creates a key pair by using an asymmetric encryption algorithm, where the key pair includes a public key and a private key; asymmetric encryption algorithms herein may include, but are not limited to: the Elgamal algorithm (an asymmetric encryption algorithm), the Rabin algorithm (an asymmetric encryption algorithm), the Diffie-Hellman algorithm (an asymmetric encryption algorithm), the ECC algorithm (elliptic curve encryption algorithm). The second processing device may sign the transaction information and the resource deduction information using a private key of the second processing device to obtain a second digital signature. The second processing device generates first information including transaction information, resource deduction information and a first digital signature, and sends the first information to the first processing device.
302. And the first processing equipment verifies the first digital signature according to the transaction information and the resource deduction information, and if the verification is successful, the first processing equipment generates a bill generation request.
After the first processing device receives the first information, the first digital signature is verified according to the transaction information and the resource deduction information in the first information. If the verification is successful, the first processing device generates a ticket generation request comprising transaction information, resource deduction information and a first digital signature. If the verification fails, the flow is ended.
The following describes in detail how the first processing device verifies the first digital signature. For example, taking a hash algorithm as an example, the second processing device signs the transaction information and the resource deduction information to obtain a signature 1, and the second processing device generates information 1 including the transaction information, the resource deduction information and the signature 1. The second processing device sends information 1 to the first processing device. Accordingly, the first processing device receives the information 1, and the first processing device decrypts the signature 1 in the information 1 by using the public key of the second processing device to obtain the hash value 1. And the first processing device obtains a hash value 2 by adopting a hash algorithm on the transaction information and the resource deduction information in the information 1, and if the hash value 1 is the same as the hash value 2, the first processing device successfully verifies the information 1. The first processing device generates a ticket generation request including transaction information, resource deduction information, and a first digital signature.
303. The first processing device sends a ticket generation request to the blockchain network.
304. And the blockchain network verifies the first digital signature in the bill generation request, and if the verification is successful, the blockchain network generates a bill comprising the transaction information and the resource deduction amount.
And after receiving the bill generation request, the block chain network verifies the first digital signature according to the transaction information and the resource deduction information in the bill generation request. If the verification is successful, generating a bill comprising transaction information and resource deduction amount by the block chain network; if the verification fails, the flow is ended. The method for verifying the first digital signature according to the transaction information and the resource deduction information in the ticket generating request refers to the method set forth in step 302, which is not described in detail in the embodiments of the present invention. Wherein the ticket can be understood as an invoice.
It should be noted that each user may correspond to an address for storing a ticket in a block link point. For example, the user corresponding to the third processing device corresponds to a first address for storing the ticket in the blockchain node. After the bill is generated at the block link point, the generated bill is stored in the first address. And the user corresponding to the third processing equipment can view the bills generated by the block chain node on the corresponding terminal equipment. Accordingly, the user of the first processing device also corresponds to a second address for storing the ticket in the block link point. The user of the second processing device also corresponds to a third address for storing notes in the block link points.
For example, as shown in fig. 4, the blockchain network includes blockchain network nodes 1 to blockchain nodes 3. Blockchain node 1 receives the ticket generation request, which includes the transaction information, the resource deduction information and the first digital signature, and forwards the ticket generation request to node 2 and node 3. After each blockchain node receives the bill generation request, a new block including the bill generation request can be generated by one blockchain node (for example, the blockchain node which proves the most workload) first, and then the new block is broadcasted to other blockchain nodes. And after all the block chain nodes receive the new block, verifying the first digital signature according to the transaction information and the resource deduction information in the bill generation request, and if verification is successful, generating a bill comprising the transaction information and the resource deduction amount by the block chain nodes. Taking note 1 as an example, the block link point stores the generated note 1 in the first address of the user corresponding to the third processing device, and chains up the new block.
As an optional implementation, the first processing device may further sign the ticket generation request to obtain a second digital signature. The first processing device sends the ticket generation request and the second digital signature to the blockchain network. Accordingly, the blockchain network receives the ticket generation request and the second digital signature. And the block chain network verifies the second digital signature according to the bill generation request and verifies the first digital signature in the bill generation request after the verification is successful. If the first digital signature is successfully verified, the blockchain network generates a ticket including transaction information and a resource deduction amount. For example, the first processing device may sign the ticket generation request with a private key of the first processing device, resulting in a second digital signature. The blockchain network may verify the second digital signature with a public key of the first processing device and the ticket generation request.
For example, after each blockchain node receives the ticket generation request and the second digital signature, a certain blockchain node (e.g., the most workload proving blockchain node) may verify the second digital signature according to the ticket generation request. And if the second digital signature passes the verification, verifying the first digital signature according to the transaction information and the resource deduction information in the bill generation request. And if the first digital signature is successfully verified, generating a new block comprising the bill generation request and the second digital signature, and broadcasting the new block to other block chain nodes. And after receiving the new block, the other block chain nodes verify the second digital signature according to the bill generation request. And if the second digital signature passes the verification, verifying the first digital signature according to the transaction information and the resource deduction information in the bill generation request. After the second digital signature and the second digital signature are verified by the preset number of block chain nodes, generating bills comprising transaction information and resource deduction amount by all the block chain nodes, and adding the new blocks in the block chain. Taking note 1 as an example, the block link point stores the generated note 1 in the first address of the user corresponding to the third processing device, and chains up the new block.
Based on the alternative mode, the second digital signature generated by signing the bill generation request is sent to the block chain network, so that the safety of the bill generation request can be enhanced.
It can be seen that, by the method described in fig. 3, the first processing device receives the first information including the resource deduction information, and then generates a ticket generation request and sends the ticket generation request to the blockchain network, so that the blockchain network generates a ticket including the transaction information and the resource deduction amount. Based on the scheme, the bill can be generated after the tax payment is finished, so that the risk that the bill cannot be reimbursed is reduced.
Referring to fig. 5, fig. 5 is a schematic flow chart of a bill processing method according to an embodiment of the present invention. As shown in FIG. 5, the bill processing method can include the steps 501-508. Wherein:
501. the first processing device determines the transaction submission time length according to the transaction submission time in the transaction information.
The first processing device determines a transaction submission time from the transaction information and detects a duration of the transaction submission.
502. The first processing device detects whether the transaction submission time length reaches a first preset time length.
If the duration reaches a first preset duration, the first processing device executes step 503; if the first preset time length is not reached, the process is ended.
The first preset duration may be fixed, by default. Alternatively, the first preset duration may be flexibly variable. If the first preset time length is flexible, the first preset time length needs to be determined through a preset algorithm, and after the first preset time length is determined, whether the transaction submitting time length reaches the first preset time length is detected.
As an optional implementation manner, the specific implementation manner of determining the first preset time period includes steps 11) to 14):
11) the first processing device determines a transaction object from the transaction information.
12) The first processing device obtains the total transaction times and transaction failure times of the transaction object in a preset time period.
13) The first processing equipment determines a first credit level of the transaction object according to the total transaction times and the transaction failure times of the transaction object in a preset time period.
14) The first processing device determines a first preset time length corresponding to the first credit grade according to the corresponding relation between the preset credit grade and the preset time length.
In the corresponding relation between the credit levels and the preset time length, the preset time length corresponding to the first credit level is smaller than the preset time length corresponding to the second credit level, and the first credit level is larger than the second credit level.
The transaction information includes transaction objects, transaction items, transaction time, and the like. The transaction object may include a buyer user and a seller user. The first processing device in step 11) determines the buyer user in particular from the transaction information. After the first processing device determines the buyer user, the total number of transactions and the number of transaction failures of the buyer user within a preset time period can be obtained. The preset time period may be preset by the first processing device user or may be a default setting. For example, the preset time period may be 3 days, 5 days, 7 days, one month, etc. After acquiring the total transaction times and the transaction failure times of the buyer user in the preset time period, the first processing device determines a first credit level of the buyer user according to the total transaction times and the transaction failure times of the buyer user in the preset time period.
Alternatively, the first processing device may determine a first ratio of the number of transaction failures of the buyer user to the total number of transactions. And determining the user credit level corresponding to the ratio range to which the first ratio belongs according to the corresponding relation between the pre-stored ratio range and the user credit level, wherein the user credit level is the first credit level of the buyer user. For example, the first processing device prestores a ratio range and a user credit rating corresponding relationship, as shown in table 1. The corresponding relation between the ratio range of 0-20% and the credit rating of 1, the corresponding relation between the ratio range of 20-40% and the credit rating of 2, the corresponding relation between the ratio range of 40-60% and the credit rating of 3, the corresponding relation between the ratio range of 60-80% and the credit rating of 4, and the corresponding relation between the ratio range of 80-100% and the credit rating of 5. Where credit level 1 is higher than credit level 2 and credit level 2 is higher than credit level 3. By analogy, the credit level 1 to the credit level 5 are reduced step by step. The higher the ratio range of the transaction failure times to the total transaction times, the lower the corresponding credit level.
As shown in table 1 below, if the first processing device determines that the ratio of the number of transaction failures of the purchaser user to the total number of transactions is 15%, the first processing device determines that the credit rating of the purchaser user is credit rating 1. If the first processing device determines that the ratio of the number of transaction failures of the buyer user to the total number of transactions is 70%, the first processing device determines that the credit rating of the buyer user is credit rating 4.
TABLE 1
The ratio of the number of failed transactions to the total number of transactions User credit rating
0~20% Credit level 1
20%~40% Credit level 2
40%~60% Credit level 3
60%~80% Credit level 4
80%~100% Credit rating of 5
After the first processing device determines the first credit level of the buyer user, the first processing device determines a first preset time length corresponding to the first credit level according to the corresponding relation between the preset credit level and the preset time length. Wherein the corresponding relationship may be set by a user corresponding to the first processing device (i.e., a buyer user). Wherein, the preset duration in the step 14) may be preset by the user of the first processing device. For example, the preset time period may be 1 day, 3 days, 5 days, 7 days, 10 days, etc.
For example, the first processing device prestores a correspondence relationship between the credit rating and the preset time duration, as shown in table 2 below. The credit rating 1 corresponds to the preset duration 1, the credit rating 2 corresponds to the preset duration 2, the credit rating 3 corresponds to the preset duration 3, the credit rating 4 corresponds to the preset duration 4, and the credit rating 5 corresponds to the preset duration 5. Where credit level 1 is higher than credit level 2 and credit level 2 is higher than credit level 3. By analogy, the credit level 1 to the credit level 5 are reduced step by step. The preset time length 1 is less than the preset time length 2, and the preset time length 2 is less than the preset time length 3. By analogy, the preset time length 1-5 are increased in sequence. The higher the credit rating, the smaller the corresponding preset duration.
TABLE 2
User credit rating Preset duration
Credit level 1 Preset duration 1
Credit level 2 Preset duration 2
Credit level 3 Preset duration 3
Credit level 4 Preset duration 4
Credit rating of 5 Preset duration 5
Based on the optional mode, the bill can be generated quickly according to the credit level of the user, and the bill generation efficiency is improved.
As an optional implementation manner, another specific implementation manner of determining the first preset time period is described, and the specific implementation manner includes steps 21) to 23):
21) the first processing device determines a transaction item from the transaction information.
22) The first processing device determines a first category of the transaction item.
The type of the transaction article is judged according to the attribute of the transaction article, particularly the special type of articles such as pre-sold clothes, virtual goods and the like.
23) The first processing equipment determines a first preset time corresponding to the first category according to the corresponding relation between the preset article category and the preset time.
The first processing device obtains the transaction articles in the transaction information, determines a first category of the transaction articles, and determines a first preset time length corresponding to the first category according to the corresponding relation between the preset article category and the preset time length. For example, the first processing device prestores a corresponding relationship between the article type and a preset time length. Wherein the corresponding relationship may be set by a user corresponding to the first processing device (i.e., a buyer user).
As shown in table 3 below, the category 1 corresponds to the preset duration 1, the category 2 corresponds to the preset duration 2, the category 3 corresponds to the preset duration 3, the category 4 corresponds to the preset duration 4, and the category 5 corresponds to the preset duration 5. Wherein the first processing device user can set the preset time length for the characteristics of different transaction article types. For example, if the category 1 is a virtual commodity, the corresponding preset duration 1 may be set to 2 hours, and the refund is not supported by the telephone fee recharge and the virtual game currency recharge. The first processing device may send the first information to the second processing device after the transaction is completed, when the transaction is completed for 2 hours. For another example, if the category 2 is pre-sold goods, the corresponding preset time period may be set to 30 days, and the specific preset time period may be determined according to the pre-sold time period of the pre-sold goods, which is not limited in the embodiment of the present invention.
TABLE 3
Transaction item categories Preset duration
Class 1 Preset duration 1
Class 2 Preset duration 2
Class 3 Preset duration 3
Class 4 Preset duration 4
Class 5 Preset duration 5
Based on the optional mode, the bill can be generated quickly according to the category of the transaction article, and the bill generation efficiency is improved.
503. And if the transaction submitting time length reaches a first preset time length, the first processing equipment sends second information to the second processing equipment, wherein the second information comprises transaction information.
Before the first processing device sends the second information to the second processing device, the first processing device receives the transaction submitted by the third processing device. The first processing device acquires transaction information corresponding to the transaction and generates second information according to the transaction information. The transaction information includes, but is not limited to, transaction submission time, resource amount, transaction item, and transaction object. The transaction corresponding to the transaction information may be any one of the transactions.
Optionally, the first processing device may further sign the transaction information to obtain a third digital signature. The first processing device generates second information including the transaction information and a third digital signature and sends the second information to the second processing device. Correspondingly, after receiving the second information, the second processing device verifies the third digital signature according to the transaction information, and if the verification is successful, step 504 is executed. If the verification fails, the flow is ended. For example, the first processing device may sign the transaction information with a private key of the first processing device to obtain a third digital signature. The blockchain network may verify the third digital signature with the public key of the first processing device and the transaction information.
504. And the second processing equipment determines the resource deduction amount according to the resource amount in the transaction information, and generates first information after deducting the resource deduction amount for the first user corresponding to the first processing equipment.
And after the second processing equipment receives the second information, determining the resource deduction amount according to the resource amount in the transaction information in the second information. The second processing device generates first information after deducting the resource deduction amount from the first user corresponding to the first processing device, wherein the first information comprises transaction information, resource deduction information and a first digital signature. The resource amount can be understood as a transaction amount, and the resource deduction amount can be understood as a deduction amount.
505. The second processing device sends first information to the first processing device, wherein the first information comprises transaction information, resource deduction information and a first digital signature.
506. And the first processing equipment verifies the first digital signature according to the transaction information and the resource deduction information, and if the verification is successful, a bill generation request is generated.
507. The first processing device sends a ticket generation request to the blockchain network.
508. And the blockchain network verifies the first digital signature in the bill generation request, and if the verification is successful, the blockchain network generates a bill comprising the transaction information and the resource deduction amount.
The steps 505 to 508 in the embodiment of the present invention may specifically refer to the execution processes of the steps 301 to 304 in the above embodiment, and the embodiment of the present invention is not described again.
It can be seen that by the method described in fig. 5, the first processing device determines the time to send the second information by determining the first preset duration by the credit rating of the first user or by the category of the transaction item. Based on this alternative, the first processing device does not generate and transmit the second information for each transaction immediately upon receipt of the transaction.
Referring to fig. 6, fig. 6 is a schematic flow chart of a bill processing method according to an embodiment of the present invention. As shown in FIG. 6, the bill processing method can comprise 601-605 parts. Wherein:
601. the second processing device sends first information to the first processing device, wherein the first information comprises transaction information, resource deduction information and a first digital signature.
Step 601 may specifically refer to the execution process of step 301 in the above embodiments, and the embodiments of the present invention are not described again.
602. And the first processing equipment verifies the first digital signature according to the transaction information and the resource deduction information, and if the verification is successful, an acquisition request is sent to the third processing equipment.
The first processing device verifies the first digital signature based on the transaction information and the resource deduction information. And if the verification is successful, the first processing device sends an acquisition request to the third processing device, wherein the acquisition request is used for acquiring the ticket collector information from the third processing device. If the verification fails, the flow is ended. The specific method for verifying the first digital signature by the first processing device refers to the verification method set forth in step 302, which is not described in detail in the embodiments of the present invention.
The information of the ticket collector includes, but is not limited to, the name of the purchaser, the taxpayer identification number, the address, the telephone, the bank account, the account number, etc.
603. The first processing device generates a ticket generation request.
After the first processing device sends the obtaining request to the third processing device, if the obtaining of the ticket collecting party information is successful within the second preset time length, the ticket generating request generated by the first processing device further comprises the ticket collecting party information. And if the ticket acquirer information acquisition in the second preset time length fails, the ticket generation request generated by the first processing device further comprises preset ticket acquirer information. The preset ticket collector information may be preset by the first processing device user (i.e., the seller user). For example, only one item of information may be set, such as filling out an individual at a ticket name.
The second preset time period may be preset by the user of the first processing device. For example, the second preset time period may be 1 hour, 3 hours, 10 hours, 1 day, 3 days, etc.
604. The first processing device sends a ticket generation request to the blockchain network.
605. And the block chain network verifies the first digital signature in the bill generation request, and if the verification is successful, the block chain network generates the bill according to the bill generation request.
The blockchain network receives a bill generation request from the first processing device, and if the bill generation request comprises transaction information, resource deduction information, a first digital signature and ticket collector information, the blockchain network verifies the first digital signature according to the transaction information and the resource deduction information. If the verification is successful, the blockchain network generates a bill comprising the transaction information, the resource deduction amount and the ticket collector information. If the verification fails, the flow is ended. And if the bill generation request comprises transaction information, resource deduction information, a first digital signature and preset bill collector information, the block chain network verifies the first digital signature according to the transaction information and the resource deduction information. If the verification is successful, the block chain network generates a bill comprising the transaction information, the resource deduction amount and the preset ticket collector information. If the verification fails, the flow is ended. The method for generating the ticket for the transaction in the blockchain network refers to the method set forth in step 304, and the embodiment of the present invention is not described in detail.
It can be seen that by the method described in fig. 6, in this solution, the ticket acquirer information is obtained by the third processing device before the ticket generation request is generated; when the acquisition is successful, a bill can be generated for the user according to the requirement of the user; and when the acquisition fails, generating a default preset bill for the user. Based on this alternative, it can be guaranteed that a ticket is generated for each transaction.
Referring to fig. 7, fig. 7 is a schematic flow chart of a bill processing method according to an embodiment of the present invention. As shown in FIG. 7, the bill processing method can comprise 701-706 parts. Wherein:
701. the first processing device sends second information to the second processing device, wherein the second information comprises transaction information and resource deduction information.
Specifically, the first processing device calculates a resource deduction amount (i.e. a tax deduction amount) according to the resource amount (i.e. a transaction amount) in the transaction information and actively completes tax payment. After completing the tax payment, the first processing device may obtain resource deduction information including the amount of the resource, the transaction item, and the resource deduction amount. The first processing device generates second information including the transaction information and the resource deduction information and sends the second information to the second processing device.
702. And the second processing equipment verifies the resource deduction amount in the resource deduction information according to the transaction information, and if the verification is successful, the second processing equipment generates the first information.
And after the second processing equipment receives the second information, checking the resource deduction information. If the verification is successful, the second processing device generates first information comprising the transaction information, the resource deduction information and the first digital signature. If the verification fails, the flow is ended.
How the second processing device checks the resource deduction amount is described in detail below. For example, the second processing device first acquires the resource amount 1 in the second information and the resource deduction amount 1 in the resource deduction information. And the second processing equipment calculates a resource deduction amount 2 according to the resource amount 1. The second processing device will then compare the resource deduction 1 with the resource deduction 2. And if the resource quantity deduction 1 is consistent with the resource quantity deduction 2, the second processing equipment successfully verifies the resource deduction quantity.
703. The second processing device sends first information to the first processing device, wherein the first information comprises transaction information, resource deduction information and a first digital signature.
Optionally, the second processing device may not send the plaintext (i.e., the transaction information and the resource deduction information) to the first processing device, and may only send the first digital signature to the first processing device. Accordingly, taking the hash algorithm as an example, after receiving the first digital signature, the first processing device decrypts the first digital signature to obtain the hash value 1. And if the first processing device finds the hash value 2 which is the same as the hash value 1 in the pre-stored hash values, determining that the first processing device successfully verifies the first digital signature. The first processing device acquires transaction information and resource deduction information corresponding to the hash value 2, and generates a bill generation request according to the transaction information, the resource deduction information and the first digital signature.
The pre-stored hash value is obtained by performing hash calculation on transaction information and resource deduction information after the first processing device actively completes tax payment.
704. And the first processing equipment verifies the first digital signature according to the transaction information and the resource deduction information, and if the verification is successful, a bill generation request is generated.
705. The first processing device sends a ticket generation request to the blockchain network.
706. And the blockchain network verifies the first digital signature in the bill generation request, and if the verification is successful, the blockchain network generates a bill comprising the transaction information and the resource deduction amount.
The steps 703 to 706 in the embodiment of the present invention may specifically refer to the execution processes of steps 301 to 304 in the above embodiment, and are not described again in the embodiment of the present invention.
As can be seen from the method described in fig. 7, in this technical solution, since the second information sent by the first processing device includes the resource deduction information, the second processing device only needs to check the resource deduction amount of the resource deduction information, and does not need to perform the deduction operation. Based on this alternative, the operation steps of the second processing device can be reduced, and the load can be reduced.
In order to better understand the embodiments of the present invention, the following describes the embodiments of the method in conjunction with practical application scenarios. For example, the buyer user submits transaction 1 on the shopping software as shown in FIG. 8. The seller processing device acquires that the total transaction times of the buyer user in one month in the seller shop is 8 and the transaction failure times is 1. The first processing device may determine a first ratio of a number of transaction failures of the buyer user to a total number of transactions. The seller processing arrangement then determines that the ratio of the number of transaction failures of the buyer user to the total number of transactions is 12.5%. As shown in table 4 below, the seller processing device determines that the ratio range to which 12.5% belongs is 0-20% according to the corresponding relationship between the pre-stored ratio range and the user credit level, and the buyer credit level corresponding to the ratio range is credit level 1. And then, according to the table 5, determining that the preset time length corresponding to the credit level 1 is 1 day according to the corresponding relation between the user credit level and the preset time length. After the seller processing device again determines that the preset duration is 1 day, it detects that the transaction 1 submission duration has reached 1 day. The seller processing device signs the transaction information 1, resulting in a signature 1. As shown in fig. 7, the first processing device sends information 1 to the taxing authority processing device, where the information 1 includes transaction information 1 and a signature 1. Accordingly, the tax authority processing device receives the information 1 and verifies the signature 1 in the information 1. And after the successful verification, the tax bureau processing equipment calculates the resource deduction amount according to the resource amount in the transaction information 1 and finishes tax deduction on the transaction 1. The tax bureau processing equipment generates resource deduction information 1 including the amount of the resource deduction, the amount of the resource, and the transaction item. And the tax bureau processing equipment signs the information 1 and the resource deduction information 1 to obtain a signature 2. The tax authority processing device then generates information 2 including the transaction information 1, the tax deduction voucher 1 and the signature 2 and sends this information 2 to the first processing device. The first processing device verifies the signature 2 in the information 2 after receiving the information 2. The first processing device sends an acquisition request to the buyer processing device to acquire the collector information after successfully verifying the signature 2. The first processing device successfully acquires the ticket collector information within 1 hour. The first processing device generates a ticket generation request comprising transaction information 1, resource deduction information 1, signature 2 and ticket collector information. The first processing device signs the ticket generation request, resulting in signature 3. The first processing device sends the ticket generation request with the signature 3 to the blockchain network. Accordingly, after receiving the request 2 and the signature 3, the blockchain network verifies the signature 3, and then verifies the signature 2 after the verification is successful. The blockchain network generates a ticket including transaction information 1, resource deduction amount and ticket collector information after successfully verifying the signature 2. The blockchain network stores the generated ticket in the buyer address.
TABLE 4
The ratio of the number of failed transactions to the total number of transactions User credit rating
0~20% Credit level 1
20%~40% Credit level 2
40%~60% Credit level 3
60%~80% Credit level 4
80%~100% Credit rating of 5
TABLE 5
User credit rating Preset duration
Credit level 1 1 day
Credit level 2 5 days
Credit level 3 7 days
Credit level 4 10 days
Credit rating of 5 15 days
Referring to fig. 9, fig. 9 is a schematic structural diagram of a bill processing device according to an embodiment of the present application. The note processing device shown in fig. 9 may be used to perform some or all of the functions of the processing apparatus in the method embodiments described above in fig. 3, 5, 6 and 7. The bill processing apparatus shown in fig. 9 may include a sending unit 901, a receiving unit 902, a verifying unit 903, and a processing unit 904. Wherein:
a receiving unit 902, configured to receive first information sent by a second processing device;
a verification unit 903, configured to verify the first digital signature according to the transaction information and the resource deduction information;
if the first digital signature is successfully verified, the processing unit 904 is configured to generate a ticket generation request;
a sending unit 901, configured to send a ticket generation request to the blockchain network.
As an optional implementation manner, the processing unit 904 is further configured to sign the ticket generation request, so as to obtain a second digital signature;
the sending unit 901 is further configured to send the ticket generation request and the second digital signature to the blockchain network.
As an optional implementation manner, before sending the first information to the second processing device, the processing unit 904 is further configured to determine a transaction submission time length according to the transaction submission time in the transaction information;
the processing unit 904 is further configured to detect whether the transaction submission time length reaches a first preset time length;
if the transaction submission time reaches the first preset time, the sending unit 901 is further configured to send a second message to the second processing device.
As an optional implementation manner, before detecting whether the transaction submission time reaches the first preset time, the processing unit 904 is further configured to determine a transaction object from the transaction information;
the processing unit 904 is further configured to obtain a total transaction number and a transaction failure number of the transaction object in a preset time period;
the processing unit 904 is further configured to determine a first credit level of the transaction object according to the total transaction times and the transaction failure times of the transaction object in a preset time period;
the processing unit 904 is further configured to determine a first preset duration corresponding to the first credit level according to a corresponding relationship between the preset credit level and the preset duration.
As an optional implementation manner, before detecting whether the transaction submission time length reaches the first preset time length, the processing unit 904 is further configured to determine a transaction item from the transaction information;
a processing unit 904 for determining a first category of the transaction item;
the processing unit 904 is further configured to determine a first preset time duration corresponding to the first category according to a corresponding relationship between the preset article category and the preset time duration.
As an optional implementation manner, the sending unit 901 is further configured to send an acquisition request to a third processing device.
As an optional implementation manner, before receiving the first information sent by the second processing device, the sending unit 901 is further configured to send second information including the transaction information and the resource deduction information to the second processing device.
It should be noted that, for details that are not mentioned in the embodiment corresponding to fig. 9 and the specific implementation manner of the step executed by each unit, reference may be made to the embodiments shown in fig. 3, fig. 5, fig. 6, and fig. 7 and the foregoing description, and details are not repeated here.
Referring to fig. 10, fig. 10 is a schematic structural diagram of a processing device according to an embodiment of the present invention, where the processing device includes a processor 1001, a memory 1002, and a communication interface 1003, and the processor 1001, the memory 1002, and the communication interface 1003 are connected by one or more communication buses.
The processor 1001 is configured to support the processing device to perform the corresponding functions of the processing device in the methods of fig. 3, 5, 6 and 7. The processor 1001 may be a Central Processing Unit (CPU), a Network Processor (NP), a hardware chip, or any combination thereof.
The memory 1002 is used to store program codes and the like. The memory 1002 may include volatile memory (volatile memory), such as Random Access Memory (RAM); the memory 1002 may also include a non-volatile memory (non-volatile memory), such as a read-only memory (ROM), a flash memory (flash memory), a Hard Disk Drive (HDD), or a solid-state drive (SSD); the memory 1002 may also comprise a combination of the above-described types of memory.
The communication interface 1003 is used for receiving data and for transmitting data. For example, the communication interface 1003 is used to receive first information transmitted by the second processing device, or is used to transmit second information to the second processing device, and the like.
In an embodiment of the present invention, the processor 1001 may call the program code stored in the memory 1002 to perform the following operations:
a communication interface 1003, configured to receive first information sent by a second processing device;
a processor 1001 configured to verify the first digital signature according to the transaction information and the resource deduction information;
if the first digital signature is successfully verified, the processor 1001 is further configured to generate a ticket generation request, where the ticket generation request includes transaction information, resource deduction information, and the first digital signature;
a communication interface 1003 for sending a ticket generation request to the blockchain network.
As an optional implementation, the processor 1001 is further configured to sign the ticket generation request to obtain a second digital signature;
the communication interface 1003 is further configured to send the ticket generation request and the second digital signature to the blockchain network.
As an optional implementation manner, before sending the first information to the second processing device, the processor 1001 is further configured to determine a transaction submission time length according to the transaction submission time in the transaction information;
the processor 1001 is further configured to detect whether the transaction submission time length reaches a first preset time length;
if the transaction submitting time length reaches the first preset time length, the communication interface 1003 is further configured to send second information to the second processing device.
As an optional implementation manner, before detecting whether the transaction submission time length reaches the first preset time length, the processor 1001 is further configured to determine a transaction object from the transaction information;
the processor 1001 is further configured to obtain a total transaction number and a transaction failure number of the transaction object in a preset time period;
the processor 1001 is further configured to determine a first credit level of the transaction object according to the total transaction times and the transaction failure times of the transaction object within a preset time period;
the processor 1001 is further configured to determine a first preset duration corresponding to the first credit level according to a corresponding relationship between the preset credit level and the preset duration.
As an optional implementation manner, before detecting whether the transaction submission time length reaches the first preset time length, the processor 1001 is further configured to determine a transaction item from the transaction information;
a processor 1001 for determining a first category of a transaction item; the processor 1001 is further configured to determine a first preset time duration corresponding to the first category according to a corresponding relationship between the preset item category and the preset time duration.
As an optional implementation, the communication interface 1003 is further configured to send an acquisition request to the third processing device.
As an optional implementation manner, before receiving the first information sent by the second processing device, the communication interface 1003 is further configured to send second information including the transaction information and the resource deduction information to the second processing device.
Further, the processor 1001 may further cooperate with the communication interface 1003 to perform corresponding operations in the embodiments shown in fig. 3, fig. 5, fig. 6, and fig. 7, which may specifically refer to the description in the method embodiments and is not described herein again.
Embodiments of the present invention also provide a computer-readable storage medium, which can be used to store computer software instructions for the processing device in the embodiments shown in fig. 3, fig. 5, fig. 6, and fig. 7, and which contain programs designed for the processing device in the above-mentioned embodiments.
The computer readable storage medium includes, but is not limited to, flash memory, hard disk, solid state disk.
Those of ordinary skill in the art would appreciate that the various illustrative elements and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware or combinations of computer software and electronic hardware. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present application.
In the above embodiments, the implementation may be wholly or partially realized by software, hardware, firmware, or any combination thereof. When implemented in software, may be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. The procedures or functions according to the embodiments of the invention are brought about in whole or in part when the computer program instructions are loaded and executed on a computer. The computer may be a general purpose computer, a special purpose computer, a network of computers, or other programmable device. The computer instructions may be stored on or transmitted over a computer-readable storage medium. The computer instructions may be transmitted from one website site, computer, server, or data center to another website site, computer, server, or data center by wire (e.g., coaxial cable, fiber optic, Digital Subscriber Line (DSL)) or wirelessly (e.g., infrared, wireless, microwave, etc.). The computer-readable storage medium can be any available medium that can be accessed by a computer or a data storage device, such as a server, a data center, etc., that incorporates one or more of the available media. The usable medium may be a magnetic medium (e.g., floppy Disk, hard Disk, magnetic tape), an optical medium (e.g., DVD), or a semiconductor medium (e.g., Solid State Disk (SSD)), among others.
The above description is only for the specific embodiments of the present invention, but the scope of the present invention is not limited thereto, and any person skilled in the art can easily conceive of the changes or substitutions within the technical scope of the present invention, and the changes or substitutions should be covered within the scope of the present invention. Therefore, the protection scope of the present invention shall be subject to the protection scope of the claims.

Claims (10)

1. A method of processing a document for application to a first processing device, the method comprising:
receiving first information sent by second processing equipment, wherein the first information comprises transaction information, resource deduction information and a first digital signature, the resource deduction information comprises resource deduction amount deducted by a first user corresponding to the first processing equipment, the resource deduction amount is determined according to the resource amount in the transaction information, and the first digital signature is obtained by signing the transaction information and the resource deduction information by the second processing equipment;
verifying the first digital signature according to the transaction information and the resource deduction information;
if the first digital signature is successfully verified, generating a bill generation request, wherein the bill generation request comprises the transaction information, the resource deduction information and the first digital signature;
and sending the bill generation request to a blockchain network so that the blockchain network verifies the first digital signature according to the transaction information and the resource deduction information, and after verification is successful, generating a bill comprising the transaction information and the resource deduction amount.
2. The method of claim 1, further comprising:
signing the bill generation request to obtain a second digital signature;
the sending the ticket generation request to a blockchain network includes:
and sending the bill generation request and the second digital signature to the blockchain network, so that the blockchain network verifies the second digital signature according to the bill generation request, and after verification is successful, verifying the first digital signature according to the transaction information and the resource deduction information.
3. The method according to claim 1 or 2, wherein before receiving the first information sent by the second processing device, the method further comprises:
determining transaction submission time length according to the transaction submission time in the transaction information;
detecting whether the transaction submission time reaches a first preset time;
if the transaction submitting duration reaches the first preset duration, second information including the transaction information is sent to second processing equipment, so that the second processing equipment determines the resource deduction amount according to the resource amount in the transaction information, generates the first information after deducting the resource deduction amount for a first user corresponding to the first processing equipment, and sends the first information to the first processing equipment.
4. The method of claim 3, wherein before detecting whether the transaction submission time period reaches a first preset time period, the method further comprises:
determining a transaction object from the transaction information;
acquiring the total transaction times and transaction failure times of the transaction object in a preset time period;
determining a first credit level of the transaction object according to the total transaction times and the transaction failure times of the transaction object in a preset time period;
determining a first preset time length corresponding to the first credit grade according to the corresponding relation between the preset credit grade and the preset time length;
in the correspondence between the credit levels and the preset duration, the preset duration corresponding to the first credit level is less than the preset duration corresponding to the second credit level, and the first credit level is greater than the second credit level.
5. The method of claim 3, wherein before detecting whether the transaction submission time period reaches a first preset time period, the method further comprises:
determining a transaction item from the transaction information;
determining a first category of the transaction item;
and determining the first preset time corresponding to the first category according to the corresponding relation between the preset article category and the preset time.
6. The method of claim 1 or 2, wherein after the first digital signature is successfully verified, the method further comprises:
sending an acquisition request to third processing equipment, wherein the acquisition request is used for requesting to acquire ticket collector information;
if the ticket acquirer information is received from the third processing device within a second preset time after the acquisition request is sent to the third processing device, the ticket generation request further includes the ticket acquirer information, and the ticket generated by the block chain network further includes the ticket acquirer information;
if the ticket acquirer information is not received within the second preset time after the acquisition request is sent to the third processing device, the ticket generation request further includes preset ticket acquirer information, and the ticket generated by the block chain network further includes the preset ticket acquirer information.
7. The method according to claim 1 or 2, wherein before receiving the first information sent by the second processing device, the method further comprises:
and sending second information comprising the transaction information and the resource deduction information to second processing equipment, so that the second processing equipment verifies the resource deduction amount in the resource deduction information according to the transaction information, generates the first information after the verification is passed, and sends the first information to the first processing equipment.
8. A bill handling apparatus comprising:
a receiving unit, configured to receive first information sent by a second processing device, where the first information includes transaction information, resource deduction information, and a first digital signature, the resource deduction information includes a resource deduction amount deducted by a first user corresponding to the first processing device, the resource deduction amount is determined according to a resource amount in the transaction information, and the first digital signature is obtained by the second processing device signing the transaction information and the resource deduction information;
the verification unit is used for verifying the first digital signature according to the transaction information and the resource deduction information;
the processing unit is used for generating a bill generation request if the first digital signature is successfully verified, wherein the bill generation request comprises the transaction information, the resource deduction information and the first digital signature;
a sending unit, configured to send the ticket generation request to a blockchain network, so that the blockchain network verifies the first digital signature according to the transaction information and the resource deduction information, and after verification is successful, generates a ticket including the transaction information and the resource deduction amount.
9. A processing device comprising a processor and a memory, the processor and the memory being interconnected, wherein the memory is configured to store a computer program comprising program instructions, and wherein the processor is configured to invoke the program instructions to perform the method of any of claims 1 to 7.
10. A computer storage medium, characterized in that the computer storage medium stores a computer program comprising program instructions that, when executed by a processor, cause the processor to perform the method according to any of claims 1-7.
CN201910908338.XA 2019-09-24 2019-09-24 Bill processing method, bill processing device, bill processing equipment and computer storage medium Active CN110598457B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910908338.XA CN110598457B (en) 2019-09-24 2019-09-24 Bill processing method, bill processing device, bill processing equipment and computer storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910908338.XA CN110598457B (en) 2019-09-24 2019-09-24 Bill processing method, bill processing device, bill processing equipment and computer storage medium

Publications (2)

Publication Number Publication Date
CN110598457A true CN110598457A (en) 2019-12-20
CN110598457B CN110598457B (en) 2023-11-24

Family

ID=68863024

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910908338.XA Active CN110598457B (en) 2019-09-24 2019-09-24 Bill processing method, bill processing device, bill processing equipment and computer storage medium

Country Status (1)

Country Link
CN (1) CN110598457B (en)

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108288222A (en) * 2018-03-05 2018-07-17 数字乾元科技有限公司 Property tax processing system and method based on block chain
CN109035019A (en) * 2018-07-11 2018-12-18 平安科技(深圳)有限公司 Bill business method, system, computer equipment and storage medium
CN109034924A (en) * 2018-08-16 2018-12-18 腾讯科技(深圳)有限公司 Electronic bill generation method, device, storage medium and computer equipment
CN109191272A (en) * 2018-08-17 2019-01-11 腾讯科技(深圳)有限公司 About the data processing method of electronic bill, device, storage medium and equipment
CN109359485A (en) * 2018-09-18 2019-02-19 深圳壹账通智能科技有限公司 Invoice data shared system and method based on block chain
CN109447648A (en) * 2018-12-07 2019-03-08 深圳市智税链科技有限公司 The method of recorded data zone block, accounting nodes and medium in block chain network
CN110046945A (en) * 2018-12-13 2019-07-23 阿里巴巴集团控股有限公司 Invoice creation method and device, electronic equipment based on block chain
CN110070443A (en) * 2019-04-23 2019-07-30 深圳前海微众银行股份有限公司 A kind of bill processing method and device based on block chain
US20190244186A1 (en) * 2017-03-10 2019-08-08 Tencent Technology (Shenzhen) Company Limited Electronic bill management method, apparatus, and storage medium

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20190244186A1 (en) * 2017-03-10 2019-08-08 Tencent Technology (Shenzhen) Company Limited Electronic bill management method, apparatus, and storage medium
CN108288222A (en) * 2018-03-05 2018-07-17 数字乾元科技有限公司 Property tax processing system and method based on block chain
CN109035019A (en) * 2018-07-11 2018-12-18 平安科技(深圳)有限公司 Bill business method, system, computer equipment and storage medium
CN109034924A (en) * 2018-08-16 2018-12-18 腾讯科技(深圳)有限公司 Electronic bill generation method, device, storage medium and computer equipment
CN109191272A (en) * 2018-08-17 2019-01-11 腾讯科技(深圳)有限公司 About the data processing method of electronic bill, device, storage medium and equipment
CN109359485A (en) * 2018-09-18 2019-02-19 深圳壹账通智能科技有限公司 Invoice data shared system and method based on block chain
CN109447648A (en) * 2018-12-07 2019-03-08 深圳市智税链科技有限公司 The method of recorded data zone block, accounting nodes and medium in block chain network
CN110046945A (en) * 2018-12-13 2019-07-23 阿里巴巴集团控股有限公司 Invoice creation method and device, electronic equipment based on block chain
CN110070443A (en) * 2019-04-23 2019-07-30 深圳前海微众银行股份有限公司 A kind of bill processing method and device based on block chain

Also Published As

Publication number Publication date
CN110598457B (en) 2023-11-24

Similar Documents

Publication Publication Date Title
CN109102269B (en) Transfer method and device based on block chain, block chain node and storage medium
US20200394651A1 (en) Dynamic off-chain digital currency transaction processing
CN108596619B (en) Transaction method, device, central node and system for blockchain system
CN109636593B (en) System and method for authenticating a user in a network transaction
CN111738725B (en) Cross-border resource transfer authenticity auditing method and device and electronic equipment
CN111585767B (en) Data exchange method and device for main chain and side chain
CN110874742B (en) Payment method and device based on block chain and intelligent contract
CN111784347B (en) Resource transfer method and device
CN111325585A (en) Asset transfer method, device and computer readable storage medium
CN112001713A (en) Block chain system and request processing method and device
TW201317911A (en) Cloud credit card transaction system and transaction method thereof
CN111325586B (en) Bill generation method, device, server and medium based on block chain network
CN111768199A (en) Digital currency transaction method and local wallet system
WO2021121030A1 (en) Resource transfer method, settlement terminal, and server node
CN110598457B (en) Bill processing method, bill processing device, bill processing equipment and computer storage medium
CN110661866B (en) Bill processing method and equipment
CN111144958B (en) Electronic invoice issuing method, device and system based on block chain
CN110570305A (en) Game data processing method and device based on block chain
CN105913259A (en) Trade method and trade system of electronic signature device, and electronic signature device
CN111198763A (en) Resource reuse detection method, terminal and computer-readable storage medium
CN110544169A (en) payment data processing method and device based on block chain
CN110599347A (en) Bill processing method, device, computer readable storage medium and computer equipment
CN110766407A (en) Transaction verification method, accounting node and medium based on block chain
CN113362064B (en) Multiple signature method, computer device, and storage medium
CN110956551B (en) Revenue distribution method and related equipment

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