You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

Hyperledger Fabric中AND('Org1.member','Org2.member')的YAML背书政策查询

YAML Format for Hyperledger Fabric Endorsement Policy: AND('Org1.member', 'Org2.member')

Alright, since you're working through the BYFN network in Fabric Samples 1.0 and need to translate that logical endorsement policy into structured YAML, here's exactly what you need to enforce signatures from one member each of Org1 and Org2:

identities:
  - role:
      name: member
      mspId: Org1MSP
  - role:
      name: member
      mspId: Org2MSP
policy:
  1-of:
    - 1-of:
        - signed-by: 0
    - 1-of:
        - signed-by: 1

Let me break down what this does:

  • The identities section defines two valid signer roles: a member of Org1 (indexed as 0) and a member of Org2 (indexed as 1).
  • The policy section uses nested 1-of rules to implement the AND logic:
    1. First, we require at least 1 signature from the first identity group (Org1 members)
    2. Second, we require at least 1 signature from the second identity group (Org2 members)
      Together, these two conditions mean both organizations must provide a member signature for the endorsement to be valid—exactly matching your AND('Org1.member', 'Org2.member') requirement.

If you're specifying this policy during chaincode instantiation, you might also see the shorthand command-line syntax -P "AND('Org1MSP.member','Org2MSP.member')", but the YAML above is the fully structured version that maps directly to that logical expression.

内容的提问来源于stack exchange,提问作者Skadoosh

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.05.25 07:22:30