Hyperledger fabric 1.4 endorsement and endorsement strategy

Time:2020-4-25

Endorsements in the hyperledger fabric are a more complex concept. If you need to learn fabric through video, you can refer to video tutorials.

Endorsement is the process of digital signature before performing some operations. All operations of the upper block in fabric need to be endorsed.
The node for endorsement is the endorsement node.
The rule of endorsement is called endorsement strategy.

There are three strategies in fabric:

  1. System level policies
  2. Policy at the chaincode level
  3. Key level policy (less)

System level policies refer to specific operations, such as adding organizations, creating alliances, creating channels, and installing system contracts. These operations sound like what some super administrators can do. At the same time, these operations are operated by system contracts embedded in fabric systems, not by contracts developed by users themselves Made. Most of these configurations are stored in the configuration block of the channel. For example, adding an organization requires the signature and consent of the admin user of most organizations in the alliance. This policy is stored in the configuration block of the channel, as shown in the following figure: majority means a large part
Hyperledger fabric 1.4 endorsement and endorsement strategy

The chaincode level policy refers to the contracts developed by users themselves. It specifies which nodes are required to sign and endorse these contracts. Usually, we specify them when instance contracts or upgrade contracts, as follows:
Hyperledger fabric 1.4 endorsement and endorsement strategy

The roles of endorsement strategy include the following:

'org1. Admin': admin of org1msp  
'org1. Member': any member of org1msp  
'org1. Client': any client of org1msp  
"Org1.peer": any peer node of Org1MSP

Admin represents only admin users
Only endorsement is allowed. Client means that all org users can sign, peer means that the peer node of Org can sign. This method can automatically sign, and member means that any one of the three methods can sign.

The key level policy is rarely used and is set at the code level, which is not described here.

This article is published by openwrite, a blog platform with one article and multiple posts!