Credit information sharing method, center node and storage medium
Through the generation and aggregation of signatures of central nodes, the problems of data reliability and efficiency in blockchain are solved, and the rapid linking of credit information and data reliability are achieved.
Patent Information
- Application Number
- CN202510683753.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-26
- Publication Date
- 2025-07-18
AI Technical Summary
When sharing and storing data, existing blockchains do not consider the situation of malicious nodes, resulting in poor data reliability and when the number of master nodes is large, multiple rounds of broadcasting and signature authentication verification are required, which is inefficient.
The credit information sharing method is adopted to generate a hash signature through the central node, broadcast the shared party's signature and receive the shared party's signature, aggregate the signature and determine the shared information and write it to the blockchain to achieve rapid linkage, and at the same time, the principle of insufficient trust is used to verify the data.
It realizes the rapid linkage of credit information, improves the data reliability in the alliance blockchain, prevents information tampering, and improves data sharing efficiency.
Smart Images

Figure CN120342578A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of information security technology, and particularly to a method for sharing credit information, a central node, and a storage medium. Background Art
[0002] Blockchain is a distributed ledger technology jointly maintained by multiple parties, which ensures the security of transmission and access through cryptography, can achieve consistent data storage, is difficult to tamper with, and prevents repudiation. Blockchain has features such as decentralization, immutability, transparent traceability, and collective maintenance, and has been widely applied in fields such as finance, supply chain, healthcare, and real estate.
[0003] When the existing blockchain shares and stores data, the off-chain nodes obtain the on-chain data on the premise of fully trusting the main node, without considering the situation of malicious nodes, resulting in poor data reliability. Moreover, if there are a large number of main nodes, then each main node needs to perform multiple rounds of broadcasting and signature authentication to achieve verification / reach consensus. Summary of the Invention
[0004] The present invention provides a method for sharing credit information, a central node, and a storage medium, which can achieve the rapid uploading of credit information while ensuring data reliability.
[0005] According to an aspect of the present invention, there is provided a method for sharing credit information, which is applied to any one of a plurality of central nodes included in a consortium blockchain. When the central node is a sharing party and other central nodes are sharing parties, the method includes: generating a first hash value according to the first credit information, and signing the first hash value to obtain a first sharing party signature; broadcasting the first sharing party signature, and receiving the first shared party signatures sent by all other central nodes, where the first shared party signature is obtained by other central nodes signing the first hash value after verifying and passing the first sharing party signature; determining the first shared information according to the first aggregated signature and the first credit information, where the first aggregated signature includes the first sharing party signature and all the first shared party signatures; broadcasting the first shared information, so that after other central nodes verify and pass the first shared information, they write the first credit information into the corresponding blockchain.
[0006] Optionally, an aggregated public key of the consortium blockchain is stored in each of the multiple central nodes included in the consortium blockchain; when another central node serves as the sharing party, and the central node and the remaining central nodes other than the other central nodes serving as the sharing party serve as the shared parties, the method further includes: receiving a second sharing party signature broadcast by the other central node serving as the sharing party, where the second sharing party signature is obtained by the other central node serving as the sharing party signing a second hash value, and the second hash value is generated according to second credit information; after verifying and passing the second sharing party signature, signing the second hash value to obtain a second shared party signature; sending the second shared party signature to the other central node serving as the sharing party, and receiving second sharing information broadcast by the other central node serving as the sharing party, where the second sharing information is determined by the other central node serving as the sharing party according to a second aggregated signature and the second credit information, and the second aggregated signature includes the second sharing party signature and all second shared party signatures; verifying the second sharing information according to the aggregated public key, and writing the second credit information into the corresponding blockchain after the verification passes.
[0007] Optionally, all central nodes included in the consortium blockchain determine public parameters through a consensus mechanism; where the public parameters include a first additive group, a second additive group, a first generator, a second generator, a multiplicative group, a first hash function, and a second hash function; the first generator is the generator of the first additive group, the second generator is the generator of the second additive group, and the first additive group, the second additive group, and the multiplicative group satisfy a bilinear mapping relationship.
[0008] Optionally, the aggregated public key is aggregated from the keys corresponding to all central nodes included in the consortium blockchain, and the key corresponding to a central node is determined according to the public key of the central node, the second hash function, and the public keys of all central nodes included in the consortium blockchain.
[0009] Optionally, generating a first hash value according to the first credit information and signing the first hash value to obtain a first sharing party signature includes: generating a first hash value according to the first credit information and the first hash function; using the private key of the central node, the second hash function, and the public keys of all central nodes included in the consortium blockchain to sign the first hash value to obtain a first sharing party signature.
[0010] Optionally, verifying the second sharing information according to the aggregated public key includes: determining whether the value of the second aggregated signature and the second generator under the bilinear mapping relationship is equal to the value of the second hash value and the aggregated public key under the bilinear mapping relationship; if so, determining that the verification of the second sharing information passes; if not, determining that the verification of the second sharing information fails.
[0011] Optionally, the method further includes: receiving a query request sent by an off-chain node, where the central node is the central node closest to the off-chain node or the central node with the lowest load at the current moment, the off-chain node stores the aggregated public key of the consortium blockchain, and the query request includes a user identifier; determining third shared information according to the user identifier, where the third shared information is determined according to the third aggregated signature and the third credit information, and the user identifier corresponds to the third credit information; signing the third shared information and sending the signed third shared information to the off-chain node, so that after the off-chain node verifies and passes the signed third shared information, it further verifies the third shared information according to the aggregated public key, and obtains the third credit information after the secondary verification passes.
[0012] Optionally, signing the third shared information includes: signing the third shared information with the private key of the central node to obtain the signed third shared information.
[0013] According to another aspect of the present invention, a central node is provided, and the central node includes: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores a computer program executable by the at least one processor, and the computer program is executed by the at least one processor to enable the at least one processor to execute the method for sharing credit information according to any embodiment of the present invention.
[0014] According to another aspect of the present invention, a computer-readable storage medium is provided, and the computer-readable storage medium stores computer instructions for enabling a processor to implement the method for sharing credit information according to any embodiment of the present invention when executed.
[0015] In the technical solution of the embodiment of the present invention, for the central node as the sharing party, by processing the first credit information to be shared, a first shared party signature is obtained; then the first shared party signature is broadcast, and the first shared party signatures sent by all other central nodes are received, so as to jointly form a first aggregated signature based on the first shared party signature and all the first shared party signatures; finally, according to the first aggregated signature and the first credit information, the first shared information is determined and broadcast, so that after other central nodes verify and pass the first shared information, the first credit information is written into the corresponding blockchain. Since the central node as the sharing party only needs to broadcast twice to share credit information within the consortium blockchain, the rapid uploading of credit information can be achieved. At the same time, other central nodes will verify any data broadcast by the received central node, that is, adhering to the principle of not fully trusting the on-chain nodes, which can ensure that the information is not tampered with and improve the data reliability within the consortium blockchain.
[0016] It should be understood that the content described in this part is not intended to identify the key or important features of the embodiments of the present invention, nor is it used to limit the scope of the present invention. Other features of the present invention will become readily understood from the following description. Description of the Drawings
[0017] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the following briefly introduces the drawings required for the description of the embodiments. Obviously, the drawings in the following description are only some embodiments of the present invention. For those of ordinary skill in the art, without creative efforts, other drawings can be obtained based on these drawings.
[0018] Figure 1 is an architecture diagram of a consortium blockchain provided in Embodiment 1 of the present invention;
[0019] Figure 2 is a schematic flowchart of a method for sharing credit information provided in Embodiment 1 of the present invention;
[0020] Figure 3 is a schematic flowchart of another method for sharing credit information provided in Embodiment 1 of the present invention;
[0021] Figure 4 is a schematic diagram of an addition operation on an elliptic curve provided in Embodiment 2 of the present invention;
[0022] Figure 5 is a schematic structural diagram of a device for sharing credit information provided in Embodiment 3 of the present invention;
[0023] Figure 6 is a schematic structural diagram of a central node provided in Embodiment 4 of the present invention. Detailed Embodiments
[0024] In order to enable those skilled in the art to better understand the solutions of the present invention, the following clearly and completely describes the technical solutions in the embodiments of the present invention with reference to the drawings in the embodiments of the present invention. Obviously, the described embodiments are only some of the embodiments of the present invention, rather than all the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative efforts shall fall within the protection scope of the present invention.
[0025] It should be noted that the terms "first", "second", "third", "other", "remaining", etc. in the description, claims and the above-mentioned drawings of the present invention are used to distinguish similar objects, and do not necessarily describe a specific order or sequence. It should be understood that the data used in this way can be interchanged under appropriate circumstances, so that the embodiments of the present invention described here can be implemented in an order other than those illustrated or described here. In addition, the terms "comprising" and "having" and any variations thereof are intended to cover non-exclusive inclusion. For example, a process, method, system, product or device comprising a series of steps or units does not necessarily have to be limited to those steps or units clearly listed, but may include other steps or units not clearly listed or inherent to these processes, methods, products or devices.
[0026] It should also be noted that all steps such as the collection, storage, use, and processing of credit information and user information in the present invention comply with the relevant regulations of national laws and regulations.
[0027] Embodiment 1
[0028] Figure 1 is an architecture diagram of a consortium blockchain provided by Embodiment 1 of the present invention. As Figure 1 shown, a consortium blockchain is a blockchain between a public blockchain and a private blockchain, jointly maintained by multiple central nodes included in the consortium blockchain. The central nodes are nodes on the chain and directly participate in the consensus, data storage, and transaction processing of the main chain of the consortium blockchain. The central nodes can be connected to off-chain nodes, and the off-chain nodes do not directly participate in the consensus, data storage, and transaction processing of the main chain of the consortium blockchain. The central nodes adhere to the principle of insufficient trust. In the consortium blockchain, the voting rights for the addition of new nodes and the generation of new blocks are on the pre-set nodes, and the un-set nodes can only participate in transactions. The relevant information in the consortium blockchain will be protected, but its query permission is public, and even entities not in the consortium blockchain can query through the pre-set open interfaces.
[0029] Exemplarily, assuming Figure 1 the consortium blockchain shown is a blockchain in the credit finance field, then one central node can correspond to one credit institution, and the off-chain nodes managed by this central node can be the subsidiaries or branches of this credit institution.
[0030] Figure 2 is a schematic flowchart of a method for sharing credit information provided by Embodiment 1 of the present invention. This embodiment is applicable to the situation of sharing credit information in the Figure 1 consortium blockchain shown. This method can be executed by a credit information sharing device, which can be implemented in the form of hardware and / or software, and the credit information sharing device can be configured in Figure 1in any one of the multiple central nodes included in the shown consortium blockchain. As Figure 2 shown, when this central node is the sharing party and other central nodes are the shared parties, the method includes:
[0031] S110. Generate a first hash value according to the first credit information, and sign the first hash value to obtain a first sharing party signature.
[0032] The method for sharing credit information provided by the present invention can be applied to various financial scenarios. The credit information may include at least one of the following information: basic information, credit transaction information, and public information. Basic information is the basic information for identifying the identity of the financial transaction subject; credit transaction information is the core information reflecting the credit behavior of the financial transaction subject in the transaction and is crucial for evaluating its credit status; public information is the social public record closely related to the credit status of the financial transaction subject, which can make the credit assessment result more comprehensive and accurate.
[0033] In the present invention, the sharing party refers to the party that initiates the sharing, and the shared party refers to the party that receives the credit information. A central node can act as both a sharing party and a shared party. Exemplarily, it is assumed that there are 3 central nodes in the consortium blockchain, denoted as central node 1, central node 2, and central node 3 respectively. When central node 1 is the sharing party, central node 2 and central node 3 are the shared parties; when central node 2 is the sharing party, central node 1 and central node 3 are the shared parties; when central node 3 is the sharing party, central node 1 and central node 2 are the shared parties.
[0034] In an embodiment, the first credit information can be processed by using a hash algorithm (such as the Secure Hash Algorithm). The hash algorithm will map the first credit information of any length into a binary value of a fixed length through complex mathematical operations, and this binary value is the first hash value. Then, the first hash value is signed to implement the encryption of the first hash value, and a first sharing party signature is obtained. Among them, the encryption process can be performed by using a public key cryptography algorithm (such as an asymmetric encryption algorithm, an elliptic curve public key cryptography algorithm, etc.). By signing the first hash value, the first sharing party signature has uniqueness and non-forgeability.
[0035] Optionally, before step S110 is executed, the consortium blockchain can also be initialized. During the initialization process, all central nodes determine the public parameters through a consensus mechanism. In one implementation, the public parameters include a first additive group, a second additive group, a first generator, a second generator, a multiplicative group, a first hash function, and a second hash function; the first generator is the generator of the first additive group, the second generator is the generator of the second additive group, and the first additive group, the second additive group, and the multiplicative group satisfy a bilinear mapping relationship.
[0036] On the basis of determining the common parameters, a first hash value can be generated according to the first credit information and the first hash function; then, the private key of the central node, the second hash function, and the public keys of all central nodes included in the consortium blockchain are used to sign the first hash value to obtain a first shared party signature.
[0037] S120. Broadcast the first shared party signature and receive the first signature of the shared party sent by all other central nodes. Among them, the first signature of the shared party is obtained by other central nodes signing the first hash value after verifying and passing the first shared party signature.
[0038] Broadcasting the first shared party signature enables all other central nodes in the consortium blockchain to verify the first shared party signature in parallel, thus improving the data sharing efficiency.
[0039] The number of first signatures of the shared party received by the central node corresponds to the number of other central nodes. For example, if the number of other central nodes is 3, then the number of first signatures of the shared party received by the central node is also 3.
[0040] The first signature of the shared party is obtained by other central nodes signing the first hash value after verifying and passing the first shared party signature. Specifically, other central nodes can use the public key cryptography algorithm in the above step S110 to decrypt the first shared party signature and verify its reliability; if it is reliable, the public key cryptography algorithm is used again to sign the first hash value to encrypt the first hash value and obtain the first signature of the shared party.
[0041] S130. Determine the first shared information according to the first aggregated signature and the first credit information, where the first aggregated signature includes the first shared party signature and all first signatures of the shared party.
[0042] Since the first shared party signature and all first signatures of the shared party have been obtained in the above steps S110 - S120, the first shared party signature and all first signatures of the shared party can be aggregated to obtain the first aggregated signature. The first aggregated signature has a corresponding relationship with the first credit information, that is, the first aggregated signature is an aggregated signature for sharing the first credit information.
[0043] Pack the first aggregated signature and the first credit information into a transaction, and this transaction is the first shared information.
[0044] S140. Broadcast the first shared information so that after other central nodes verify and pass the first shared information, they write the first credit information into the corresponding blockchain.
[0045] Broadcast the first shared information so that all other central nodes in the consortium blockchain can verify the first shared information in parallel, thereby improving the data sharing efficiency. Moreover, as long as the first shared information passes the verification, other central nodes can write the first credit information into the corresponding blockchain. That is, the central node as the sharing party only needs to broadcast twice to share the credit information within the consortium blockchain, realizing the fast uploading of credit information to the blockchain.
[0046] Based on the above embodiments, Figure 3 is a schematic flowchart of another method for sharing credit information provided in the first embodiment of the present invention. As Figure 3 shown, since a central node can act as both a sharing party and a shared party, when another central node acts as the sharing party, and this central node and the remaining central nodes except the other central nodes acting as the sharing party act as the shared parties, the method further includes:
[0047] S150. Receive the second sharing party signature broadcast by another central node acting as the sharing party, where the second sharing party signature is obtained by the other central node acting as the sharing party signing the second hash value, and the second hash value is generated according to the second credit information.
[0048] In an embodiment, the method for the other central node acting as the sharing party to sign the second hash value to obtain the second sharing party signature and the method for generating the second hash value according to the second credit information are similar to step S110, and the description of step S110 can be referred to, which will not be elaborated here.
[0049] S160. After verifying and passing the second sharing party signature, sign the second hash value to obtain the second shared party signature.
[0050] Specifically, signing the second hash value realizes the encryption of the second hash value to obtain the second sharing party signature. Among them, the encryption process can be carried out using a public key cryptography algorithm (such as an asymmetric encryption algorithm, an elliptic curve public key cryptography algorithm, etc.). By signing the second hash value, the second shared party signature has uniqueness and non-forgeability.
[0051] S170. Send the second shared party signature to the other central node acting as the sharing party, and receive the second shared information broadcast by the other central node acting as the sharing party, where the second shared information is determined by the other central node acting as the sharing party according to the second aggregated signature and the second credit information, and the second aggregated signature includes the second sharing party signature and all second shared party signatures.
[0052] Specifically, since the central node and the remaining central nodes other than the other central nodes acting as sharing parties have sent the second shared party signatures determined by themselves to the other central nodes acting as sharing parties, the other central nodes acting as sharing parties can aggregate the second sharing party signatures and all the second shared party signatures to obtain a second aggregated signature; then determine the second shared information based on the second aggregated signature and the second credit information. The second aggregated signature has a corresponding relationship with the second credit information, that is, the second aggregated signature is the aggregated signature used to share the second credit information. The other central nodes acting as sharing parties package the second aggregated signature and the second credit information into a transaction, and this transaction is the second shared information.
[0053] S180. Verify the second shared information according to the aggregated public key, and write the second credit information into the corresponding blockchain after the verification passes.
[0054] The aggregated public key is a key pre-stored in each central node included in the consortium blockchain and used to verify the shared information. Optionally, the aggregated public key can also be stored in an off-chain node.
[0055] In one embodiment, the aggregated public key is aggregated by the keys corresponding to all the central nodes included in the consortium blockchain, and the key corresponding to a central node is determined according to the public key of this central node, the second hash function, and the public keys of all the central nodes included in the consortium blockchain.
[0056] Verify the second shared information using the aggregated public key. If the verification passes, it means that the second shared information has not been tampered with and is secure information. At this time, directly write the second credit information into the corresponding blockchain to complete the on-chain process; if the verification fails, it means that the second shared information may have been tampered with and is not secure information. At this time, discard the second shared information.
[0057] On the basis of determining the public parameters, it can be determined whether the values of the second aggregated signature and the second generator under the bilinear mapping relationship are equal to the values of the second hash value and the aggregated public key under the bilinear mapping relationship; if so (that is, the values of the second aggregated signature and the second generator under the bilinear mapping relationship are equal to the values of the second hash value and the aggregated public key under the bilinear mapping relationship), it is determined that the verification of the second shared information passes; if not (that is, the values of the second aggregated signature and the second generator under the bilinear mapping relationship are not equal to the values of the second hash value and the aggregated public key under the bilinear mapping relationship), it is determined that the verification of the second shared information fails.
[0058] Further optionally, based on the above embodiments, the central node may also respond to the query requests of off-chain nodes. Specifically, it receives the query requests sent by the off-chain nodes, where the central node is the central node closest to the off-chain node or the central node with the lowest load at the current moment. The off-chain node stores the aggregated public key of the consortium blockchain, and the query request includes a user identifier. According to the user identifier, the third shared information is determined, where the third shared information is determined based on the third aggregated signature and the third credit information, and the user identifier corresponds to the third credit information. Sign the third shared information and send the signed third shared information to the off-chain node, so that after the off-chain node verifies and passes the signed third shared information, it further verifies the third shared information based on the aggregated public key and obtains the third credit information after the secondary verification passes.
[0059] Specifically, the central node may use the private key of the central node to sign the third shared information to obtain the signed third shared information.
[0060] In the present invention, the third credit information may be the first credit information or the second credit information, or any other credit information stored in the consortium blockchain.
[0061] For the central node as the sharing party, the technical solution of the embodiment of the present invention processes the first credit information to be shared to obtain the first sharing party signature; then broadcasts the first sharing party signature and receives the first shared party signatures sent by all other central nodes, so as to jointly form the first aggregated signature based on the first sharing party signature and all the first shared party signatures; finally, determines and broadcasts the first shared information based on the first aggregated signature and the first credit information, so that after other central nodes verify and pass the first shared information, they write the first credit information into the corresponding blockchain. Since the central node as the sharing party only needs to broadcast twice to realize the sharing of credit information within the consortium blockchain, the rapid on-chain of credit information can be achieved. At the same time, other central nodes will verify any data broadcast by the received central nodes, that is, adhering to the principle of not fully trusting the on-chain nodes, it can ensure that the information is not tampered with and improve the data reliability within the consortium blockchain.
[0062] Embodiment 2
[0063] Based on the above Embodiment 1, this embodiment provides a method for sharing credit information based on the elliptic curve public key cryptography algorithm. In the elliptic curve cryptosystem, the classic elliptic curve is a curve that satisfies the following equation: Y 2 Z + a1XYZ + a3YZ 2 = X 3 + a2X 2 Z + a4XZ 2+a6Z 3 In cryptography, a relatively common elliptic curve equation is y 2 = x 3 + ax + b, where the parameters a and b satisfy: 4a 3 + 27b 2 ≠ 0. Figure 4 This is a schematic diagram of the addition operation on an elliptic curve provided in the second embodiment of the present invention. As Figure 4 shown, take any two points P and Q on the curve, connect the two points P and Q, and the straight line intersects the curve at point G (if points P and Q coincide, then make the tangent of this point). Draw a perpendicular line to the X-axis through point G and intersect the curve at point R. Constructing the above elliptic curve on a finite field becomes the basis of the elliptic curve public key cryptography algorithm, and its specific form is: y 2 (mod q) = x 3 + ax + b (mod q), where Δ(4a 3 + 27b 2 )(mod q) ≠ 0. Denote it as E q (a, b), which also includes the infinite point O as the identity element, and q is the characteristic value of the finite field GF(q) where E q (a, b) is located.
[0064] The method for sharing credit information based on the elliptic curve public key cryptography algorithm includes three steps in total.
[0065] Step 1: Initialize the consortium blockchain.
[0066] For each central node in the consortium blockchain, all central nodes determine the public parameters through a consensus mechanism. Among them, the public parameters include the cyclic additive group G1 of order q, the cyclic additive group G2, the cyclic multiplicative group Gt of the same order, the generator g1 of G1, the generator g2 of G2, the first hash function H0: {0, 1} * → G1 and the second hash function H1: {0, 1} * → Z q , where q is a large prime number. G1, G2, and Gt satisfy the bilinear mapping relationship e: G1 × G2 → G t .
[0067] The private key of the i-th central node is sk i , which is a random number selected by this central node. And based on the private key sk i generate the public key pk i = sk i * g1. Each central node securely stores the private key and broadcasts the public key to other central nodes through a secure channel. After each central node receives the public keys of other central nodes, it generates and stores the aggregated public key a i= H1(pk i , (pk1,..., pk N ))), where N is the total number of central nodes included in the consortium blockchain. All central nodes jointly maintain the consortium blockchain. The off-chain nodes managed by the central nodes have both sending and receiving functions. After the successful initialization of the consortium blockchain, the central nodes will broadcast the aggregated public key apk to the off-chain nodes they are responsible for managing, and the off-chain nodes locally store the aggregated public key apk. Each central node can be a sharing party of credit information, and each central node can query information for off-chain nodes (such as ordinary nodes in the consortium blockchain) and return a sequence of verification values.
[0068] Step 2: Sharing of credit information
[0069] When the nth central node needs to share credit information credit as a sharing party, according to the credit information credit and the first hash function H0: {0, 1} * → G1 to generate the hash value H0(credit); then use the private key sk of the nth central node n , the second hash function H1: {0, 1} * → Z q and the public keys of all central nodes included in the consortium blockchain to sign the hash value H0(credit) to obtain the sharing party signature sig n = sk n * a n * H0(credit), a n = H1(pk n , (pk1,..., pk N ))). The nth central node broadcasts the sharing party signature sig n to other central nodes.
[0070] Other central nodes verify the sharing party signature sig n = sk n * a n * H0(credit), and after passing the verification, sign the hash value H0(credit) to obtain the shared party signature sig m , where m takes other values except n. Send the shared party signature sig m to the nth central node so that the nth central node aggregates the sharing party signature sig n and the shared party signature sig m to obtain the aggregated signature
[0071] The nth central node will use the aggregated signature sig aggThe credit information cerdit is packaged into shared information, and the shared information is broadcast to other central nodes. After receiving the shared information, other central nodes verify the shared information based on the aggregated public key apk. If e(sig agg ,g2) = e(H0(cerdit),apk), then the shared information passes the verification. At this time, other central nodes write the credit information cerdit into the corresponding blockchain, and the process of uploading to the chain can be completed.
[0072] Step 3: Query of credit information
[0073] When the off-chain node Node needs to query credit information, it can broadcast a query request. The central node closest to the off-chain node or the central node with the lowest load at the current moment receives the query request sent by the off-chain node, and determines the user identifier Info cer included in the query request. The central node x determines whether there is relevant shared information on the corresponding blockchain according to the user identifier Info cer . If there is no relevant shared information, after notifying the off-chain node Node, the process ends; if there is relevant shared information, the private key sk x of the central node x is used to Info sign the shared information Tir x , and the signed shared information sig Info = Tir x * sk
[0074] is obtained. The signed shared information is sent to the off-chain node, so that after the off-chain node verifies and passes the signed shared information, it further verifies the shared information according to the aggregated public key, and obtains the credit information after the secondary verification passes, so as to realize the query of information.
[0075] Example 3
[0076] Figure 5 is a schematic structural diagram of a credit information sharing device provided in the third embodiment of the present invention. As Figure 5 shown, the device includes: an encryption / decryption module 501 and a communication module 502.
[0077] The encryption / decryption module 501 is used to generate a first hash value according to the first credit information, and sign the first hash value to obtain a first signature of the sharing party;
[0078] The communication module 502 is used to broadcast the first sharer signature and receive the first shared-signature of all other central nodes, where the first shared-signature is obtained by other central nodes signing the first hash value after verifying and passing the first sharer signature;
[0079] The encryption and decryption module 501 is further used to determine the first shared information according to the first aggregated signature and the first credit information, where the first aggregated signature includes the first sharer signature and all the first shared-signatures;
[0080] The communication module 502 is further used to broadcast the first shared information, so that other central nodes write the first credit information into the corresponding blockchain after verifying and passing the first shared information.
[0081] Optionally, the communication module 502 is further used to receive the second sharer signature broadcast by other central nodes acting as sharers, where the second sharer signature is obtained by other central nodes acting as sharers signing the second hash value, and the second hash value is generated according to the second credit information;
[0082] The encryption and decryption module 501 is further used to sign the second hash value after verifying and passing the second sharer signature, obtaining the second shared-signature;
[0083] The communication module 502 is further used to send the second shared-signature to other central nodes acting as sharers and receive the second shared information broadcast by other central nodes acting as sharers, where the second shared information is determined by other central nodes acting as sharers according to the second aggregated signature and the second credit information, and the second aggregated signature includes the second sharer signature and all the second shared-signatures;
[0084] The encryption and decryption module 501 is further used to verify the second shared information according to the aggregated public key and write the second credit information into the corresponding blockchain after the verification passes.
[0085] Optionally, all central nodes included in the consortium blockchain determine the public parameters through a consensus mechanism;
[0086] Among them, the public parameters include a first additive group, a second additive group, a first generator, a second generator, a multiplicative group, a first hash function, and a second hash function;
[0087] The first generator is the generator of the first additive group, the second generator is the generator of the second additive group, and the first additive group, the second additive group, and the multiplicative group satisfy a bilinear mapping relationship.
[0088] Optionally, the aggregated public key is formed by aggregating the keys corresponding to all central nodes included in the consortium blockchain. The key corresponding to a central node is determined according to the public key of the central node, the second hash function, and the public keys of all central nodes included in the consortium blockchain.
[0089] Optionally, the encryption and decryption module 501 is specifically configured to generate a first hash value according to the first credit information and the first hash function; use the private key of the central node, the second hash function, and the public keys of all central nodes included in the consortium blockchain to sign the first hash value to obtain a first shared party signature.
[0090] Optionally, the encryption and decryption module 501 is specifically configured to determine whether the value of the second aggregated signature and the second generator under the bilinear mapping relationship is equal to the value of the second hash value and the aggregated public key under the bilinear mapping relationship; if so, determine that the verification of the second shared information passes; if not, determine that the verification of the second shared information fails.
[0091] Optionally, the communication module 502 is further configured to receive a query request sent by an off-chain node, where the central node is the central node closest to the off-chain node or the central node with the lowest load at the current moment. The off-chain node stores the aggregated public key of the consortium blockchain, and the query request includes a user identifier;
[0092] The encryption and decryption module 501 is further configured to determine third shared information according to the user identifier, where the third shared information is determined according to the third aggregated signature and the third credit information, and the user identifier corresponds to the third credit information; sign the third shared information;
[0093] The communication module 502 is further configured to send the signed third shared information to the off-chain node, so that after the off-chain node verifies and passes the signed third shared information, it further verifies the third shared information according to the aggregated public key, and obtains the third credit information after the secondary verification passes.
[0094] Optionally, the encryption and decryption module 501 is specifically configured to use the private key of the central node to sign the third shared information to obtain the signed third shared information.
[0095] The credit information sharing device provided by the embodiments of the present invention can execute the credit information sharing method provided by any embodiment of the present invention, and has the corresponding functional modules and beneficial effects for executing the method.
[0096] Embodiment 4
[0097] The embodiments of the present invention further provide a central node for implementing the above credit information sharing method. Figure 6FIG. 0 shows a schematic structural diagram of a central node 10 that can be used to implement an embodiment of the present invention. The central node is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The components shown herein, their connections and relationships, and their functions are merely examples and are not intended to limit the implementation of the present invention described and / or claimed herein.
[0098] As Figure 6 shown, the central node 10 includes at least one processor 11 and a memory communicatively connected to the at least one processor 11, such as a read-only memory (ROM) 12, a random access memory (RAM) 13, etc. The memory stores a computer program executable by the at least one processor. The processor 11 can perform various appropriate actions and processes according to the computer program stored in the read-only memory (ROM) 12 or the computer program loaded from the storage unit 18 into the random access memory (RAM) 13. In the RAM 13, various programs and data required for the operation of the central node 10 can also be stored. The processor 11, the ROM 12, and the RAM 13 are connected to each other via a bus 14. An input / output (I / O) interface 15 is also connected to the bus 14.
[0099] A plurality of components in the central node 10 are connected to the I / O interface 15, including: an input unit 16, such as a keyboard, a mouse, etc.; an output unit 17, such as various types of displays, speakers, etc.; a storage unit 18, such as a disk, an optical disc, etc.; and a communication unit 19, such as a network card, a modem, a wireless communication transceiver, etc. The communication unit 19 allows the central node 10 to exchange information / data with other devices via a computer network such as the Internet and / or various telecommunication networks.
[0100] The processor 11 can be various general-purpose and / or special-purpose processing components with processing and computing capabilities. Some examples of the processor 11 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various dedicated artificial intelligence (AI) computing chips, various processors running machine learning model algorithms, a digital signal processor (DSP), and any suitable processor, controller, microcontroller, etc. The processor 11 executes the various methods and processes described above, such as the method for sharing credit information.
[0101] In some embodiments, the method for sharing credit information may be implemented as a computer program tangibly embodied in a computer-readable storage medium, such as storage unit 18. In some embodiments, part or all of the computer program may be loaded and / or installed onto the central node 10 via the ROM 12 and / or the communication unit 19. When the computer program is loaded into the RAM 13 and executed by the processor 11, one or more steps of the method for sharing credit information described above may be performed. Alternatively, in other embodiments, the processor 11 may be configured to execute the method for sharing credit information by any other suitable means (e.g., by means of firmware).
[0102] The various embodiments of the systems and techniques described above in this document may be implemented in digital electronic circuitry, integrated circuit systems, field programmable gate arrays (FPGA), application specific integrated circuits (ASIC), application specific standard products (ASSP), systems on a chip (SOC), complex programmable logic devices (CPLD), computer hardware, firmware, software, and / or combinations thereof. These various embodiments may include: implemented in one or more computer programs that may be executed and / or interpreted on a programmable system including at least one programmable processor, which may be a special-purpose or general-purpose programmable processor that receives data and instructions from a storage system, at least one input device, and at least one output device, and transmits the data and instructions to the storage system, the at least one input device, and the at least one output device.
[0103] The computer program for implementing the method of the present invention may be written in any combination of one or more programming languages. These computer programs may be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing device, such that the computer program, when executed by the processor, causes the functions / operations specified in the flowchart and / or block diagram to be implemented. The computer program may be executed entirely on the machine, partially on the machine, as a stand-alone software package partially on the machine and partially on a remote machine, or entirely on a remote machine or server.
[0104] In the context of the present invention, a computer-readable storage medium can be a tangible medium that can contain or store a computer program for use by or in connection with an instruction execution system, apparatus, or device. The computer-readable storage medium can include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination of the foregoing. Alternatively, the computer-readable storage medium can be a machine-readable signal medium. More specific examples of the machine-readable storage medium would include an electrical connection based on one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
[0105] To provide for interaction with a user, the systems and techniques described herein can be implemented on a central node that has: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and a pointing device (e.g., a mouse or a trackball) by which the user can provide input to the central node. Other kinds of devices can also be used to provide for interaction with the user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including acoustic input, speech input, or tactile input).
[0106] The systems and techniques described herein can be implemented in a computing system that includes back-end components (e.g., as a data server), or a computing system that includes middleware components (e.g., an application server), or a computing system that includes front-end components (e.g., a user computer having a graphical user interface or a web browser through which the user can interact with an implementation of the systems and techniques described herein), or a computing system that includes any combination of such back-end components, middleware components, or front-end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: a local area network (LAN), a wide area network (WAN), a blockchain network, and the Internet.
[0107] A computing system may include a client and a server. The client and the server are generally far from each other and usually interact via a communication network. The relationship between the client and the server is generated by computer programs running on respective computers and having a client-server relationship with each other. The server may be a cloud server, also known as a cloud computing server or a cloud host, which is a host product in the cloud computing service system, solving the defects of difficult management and weak business scalability existing in traditional physical hosts and VPS services.
[0108] An embodiment of the present invention also provides a computer program product, including a computer program which, when executed by a processor, implements the method for sharing credit information provided in any embodiment of the present invention.
[0109] In the process of implementing the computer program product, computer program code for performing the operations of the present invention can be written in one or more programming languages or combinations thereof. The programming languages include object-oriented programming languages such as Java, Smalltalk, C++, and also include conventional procedural programming languages such as the "C" language or similar programming languages. The program code can be executed entirely on the user's computer, partially on the user's computer, executed as an independent software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In the case of a remote computer, the remote computer can be connected to the user's computer through any type of network - including a local area network (LAN) or a wide area network (WAN) - or can be connected to an external computer (for example, by using an Internet service provider to connect through the Internet).
[0110] It should be understood that various forms of the processes shown above can be used, with steps reordered, added, or deleted. For example, the steps recited in the present invention can be executed in parallel, sequentially, or in a different order, as long as the desired results of the technical solution of the present invention can be achieved, and no limitation is made herein.
[0111] The above specific embodiments do not constitute a limitation to the protection scope of the present invention. Those skilled in the art should understand that various modifications, combinations, sub-combinations, and substitutions can be made according to design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of the present invention shall be included within the protection scope of the present invention.
Claims
1. A method for sharing credit information, characterized in that, Applied to any one of the multiple central nodes included in the consortium blockchain, when the central node is the sharing party and other central nodes are the shared parties, the method includes: Generating a first hash value according to the first credit information, and signing the first hash value to obtain a first sharing party signature; Broadcasting the first sharing party signature, and receiving the first shared party signatures sent by all other central nodes, where the first shared party signature is obtained by other central nodes signing the first hash value after verifying and passing the first sharing party signature; Determining first shared information according to the first aggregated signature and the first credit information, where the first aggregated signature includes the first sharing party signature and all first shared party signatures; Broadcasting the first shared information so that other central nodes write the first credit information into the corresponding blockchain after verifying and passing the first shared information.
2. The method for sharing credit information according to claim 1, wherein The aggregated public key of the consortium blockchain is stored in each of the multiple central nodes included; When another central node is the sharing party, and the central node and the remaining central nodes except the other central nodes acting as the sharing party are the shared parties, the method further includes: Receiving a second sharing party signature broadcast by another central node acting as the sharing party, where the second sharing party signature is obtained by another central node acting as the sharing party signing a second hash value, and the second hash value is generated according to second credit information; After verifying and passing the second sharing party signature, signing the second hash value to obtain a second shared party signature; Sending the second shared party signature to another central node acting as the sharing party, and receiving the second shared information broadcast by another central node acting as the sharing party, where the second shared information is determined by another central node acting as the sharing party according to a second aggregated signature and the second credit information, and the second aggregated signature includes the second sharing party signature and all second shared party signatures; Verifying the second shared information according to the aggregated public key, and writing the second credit information into the corresponding blockchain after the verification passes.
3. The method for sharing credit information according to claim 1 or 2, characterized in that All central nodes included in the consortium blockchain determine public parameters through a consensus mechanism; Wherein, the public parameters include a first additive group, a second additive group, a first generator, a second generator, a multiplicative group, a first hash function, and a second hash function; The first generator is the generator of the first additive group, the second generator is the generator of the second additive group, and the first additive group, the second additive group, and the multiplicative group satisfy a bilinear mapping relationship.
4. The method for sharing credit information according to claim 3, wherein The aggregated public key is aggregated by the keys corresponding to all central nodes included in the consortium blockchain, and the key corresponding to a central node is determined according to the public key of this central node, the second hash function, and the public keys of all central nodes included in the consortium blockchain.
5. The method for sharing credit information according to claim 3, wherein The generating a first hash value according to the first credit information, and signing the first hash value to obtain a first sharing party signature includes: Generate a first hash value according to the first credit information and the first hash function; Use the private key of the central node, the second hash function, and the public keys of all central nodes included in the consortium blockchain to sign the first hash value to obtain a first shared party signature.
6. The method for sharing credit information according to claim 3, characterized in that, The verifying the second shared information according to the aggregated public key includes: Determine whether the values of the second aggregated signature and the second generator under the bilinear mapping relationship are equal to the values of the second hash value and the aggregated public key under the bilinear mapping relationship; If so, determine that the verification of the second shared information passes; If not, determine that the verification of the second shared information fails.
7. The method for sharing credit information according to claim 1 or 2, characterized in that The method further includes: Receive a query request sent by an off-chain node, where the central node is the central node closest to the off-chain node or the central node with the lowest load at the current moment, the off-chain node stores the aggregated public key of the consortium blockchain, and the query request includes a user identifier; Determine third shared information according to the user identifier, where the third shared information is determined according to a third aggregated signature and third credit information, and the user identifier corresponds to the third credit information; Sign the third shared information and send the signed third shared information to the off-chain node, so that after the off-chain node verifies and passes the signed third shared information, it further verifies the third shared information according to the aggregated public key, and obtains the third credit information after the secondary verification passes.
8. The method for sharing credit information according to claim 7, characterized in that, The signing the third shared information includes: Use the private key of the central node to sign the third shared information to obtain the signed third shared information.
9. A central node, characterized in that, The central node includes: At least one processor; and a memory communicatively connected to the at least one processor; where The memory stores a computer program executable by the at least one processor, and the computer program is executed by the at least one processor so that the at least one processor can execute the method for sharing credit information according to any one of claims 1-8.
10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer instructions for causing a processor to implement the method for sharing credit information according to any one of claims 1-8 when executed.