A proxy firewall protection method and system for smart contracts

A smart contract and firewall technology, applied in transmission systems, digital transmission systems, data processing applications, etc., can solve problems such as inability to guarantee testability, inability to know, and inability to protect smart contracts, achieving efficient and timely access control, The effect of ensuring transaction security

Active Publication Date: 2022-06-07
GUANGZHOU UNIVERSITY
View PDF3 Cites 0 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0005] However, during the research and practice of the existing technology, the inventors of the present invention found that the existing smart contract security technology has the following defects: the mutual calling of smart contracts leads to unknown code execution space, and it is impossible to ensure sufficient Testability; first, unknown external functions can be called in smart contracts
For example, if a smart contract uses the call function to perform a transfer operation, the transfer operation will call the fallback function of the transferred address by default, and it is impossible to know whether there is an unsafe code similar to a circular call in the fallback function of the other party before the smart contract is chained; Secondly, the smart contract firewall needs to insert code into the protected smart contract before going to the chain. Smart contract developers need to introduce a library file provided by the existing smart contract firewall when writing a smart contract to realize the security management of the contract ; and the protection scheme of the smart contract cannot be changed after it is on the chain, and the unprotected smart contract that has been on the chain cannot be protected

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • A proxy firewall protection method and system for smart contracts
  • A proxy firewall protection method and system for smart contracts
  • A proxy firewall protection method and system for smart contracts

Examples

Experimental program
Comparison scheme
Effect test

no. 1 example

[0045]See Figure 1-3 。

[0046] as Figure 1 As shown, the present embodiment provides a proxy firewall protection method for smart contracts, comprising at least the following steps:

[0047] S101. After the user publishes the transaction, the proxy contract in the proxy firewall is invoked, and the proxy firewall performs security checks the parameter content of the transaction according to the preset security policy;

[0048] Specifically, for step S101, the user publishes a transaction to invoke the proxy firewall contract, the proxy firewall checks the parameter content of the transaction according to the security policy, such as whether the sender address is in the blacklist of the protection policy library.

[0049] It should be noted that transactions are a data structure of the blockchain that mainly contains the following main fields: Type: type of transaction, ContractCreation (creating a contract) or MessageCall (calling a contract or transferring a transfer); Nonce: Th...

no. 2 example

[0073] See Figure 4-5 。

[0074] as Figure 4 As shown in this embodiment, the present embodiment provides a proxy firewall protection system for smart contracts, comprising:

[0075] Transaction release module 100, for invoking the proxy contract in the proxy firewall after the user publishes the transaction, the proxy firewall performs security checks on the parameter content of the transaction according to the preset security policy;

[0076] Specifically, for the transaction publishing module 100, the user publishes a transaction to call the proxy firewall contract, the proxy firewall checks the parameter content of the transaction according to the security policy, such as whether the sender address is in the blacklist of the protection policy library.

[0077] Smart contract calling module 200, for passing the security check, the proxy firewall will change the source address of the transaction to the address of the proxy contract, and publish the transaction to the target smar...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

PUM

No PUM Login to view more

Abstract

The invention discloses a proxy firewall protection method and system for smart contracts. The method includes: calling the proxy contract in the proxy firewall after the user issues a transaction, and the proxy firewall secures the parameter content of the transaction according to the security policy. Check; after passing the security check, the proxy firewall changes the source address of the transaction to the address of the proxy contract, and publishes the transaction to the target smart contract, so that the proxy firewall calls the target smart contract; after completing the call of the target smart contract, the proxy The firewall updates the transaction execution result to the transaction content and returns it to the proxy contract; the proxy contract publishes the updated transaction to the user address, so that the proxy firewall transmits the transaction execution result to the user and completes the call of the proxy contract. The invention provides a call interface between the user and the target contract through the agent firewall, realizes the safe call of the smart contract, and improves the transaction security of the contract issuer and the caller.

Description

Technical field [0001] The present invention relates to the field of electronic and computer information technology, in particular to a proxy firewall protection method and system for smart contracts. Background [0002] Blockchain is a form of distributed ledger technology that has received widespread attention and applications since the introduction of digital currencies. Blockchain was originally introduced as a peer-to-peer payment, but has recently been expanded to allow programmable transactions in the form of smart contracts. Smart contracts are programs that can be executed together by a network of mutually distrusted nodes that implement a consensus protocol (such as proof of work or proof of stake) and are enforced digitally. [0003] Since smart contracts are entrusted by users to handle and transfer assets of considerable value, they are subject to intensive hacking activities. This kind of hacking is more dangerous than traditional network systems because smart contr...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

Application Information

Patent Timeline
no application Login to view more
Patent Type & Authority Patents(China)
IPC IPC(8): H04L9/40G06Q40/04
CPCH04L63/0281H04L63/0227H04L63/20G06Q40/04H04L63/1425H04L9/50
Inventor 田志宏杜莎莎苏申林炼升曾标孙彦斌姜誉鲁辉
Owner GUANGZHOU UNIVERSITY
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products