US 11,687,921 B2
Method and device for control of blockchain data access based on smart contract
Hehe Wang, Shanghai (CN); Yuzhuang Xu, Shanghai (CN); Tao Zhu, Shanghai (CN); and Yu Zhou, Shanghai (CN)
Assigned to CHINA UNIONPAY CO., LTD., Shanghai (CN)
Appl. No. 17/595,767
Filed by CHINA UNIONPAY CO., LTD., Shanghai (CN)
PCT Filed Sep. 23, 2020, PCT No. PCT/CN2020/117172
§ 371(c)(1), (2) Date Nov. 23, 2021,
PCT Pub. No. WO2021/129004, PCT Pub. Date Jul. 1, 2021.
Claims priority of application No. 201911355239.X (CN), filed on Dec. 25, 2019.
Prior Publication US 2022/0327531 A1, Oct. 13, 2022
Int. Cl. G06Q 20/38 (2012.01); G06Q 20/40 (2012.01); H04L 9/32 (2006.01)
CPC G06Q 20/3827 (2013.01) [G06Q 20/38215 (2013.01); G06Q 20/407 (2013.01); G06Q 20/4014 (2013.01); H04L 9/3297 (2013.01)] 9 Claims
OG exemplary drawing
 
1. A method for control of blockchain data access based on a smart contract, comprising:
obtaining, by a blockchain node, an access operation request of an institution, wherein the access operation request includes a transaction identifier of a transaction to be accessed;
according to the transaction identifier, determining, by the blockchain node, a blockchain state corresponding to the transaction identifier, wherein the blockchain state includes a hash value of a transaction corresponding to a last time change of the blockchain state;
according to the hash value of the transaction corresponding to the last time change in the blockchain state and an identifier of the institution, performing, by the blockchain node, data access control on the institution to obtain a control result, wherein performing the data access control comprises:
according to the hash value of the transaction corresponding to the last time change in the blockchain state, determining a timestamp of a block corresponding to the hash value;
according to the identifier of the institution, determining a timestamp of a configuration block of the institution;
determining whether the timestamp of the configuration block of the institution is earlier than the timestamp of the block corresponding to the hash value; and
when the timestamp of the configuration block of the institution is earlier than the timestamp of the block corresponding to the hash value, executing an access operation of the institution, determining result of the access operation as the control result, and when the timestamp of the configuration block of the institution is not earlier than the timestamp of the block corresponding to the hash value, determining that the institution is not authorized to access the transaction, and determining access denial information as the control result; and
transmitting, by the blockchain node, the control result to the institution.