Movatterモバイル変換


[0]ホーム

URL:


CN108667632B - Credit record sharing method and device based on block chain and electronic equipment - Google Patents

Credit record sharing method and device based on block chain and electronic equipment
Download PDF

Info

Publication number
CN108667632B
CN108667632BCN201810351841.5ACN201810351841ACN108667632BCN 108667632 BCN108667632 BCN 108667632BCN 201810351841 ACN201810351841 ACN 201810351841ACN 108667632 BCN108667632 BCN 108667632B
Authority
CN
China
Prior art keywords
blockchain
node device
user credit
records
chain
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.)
Active
Application number
CN201810351841.5A
Other languages
Chinese (zh)
Other versions
CN108667632A (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.)
Advanced New Technologies Co Ltd
Advantageous New Technologies Co Ltd
Original Assignee
Alibaba Group Holding Ltd
Advanced New Technologies 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 Alibaba Group Holding Ltd, Advanced New Technologies Co LtdfiledCriticalAlibaba Group Holding Ltd
Priority to CN201810351841.5ApriorityCriticalpatent/CN108667632B/en
Priority to CN202011475094.XAprioritypatent/CN112600841B/en
Publication of CN108667632ApublicationCriticalpatent/CN108667632A/en
Application grantedgrantedCritical
Publication of CN108667632BpublicationCriticalpatent/CN108667632B/en
Activelegal-statusCriticalCurrent
Anticipated expirationlegal-statusCritical

Links

Images

Classifications

Landscapes

Abstract

One or more embodiments of the present specification provide a block chain-based credit record sharing method and apparatus, and an electronic device, where the method may include: target node equipment in the block chain collects user credit records which are broadcast and issued to the block chain by each node equipment in the block chain in the current accounting period and are verified by each node equipment in the block chain together; initiating consensus processing of the collected user credit records in the blockchain to determine a billing node device; and if the target node device is determined to be a billing node, issuing a block broadcast created based on the collected user credit records to the block chain for storage in a distributed database of the block chain.

Description

Translated fromChinese
基于区块链的信用记录共享方法及装置、电子设备Blockchain-based credit record sharing method and device, and electronic equipment

技术领域technical field

本说明书一个或多个实施例涉及区块链技术领域,尤其涉及一种基于区块链的信用记录共享方法及装置、电子设备。One or more embodiments of this specification relate to the field of blockchain technology, and in particular, to a method and apparatus for sharing credit records based on blockchain, and an electronic device.

背景技术Background technique

区块链技术,也被称之为分布式账本技术,是一种由若干台计算设备共同参与“记账”,共同维护一份完整的分布式数据库的新兴技术。由于区块链技术具有去中心化、公开透明、每台计算设备可以参与数据库记录、并且各计算设备之间可以快速的进行数据同步的特性,利用区块链技术来搭建去中心化系统,已在众多的领域中广泛的进行应用。Blockchain technology, also known as distributed ledger technology, is an emerging technology in which several computing devices jointly participate in "bookkeeping" and jointly maintain a complete distributed database. Since the blockchain technology has the characteristics of decentralization, openness and transparency, each computing device can participate in database records, and data synchronization between computing devices can be performed quickly, the use of blockchain technology to build a decentralized system has It is widely used in many fields.

发明内容SUMMARY OF THE INVENTION

本说明书提出一种基于区块链的信用记录共享方法,所述方法包括:This specification proposes a blockchain-based credit record sharing method, which includes:

区块链中的目标节点设备收集当前记账周期内由区块链中的各节点设备广播发布至区块链,且由所述区块链中的各节点设备共同验证通过的用户信用记录;The target node device in the blockchain collects the user credit records that are broadcast and published to the blockchain by the node devices in the blockchain during the current accounting cycle, and are jointly verified by the node devices in the blockchain;

在所述区块链中发起对收集到的所述用户信用记录进行共识处理以确定记账节点设备;Initiating consensus processing on the collected user credit records in the blockchain to determine billing node devices;

如果所述目标节点设备被确定为记账节点,将基于收集到的所述用户信用记录创建的区块广播发布至所述区块链,以在所述区块链的分布式数据库中存储。If the target node device is determined to be an accounting node, a block created based on the collected credit records of the user is broadcast and published to the blockchain for storage in a distributed database of the blockchain.

可选的,所述方法还包括:Optionally, the method further includes:

获取待发布的用户信用记录;Obtain user credit records to be released;

将所述用户信用记录在区块链中进行广播发布,以由其它各节点设备对所述用户信用记录进行验证,并由其它各节点设备将验证结果在所述区块链中进行广播发布;以及,Broadcasting and publishing the user credit record in the blockchain, so that other node devices can verify the user credit record, and other node devices will broadcast the verification result in the blockchain; as well as,

接收到其它各节点设备广播发布的用户信用记录时,对该用户信用记录进行验证,并将验证结果在所述区块链中进行广播发布。When receiving the user credit record broadcasted by other node devices, verify the user credit record, and broadcast the verification result in the blockchain.

可选的,所述由所述区块链中的各节点设备共同验证通过的用户信用记录包括:由所述区块链中的各节点设备中预设比例的节点设备验证通过的用户信用记录;Optionally, the user credit records that are jointly verified by each node device in the blockchain include: user credit records that are verified by a preset proportion of node devices in each node device in the blockchain. ;

所述收集当前记账周期内由区块链中的各节点设备广播发布至区块链,且由所述区块链中的各节点设备共同验证通过的用户信用记录,包括:The collection of user credit records that are broadcast and released to the blockchain by each node device in the blockchain in the current accounting cycle, and are jointly verified by each node device in the blockchain, include:

收集当前记账周期内由区块链中的各节点设备广播发布至区块链的用户信用记录;以及,所述区块链中的各节点设备对当前记账周期内广播发布至区块链的所述用户信用记录的验证结果;Collect the user credit records broadcasted to the blockchain by each node device in the blockchain in the current accounting cycle; and, each node device in the blockchain broadcasts the current accounting cycle to the blockchain. The verification result of the user's credit record;

筛选出当前记账周期内由区块链中的各节点设备广播发布至区块链的用户信用记录中,由各节点设备中预设比例的节点设备验证通过的用户信用记录。Screen out the user credit records broadcasted to the blockchain by each node device in the blockchain in the current accounting cycle, and verified by a preset proportion of node devices in each node device.

可选的,所述在所述区块链中发起对收集到的所述用户信用记录进行共识处理以确定记账节点设备,包括:Optionally, initiating consensus processing on the collected user credit records in the blockchain to determine billing node devices, including:

确定收集到的用户信用记录对应的发布方节点设备;Determine the publisher node device corresponding to the collected user credit record;

统计确定出的各发布方节点设备在当前记账周期内发布的用户信用记录的数量;Statistically determine the number of user credit records published by each publisher node device within the current accounting cycle;

将在当前记账周期内发布的用户信用记录的数量最多的发布方节点设备,确定为记账节点设备。The publisher node device with the largest number of user credit records published in the current accounting cycle is determined as the accounting node device.

可选的,所述统计确定出的各发布方节点设备在当前记账周期内发布的用户信用记录的数量,包括:Optionally, the number of user credit records published by each issuer node device within the current billing cycle determined by the statistics includes:

统计确定出的各发布方节点设备在当前记账周期内发布的,且在所述区块链的分布式数据库中不存在对应的重复记录的用户信用记录的数量。Statistically determine the number of user credit records that are published by each publisher node device within the current billing cycle and have no corresponding duplicate records in the distributed database of the blockchain.

可选的,还包括:Optionally, also include:

如果所述目标节点设备被确定为记账节点,获取所述区块链生成的预设数量的虚拟资源,并将所述虚拟资源下发至与所述目标节点设备对应的账户地址;或者,If the target node device is determined to be an accounting node, obtain a preset number of virtual resources generated by the blockchain, and deliver the virtual resources to the account address corresponding to the target node device; or,

如果所述目标节点设备发布的用户信用记录被存储至所述区块链的分布式数据库,获取所述区块链生成的预设数量的虚拟资源,并将所述虚拟资源下发至与所述目标节点设备对应的账户地址;If the user credit record issued by the target node device is stored in the distributed database of the blockchain, obtain a preset number of virtual resources generated by the blockchain, and deliver the virtual resources to the Describe the account address corresponding to the target node device;

其中,所述虚拟资源用于取得所述区块链的分布式数据库中存储的用户信用记录的使用权限。Wherein, the virtual resource is used to obtain the usage authority of the user credit record stored in the distributed database of the blockchain.

可选的,还包括:Optionally, also include:

接收到针对所述分布式数据库的数据查询请求;receiving a data query request for the distributed database;

响应于所述数据查询请求,调用与所述数据查询对应的智能合约,从所述目标节点设备对应的账户地址中扣除预设数量的虚拟资源。In response to the data query request, the smart contract corresponding to the data query is invoked, and a preset number of virtual resources are deducted from the account address corresponding to the target node device.

可选的,所述虚拟资源为虚拟积分。Optionally, the virtual resources are virtual credits.

可选的,所述区块链包括主链;以及,与主链锚定的若干子链;Optionally, the blockchain includes a main chain; and, several sub-chains anchored to the main chain;

所述将基于收集到的所述用户信用记录创建的区块广播发布至所述区块链,包括:The broadcasting of the block created based on the collected user credit records to the blockchain includes:

如果所述目标节点设备为所述主链中的节点设备,将基于收集到的当前记账周期内由所述主链以及各子链中的各节点设备广播发布至所述主链,且由所述主链中的各节点设备共同验证通过的用户信用记录创建的区块,广播发布至所述区块链的主链;If the target node device is a node device in the main chain, it will be broadcast and published to the main chain by the main chain and each node device in each sub-chain based on the collected current billing cycle, and published by the main chain. The blocks created by the user credit records that are jointly verified by the node devices in the main chain are broadcast and released to the main chain of the blockchain;

如果所述目标节点设备为所述子链中的节点设备,将基于收集到的当前记账周期内由所述子链中的各节点设备广播发布至所述子链,且由所述子链中的各节点设备共同验证通过的用户信用记录创建的区块广播发布至所述区块链的主链。If the target node device is a node device in the sub-chain, it will broadcast and publish to the sub-chain based on the collected current accounting cycle by each node device in the sub-chain, and the sub-chain will broadcast it to the sub-chain. The blocks created by the user credit records that are jointly verified by each node device in the system are broadcast and released to the main chain of the blockchain.

可选的,所述区块链为由若干商家节点设备构成的联盟链;所述联盟链包括主链;以及,与主链锚定的若干子链;其中,不同的子链分别对应不同的商家类型。Optionally, the blockchain is a consortium chain composed of several merchant node devices; the consortium chain includes a main chain; and several sub-chains anchored to the main chain; wherein, different sub-chains correspond to different Business type.

本说明书还提出一种基于区块链的信用记录共享装置,所述装置包括:This specification also proposes a blockchain-based credit record sharing device, the device comprising:

收集模块,收集当前记账周期内由区块链中的各节点设备广播发布至区块链,且由所述区块链中的各节点设备共同验证通过的用户信用记录;The collection module collects the user credit records that are broadcast and published to the blockchain by each node device in the blockchain in the current accounting cycle, and are jointly verified by each node device in the blockchain;

共识模块,在所述区块链中发起对收集到的所述用户信用记录进行共识处理以确定记账节点设备;A consensus module, which initiates consensus processing on the collected user credit records in the blockchain to determine billing node equipment;

发布模块,如果所述装置对应的目标节点设备被确定为记账节点,将基于收集到的所述用户信用记录创建的区块广播发布至所述区块链,以在所述区块链的分布式数据库中存储。The publishing module, if the target node device corresponding to the device is determined to be a billing node, broadcasts the block created based on the collected user credit records to the blockchain, so that in the blockchain stored in a distributed database.

可选的,所述装置还包括:Optionally, the device further includes:

获取模块,获取待发布的用户信用记录;将所述用户信用记录在区块链中进行广播发布,以由其它各节点设备对所述用户信用记录进行验证,并由其它各节点设备将验证结果在所述区块链中进行广播发布;The acquisition module obtains the user credit records to be released; broadcasts the user credit records in the blockchain, so that other node devices can verify the user credit records, and other node devices will verify the results. broadcast in the blockchain;

接收模块,接收到其它各节点设备广播发布的用户信用记录时,对该用户信用记录进行验证,并将验证结果在所述区块链中进行广播发布。The receiving module, when receiving the user credit record broadcasted by other node devices, verifies the user credit record, and broadcasts the verification result in the blockchain.

可选的,所述由所述区块链中的各节点设备共同验证通过的用户信用记录包括:由所述区块链中的各节点设备中预设比例的节点设备验证通过的用户信用记录;Optionally, the user credit records that are jointly verified by each node device in the blockchain include: user credit records that are verified by a preset proportion of node devices in each node device in the blockchain. ;

所述收集模块:The collection module:

收集当前记账周期内由区块链中的各节点设备广播发布至区块链的用户信用记录;以及,所述区块链中的各节点设备对当前记账周期内广播发布至区块链的所述用户信用记录的验证结果;Collect the user credit records broadcasted to the blockchain by each node device in the blockchain in the current accounting cycle; and, each node device in the blockchain broadcasts the current accounting cycle to the blockchain. The verification result of the user's credit record;

筛选出当前记账周期内由区块链中的各节点设备广播发布至区块链的用户信用记录中,由各节点设备中预设比例的节点设备验证通过的用户信用记录。Screen out the user credit records broadcasted to the blockchain by each node device in the blockchain in the current accounting cycle, and verified by a preset proportion of node devices in each node device.

可选的,所述共识模块:Optionally, the consensus module:

确定收集到的用户信用记录对应的发布方节点设备;Determine the publisher node device corresponding to the collected user credit record;

统计确定出的各发布方节点设备在当前记账周期内发布的用户信用记录的数量;Statistically determine the number of user credit records published by each publisher node device within the current accounting cycle;

将在当前记账周期内发布的用户信用记录的数量最多的发布方节点设备,确定为记账节点设备。The publisher node device with the largest number of user credit records published in the current accounting cycle is determined as the accounting node device.

可选的,所述共识模块进一步:Optionally, the consensus module further:

统计确定出的各发布方节点设备在当前记账周期内发布的,且在所述区块链的分布式数据库中不存在对应的重复记录的用户信用记录的数量。Statistically determine the number of user credit records that are published by each publisher node device within the current billing cycle and have no corresponding duplicate records in the distributed database of the blockchain.

可选的,所述发布模块进一步:Optionally, the publishing module further:

如果所述装置对应的目标节点设备被确定为记账节点,获取所述区块链生成的预设数量的虚拟资源,并将所述虚拟资源下发至与所述目标节点设备对应的账户地址;或者,如果所述目标节点设备发布的用户信用记录被存储至所述区块链的分布式数据库,获取所述区块链生成的预设数量的虚拟资源,并将所述虚拟资源下发至与所述目标节点设备对应的账户地址;其中,所述虚拟资源用于取得所述区块链的分布式数据库中存储的用户信用记录的使用权限。If the target node device corresponding to the device is determined to be an accounting node, obtain a preset number of virtual resources generated by the blockchain, and deliver the virtual resources to the account address corresponding to the target node device Or, if the user credit record issued by the target node device is stored in the distributed database of the blockchain, obtain a preset number of virtual resources generated by the blockchain, and issue the virtual resources to the account address corresponding to the target node device; wherein, the virtual resource is used to obtain the use authority of the user credit record stored in the distributed database of the blockchain.

可选的,所述装置还包括:Optionally, the device further includes:

查询模块,接收到针对所述分布式数据库的数据查询请求;响应于所述数据查询请求,调用与所述数据查询对应的智能合约,从所述目标节点设备对应的账户地址中扣除预设数量的虚拟资源。The query module receives a data query request for the distributed database; in response to the data query request, invokes a smart contract corresponding to the data query, and deducts a preset amount from the account address corresponding to the target node device virtual resources.

可选的,所述虚拟资源为虚拟积分。Optionally, the virtual resources are virtual credits.

可选的,所述区块链包括主链;以及,与主链锚定的若干子链;Optionally, the blockchain includes a main chain; and, several sub-chains anchored to the main chain;

所述发布模块:The publishing module:

如果所述装置对应的目标节点设备为所述主链中的节点设备,将基于收集到的当前记账周期内由所述主链以及各子链中的各节点设备广播发布至所述主链,且由所述主链中的各节点设备共同验证通过的用户信用记录创建的区块,广播发布至所述区块链的主链;If the target node device corresponding to the device is a node device in the main chain, the main chain and each node device in each sub-chain will broadcast and publish to the main chain based on the collected current accounting cycle. , and the blocks created by the user credit records that are jointly verified by each node device in the main chain are broadcast and published to the main chain of the blockchain;

如果所述装置对应的目标节点设备为所述子链中的节点设备,将基于收集到的当前记账周期内由所述子链中的各节点设备广播发布至所述子链,且由所述子链中的各节点设备共同验证通过的用户信用记录创建的区块广播发布至所述区块链的主链。If the target node device corresponding to the device is a node device in the sub-chain, it will be broadcast and published to the sub-chain by each node device in the sub-chain based on the collected current accounting cycle, and the The blocks created by the user credit records that are jointly verified by each node device in the sub-chain are broadcast and released to the main chain of the blockchain.

可选的,所述区块链为由若干商家节点设备构成的联盟链;所述联盟链包括主链;以及,与主链锚定的若干子链;其中,不同的子链分别对应不同的商家类型。Optionally, the blockchain is a consortium chain composed of several merchant node devices; the consortium chain includes a main chain; and several sub-chains anchored to the main chain; wherein, different sub-chains correspond to different Business type.

本说明书还提出一种电子设备,包括:This specification also proposes an electronic device, comprising:

处理器;processor;

用于存储机器可执行指令的存储器;memory for storing machine-executable instructions;

其中,通过读取并执行所述存储器存储的与基于区块链的基于区块链的信用记录共享的控制逻辑对应的机器可执行指令,所述处理器被促使:wherein, by reading and executing machine executable instructions stored by the memory corresponding to control logic shared with blockchain-based blockchain-based credit records, the processor is caused to:

收集当前记账周期内由区块链中的各节点设备广播发布至区块链,且由所述区块链中的各节点设备共同验证通过的用户信用记录;Collect the user credit records that are broadcast and published to the blockchain by each node device in the blockchain during the current accounting cycle, and are jointly verified by each node device in the blockchain;

在所述区块链中发起对收集到的所述用户信用记录进行共识处理以确定记账节点设备;Initiating consensus processing on the collected user credit records in the blockchain to determine billing node devices;

如果所述电子设备被确定为记账节点,将基于收集到的所述用户信用记录创建的区块广播发布至所述区块链,以在所述区块链的分布式数据库中存储。If the electronic device is determined to be a billing node, a block created based on the collected credit records of the user is broadcast and published to the blockchain for storage in a distributed database of the blockchain.

附图说明Description of drawings

图1是一示例性实施例提供的一种基于区块链的信用记录共享方法的流程图;1 is a flowchart of a method for sharing credit records based on a blockchain provided by an exemplary embodiment;

图2是一示例性实施例提供的一种联盟链的示意图;2 is a schematic diagram of a consortium chain provided by an exemplary embodiment;

图3是一示例性实施例提供的商户基于联盟链共享用户信用记录的流程图;3 is a flowchart of a merchant sharing user credit records based on a consortium chain provided by an exemplary embodiment;

图4是一示例性实施例提供的一种电子设备的结构示意图;4 is a schematic structural diagram of an electronic device provided by an exemplary embodiment;

图5是一示例性实施例提供的一种基于区块链的信用记录共享装置的框图。FIG. 5 is a block diagram of a blockchain-based credit record sharing apparatus provided by an exemplary embodiment.

具体实施方式Detailed ways

信用闭环业务,是指对于一些从事与用户信用相关的服务的商家,可以将与用户信用相关的数据共享给信用评估方,由信用评估方基于这些信息生成用户信用记录,并对生成的用户信用记录进行维护;而信用评估方,可以基于维护的信用记录,以及自身的渠道来触达该用户,来反向监督和促进该用户积极履约,进而对维护的用户信用记录进行不断的积累,形成业务闭环的业务模式。Credit closed-loop business means that for some merchants engaged in services related to user credit, the data related to user credit can be shared with credit evaluators, and the credit evaluator will generate user credit records based on the information, and the generated user credit The credit evaluation party can reach the user based on the maintained credit record and its own channels to reversely supervise and promote the user's active performance of the contract, and then continuously accumulate the maintained user credit record to form Closed-loop business model.

而在本说明书中,则正是在信用闭环业务的业务背景下,提出的一种利用区块链技术来搭建一个信用记录共享平台,使得加入区块链的各个节点设备(商家)之间,可以依托于区块链的架构,以去中心化的方式来快捷的进行信用记录的共享的技术方案。In this specification, it is under the business background of the credit closed-loop business that a blockchain technology is used to build a credit record sharing platform, so that each node device (merchant) that joins the blockchain, It can rely on the architecture of the blockchain to quickly share the technical solution of credit records in a decentralized way.

在实现时,区块链的运营方可以预先搭建一个由若干商家节点设备构成的区块链网络,并依托于该区块链网络来部署信用闭环业务,使得加入该区块链网络的商家节点设备,可以通过向区块链的分布式数据库(即分布式账本)中广播发布用户信用记录,来实现将用户信用记录在不同的商家中进行共享。During implementation, the blockchain operator can pre-build a blockchain network consisting of several merchant node devices, and rely on the blockchain network to deploy the credit closed-loop business, so that the merchant nodes that join the blockchain network The device can realize the sharing of user credit records among different merchants by broadcasting and publishing user credit records to the distributed database (ie, distributed ledger) of the blockchain.

而对于区块链中的各个商家节点设备而言,可以收集当前记账周期内由各个商家节点设备广播发布至区块链,且经过各节点设备共同验证通过的用户信用记录,并基于收集到的用户信用记录来创建候选区块,然后基于上述区块链网络所支持的共识算法,在区块链中发起对该候选区块中所收录的用户信用记录进行共识处理,来“竞争”记账权限。For each merchant node device in the blockchain, it is possible to collect the user credit records that are broadcast and released to the blockchain by each merchant node device in the current accounting cycle, and are jointly verified by each node device, and based on the collected data Then, based on the consensus algorithm supported by the above-mentioned blockchain network, the consensus processing of the user credit records included in the candidate block is initiated in the blockchain to "compete" the record. account permissions.

如果共识完成后,该商家节点设备被确定未记账节点,该商家节点设备可以将该候选区块作为最新的区块广播发布至该区块链网络,将该最新的区块加入到区块链的分布式数据库中。If the merchant node device is determined to be an unaccounted node after the consensus is completed, the merchant node device can broadcast the candidate block as the latest block to the blockchain network, and add the latest block to the block in the distributed database of the chain.

一方面,由于区块链具有历史可追溯性和不可篡改性,因此通过这种方式能够在区块链上真实的记录一段时间内产生的用户信用记录,并且所有用户信用记录均可以在区块链上进行追溯;而且,由于用户信用记录是由所有节点设备共同验证和维护,要进行用户信用记录的篡改,则需要控制大多数的节点设备才能做到,因此可以确保用户信用记录的公正性;On the one hand, since the blockchain has historical traceability and cannot be tampered with, in this way, the user credit records generated over a period of time can be truly recorded on the blockchain, and all user credit records can be recorded in the block chain. Traceability on the chain; moreover, since the user credit record is jointly verified and maintained by all node devices, to tamper with the user credit record, it is necessary to control most of the node devices, so the impartiality of the user credit record can be ensured ;

另一方面,由于区块链中的各个节点设备产生的用户信用记录是共享的,各个节点设备通过在链上进行查询,就可以获得其它节点设备发布的用户信用记录,因此使得信用闭环可以不集中在其中一个节点设备,各个节点设备之间可以互相共享和监督;而且,在部署信用闭环业务时,触达用户的渠道也相应增多,多个节点设备可以通过使用链上的用户信用记录,对用户进行联合催缴、联合惩戒、以及联合激励等,来联合监督和促进用户积极履约。On the other hand, since the user credit records generated by each node device in the blockchain are shared, each node device can obtain the user credit records issued by other node devices by querying on the chain, so the credit closed loop can not be Concentrating on one of the node devices, each node device can share and supervise each other; moreover, when deploying the credit closed-loop business, the channels for reaching users are also increased accordingly, and multiple node devices can use the user credit records on the chain, To jointly supervise and promote the active performance of the contract by the users, joint payment, joint punishment, and joint incentives are carried out for users.

下面通过具体实施例并结合具体的应用场景对本说明书进行描述。The present specification will be described below through specific embodiments and in conjunction with specific application scenarios.

请参考图1,图1是本说明书一实施例提供的一种基于区块链的信用记录共享方法,执行以下步骤:Please refer to FIG. 1. FIG. 1 is a block chain-based credit record sharing method provided by an embodiment of this specification. The following steps are performed:

步骤102,区块链中的目标节点设备收集当前记账周期内由区块链中的各节点设备广播发布至区块链,且由所述区块链中的各节点设备共同验证通过的用户信用记录;Instep 102, the target node device in the blockchain collects users who are broadcast and published to the blockchain by the node devices in the blockchain in the current accounting cycle, and are jointly verified by the node devices in the blockchain. credit history;

步骤104,在所述区块链中发起对收集到的所述用户信用记录进行共识处理以确定记账节点设备;Step 104, initiate consensus processing on the collected user credit records in the blockchain to determine billing node equipment;

步骤106,如果所述目标节点设备被确定为记账节点,将基于收集到的所述用户信用记录创建的区块广播发布至所述区块链,以在所述区块链的分布式数据库中存储。Step 106, if the target node device is determined to be an accounting node, broadcast the block created based on the collected user credit records to the blockchain, so that it can be stored in the distributed database of the blockchain. in storage.

在本说明书描述的区块链,具体可以包括任意类型的区块链网络。The blockchain described in this specification can specifically include any type of blockchain network.

例如,在示出的一种实施方式中,上述区块链具体可以是一个由若干商家节点设备组成的联盟链。各个商家可以依托于上述联盟链,将运营的一些与用户信用相关的线上或者线下服务所产生的用户信用记录,在区块链中进行发布,并收录在区块链的分布式数据库,以实现各个商家的用户信用记录的共享。For example, in the illustrated embodiment, the above-mentioned blockchain may specifically be a consortium chain composed of several merchant node devices. Each merchant can rely on the above-mentioned alliance chain to publish the user credit records generated by some online or offline services related to user credit in the blockchain, and record them in the distributed database of the blockchain. In order to realize the sharing of user credit records of various merchants.

其中,在示出的一种实施方式中,上述区块链具体可以包括一个主链,以及与主链锚定的若干子链;Wherein, in the illustrated embodiment, the above-mentioned blockchain may specifically include a main chain, and several sub-chains anchored to the main chain;

例如,以上述区块链为由若干商家节点设备构成的联盟链为例,可以基于作为联盟成员的商家的具体类型(比如商家所提供的服务的行业类型),将该联盟链划分为一主链,以及与主链锚定的若干分别对应不同的商家类型的子链。For example, taking the above blockchain as an example of a consortium chain composed of several merchant node devices, the consortium chain can be divided into a main chain, and several sub-chains anchored to the main chain corresponding to different merchant types.

上述节点设备,可以包括能够作为成员加入至上述区块链的任意类型的电子设备;例如,上述电子设备可以包括但不限于是商家的PC终端、移动终端、服务器等。The above-mentioned node device may include any type of electronic device that can join the above-mentioned blockchain as a member; for example, the above-mentioned electronic device may include but not limited to a merchant's PC terminal, mobile terminal, server, etc.

上述信用记录,具体可以包括能够反映用户的信用状况的任意形式的数据记录;例如,与信用相关的服务的使用记录、履约记录、违约记录,等等。The above-mentioned credit records may specifically include data records in any form that can reflect the user's credit status; for example, credit-related service usage records, contract performance records, default records, and the like.

上述记账周期,是指区块链上任意两个区块链接到区块链的分布式数据库上的时间间隔。相应的,上述当前记账周期,是指区块链的分布式数据库上的最新的区块链接到上述分布式数据库的时刻,至记账节点将下一个区块成功链接到上述分布式数据库的时刻之间的时间间隔。其中,上述记账周期的具体取值,可以由上述区块链的运营方基于实际的业务需求进行设定,在本说明书中不进行特别限定;例如,比特币的区块链网络的记账周期,为10分钟,每间隔10分钟产生一个新的区块。The above accounting period refers to the time interval between any two blocks on the blockchain being linked to the distributed database of the blockchain. Correspondingly, the above-mentioned current accounting cycle refers to the moment when the latest block on the distributed database of the blockchain is linked to the above-mentioned distributed database, until the accounting node successfully links the next block to the above-mentioned distributed database. The time interval between moments. The specific value of the above-mentioned accounting period can be set by the operator of the above-mentioned blockchain based on actual business needs, and is not particularly limited in this specification; for example, the accounting of the Bitcoin blockchain network The period is 10 minutes, and a new block is generated every 10 minutes.

以下以上述目标节点设备为商家节点设备,上述区块链为由若干商家节点设备构成的联盟链为例对本说明书的技术方案进行详细说明。Hereinafter, the technical solution of this specification will be described in detail by taking the above-mentioned target node device as a merchant node device and the above-mentioned blockchain as a consortium chain composed of several merchant node devices as an example.

请参见图2,图2为本说明书示出的一种联盟链的示意图。Please refer to FIG. 2, which is a schematic diagram of a consortium chain shown in this specification.

如图2所示,区块链的运营方可以预先搭建一个由若干从事与用户信用相关的服务的商家组成的联盟链,而各个商家的商家节点设备,可以作为联盟链接入上述联盟链。As shown in Figure 2, the blockchain operator can pre-build a consortium chain composed of several merchants engaged in services related to user credit, and the merchant node equipment of each merchant can be used as an alliance link to join the above-mentioned alliance chain.

在示出的一种实施方式中,各个商家节点设备可以搭载用于生成私钥以及公钥的密钥算法,该商家节点设备在作为成员设备接入联盟链时,首先可以通过搭载的私钥以及公钥的生成硬件,或者调用搭载的密钥算法,创建一对私钥和公钥。或者,在实际应用中,各个商家所持有的私钥以及公钥,也可以由联盟链的运营方进行统一分配和下发。In the illustrated embodiment, each merchant node device can be equipped with a key algorithm for generating a private key and a public key. When the merchant node device accesses the consortium chain as a member device, it can first use the carried private key And the generation hardware of the public key, or call the onboard key algorithm to create a pair of private key and public key. Alternatively, in practical applications, the private key and public key held by each merchant can also be uniformly distributed and issued by the operator of the alliance chain.

然后,各个商家节点设备可以进一步构建一个用于发起注册的交易(transfer),并基于生成的私钥对该交易进行签名后,将该交易在联盟链中进行发布,来申请加入联盟链。而联盟链中部分指定的成员节点设备在收到该交易后,可以基于对该交易进行签名时所使用的私钥对应的公钥,对该交易的签名进行验证,并在签名验证通过后,可以对该交易进行共识处理,并在共识通过后,允许该商家节点设备加入联盟链,然后可以对该商家节点设备的公钥进行计算,为该商家节点设备在联盟链中创建一个账户地址。此时,该商家节点设备作为成员节点设备成功加入联盟链,为该商家节点设备生成的账户地址,为该商家节点设备在联盟链上的身份。Then, each merchant node device can further construct a transaction for initiating registration, and after signing the transaction based on the generated private key, publish the transaction in the alliance chain to apply for joining the alliance chain. After receiving the transaction, some designated member node devices in the alliance chain can verify the signature of the transaction based on the public key corresponding to the private key used to sign the transaction, and after the signature verification is passed, The transaction can be processed by consensus, and after the consensus is passed, the merchant node device is allowed to join the alliance chain, and then the public key of the merchant node device can be calculated to create an account address for the merchant node device in the alliance chain. At this time, the merchant node device successfully joins the alliance chain as a member node device, and the account address generated for the merchant node device is the identity of the merchant node device on the alliance chain.

当上述由若干商家节点设备构成的联盟链搭建完毕后,上述联盟链的运营方,依托于该联盟链来部署信用闭环业务。而加入该联盟链的商家,可以通过商家节点设备,通过向联盟链的分布式数据库中广播发布用户信用记录,来实现将用户信用记录在不同的商家中进行共享。When the above-mentioned consortium chain consisting of several merchant node devices is built, the operator of the above-mentioned consortium chain will deploy the credit closed-loop business relying on the consortium chain. Merchants who join the alliance chain can share user credit records among different merchants by broadcasting and publishing user credit records to the distributed database of the alliance chain through merchant node devices.

请参见图3,图3为本说明书示出的一种商户基于联盟链共享用户信用记录的流程图。Please refer to FIG. 3. FIG. 3 shows a flow chart of a merchant sharing user credit records based on a consortium chain shown in this specification.

如图3所示,商家节点设备可以获取待发布的用户信用记录,然后可以基于获取到的用户信用记录向联盟链发起记账。As shown in FIG. 3 , the merchant node device can obtain the user credit record to be published, and then can initiate billing to the alliance chain based on the obtained user credit record.

其中,待发布的用户信用记录,具体可以由商家通过商家节点设备手工录入,也可以由上述上述商家节点设备基于面向用户提供与信用相关的服务时,所产生的服务数据来自动生成。也即,商家节点设备可以获取商家手工录入的用户信用记录,作为待发布的用户信用记录;也可以来获取基于用户所产生的服务数据自动生成的用户数据记录,来作为待发布的用户信用记录。The user credit record to be released can be manually entered by the merchant through the merchant node device, or can be automatically generated by the above-mentioned merchant node device based on service data generated when providing credit-related services to users. That is, the merchant node device can obtain the user credit record manually entered by the merchant as the user credit record to be released; it can also obtain the user data record automatically generated based on the service data generated by the user as the user credit record to be released. .

需要说明的是,上述用户信用记录的具体格式,在本说明书中不进行特别限定,在实际应用中,可以由上述联盟链的运营方,基于实际的需求,来为联盟链定制一套标准的数据格式。It should be noted that the specific format of the above-mentioned user credit record is not particularly limited in this manual. In practical applications, the operator of the above-mentioned alliance chain can customize a set of standard formats for the alliance chain based on actual needs. Data Format.

例如,在示出的一种实施方式中,上述用户信用记录具体可以是由以下字段构成的数据记录:For example, in the illustrated embodiment, the above-mentioned user credit record may specifically be a data record composed of the following fields:

时间戳字段,用于填充用户信用记录的录入或者产生的时间戳。该时间戳具体可以向部署的时间戳服务器进行查询得到。The timestamp field is used to fill in the entry or generated timestamp of the user's credit record. Specifically, the timestamp can be obtained by querying the deployed timestamp server.

类型字段,用于填充用户信用记录的类型标识。联盟链的运营方可以基于实际的需求,定义多种用户信用记录的类型;例如,在一个例子中,联盟链的运营方可以定义“服务使用记录”、“服务违约记录”以及“服务履约记录”三种类型的用户信用记录,并为以上三种记录分别定义一个对应的类型标识。Type field, which is used to fill in the type identifier of the user's credit record. The operator of the alliance chain can define various types of user credit records based on actual needs; for example, in one example, the operator of the alliance chain can define "service usage records", "service default records" and "service performance records". ” three types of user credit records, and define a corresponding type identifier for the above three records.

记录内容字段,用于填充用户信息记录的具体内容。The record content field is used to fill in the specific content of the user information record.

用户身份字段,用于填充用户信用记录对应的用户身份;比如,身份证号、社会保障码等。The user identity field is used to fill in the user identity corresponding to the user's credit record; for example, ID number, social security code, etc.

证明材料字段,用于填充用于证明该用户信用记录的有效性的证明材料;例如,以上述用户信用记录为“服务履约记录”为例,上述证明材料具体可以是能够证明该用户已经完成履约的用户数据;比如,以上述“服务履约记录”为“共享产品的履约服务记录”为例,上述证明材料具体可以是用户按期规划共享产品的订单数据、押金支付记录,等等。The proof material field is used to fill in the proof material used to prove the validity of the user's credit record; for example, taking the above-mentioned user credit record as "service performance record" as an example, the above-mentioned proof material may specifically be able to prove that the user has completed the performance of the contract For example, taking the above-mentioned "service performance record" as "shared product performance service record" as an example, the above-mentioned proof materials may specifically be the user's scheduled sharing product order data, deposit payment records, and so on.

请继续参见图3,商家节点设备在基于获取到的用户信用记录向联盟链发起记账时,具体可以将上述用户信用记录,在联盟链中进行广播发布。Please continue to refer to FIG. 3 , when the merchant node device initiates billing to the alliance chain based on the obtained user credit record, the above-mentioned user credit record can be broadcast and published in the alliance chain.

在示出的一种实施方式中,上述商家节点设备可以将待发布的用户信用记录作为交易内容,构建一笔交易,然后基于持有的私钥对该交易进行签名。In the illustrated embodiment, the above-mentioned merchant node device may use the user credit record to be published as the transaction content, construct a transaction, and then sign the transaction based on the held private key.

请继续参见图3,当联盟链中的其它各节点设备接收到该笔交易后,可以对该笔交易进行验证,并在验证通过后将验证结果在联盟链中进行广播发布;Please continue to refer to Figure 3, when other node devices in the alliance chain receive the transaction, they can verify the transaction, and broadcast the verification result in the alliance chain after the verification is passed;

在本说明书中,对上述交易进行验证,具体可以包括对该交易的发布者的身份验证,以及交易内容的验证;其中,对上述交易内容的验证,又进一步可以包括对上述交易内容的完整性验证,以及对上述交易内容的有效性验证,In this specification, the verification of the above-mentioned transaction may specifically include the identity verification of the issuer of the transaction and the verification of the transaction content; wherein, the verification of the above-mentioned transaction content may further include the integrity of the above-mentioned transaction content. verification, and verification of the validity of the above transaction content,

在实现时,商家节点设备在对上述交易进行签名时,通常可以对该交易进行计算得到内容摘要(比如hash值),然后基于持有的私钥对该内容摘要进行加密得到数字签名。而其它各节点设备在接收到签名后的交易后,可以基于该商家节点设备的公开公钥对上述数字签名进行解密;如果成功解密,则表示发布该交易的商家节点设备的身份验证通过,该笔交易为由该商家节点设备发布的合法交易。During implementation, when the merchant node device signs the above transaction, it can usually calculate the transaction to obtain a content digest (such as a hash value), and then encrypt the content digest based on the held private key to obtain a digital signature. After receiving the signed transaction, other node devices can decrypt the above-mentioned digital signature based on the public key of the merchant node device; if the decryption is successful, it means that the identity verification of the merchant node device that issued the transaction has passed. A transaction is a legitimate transaction issued by the merchant node device.

其次,其它各节点设备还可以进一步对该交易重新进行计算得到一个内容摘要,然后将重新计算出的内容摘要,与通过解密数字签名得到的原始内容摘要进行匹配;如果二者匹配,表示对交易内容的完整性验证通过,该交易的交易内容在交易传输过程中未被非法篡改。Secondly, other node devices can further recalculate the transaction to obtain a content digest, and then match the recalculated content digest with the original content digest obtained by decrypting the digital signature; if the two match, it means that the transaction is not valid. The integrity verification of the content is passed, and the transaction content of the transaction has not been illegally tampered with during the transaction transmission process.

进一步的,当该商家节点设备完成对该交易的发布者的身份验证,以及交易内容的完整性验证后,还可以基于作为交易内容的用户信用记录中记载的信息,来对该用户信用记录进行有效性验证。例如,商家节点设备可以读取用户信用记录中的“证明材料字段”中填充的证明材料,来验证用户信用记录的有效性。Further, when the merchant node device completes the identity verification of the issuer of the transaction and the integrity verification of the transaction content, the user credit record can also be based on the information recorded in the user credit record as the transaction content. Validity verification. For example, the merchant node device can read the proof material filled in the "proof material field" in the user's credit record to verify the validity of the user's credit record.

请继续参见图3,当其它各节点设备对上述商家节点设备发布的交易验证通过后,可以将验证结果在联盟链中进行广播发布;其中,其它各节点设备也可以基于持有的私钥对验证结果进行签名,并且接收到该验证结果的节点设备,也可以基于与该私钥对应的公钥对该验证结果的数据签名进行验证,具体的实施细节本说明书中不再进行赘述。Please continue to refer to Figure 3, when other node devices pass the verification of the transaction issued by the above-mentioned merchant node device, the verification result can be broadcast and released in the alliance chain; among them, other node devices can also be based on the private key pair they hold. The verification result is signed, and the node device that receives the verification result can also verify the data signature of the verification result based on the public key corresponding to the private key. The specific implementation details are not repeated in this specification.

相应的,其它各节点设备在获取到待分布的用户信用记录后,也可以通过相同的方式来构建交易,在联盟链上进行广播发布;而如果上述商家节点设备收到其它各节点设备发布的交易后,也可以采用相同的方式对该交易进行验证,然后向联盟链广播验证结果,在本说明书中不再进行赘述。Correspondingly, after obtaining the user credit records to be distributed, other node devices can also construct transactions in the same way and broadcast them on the alliance chain; After the transaction, the transaction can also be verified in the same way, and then broadcast the verification result to the alliance chain, which will not be repeated in this manual.

在本说明书中,上述商家节点设备,可以收集当前记账周期内由区块链中的各节点设备(包括该商家节点设备)广播发布至联盟链,且由联盟链中的各节点设备共同验证通过的用户信用记录。In this specification, the above-mentioned merchant node devices can collect data broadcasted by each node device in the blockchain (including the merchant node device) in the current accounting cycle to the consortium chain, and be jointly verified by each node device in the consortium chain. User credit history passed.

其中,上述共同验证通过,具体是指经过联盟链中大多数的节点设备验证通过。即在联盟链中,只要上述用户信用记录由联盟链中的大多数节点设备验证通过,得到了联盟链中大多数节点设备的共识认可后,即认为该用户信用记录由联盟链中的各节点设备共同验证通过。Among them, the above-mentioned common verification passed, specifically refers to passing the verification of most of the node devices in the alliance chain. That is, in the alliance chain, as long as the above-mentioned user credit record is verified by most of the node devices in the alliance chain and has been approved by the consensus of most node devices in the alliance chain, it is considered that the user's credit record is determined by each node in the alliance chain. The devices are jointly authenticated.

在示出的一种实施方式中,上述商家节点设备在收集当前记账周期内由区块链中的各节点设备广播发布至联盟链,且由联盟链中的各节点设备共同验证通过的用户信用记录时,具体可以收集当前记账周期内,由联盟链中的各节点设备(包括该商家节点设备)广播发布至联盟链的用户信用记录;以及,收集联盟链中的各节点设备对当前记账周期内广播发布至区块链的用户信用记录的验证结果;然后基于收集到的信息,来筛选出当前记账周期内由区块链中的各节点设备广播发布至区块链的用户信用记录中,由各节点设备中预设比例的节点设备验证通过的用户信用记录。In the illustrated embodiment, the above-mentioned merchant node devices are broadcasted and released to the alliance chain by each node device in the blockchain within the current accounting cycle, and the users who have passed the verification jointly by each node device in the alliance chain In the case of credit records, it is possible to collect the user credit records broadcasted to the alliance chain by each node device in the alliance chain (including the merchant node device) in the current billing cycle; Broadcast the verification results of the user credit records published to the blockchain during the accounting cycle; then based on the collected information, screen out the users broadcasted to the blockchain by each node device in the blockchain during the current accounting cycle In the credit records, the user credit records that are verified by a preset proportion of node devices in each node device.

其中,上述预设比例的取值大小,在本说明书中不进行特别限定,具体可以是一个大于50%的任意比值;比如,51%,或者100%。Wherein, the value of the above-mentioned preset ratio is not particularly limited in this specification, and may specifically be an arbitrary ratio greater than 50%; for example, 51%, or 100%.

在本说明书中,当上述商家节点设备收集到当前记账周期内由区块链中的各节点设备广播发布至联盟链,且由联盟链中的各节点设备共同验证通过的用户信用记录后,可以基于收集到的这些用户信用记录来构建一个候选区块,然后基于联盟链所支持的共识算法,在联盟链中发起对该候选区块中所收录的用户信用记录进行共识处理,来“竞争”记账权限。In this specification, when the above-mentioned merchant node equipment collects the user credit records that are broadcast and published to the alliance chain by each node equipment in the blockchain in the current billing cycle, and are jointly verified by each node equipment in the alliance chain, the user credit record, A candidate block can be constructed based on the collected user credit records, and then based on the consensus algorithm supported by the alliance chain, consensus processing of the user credit records included in the candidate block can be initiated in the alliance chain to "compete". "Accounting authority.

其中,上述联盟链中所支持的共识算法的具体类型,在本说明书中不进行限定限定,在实际应用中,可以采用一些适宜在联盟链中使用的经典共识算法(比如PBFT算法),也可以由联盟链的运营方基于实际的业务需求,来定制一些能够高效处理交易的共识算法。Among them, the specific types of consensus algorithms supported in the above-mentioned alliance chain are not limited in this specification. In practical applications, some classic consensus algorithms (such as PBFT algorithms) suitable for use in alliance chains can be used, or The operator of the alliance chain customizes some consensus algorithms that can efficiently process transactions based on actual business needs.

在示出的一种实施方式中,上述联盟链中支持的共识算法,具体可以是由上述联盟链的运营方定制的,基于各商家节点设备在当前记账周期内发布的用户信用记录的数据量,将在当前记账周期内发布的用户信用记录的数量最多的发布方节点设备选举为记账节点,对候选区块进行共识处理的共识算法。In the illustrated embodiment, the consensus algorithm supported in the above-mentioned consortium chain may be specifically customized by the operator of the above-mentioned consortium chain, based on the data of the user credit records published by each merchant node device in the current billing cycle The consensus algorithm is to elect the publisher node device with the largest number of user credit records published in the current accounting cycle as the accounting node, and to perform consensus processing on candidate blocks.

在实现时,上述商家节点设备在发起对上述候选区块进行共识处理时,首先可以确定收集到的用户信用记录对应的发布方节点设备;比如,可以在承载用户信用记录的交易中添加发布方节点设备的设备标识;然后可以统计各发布方节点设备在当前记账周期内所发布的用户信用记录的数量;最后,可以将在当前记账周期内所发布的用户信用记录的数量最多的发布方节点设备,确定为记账节点设备。During implementation, when the above-mentioned merchant node device initiates consensus processing on the above-mentioned candidate block, it can first determine the publisher node device corresponding to the collected user credit record; for example, the publisher can be added to the transaction carrying the user credit record. The device identification of the node device; then the number of user credit records published by each publisher node device in the current billing cycle can be counted; finally, the largest number of user credit records published in the current billing cycle can be published. The party node device is determined as the accounting node device.

其中,在实际应用中,联盟链中的节点设备所发布的用户信用记录中,可能存在一些已经在联盟链的分布式数据库中存储的重复记录,在这种情况下,通过上述共识算法所共识出的记账节点,可能会存在不准确的问题;比如,一些恶意的节点设备,可能会通过发布大量重复记录,来取得记账权限;而针对这种情况,按照上述共识算法,可能会将这类恶意的节点设备选举为记账节点。Among them, in practical applications, there may be some duplicate records that have been stored in the distributed database of the alliance chain in the user credit records published by the node devices in the alliance chain. There may be inaccurate problems in the outgoing billing nodes; for example, some malicious node devices may obtain billing authority by publishing a large number of duplicate records; and in this case, according to the above consensus algorithm, it may be Such malicious node devices are elected as accounting nodes.

基于此,在示出的一种实施方式中,在上述共识算法中,可以将各发布方节点设备在当前记账周期内所发布的用户信用记录的数量,声明为各发布方节点设备在当前记账周期内发布的,且在联盟链的分布式数据库中不存在对应的重复记录的用户信用记录的数量。Based on this, in the illustrated embodiment, in the above consensus algorithm, the number of user credit records published by each issuer node device in the current billing cycle can be declared as the current issuer node device. The number of user credit records that are released during the accounting period and have no corresponding duplicate records in the distributed database of the alliance chain.

在这种情况下,上述商家节点设备在统计各发布方节点设备在当前记账周期内所发布的用户信用记录的数量时,可以向联盟链的分布式数据库发起查询,来确定各发布方节点设备所发布的用户信用记录,是否已经在联盟链的分布式数据库中存在重复记录;In this case, when the above-mentioned merchant node device counts the number of user credit records published by each issuer node device in the current billing cycle, it can initiate a query to the distributed database of the alliance chain to determine each issuer node. Whether the user credit records published by the device have duplicate records in the distributed database of the alliance chain;

例如,在实现时,可以通过计算待查询的用户信用记录的hash值,基于该hash值定位包含该用户信用记录的区块,然后通过在定位出的该区块的Merkle树中,遍历该用户信用记录的hash值,来确定该用户信用记录是否已经收录在区块链的区块中。For example, during implementation, the hash value of the user's credit record to be queried can be calculated, the block containing the user's credit record can be located based on the hash value, and then the user can be traversed in the Merkle tree of the located block by traversing the user. The hash value of the credit record is used to determine whether the user's credit record has been included in the block of the blockchain.

进一步的,上述商家节点设备可以将这些在联盟链中存在重复记录的用户信用记录从上述候选区块中移除,然后统计各发布方节点设备在当前记账周期内发布的,且在联盟链的分布式数据库中不存在对应的重复记录的用户信用记录的数量,然后基于上述共识算法,将在当前记账周期内发布的用户信用记录的数量最多的发布方节点设备,确定为记账节点设备。Further, the above-mentioned merchant node equipment can remove these user credit records with duplicate records in the alliance chain from the above-mentioned candidate blocks, and then count the information issued by each issuer node equipment within the current accounting cycle, and the information is in the alliance chain. Then, based on the above consensus algorithm, the publisher node device with the largest number of user credit records published in the current accounting cycle is determined as the accounting node. equipment.

通过这种方式,可以避免一些恶意的节点设备,可通过发布大量重复记录,来取得记账权限的问题。In this way, some malicious node devices can be avoided, and the problem of accounting authority can be obtained by publishing a large number of duplicate records.

当然,上述共识算法中的算法逻辑,除了可以是以上描述的,将在当前记账周期内发布的用户信用记录的数量最多的发布方节点设备选举为记账节点,以外,在实际应用中,也可以是由联盟链的运营方定制的其它形式的算法逻辑;例如,将在当前记账周期内发布的用户信用记录的质量最高、发布速度最快的商家节点设备选举为记账节点;或者,也可以由联盟链的运营方基于一定的规则(比如按照一定的顺序)将各个节点设备中的特定节点指定为为记账节点,在本说明书中不再进行一一列举。Of course, the algorithm logic in the above consensus algorithm can be described above, except that the publisher node device with the largest number of user credit records published in the current accounting cycle is elected as the accounting node. In practical applications, It can also be other forms of algorithm logic customized by the operator of the consortium chain; for example, the merchant node device with the highest quality and fastest publishing speed of the user credit records released in the current accounting cycle is elected as the accounting node; or , the operator of the alliance chain can also designate a specific node in each node device as an accounting node based on certain rules (for example, according to a certain order), which will not be listed one by one in this specification.

请继续参见图3,如果上述商家节点设备最终被确定为记账节点,此时该商家节点设备生成的候选区块共识通过,该商家节点设备可以将该候选区块作为最新的区块,在联盟链中进行广播发布。而接收到该最新的区块的各个节点设备,可以分别基于该最新的区块来发起记账,将该最新的区块与历史区块进行链接,进而加入到联盟链的分布式数据中进行永久存储。Please continue to refer to Fig. 3, if the above-mentioned merchant node device is finally determined as the billing node, at this time, the candidate block generated by the merchant node device has passed the consensus, and the merchant node device can use the candidate block as the latest block. Broadcast and release in the alliance chain. And each node device that receives the latest block can initiate accounting based on the latest block, link the latest block with the historical block, and then add it to the distributed data of the alliance chain. Permanent storage.

在本说明书中,由于作为联盟成员的商家,可能分别对应不同的商家类型;例如,加入联盟链的各个商家所提供的服务,可能隶属于不同的行业;而在信用闭环业务中,不同的商家的信用评价体系,可能会存在一定的差异;因此,在一种实施方式中,联盟链的运营方,可以基于作为联盟成员的商家的具体类型,将该联盟链划分为一主链,以及与主链锚定的若干分别对应不同的商家类型的子链。In this specification, the merchants that are members of the alliance may correspond to different types of merchants; for example, the services provided by the merchants joining the alliance chain may belong to different industries; in the closed-loop credit business, different merchants There may be some differences in the credit evaluation system of the consortium; therefore, in one embodiment, the operator of the consortium chain can divide the consortium chain into a main chain based on the specific types of merchants that are members of the consortium, and Several sub-chains anchored by the main chain correspond to different merchant types.

例如,以加入联盟的链的商家包含连锁酒店、超市、以及共享产品服务提供商为等商家为例,可以将连锁酒店、超市、以及共享产品服务提供商等商家的节点设备,划分至不同的子链中,与主链进行锚定。For example, taking the merchants joining the alliance chain including chain hotels, supermarkets, and shared product service providers as an example, the node devices of merchants such as chain hotels, supermarkets, and shared product service providers can be divided into different In the child chain, it is anchored with the main chain.

其中,联盟链中的主链以及子链的运行方式可以完全相同,子链中的发布的用户信用记录,可以通过以上示出的相同的方式,汇总后以区块的形式加入到主链中。Among them, the main chain and sub-chain in the alliance chain can operate in exactly the same way, and the published user credit records in the sub-chain can be aggregated and added to the main chain in the form of blocks in the same way as shown above. .

一方面,对于子链中的商家节点设备而言,在收集到当前记账周期内由子链中的各节点设备广播发布至上述子链,且由上述子链中的各节点设备共同验证通过的用户信用记录后,可以基于收集到的用户信用记录创建候选区块,并在被确定为记账节点后,除了可以将该候选区块作为最新的区块广播发布至该子链,加入到该子链的分布式数据库以外,也可以将该候选区块广播发布至主链,加入到主链中。On the one hand, for the merchant node devices in the sub-chain, within the current accounting cycle collected, each node device in the sub-chain broadcasts and publishes it to the above-mentioned sub-chain, and is jointly verified by all the node devices in the above-mentioned sub-chain. After the user's credit record, a candidate block can be created based on the collected user's credit record, and after being determined as a billing node, the candidate block can be broadcast to the sub-chain as the latest block and added to the sub-chain. In addition to the distributed database of the sub-chain, the candidate block can also be broadcasted to the main chain and added to the main chain.

另一方面,对于主链中的商家节点设备而言,在收集到当前记账周期内由主链以及各子链中的各节点设备广播发布至上述主链,且由上述主链中的各节点设备共同验证通过的用户信用记录后(即由主链中的节点设备来验证子链中发布的用户信用记录),可以基于收集到的用户信用记录创建候选区块,并在被确定为记账节点后,将该候选区块广播发布至主链,加入到主链中。On the other hand, for the merchant node devices in the main chain, the main chain and each node device in each sub-chain will broadcast and publish it to the above-mentioned main chain within the current accounting cycle collected, and will be broadcast by each node in the above-mentioned main chain. After the node devices jointly verify the passed user credit record (that is, the node device in the main chain verifies the user credit record published in the sub-chain), a candidate block can be created based on the collected user credit record, and is determined as a credit record. After the account node is established, the candidate block is broadcasted to the main chain and added to the main chain.

当由商家节点设备发布的用户信用记录,被成功收录存储至联盟链的分布式数据库中,各个商家节点设备可以通过查询联盟链中的用户信用记录,与共享由其它商家节点设备发布的用户信用记录,并使用联盟链中收录存储的用户信用记录,来完成信用闭环业务的线上或者线下运营;When the user credit records published by the merchant node devices are successfully recorded and stored in the distributed database of the alliance chain, each merchant node device can share the user credit records published by other merchant node devices by querying the user credit records in the alliance chain. record, and use the user credit records recorded and stored in the alliance chain to complete the online or offline operation of the credit closed-loop business;

例如,多个商家节点设备,可以基于联盟链中收录存储的用户信用记录,对用户进行联合催缴、联合惩戒、以及联合激励等,来联合监督和促进用户积极履约,实现同行业,以及跨行业间的业务联动。比如,多个商家在获取到联盟链中最新收录的用户信用记录后,均可以基于各自触达用户的渠道,对用户进行催缴、惩戒、激励等。For example, multiple merchant node devices can jointly supervise and promote users' active performance of contracts based on the user credit records recorded and stored in the alliance chain, and jointly supervise and promote users' active performance, realizing the same industry, and cross-border Business linkage between industries. For example, after obtaining the latest user credit records in the alliance chain, multiple merchants can urge, punish, and motivate users based on their respective channels to reach users.

在本说明书中,上述联盟链具体也可以引入记账奖励机制。所谓记账奖励机制,具体是指参与记账的节点设备,可以获得由联盟链分配的一笔奖励。In this specification, the above-mentioned consortium chain can also introduce a bookkeeping reward mechanism. The so-called bookkeeping reward mechanism specifically refers to the node equipment participating in the bookkeeping, which can obtain a reward distributed by the alliance chain.

其中,参与记账的节点设备,具体可以包括取得记账权限的节点设备,也可以包括所有成功在联盟链收录了用户信用记录的节点设备。Among them, the node devices participating in the accounting may specifically include the node devices that have obtained the accounting authority, and may also include all the node devices that have successfully recorded the user's credit record in the alliance chain.

在示出的一种实施方式中,如果联盟链中的商家节点设备被确定为记账节点,可以获取到联盟链生成的预设数量的虚拟资源,然后将获取到的虚拟资源下发至与该商家节点设备对应的账户地址进行持有。In the illustrated embodiment, if the merchant node device in the consortium chain is determined to be the billing node, it can acquire a preset number of virtual resources generated by the consortium chain, and then deliver the acquired virtual resources to the The account address corresponding to the merchant node device is held.

在示出的另一种实施方式中,如果联盟链中的商家节点设备所发布的用户信用记录最终被成功收录存储至联盟链的分布式数据库(即该节点设备并不是记账节点,其发布的用户信用记录被记账节点成功收录至联盟链),可以获取到联盟链生成的预设数量的虚拟资源,然后将获取到的虚拟资源下发至与该商家节点设备对应的账户地址进行持有。In another embodiment shown, if the user credit record published by the merchant node device in the alliance chain is finally successfully included and stored in the distributed database of the alliance chain (that is, the node device is not an accounting node, its published The user's credit record is successfully recorded into the alliance chain by the billing node), the preset number of virtual resources generated by the alliance chain can be obtained, and then the obtained virtual resources are sent to the account address corresponding to the merchant node equipment for holding Have.

其中,联盟链在生成虚拟资源时,具体可以由参与记账的商家节点设备基于运行的算法自动生成,也可以由联盟链中指定的节点设备来生成,然后进行统一下发;例如,可以在联盟链中的节点设备中指定一权威节点设备或者中心节点设备,由该节点设备负责面向参与记账的各个商家节点设备生成并下发虚拟资源作为记账奖励。Among them, when the alliance chain generates virtual resources, it can be automatically generated by the merchant node equipment participating in the bookkeeping based on the running algorithm, or it can be generated by the node equipment specified in the alliance chain, and then distributed uniformly; An authoritative node device or a central node device is designated in the node devices in the alliance chain, and the node device is responsible for generating and issuing virtual resources as accounting rewards for each merchant node device participating in the accounting.

上述虚拟资源的具体类型,在本说明书中不进行特别限定;例如,在实际应用中,上述虚拟资源具体可以是积分,或者与积分类似的其它形式的虚拟奖励。The specific types of the above virtual resources are not particularly limited in this specification; for example, in practical applications, the above virtual resources may specifically be points, or other forms of virtual rewards similar to points.

在本说明书中,上述虚拟资源具体用于取得联盟链的分布式数据库中收录存储的用户信用记录的使用权限。对于联盟链中的节点设备而言,如果需要使用已经收录存储在联盟链的分布式数据库中的用户信用记录,则需要“消耗”一定数量的虚拟资源。In this specification, the above-mentioned virtual resources are specifically used to obtain the use authority of the user credit records recorded and stored in the distributed database of the alliance chain. For the node device in the alliance chain, if it needs to use the user credit records that have been recorded and stored in the distributed database of the alliance chain, it needs to "consume" a certain amount of virtual resources.

在实现时,联盟链的运营方,可以在联盟链中定义使用联盟链中的用户信用记录时,所要“消耗”的虚拟资源的数量。During implementation, the operator of the alliance chain can define in the alliance chain the number of virtual resources to be "consumed" when using the user credit records in the alliance chain.

在示出的一种实施方式中,以上述虚拟资源为积分为例,联盟链的运营方可以预先在联盟链中发布一个与用户信用记录查询相关的智能合约,并在该智能合约中声明查询和使用该联盟链中的用户信用记录时,所要“消耗”的虚拟资源的数量。同时,还可以在智能合约中声明与用户信用记录使用相关的虚拟资源“扣除”逻辑;比如,该逻辑可以是收到针对分布式数据库中的用户信用记录的数据查询请求后,可以基于需要查询的用户信用记录的数量,从查询方的账户地址中“扣除”一定数量的虚拟资源。In the illustrated embodiment, taking the above virtual resource as an example, the operator of the alliance chain can publish a smart contract related to the query of the user's credit record in the alliance chain in advance, and declare the query in the smart contract and the number of virtual resources to be "consumed" when using the user's credit record in the alliance chain. At the same time, the virtual resource "deduction" logic related to the use of the user's credit record can also be declared in the smart contract; for example, the logic can be that after receiving a data query request for the user's credit record in the distributed database, it can be queried based on needs The number of user credit records of the query party, and a certain amount of virtual resources are "deducted" from the account address of the inquiring party.

当商家需要使用联盟链中收录存储的用户信用记录,可以通过商家节点设备向联盟链的分布式数据库发起一个数据查询请求(交易),商家节点设备在收到该数据查询请求后,可以响应该数据查询请求,调用上述智能合约,基于上述智能合约中声明的使用联盟链中的用户信用记录时,所要“消耗”的积分数量,以及本次需要查询的用户信用记录的数量,来计算本次查询所要消耗的积分数量,然后从该商家节点设备对应的账户地址中扣除相应数量的积分。当然,如果商家节点设备对应的账户地址中积分数量不足,此时该商家节点设备可以向用户发出查询失败的提示。When a merchant needs to use the user credit records recorded and stored in the alliance chain, it can initiate a data query request (transaction) to the distributed database of the alliance chain through the merchant node device. After receiving the data query request, the merchant node device can respond to the data query request. Data query request, call the above smart contract, based on the amount of points to be "consumed" when using the user credit record in the alliance chain declared in the above smart contract, and the number of user credit records that need to be queried this time, to calculate this time Query the amount of points to be consumed, and then deduct the corresponding amount of points from the account address corresponding to the merchant node device. Of course, if the number of points in the account address corresponding to the merchant node device is insufficient, the merchant node device can send a prompt to the user that the query fails.

通过这种方式,由于只有参与记账的商家节点设备,能够获取到联盟链的记账奖励,因此不仅可以鼓励各个商家将运营线上或者线下业务所产生的用户信用记录通过发布至联盟链共享给其它商家,还可以将联盟链中收录存储的用户信用记录的使用权限,向参与记账的商家倾斜;同时,还可以提高联盟链中的数据查询和使用的门槛,可以限制一些不参与记账的商家,或者接入联盟链的非商家用户,来获取和使用各个商家共享的用户信用记录。In this way, since only the node devices of the merchants participating in the bookkeeping can obtain the bookkeeping rewards of the alliance chain, not only can each merchant be encouraged to publish the user credit records generated by operating online or offline business to the alliance chain Sharing with other merchants can also increase the use rights of users’ credit records recorded and stored in the alliance chain to the merchants who participate in bookkeeping; at the same time, it can also improve the threshold for data query and use in the alliance chain, and can restrict some people who do not participate. Merchants who keep accounts, or non-merchant users who access the alliance chain, can obtain and use the user credit records shared by various merchants.

通过以上实施例可见,一方面,由于区块链具有历史可追溯性和不可篡改性,因此通过这种方式能够在区块链上真实的记录一段时间内产生的用户信用记录,并且所有用户信用记录均可以在区块链上进行追溯;而且,由于用户信用记录是由所有节点设备共同验证和维护,要进行用户信用记录的篡改,则需要控制大多数的节点设备才能做到,因此可以确保用户信用记录的公正性;It can be seen from the above embodiments that, on the one hand, since the blockchain has historical traceability and cannot be tampered with, in this way, the user credit records generated over a period of time can be truly recorded on the blockchain, and all user credit records can be recorded on the blockchain. All records can be traced on the blockchain; moreover, since user credit records are jointly verified and maintained by all node devices, to tamper with user credit records, it is necessary to control most node devices, so it can be ensured The impartiality of the user's credit record;

另一方面,由于区块链中的各个节点设备产生的用户信用记录是共享的,各个节点设备通过在链上进行查询,就可以获得其它节点设备发布的用户信用记录,因此使得信用闭环可以不集中在其中一个节点设备,各个节点设备之间可以互相共享和监督;而且,在部署信用闭环业务时,触达用户的渠道也相应增多,多个节点设备可以通过使用链上的用户信用记录,对用户进行联合催缴、联合惩戒、以及联合激励等,来联合监督和促进用户积极履约。On the other hand, since the user credit records generated by each node device in the blockchain are shared, each node device can obtain the user credit records issued by other node devices by querying on the chain, so the credit closed loop can not be Concentrating on one of the node devices, each node device can share and supervise each other; moreover, when deploying the credit closed-loop business, the channels for reaching users are also increased accordingly, and multiple node devices can use the user credit records on the chain, To jointly supervise and promote the active performance of the contract by the users, joint payment, joint punishment, and joint incentives are carried out for users.

与上述方法实施例相对应,本说明书还提供了一种基于区块链的信用记录共享装置的实施例。本说明书的基于区块链的信用记录共享装置的实施例可以应用在电子设备上。装置实施例可以通过软件实现,也可以通过硬件或者软硬件结合的方式实现。以软件实现为例,作为一个逻辑意义上的装置,是通过其所在电子设备的处理器将非易失性存储器中对应的计算机程序指令读取到内存中运行形成的。从硬件层面而言,如图4所示,为本说明书的基于区块链的信用记录共享装置所在电子设备的一种硬件结构图,除了图4所示的处理器、内存、网络接口、以及非易失性存储器之外,实施例中装置所在的电子设备通常根据该电子设备的实际功能,还可以包括其他硬件,对此不再赘述。Corresponding to the above method embodiments, this specification also provides an embodiment of a block chain-based credit record sharing apparatus. The embodiments of the blockchain-based credit record sharing apparatus of this specification can be applied to electronic devices. The apparatus embodiment may be implemented by software, or may be implemented by hardware or a combination of software and hardware. Taking software implementation as an example, a device in a logical sense is formed by reading the corresponding computer program instructions in the non-volatile memory into the memory for operation by the processor of the electronic device where the device is located. From the perspective of hardware, as shown in FIG. 4, it is a hardware structure diagram of the electronic equipment where the blockchain-based credit record sharing device of this specification is located, except for the processor, memory, network interface, and In addition to the non-volatile memory, the electronic device in which the apparatus in the embodiment is located generally may also include other hardware according to the actual function of the electronic device, and details are not described herein again.

图5是本说明书一示例性实施例示出的一种基于区块链的信用记录共享装置的框图。FIG. 5 is a block diagram of a block chain-based credit record sharing apparatus according to an exemplary embodiment of the present specification.

请参考图5,所述基于区块链的信用记录共享装置50可以应用在前述图5所示的电子设备中,包括有:收集模块501、共识模块502和发布模块503。Please refer to FIG. 5 , the blockchain-based credit record sharing apparatus 50 can be applied to the electronic device shown in FIG. 5 , including a collection module 501 , a consensus module 502 and a publishing module 503 .

收集模块501,收集当前记账周期内由区块链中的各节点设备广播发布至区块链,且由所述区块链中的各节点设备共同验证通过的用户信用记录;The collection module 501 collects the user credit records that are broadcast and published to the blockchain by each node device in the blockchain in the current accounting cycle, and are jointly verified by each node device in the blockchain;

共识模块502,在所述区块链中发起对收集到的所述用户信用记录进行共识处理以确定记账节点设备;A consensus module 502, initiates consensus processing on the collected user credit records in the blockchain to determine billing node devices;

发布模块503,如果所述装置对应的目标节点设备被确定为记账节点,将基于收集到的所述用户信用记录创建的区块广播发布至所述区块链,以在所述区块链的分布式数据库中存储。Publishing module 503, if the target node device corresponding to the device is determined to be a billing node, broadcast the block created based on the collected user credit record to the blockchain, so that the block chain can be broadcast on the blockchain. stored in a distributed database.

在本实施例中,所述装置50还包括:In this embodiment, the device 50 further includes:

获取模块504(图5中未示出),获取待发布的用户信用记录;将所述用户信用记录在区块链中进行广播发布,以由其它各节点设备对所述用户信用记录进行验证,并由其它各节点设备将验证结果在所述区块链中进行广播发布;The acquisition module 504 (not shown in FIG. 5 ) acquires the user credit record to be published; broadcasts the user credit record in the blockchain, so that other node devices can verify the user credit record, And other node devices will broadcast the verification results in the blockchain;

接收模块505(图5中未示出),接收到其它各节点设备广播发布的用户信用记录时,对该用户信用记录进行验证,并将验证结果在所述区块链中进行广播发布。The receiving module 505 (not shown in FIG. 5 ), when receiving the user credit record broadcasted by other node devices, verifies the user credit record, and broadcasts the verification result in the blockchain.

在本实施例中,所述由所述区块链中的各节点设备共同验证通过的用户信用记录包括:由所述区块链中的各节点设备中预设比例的节点设备验证通过的用户信用记录;In this embodiment, the user credit records that are jointly verified by each node device in the blockchain include: users who have been verified by a preset proportion of node devices in each node device in the blockchain credit history;

所述收集模块501:The collection module 501:

收集当前记账周期内由区块链中的各节点设备广播发布至区块链的用户信用记录;以及,所述区块链中的各节点设备对当前记账周期内广播发布至区块链的所述用户信用记录的验证结果;Collect the user credit records broadcasted to the blockchain by each node device in the blockchain in the current accounting cycle; and, each node device in the blockchain broadcasts the current accounting cycle to the blockchain. The verification result of the user's credit record;

筛选出当前记账周期内由区块链中的各节点设备广播发布至区块链的用户信用记录中,由各节点设备中预设比例的节点设备验证通过的用户信用记录。Screen out the user credit records broadcasted to the blockchain by each node device in the blockchain in the current accounting cycle, and verified by a preset proportion of node devices in each node device.

在本实施例中,所述共识模块502:In this embodiment, the consensus module 502:

确定收集到的用户信用记录对应的发布方节点设备;Determine the publisher node device corresponding to the collected user credit record;

统计确定出的各发布方节点设备在当前记账周期内发布的用户信用记录的数量;Statistically determine the number of user credit records published by each publisher node device within the current accounting cycle;

将在当前记账周期内发布的用户信用记录的数量最多的发布方节点设备,确定为记账节点设备。The publisher node device with the largest number of user credit records published in the current accounting cycle is determined as the accounting node device.

在本实施例中,所述共识模块502进一步:In this embodiment, the consensus module 502 further:

统计确定出的各发布方节点设备在当前记账周期内发布的,且在所述区块链的分布式数据库中不存在对应的重复记录的用户信用记录的数量。Statistically determine the number of user credit records that are published by each publisher node device within the current billing cycle and have no corresponding duplicate records in the distributed database of the blockchain.

在本实施例中,所述发布模块503进一步:In this embodiment, the publishing module 503 further:

如果所述装置对应的目标节点设备被确定为记账节点,获取所述区块链生成的预设数量的虚拟资源,并将所述虚拟资源下发至与所述目标节点设备对应的账户地址;或者,如果所述目标节点设备发布的用户信用记录被存储至所述区块链的分布式数据库,获取所述区块链生成的预设数量的虚拟资源,并将所述虚拟资源下发至与所述目标节点设备对应的账户地址;其中,所述虚拟资源用于取得所述区块链的分布式数据库中存储的用户信用记录的使用权限。If the target node device corresponding to the device is determined to be an accounting node, obtain a preset number of virtual resources generated by the blockchain, and deliver the virtual resources to the account address corresponding to the target node device Or, if the user credit record issued by the target node device is stored in the distributed database of the blockchain, obtain a preset number of virtual resources generated by the blockchain, and issue the virtual resources to the account address corresponding to the target node device; wherein, the virtual resource is used to obtain the use authority of the user credit record stored in the distributed database of the blockchain.

在本实施例中,所述装置还包括:In this embodiment, the device further includes:

查询模块505(图5中未示出),接收到针对所述分布式数据库的数据查询请求;响应于所述数据查询请求,调用与所述数据查询对应的智能合约,从所述目标节点设备对应的账户地址中扣除预设数量的虚拟资源。The query module 505 (not shown in FIG. 5 ) receives a data query request for the distributed database; in response to the data query request, invokes a smart contract corresponding to the data query, and retrieves the data from the target node device A preset amount of virtual resources is deducted from the corresponding account address.

在本实施例中,所述虚拟资源为虚拟积分。In this embodiment, the virtual resources are virtual credits.

在本实施例中,所述区块链包括主链;以及,与主链锚定的若干子链;In this embodiment, the blockchain includes a main chain; and, several sub-chains anchored to the main chain;

所述发布模块:The publishing module:

如果所述装置对应的目标节点设备为所述主链中的节点设备,将基于收集到的当前记账周期内由所述主链以及各子链中的各节点设备广播发布至所述主链,且由所述主链中的各节点设备共同验证通过的用户信用记录创建的区块,广播发布至所述区块链的主链;If the target node device corresponding to the device is a node device in the main chain, the main chain and each node device in each sub-chain will broadcast and publish to the main chain based on the collected current accounting cycle. , and the blocks created by the user credit records that are jointly verified by each node device in the main chain are broadcast and published to the main chain of the blockchain;

如果所述装置对应的目标节点设备为所述子链中的节点设备,将基于收集到的当前记账周期内由所述子链中的各节点设备广播发布至所述子链,且由所述子链中的各节点设备共同验证通过的用户信用记录创建的区块广播发布至所述区块链的主链。If the target node device corresponding to the device is a node device in the sub-chain, it will be broadcast and published to the sub-chain by each node device in the sub-chain based on the collected current accounting cycle, and the The blocks created by the user credit records that are jointly verified by each node device in the sub-chain are broadcast and released to the main chain of the blockchain.

在本实施例中,所述区块链为由若干商家节点设备构成的联盟链;所述联盟链包括主链;以及,与主链锚定的若干子链;其中,不同的子链分别对应不同的商家类型。In this embodiment, the blockchain is a consortium chain composed of several merchant node devices; the consortium chain includes a main chain; and several sub-chains anchored to the main chain; wherein, different sub-chains correspond to Different business types.

上述装置中各个模块的功能和作用的实现过程具体详见上述方法中对应步骤的实现过程,在此不再赘述。For details of the implementation process of the functions and functions of each module in the above-mentioned device, please refer to the implementation process of the corresponding steps in the above-mentioned method, which will not be repeated here.

对于装置实施例而言,由于其基本对应于方法实施例,所以相关之处参见方法实施例的部分说明即可。以上所描述的装置实施例仅仅是示意性的,其中所述作为分离部件说明的模块可以是或者也可以不是物理上分开的,作为模块显示的部件可以是或者也可以不是物理模块,即可以位于一个地方,或者也可以分布到多个网络模块上。可以根据实际的需要选择其中的部分或者全部模块来实现本说明书方案的目的。本领域普通技术人员在不付出创造性劳动的情况下,即可以理解并实施。As for the apparatus embodiments, since they basically correspond to the method embodiments, reference may be made to the partial descriptions of the method embodiments for related parts. The device embodiments described above are only illustrative, wherein the modules described as separate components may or may not be physically separated, and the components shown as modules may or may not be physical modules, that is, they may be located in One place, or it can be distributed over multiple network modules. Some or all of the modules can be selected according to actual needs to achieve the purpose of the solution in this specification. Those of ordinary skill in the art can understand and implement it without creative effort.

上述实施例阐明的系统、装置、模块或模块,具体可以由计算机芯片或实体实现,或者由具有某种功能的产品来实现。一种典型的实现设备为计算机,计算机的具体形式可以是个人计算机、膝上型计算机、蜂窝电话、相机电话、智能电话、个人数字助理、媒体播放器、导航设备、电子邮件收发设备、游戏控制台、平板计算机、可穿戴设备或者这些设备中的任意几种设备的组合。The systems, devices, modules or modules described in the above embodiments may be specifically implemented by computer chips or entities, or by products with certain functions. A typical implementing device is a computer, which may be in the form of a personal computer, laptop computer, cellular phone, camera phone, smart phone, personal digital assistant, media player, navigation device, email sending and receiving device, game control desktop, tablet, wearable device, or a combination of any of these devices.

与上述方法实施例相对应,本说明书还提供了一种电子设备的实施例。该电子设备包括:处理器以及用于存储机器可执行指令的存储器;其中,处理器和存储器通常通过内部总线相互连接。在其他可能的实现方式中,所述设备还可能包括外部接口,以能够与其他设备或者部件进行通信。Corresponding to the foregoing method embodiments, the present specification further provides an embodiment of an electronic device. The electronic device includes a processor and a memory for storing machine-executable instructions; wherein the processor and the memory are typically connected to each other by an internal bus. In other possible implementations, the device may also include an external interface to enable communication with other devices or components.

在本实施例中,通过读取并执行所述存储器存储的与基于区块链的信用记录共享的控制逻辑对应的机器可执行指令,所述处理器被促使:In this embodiment, the processor is caused to:

收集当前记账周期内由区块链中的各节点设备广播发布至区块链,且由所述区块链中的各节点设备共同验证通过的用户信用记录;Collect the user credit records that are broadcast and published to the blockchain by each node device in the blockchain during the current accounting cycle, and are jointly verified by each node device in the blockchain;

在所述区块链中发起对收集到的所述用户信用记录进行共识处理以确定记账节点设备;Initiating consensus processing on the collected user credit records in the blockchain to determine billing node devices;

如果所述电子设备被确定为记账节点,将基于收集到的所述用户信用记录创建的区块广播发布至所述区块链,以在所述区块链的分布式数据库中存储。If the electronic device is determined to be a billing node, a block created based on the collected credit records of the user is broadcast and published to the blockchain for storage in a distributed database of the blockchain.

在本实施例中,通过读取并执行所述存储器存储的与基于区块链的信用记录共享的控制逻辑对应的机器可执行指令,所述处理器被促使:In this embodiment, the processor is caused to:

获取待发布的用户信用记录;Obtain user credit records to be released;

将所述用户信用记录在区块链中进行广播发布,以由其它各节点设备对所述用户信用记录进行验证,并由其它各节点设备将验证结果在所述区块链中进行广播发布;以及,Broadcasting and publishing the user credit record in the blockchain, so that other node devices can verify the user credit record, and other node devices will broadcast the verification result in the blockchain; as well as,

接收到其它各节点设备广播发布的用户信用记录时,对该用户信用记录进行验证,并将验证结果在所述区块链中进行广播发布。When receiving the user credit record broadcasted by other node devices, verify the user credit record, and broadcast the verification result in the blockchain.

在本实施例中,所述由所述区块链中的各节点设备共同验证通过的用户信用记录包括:由所述区块链中的各节点设备中预设比例的节点设备验证通过的用户信用记录;In this embodiment, the user credit records that are jointly verified by each node device in the blockchain include: users who have been verified by a preset proportion of node devices in each node device in the blockchain credit history;

通过读取并执行所述存储器存储的与基于区块链的信用记录共享的控制逻辑对应的机器可执行指令,所述处理器被促使:By reading and executing the memory-stored machine-executable instructions corresponding to the control logic shared with the blockchain-based credit records, the processor is caused to:

收集当前记账周期内由区块链中的各节点设备广播发布至区块链的用户信用记录;以及,所述区块链中的各节点设备对当前记账周期内广播发布至区块链的所述用户信用记录的验证结果;Collect the user credit records broadcasted to the blockchain by each node device in the blockchain in the current accounting cycle; and, each node device in the blockchain broadcasts the current accounting cycle to the blockchain. The verification result of the user's credit record;

筛选出当前记账周期内由区块链中的各节点设备广播发布至区块链的用户信用记录中,由各节点设备中预设比例的节点设备验证通过的用户信用记录。Screen out the user credit records broadcasted to the blockchain by each node device in the blockchain in the current accounting cycle, and verified by a preset proportion of node devices in each node device.

在本实施例中,通过读取并执行所述存储器存储的与基于区块链的信用记录共享的控制逻辑对应的机器可执行指令,所述处理器被促使:In this embodiment, the processor is caused to:

确定收集到的用户信用记录对应的发布方节点设备;Determine the publisher node device corresponding to the collected user credit record;

统计确定出的各发布方节点设备在当前记账周期内发布的用户信用记录的数量;Statistically determine the number of user credit records published by each publisher node device within the current accounting cycle;

将在当前记账周期内发布的用户信用记录的数量最多的发布方节点设备,确定为记账节点设备。The publisher node device with the largest number of user credit records published in the current accounting cycle is determined as the accounting node device.

在本实施例中,通过读取并执行所述存储器存储的与基于区块链的信用记录共享的控制逻辑对应的机器可执行指令,所述处理器被促使:In this embodiment, the processor is caused to:

统计确定出的各发布方节点设备在当前记账周期内发布的,且在所述区块链的分布式数据库中不存在对应的重复记录的用户信用记录的数量。Statistically determine the number of user credit records that are published by each publisher node device within the current billing cycle and have no corresponding duplicate records in the distributed database of the blockchain.

在本实施例中,通过读取并执行所述存储器存储的与基于区块链的信用记录共享的控制逻辑对应的机器可执行指令,所述处理器被促使:In this embodiment, the processor is caused to:

如果所述目标节点设备被确定为记账节点,获取所述区块链生成的预设数量的虚拟资源,并将所述虚拟资源下发至与所述目标节点设备对应的账户地址;或者,If the target node device is determined to be an accounting node, obtain a preset number of virtual resources generated by the blockchain, and deliver the virtual resources to the account address corresponding to the target node device; or,

如果所述目标节点设备发布的用户信用记录被存储至所述区块链的分布式数据库,获取所述区块链生成的预设数量的虚拟资源,并将所述虚拟资源下发至与所述目标节点设备对应的账户地址;If the user credit record issued by the target node device is stored in the distributed database of the blockchain, obtain a preset number of virtual resources generated by the blockchain, and deliver the virtual resources to the Describe the account address corresponding to the target node device;

其中,所述虚拟资源用于取得所述区块链的分布式数据库中存储的用户信用记录的使用权限。Wherein, the virtual resource is used to obtain the usage authority of the user credit record stored in the distributed database of the blockchain.

在本实施例中,通过读取并执行所述存储器存储的与基于区块链的信用记录共享的控制逻辑对应的机器可执行指令,所述处理器被促使:In this embodiment, the processor is caused to:

接收到针对所述分布式数据库的数据查询请求;receiving a data query request for the distributed database;

响应于所述数据查询请求,调用与所述数据查询对应的智能合约,从所述目标节点设备对应的账户地址中扣除预设数量的虚拟资源。In response to the data query request, the smart contract corresponding to the data query is invoked, and a preset number of virtual resources are deducted from the account address corresponding to the target node device.

本领域技术人员在考虑说明书及实践这里公开的发明后,将容易想到本说明书的其它实施方案。本说明书旨在涵盖本说明书的任何变型、用途或者适应性变化,这些变型、用途或者适应性变化遵循本说明书的一般性原理并包括本说明书未公开的本技术领域中的公知常识或惯用技术手段。说明书和实施例仅被视为示例性的,本说明书的真正范围和精神由下面的权利要求指出。Other embodiments of this specification will readily occur to those skilled in the art upon consideration of the specification and practice of the invention disclosed herein. This specification is intended to cover any variations, uses or adaptations of this specification that follow the general principles of this specification and include common knowledge or conventional techniques in the art not disclosed in this specification . The specification and examples are to be regarded as exemplary only, with the true scope and spirit of the specification being indicated by the following claims.

应当理解的是,本说明书并不局限于上面已经描述并在附图中示出的精确结构,并且可以在不脱离其范围进行各种修改和改变。本说明书的范围仅由所附的权利要求来限制。It should be understood that this specification is not limited to the precise structures described above and illustrated in the accompanying drawings and that various modifications and changes may be made without departing from the scope thereof. The scope of this specification is limited only by the appended claims.

以上所述仅为本说明书的较佳实施例而已,并不用以限制本说明书,凡在本说明书的精神和原则之内,所做的任何修改、等同替换、改进等,均应包含在本说明书保护的范围之内。The above descriptions are only preferred embodiments of this specification, and are not intended to limit this specification. Any modifications, equivalent replacements, improvements, etc. made within the spirit and principles of this specification shall be included in this specification. within the scope of protection.

Claims (17)

Translated fromChinese
1.一种基于区块链的信用记录共享方法,所述方法包括:1. A method for sharing credit records based on blockchain, the method comprising:获取待发布的、包括用于证明用户信用记录的有效性的证明材料的用户信用记录;Obtain the user credit record to be released, including the certification materials used to prove the validity of the user credit record;将所述用户信用记录在区块链中进行广播发布,以由其它各节点设备对所述用户信用记录进行验证,并由其它各节点设备将验证结果在所述区块链中进行广播发布;以及,接收到其它各节点设备广播发布的、包括用于证明用户信用记录的有效性的证明材料的用户信用记录时,对该用户信用记录基于对应的证明材料进行有效性验证,并将验证结果在所述区块链中进行广播发布;Broadcasting the user credit record in the blockchain, so that other node devices can verify the user credit record, and other node devices will broadcast the verification result in the blockchain; And, when receiving a user credit record broadcast and released by other node devices, including the certification material used to prove the validity of the user credit record, the validity of the user credit record is verified based on the corresponding certification materials, and the verification result is verified. broadcast in the blockchain;区块链中的目标节点设备收集当前记账周期内由区块链中的各节点设备广播发布至区块链,且由所述区块链中的各节点设备共同验证通过的用户信用记录;The target node device in the blockchain collects the user credit records that are broadcast and published to the blockchain by the node devices in the blockchain during the current accounting cycle, and are jointly verified by the node devices in the blockchain;确定收集到的用户信用记录对应的发布方节点设备,统计确定出的各发布方节点设备在当前记账周期内发布的用户信用记录的数量,并将在当前记账周期内发布的用户信用记录的数量最多的发布方节点设备,确定为记账节点设备;Determine the publisher node device corresponding to the collected user credit records, count the determined number of user credit records published by each publisher node device in the current accounting period, and compare the user credit records published in the current accounting period. The publisher node device with the largest number is determined as the accounting node device;如果所述目标节点设备被确定为记账节点,将基于收集到的所述用户信用记录创建的区块广播发布至所述区块链,以在所述区块链的分布式数据库中存储。If the target node device is determined to be an accounting node, a block created based on the collected credit records of the user is broadcast and published to the blockchain for storage in a distributed database of the blockchain.2.根据权利要求1所述的方法,所述由所述区块链中的各节点设备共同验证通过的用户信用记录包括:由所述区块链中的各节点设备中预设比例的节点设备验证通过的用户信用记录;2. The method according to claim 1, wherein the user credit record jointly verified by each node device in the blockchain comprises: a preset proportion of nodes in each node device in the blockchain User credit records that have passed device verification;所述收集当前记账周期内由区块链中的各节点设备广播发布至区块链,且由所述区块链中的各节点设备共同验证通过的用户信用记录,包括:The collection of user credit records that are broadcast and released to the blockchain by each node device in the blockchain in the current accounting cycle, and are jointly verified by each node device in the blockchain, include:收集当前记账周期内由区块链中的各节点设备广播发布至区块链的用户信用记录;以及,所述区块链中的各节点设备对当前记账周期内广播发布至区块链的所述用户信用记录的验证结果;Collect the user credit records broadcasted to the blockchain by each node device in the blockchain in the current accounting cycle; and, each node device in the blockchain broadcasts the current accounting cycle to the blockchain. The verification result of the user's credit record;筛选出当前记账周期内由区块链中的各节点设备广播发布至区块链的用户信用记录中,由各节点设备中预设比例的节点设备验证通过的用户信用记录。Screen out the user credit records broadcasted to the blockchain by each node device in the blockchain in the current accounting cycle, and verified by a preset proportion of node devices in each node device.3.根据权利要求1所述的方法,所述统计确定出的各发布方节点设备在当前记账周期内发布的用户信用记录的数量,包括:3. The method according to claim 1, wherein the number of user credit records issued by each issuer node device within the current billing cycle determined by the statistics comprises:统计确定出的各发布方节点设备在当前记账周期内发布的,且在所述区块链的分布式数据库中不存在对应的重复记录的用户信用记录的数量。Statistically determine the number of user credit records that are published by each publisher node device within the current billing cycle and have no corresponding duplicate records in the distributed database of the blockchain.4.根据权利要求1所述的方法,还包括:4. The method of claim 1, further comprising:如果所述目标节点设备被确定为记账节点,获取所述区块链生成的预设数量的虚拟资源,并将所述虚拟资源下发至与所述目标节点设备对应的账户地址;或者,If the target node device is determined to be an accounting node, obtain a preset number of virtual resources generated by the blockchain, and deliver the virtual resources to the account address corresponding to the target node device; or,如果所述目标节点设备发布的用户信用记录被存储至所述区块链的分布式数据库,获取所述区块链生成的预设数量的虚拟资源,并将所述虚拟资源下发至与所述目标节点设备对应的账户地址;If the user credit record issued by the target node device is stored in the distributed database of the blockchain, obtain a preset number of virtual resources generated by the blockchain, and deliver the virtual resources to the Describe the account address corresponding to the target node device;其中,所述虚拟资源用于取得所述区块链的分布式数据库中存储的用户信用记录的使用权限。Wherein, the virtual resource is used to obtain the usage authority of the user credit record stored in the distributed database of the blockchain.5.根据权利要求4所述的方法,还包括:5. The method of claim 4, further comprising:接收到针对所述分布式数据库的数据查询请求;receiving a data query request for the distributed database;响应于所述数据查询请求,调用与所述数据查询对应的智能合约,从所述目标节点设备对应的账户地址中扣除预设数量的虚拟资源。In response to the data query request, the smart contract corresponding to the data query is invoked, and a preset number of virtual resources are deducted from the account address corresponding to the target node device.6.根据权利要求4或5所述的方法,所述虚拟资源为虚拟积分。6. The method according to claim 4 or 5, wherein the virtual resources are virtual credits.7.根据权利要求1所述的方法,所述区块链包括主链;以及,与主链锚定的若干子链;7. The method of claim 1, the blockchain comprising a main chain; and, several sub-chains anchored to the main chain;所述将基于收集到的所述用户信用记录创建的区块广播发布至所述区块链,包括:The broadcasting of the block created based on the collected user credit records to the blockchain includes:如果所述目标节点设备为所述主链中的节点设备,将基于收集到的当前记账周期内由所述主链以及各子链中的各节点设备广播发布至所述主链,且由所述主链中的各节点设备共同验证通过的用户信用记录创建的区块,广播发布至所述区块链的主链;If the target node device is a node device in the main chain, it will be broadcast and published to the main chain by the main chain and each node device in each sub-chain based on the collected current billing cycle, and published by the main chain. The blocks created by the user credit records that are jointly verified by the node devices in the main chain are broadcast and published to the main chain of the blockchain;如果所述目标节点设备为所述子链中的节点设备,将基于收集到的当前记账周期内由所述子链中的各节点设备广播发布至所述子链,且由所述子链中的各节点设备共同验证通过的用户信用记录创建的区块广播发布至所述区块链的主链。If the target node device is a node device in the sub-chain, broadcast and publish it to the sub-chain based on the collected current billing cycle by each node device in the sub-chain, and the sub-chain The blocks created by the user credit records that are jointly verified by each node device in the system are broadcast and released to the main chain of the blockchain.8.根据权利要求7所述的方法,所述区块链为由若干商家节点设备构成的联盟链;所述联盟链包括主链;以及,与主链锚定的若干子链;其中,不同的子链分别对应不同的商家类型。8. The method according to claim 7, wherein the blockchain is a consortium chain composed of several merchant node devices; the consortium chain comprises a main chain; and, several sub-chains anchored to the main chain; wherein, different The sub-chains correspond to different merchant types.9.一种基于区块链的信用记录共享装置,所述装置包括:9. A device for sharing credit records based on blockchain, the device comprising:获取模块,获取待发布的、包括用于证明用户信用记录的有效性的证明材料的用户信用记录;将所述用户信用记录在区块链中进行广播发布,以由其它各节点设备对所述用户信用记录基于对应的证明材料进行有效性验证,并由其它各节点设备将验证结果在所述区块链中进行广播发布;The obtaining module obtains the user credit record to be released, including the certification materials used to prove the validity of the user credit record; broadcasts the user credit record in the blockchain, so that other node devices can verify the user credit record. The validity of the user credit record is verified based on the corresponding certification materials, and the verification results are broadcast and published in the blockchain by other node devices;接收模块,接收到其它各节点设备广播发布的、包括用于证明用户信用记录的有效性的证明材料的用户信用记录时,对该用户信用记录基于对应的证明材料进行有效性验证,并将验证结果在所述区块链中进行广播发布;The receiving module, when receiving the user credit record broadcasted by other node devices and including the certification materials used to prove the validity of the user credit record, performs validity verification on the user credit record based on the corresponding certification materials, and will verify the validity of the user credit record. The results are broadcast in the blockchain;收集模块,收集当前记账周期内由区块链中的各节点设备广播发布至区块链,且由所述区块链中的各节点设备共同验证通过的用户信用记录;The collection module collects the user credit records that are broadcast and published to the blockchain by each node device in the blockchain in the current accounting cycle, and are jointly verified by each node device in the blockchain;共识模块,确定收集到的用户信用记录对应的发布方节点设备,统计确定出的各发布方节点设备在当前记账周期内发布的用户信用记录的数量,并将在当前记账周期内发布的用户信用记录的数量最多的发布方节点设备,确定为记账节点设备;The consensus module determines the publisher node device corresponding to the collected user credit records, counts the determined number of user credit records published by each publisher node device in the current billing cycle, and will publish the data in the current billing cycle. The publisher node device with the largest number of user credit records is determined as the accounting node device;发布模块,如果所述装置对应的目标节点设备被确定为记账节点,将基于收集到的所述用户信用记录创建的区块广播发布至所述区块链,以在所述区块链的分布式数据库中存储。The publishing module, if the target node device corresponding to the device is determined to be a billing node, broadcasts the block created based on the collected user credit records to the blockchain, so that in the blockchain stored in a distributed database.10.根据权利要求9所述的装置,所述由所述区块链中的各节点设备共同验证通过的用户信用记录包括:由所述区块链中的各节点设备中预设比例的节点设备验证通过的用户信用记录;10. The apparatus according to claim 9, wherein the user credit record jointly verified by each node device in the blockchain comprises: a preset proportion of nodes in each node device in the blockchain User credit records that have passed device verification;所述收集模块:The collection module:收集当前记账周期内由区块链中的各节点设备广播发布至区块链的用户信用记录;以及,所述区块链中的各节点设备对当前记账周期内广播发布至区块链的所述用户信用记录的验证结果;Collect the user credit records broadcasted to the blockchain by each node device in the blockchain in the current accounting cycle; and, each node device in the blockchain broadcasts the current accounting cycle to the blockchain. The verification result of the user's credit record;筛选出当前记账周期内由区块链中的各节点设备广播发布至区块链的用户信用记录中,由各节点设备中预设比例的节点设备验证通过的用户信用记录。Screen out the user credit records broadcasted to the blockchain by each node device in the blockchain in the current accounting cycle, and verified by a preset proportion of node devices in each node device.11.根据权利要求9所述的装置,所述共识模块进一步:11. The apparatus of claim 9, the consensus module further:统计确定出的各发布方节点设备在当前记账周期内发布的,且在所述区块链的分布式数据库中不存在对应的重复记录的用户信用记录的数量。Statistically determine the number of user credit records that are published by each publisher node device within the current billing cycle and have no corresponding duplicate records in the distributed database of the blockchain.12.根据权利要求9所述的装置,所述发布模块进一步:12. The apparatus of claim 9, the publishing module further:如果所述装置对应的目标节点设备被确定为记账节点,获取所述区块链生成的预设数量的虚拟资源,并将所述虚拟资源下发至与所述目标节点设备对应的账户地址;或者,如果所述目标节点设备发布的用户信用记录被存储至所述区块链的分布式数据库,获取所述区块链生成的预设数量的虚拟资源,并将所述虚拟资源下发至与所述目标节点设备对应的账户地址;其中,所述虚拟资源用于取得所述区块链的分布式数据库中存储的用户信用记录的使用权限。If the target node device corresponding to the device is determined to be an accounting node, obtain a preset number of virtual resources generated by the blockchain, and deliver the virtual resources to the account address corresponding to the target node device Or, if the user credit record issued by the target node device is stored in the distributed database of the blockchain, obtain a preset number of virtual resources generated by the blockchain, and issue the virtual resources to the account address corresponding to the target node device; wherein, the virtual resource is used to obtain the use authority of the user credit record stored in the distributed database of the blockchain.13.根据权利要求12所述的装置,所述装置还包括:13. The apparatus of claim 12, further comprising:查询模块,接收到针对所述分布式数据库的数据查询请求;响应于所述数据查询请求,调用与所述数据查询对应的智能合约,从所述目标节点设备对应的账户地址中扣除预设数量的虚拟资源。The query module receives a data query request for the distributed database; in response to the data query request, invokes a smart contract corresponding to the data query, and deducts a preset amount from the account address corresponding to the target node device virtual resources.14.根据权利要求12或13所述的装置,所述虚拟资源为虚拟积分。14. The apparatus of claim 12 or 13, wherein the virtual resources are virtual credits.15.根据权利要求9所述的装置,所述区块链包括主链;以及,与主链锚定的若干子链;15. The apparatus of claim 9, the blockchain comprising a main chain; and, a number of sub-chains anchored to the main chain;所述发布模块:The publishing module:如果所述装置对应的目标节点设备为所述主链中的节点设备,将基于收集到的当前记账周期内由所述主链以及各子链中的各节点设备广播发布至所述主链,且由所述主链中的各节点设备共同验证通过的用户信用记录创建的区块,广播发布至所述区块链的主链;If the target node device corresponding to the device is a node device in the main chain, the main chain and each node device in each sub-chain will broadcast and publish to the main chain based on the collected current accounting cycle. , and the blocks created by the user credit records that are jointly verified by each node device in the main chain are broadcast and published to the main chain of the blockchain;如果所述装置对应的目标节点设备为所述子链中的节点设备,将基于收集到的当前记账周期内由所述子链中的各节点设备广播发布至所述子链,且由所述子链中的各节点设备共同验证通过的用户信用记录创建的区块广播发布至所述区块链的主链。If the target node device corresponding to the device is a node device in the sub-chain, it will be broadcast and published to the sub-chain by each node device in the sub-chain based on the collected current accounting cycle, and the The blocks created by the user credit records that are jointly verified by each node device in the sub-chain are broadcast and released to the main chain of the blockchain.16.根据权利要求15所述的装置,所述区块链为由若干商家节点设备构成的联盟链;所述联盟链包括主链;以及,与主链锚定的若干子链;其中,不同的子链分别对应不同的商家类型。16. The apparatus according to claim 15, wherein the blockchain is a consortium chain composed of several merchant node devices; the consortium chain comprises a main chain; and, several sub-chains anchored to the main chain; wherein, different The sub-chains correspond to different merchant types.17.一种电子设备,包括:17. An electronic device comprising:处理器;processor;用于存储机器可执行指令的存储器;memory for storing machine-executable instructions;其中,通过读取并执行所述存储器存储的与基于区块链的基于区块链的信用记录共享的控制逻辑对应的机器可执行指令,所述处理器被促使:wherein, by reading and executing machine executable instructions stored by the memory corresponding to control logic shared with blockchain-based blockchain-based credit records, the processor is caused to:获取待发布的、包括用于证明用户信用记录的有效性的证明材料的用户信用记录;Obtain the user credit record to be released, including the certification materials used to prove the validity of the user credit record;将所述用户信用记录在区块链中进行广播发布,以由其它各节点设备对所述用户信用记录进行验证,并由其它各节点设备将验证结果在所述区块链中进行广播发布;以及,接收到其它各节点设备广播发布的、包括用于证明用户信用记录的有效性的证明材料的用户信用记录时,对该用户信用记录基于对应的证明材料进行有效性验证,并将验证结果在所述区块链中进行广播发布;Broadcasting and publishing the user credit record in the blockchain, so that other node devices can verify the user credit record, and other node devices will broadcast the verification result in the blockchain; And, when receiving the user credit record broadcasted by other node devices and including the certification material used to prove the validity of the user credit record, the validity of the user credit record is verified based on the corresponding certification material, and the verification result is verified. broadcast in the blockchain;收集当前记账周期内由区块链中的各节点设备广播发布至区块链,且由所述区块链中的各节点设备共同验证通过的用户信用记录;Collect the user credit records that are broadcast and published to the blockchain by each node device in the blockchain during the current accounting cycle, and are jointly verified by each node device in the blockchain;确定收集到的用户信用记录对应的发布方节点设备,统计确定出的各发布方节点设备在当前记账周期内发布的用户信用记录的数量,并将在当前记账周期内发布的用户信用记录的数量最多的发布方节点设备,确定为记账节点设备;Determine the publisher node device corresponding to the collected user credit records, count the determined number of user credit records published by each publisher node device in the current accounting period, and compare the user credit records published in the current accounting period. The publisher node device with the largest number is determined as the accounting node device;如果所述电子设备被确定为记账节点,将基于收集到的所述用户信用记录创建的区块广播发布至所述区块链,以在所述区块链的分布式数据库中存储。If the electronic device is determined to be a billing node, a block created based on the collected credit records of the user is broadcast and published to the blockchain for storage in a distributed database of the blockchain.
CN201810351841.5A2018-04-192018-04-19Credit record sharing method and device based on block chain and electronic equipmentActiveCN108667632B (en)

Priority Applications (2)

Application NumberPriority DateFiling DateTitle
CN201810351841.5ACN108667632B (en)2018-04-192018-04-19Credit record sharing method and device based on block chain and electronic equipment
CN202011475094.XACN112600841B (en)2018-04-192018-04-19Credit record sharing method and device based on block chain and electronic equipment

Applications Claiming Priority (1)

Application NumberPriority DateFiling DateTitle
CN201810351841.5ACN108667632B (en)2018-04-192018-04-19Credit record sharing method and device based on block chain and electronic equipment

Related Child Applications (1)

Application NumberTitlePriority DateFiling Date
CN202011475094.XADivisionCN112600841B (en)2018-04-192018-04-19Credit record sharing method and device based on block chain and electronic equipment

Publications (2)

Publication NumberPublication Date
CN108667632A CN108667632A (en)2018-10-16
CN108667632Btrue CN108667632B (en)2020-10-30

Family

ID=63780304

Family Applications (2)

Application NumberTitlePriority DateFiling Date
CN201810351841.5AActiveCN108667632B (en)2018-04-192018-04-19Credit record sharing method and device based on block chain and electronic equipment
CN202011475094.XAActiveCN112600841B (en)2018-04-192018-04-19Credit record sharing method and device based on block chain and electronic equipment

Family Applications After (1)

Application NumberTitlePriority DateFiling Date
CN202011475094.XAActiveCN112600841B (en)2018-04-192018-04-19Credit record sharing method and device based on block chain and electronic equipment

Country Status (1)

CountryLink
CN (2)CN108667632B (en)

Families Citing this family (48)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN109493171A (en)*2018-10-182019-03-19尚维斯A kind of four-way model of a syndrome based on block chain across chain interaction
CN109409882A (en)*2018-10-182019-03-01中国联合网络通信集团有限公司A kind of credit accreditation storage method and device based on block chain
CN109461080A (en)*2018-10-182019-03-12尚维斯A kind of implementable mode of business based on block chain across chain interaction
CN109447642A (en)*2018-10-182019-03-08尚维斯A method of it is mixed and is known together based on block chain multichain
WO2020082213A1 (en)*2018-10-222020-04-30深圳市哈希树科技有限公司Network expandability blockchain implementation method
CN112232817B (en)2018-10-252024-12-27蚂蚁链技术有限公司 Transaction processing method and device based on blockchain, and electronic device
CN109508968B (en)*2018-10-252020-12-18常州唯康信息科技有限公司Block chain system and control method thereof
CN109493221B (en)*2018-10-262021-01-12全链通有限公司Method, device, network and storage medium for keeping transaction records secret in block chain
CN109639430B (en)*2018-11-092020-05-26北京航空航天大学Safe high-speed lightweight block chain system and method
CN109583912A (en)*2018-11-142019-04-05阿里巴巴集团控股有限公司Trade company's authentication method and device based on block chain
CN109493052B (en)*2018-11-212021-07-30北京蓝石环球区块链科技有限公司Cross-chain contract system based on main chain and parallel multiple sub-chains
CN111260362A (en)*2018-12-032020-06-09北京京东尚科信息技术有限公司Information processing method and device of block chain network and storage medium
CN110471953B (en)*2018-12-072023-05-26深圳市智税链科技有限公司Method, proxy node and medium for determining accounting node in blockchain network
CN109711869B (en)*2018-12-122020-05-05杭州基尔区块链科技有限公司Chip research and development transaction data storage method and system
CN109684519B (en)*2018-12-122020-04-03杭州基尔区块链科技有限公司Decentralized chip research and development transaction data storage method and system based on block chain
CN109784882A (en)*2018-12-142019-05-21深圳壹账通智能科技有限公司Alliance's chain information distribution control method and terminal device
CN109657450B (en)*2018-12-142021-04-16泰康保险集团股份有限公司Method, device, medium, and electronic device for evaluation based on block chain
CN110009337B (en)*2018-12-212020-04-21阿里巴巴集团控股有限公司 A method and device for data processing based on blockchain
CN109886659A (en)*2018-12-292019-06-14平安健康保险股份有限公司Virtual resource allocation method, apparatus and computer equipment based on block chain
CN109886677B (en)*2018-12-292021-06-29创新先进技术有限公司Commodity purchasing method and device based on block chain
CN111401889B (en)*2019-01-032023-08-18百度在线网络技术(北京)有限公司Credit data processing method, device, equipment and medium based on block chain
CN109902109B (en)*2019-02-202021-04-30北京邮电大学Multi-party collaborative data mining method and device
CN109902091B (en)2019-02-212021-08-10腾讯科技(深圳)有限公司Method for recording data blocks on block chain, leading accounting node and medium
CN109743408A (en)*2019-03-052019-05-10北京比新科技有限公司A kind of telecom client method of servicing based on block chain
CN109886695A (en)*2019-03-262019-06-14阿里巴巴集团控股有限公司Information sharing method and device and electronic equipment between different blocks chain
CN110059136A (en)*2019-04-172019-07-26江苏全链通信息科技有限公司Information storage means, equipment and storage medium based on domain name block chain
CN110175831B (en)*2019-04-232023-09-29创新先进技术有限公司Credit transfer method and device based on blockchain and electronic equipment
CN110109929A (en)*2019-04-302019-08-09翟红鹰Date storage method, device and computer readable storage medium
CN110928677B (en)*2019-09-302022-09-06咪咕文化科技有限公司Virtual resource calculation method and device based on block chain, electronic equipment and storage medium
CN110674222B (en)*2019-10-082021-08-13腾讯科技(深圳)有限公司Data sharing method, device, equipment and medium
CN110942383A (en)*2019-11-262020-03-31支付宝(杭州)信息技术有限公司Risk processing method and device based on credit organization
CN111127144A (en)*2019-12-162020-05-08中国联合网络通信集团有限公司 User credit evaluation method, device and storage medium
CN111242718B (en)*2019-12-182024-01-19深圳大学Block chain-based data transaction method, device, equipment and medium
CN111292093B (en)*2020-05-092020-12-04支付宝(杭州)信息技术有限公司Risk control method and system based on double block chains
CN111862486A (en)*2020-07-222020-10-30中国工商银行股份有限公司Card making method, device and system based on alliance chain
CN111932254B (en)*2020-08-112024-03-22杭州萌格信息科技有限公司Application method of block chain multi-chain parallel structure
CN112308557A (en)*2020-11-182021-02-02盐城鸿石智能科技有限公司Credit consumption system based on 3D camera and block chain and implementation method thereof
CN113012466A (en)*2021-02-232021-06-22中国联合网络通信集团有限公司Parking space sharing method based on block chain, user node, equipment and storage medium
CN113065775A (en)*2021-04-062021-07-02国网浙江省电力有限公司物资分公司 A Bidding System Based on Blockchain
CN113256149A (en)*2021-06-112021-08-13武汉龙津科技有限公司Block chain node reputation adjusting method and device, electronic equipment and storage medium
CN113506100B (en)*2021-06-252023-08-08网易(杭州)网络有限公司Alliance chain data processing method, device, computer equipment and storage medium
CN113706297B (en)*2021-09-062024-11-22中国银行股份有限公司Accounting node selection method and device based on alliance chain
CN114297171B (en)*2021-12-312025-07-29蚂蚁区块链科技(上海)有限公司Account data reading and writing method and device
CN114444097A (en)*2022-01-112022-05-06支付宝(杭州)信息技术有限公司 Blockchain-based user access method, device, electronic device and storage medium
CN114519208B (en)*2022-02-222025-09-12中国建设银行股份有限公司 A product selection test method, alliance chain and selection test platform node
CN115120985A (en)*2022-06-072022-09-30网易(杭州)网络有限公司 Reputation point processing method and related device based on blockchain
CN114971919A (en)*2022-06-142022-08-30中国银行股份有限公司 A fund management method and device
CN115757310B (en)*2022-11-042025-08-01招联消费金融股份有限公司Credit information sharing method, apparatus, computer device and storage medium

Citations (8)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN105488675A (en)*2015-11-252016-04-13布比(北京)网络技术有限公司Distributed shared general ledger construction method of block chain
CN105976231A (en)*2016-06-242016-09-28深圳前海微众银行股份有限公司Asset management method based on intelligent block chain contracts and nodes
CN106651346A (en)*2016-11-282017-05-10上海凯岸信息科技有限公司Block chain-based credit investigation data sharing and trading system
CN107169865A (en)*2017-04-242017-09-15北京果仁宝科技有限公司Asset data processing system based on block chain technology
TW201732697A (en)*2016-03-152017-09-16現代財富控股有限公司Clearing system based on blockchain and method thereof
TW201741969A (en)*2016-05-302017-12-01富邦金融控股股份有限公司System and method based on blockchain for providing financial end networking
CN107563754A (en)*2017-08-172018-01-09杭州云象网络技术有限公司A kind of storage of serial number information and verification method based on block chain
CN107862215A (en)*2017-09-292018-03-30阿里巴巴集团控股有限公司A kind of date storage method, data query method and device

Family Cites Families (12)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
US9875510B1 (en)*2015-02-032018-01-23Lance KasperConsensus system for tracking peer-to-peer digital records
US10013573B2 (en)*2015-12-162018-07-03International Business Machines CorporationPersonal ledger blockchain
CN105719185B (en)*2016-01-222019-02-15杭州复杂美科技有限公司The data comparison and common recognition method of block chain
AU2017216289A1 (en)*2016-02-042018-09-27Nasdaq Technology AbSystems and methods for storing and sharing transactional data using distributed computer systems
KR101701131B1 (en)*2016-04-282017-02-13주식회사 라피Data recording and validation methods and systems using the connecting of blockchain between different type
US20170357966A1 (en)*2016-06-092017-12-14Mastercard International IncorporatedMethod and system for use of a proprietary private blockchain
US10565570B2 (en)*2016-09-272020-02-18The Toronto-Dominion BankProcessing network architecture with companion database
CN106452785B (en)*2016-09-292019-05-17财付通支付科技有限公司Block chain network, branch node and block chain network application method
CN106682907A (en)*2016-12-102017-05-17江苏恒为信息科技有限公司Comparison and consensus method for block chain data
CN106878000B (en)*2017-03-062020-02-21中钞信用卡产业发展有限公司杭州区块链技术研究院Alliance chain consensus method and system
CN107464112B (en)*2017-07-202021-05-25捷德(中国)科技有限公司Transaction management method and system based on block chain
CN107864198B (en)*2017-11-072019-09-24山东浪潮人工智能研究院有限公司A kind of block chain common recognition method based on deep learning training mission

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN105488675A (en)*2015-11-252016-04-13布比(北京)网络技术有限公司Distributed shared general ledger construction method of block chain
TW201732697A (en)*2016-03-152017-09-16現代財富控股有限公司Clearing system based on blockchain and method thereof
TW201741969A (en)*2016-05-302017-12-01富邦金融控股股份有限公司System and method based on blockchain for providing financial end networking
CN105976231A (en)*2016-06-242016-09-28深圳前海微众银行股份有限公司Asset management method based on intelligent block chain contracts and nodes
CN106651346A (en)*2016-11-282017-05-10上海凯岸信息科技有限公司Block chain-based credit investigation data sharing and trading system
CN107169865A (en)*2017-04-242017-09-15北京果仁宝科技有限公司Asset data processing system based on block chain technology
CN107563754A (en)*2017-08-172018-01-09杭州云象网络技术有限公司A kind of storage of serial number information and verification method based on block chain
CN107862215A (en)*2017-09-292018-03-30阿里巴巴集团控股有限公司A kind of date storage method, data query method and device

Also Published As

Publication numberPublication date
CN108667632A (en)2018-10-16
CN112600841B (en)2023-09-19
CN112600841A (en)2021-04-02

Similar Documents

PublicationPublication DateTitle
CN108667632B (en)Credit record sharing method and device based on block chain and electronic equipment
US12273470B2 (en)Data processing method and apparatus, intelligent device, and storage medium
JP7450339B2 (en) Systems, methods, and computer programs for resource fairness for blockchain
US11171789B2 (en)System and method for implementing a resolver service for decentralized identifiers
TWI679874B (en) Cross-blockchain authentication method and device, and electronic equipment
TWI694390B (en) Blockchain-based transaction processing method and device, and electronic equipment
CN112651740B (en)Block chain transaction method and device and electronic equipment
CN112020705B (en)Blockchain random timer transaction synchronization
US11556925B2 (en)Ensuring information fairness and input privacy using a blockchain in a competitive scenario governed by a smart contract
US20200374113A1 (en)Decentralized application platform for private key management
WO2021184826A1 (en)Blockchain-based resource transfer method and apparatus, and node device and storage medium
CN108805569A (en)Transaction processing method and device, electronic equipment based on block chain
CN109726887A (en) Blockchain-based mobile crowdsourcing data collection and processing system and method
US11397919B1 (en)Electronic agreement data management architecture with blockchain distributed ledger
CN110601816A (en)Lightweight node control method and device in block chain system
CN110569666A (en) A method and device for data statistics based on blockchain
CN112418851A (en)Digital copyright registration, transaction and protection method and system
CN116032937A (en) A computing power trading method and system for an edge computing device
CN115660840A (en)Transaction method and system based on block chain and block chain system
KR101120059B1 (en)Billing verifying apparatus, billing apparatus and method for cloud computing environment
JP2020047216A (en) Billing information generating program, billing information generating device, and billing information generating method
Xu et al.Blockchain‐Based Trust Auction for Dynamic Virtual Machine Provisioning and Allocation in Clouds
CN110766407A (en)Transaction verification method, accounting node and medium based on block chain
HK1262026B (en)Blockchain-based credit record sharing method and device and electronic equipment
HK1262026A1 (en)Blockchain-based credit record sharing method and device and electronic equipment

Legal Events

DateCodeTitleDescription
PB01Publication
PB01Publication
SE01Entry into force of request for substantive examination
SE01Entry into force of request for substantive examination
REGReference to a national code

Ref country code:HK

Ref legal event code:DE

Ref document number:1262026

Country of ref document:HK

TA01Transfer of patent application right

Effective date of registration:20200924

Address after:Cayman Enterprise Centre, 27 Hospital Road, George Town, Grand Cayman Islands

Applicant after:Innovative advanced technology Co.,Ltd.

Address before:Cayman Enterprise Centre, 27 Hospital Road, George Town, Grand Cayman Islands

Applicant before:Advanced innovation technology Co.,Ltd.

Effective date of registration:20200924

Address after:Cayman Enterprise Centre, 27 Hospital Road, George Town, Grand Cayman Islands

Applicant after:Advanced innovation technology Co.,Ltd.

Address before:A four-storey 847 mailbox in Grand Cayman Capital Building, British Cayman Islands

Applicant before:Alibaba Group Holding Ltd.

TA01Transfer of patent application right
GR01Patent grant
GR01Patent grant

[8]ページ先頭

©2009-2025 Movatter.jp