Patent ID: 11914721
Assignee: NEC CORPORATION
Field: Computer technology (Electrical engineering)
Classification: CPC G  H | IPC G

Claim 14:
15. A contract rewriting framework system for supporting smart contracts in a blockchain network, the blockchain network being a distributed blockchain network having nodes, each node, of the nodes that validates transactions running a virtual machine for executing a smart contract, the contract rewriting framework system comprises:
a vulnerability detection tool;
a rewriter tool; and
a deployment component,
wherein the deployment component is configured to obtain a permission to upgrade the smart contract, wherein the permission is granted to the deployment component by a creator or owner of the smart contract during a creation phase of the smart contract,
wherein the contract rewriting framework system is configured to retrieve the smart contract from the blockchain network, wherein the smart contract is passed to the vulnerability detection tool,
wherein the vulnerability detection tool is configured to detect a vulnerability in the smart contract, the vulnerability detection tool determines a type of the vulnerability and an instruction location of the vulnerability,
wherein the rewriter tool is configured to rewrite the smart contract to include a patch for fixing the vulnerability, wherein a patched smart contract is generated by the rewriter tool based on the type of the vulnerability and the instruction location of the vulnerability, and
wherein the deployment component is configured to issue an upgrade transaction including the patched smart contract to the blockchain network, such that the patched smart contract is deployed in the blockchain network.