【发布时间】:2021-10-13 16:11:07
【问题描述】:
我正在使用fabric ca-client 来注册和注册“用户”以与链码进行交互。使用组织 CA admin 注册用户如下:
export FABRIC_CA_CLIENT_TLS_CERTFILES=/tmp/hyperledger/org1/ca/crypto/ca-cert.pem
export FABRIC_CA_CLIENT_HOME=/tmp/hyperledger/org1/ca/admin
export FABRIC_CA_CLIENT_MSPDIR=msp
fabric-ca-client register -d --id.name userk2 --id.secret userk2PW --id.type user -u https://0.0.0.0:7054
并且注册的用户没有 org-ca 的管理员身份
fabric-ca-client enroll -u "https://userk2:userk2PW@0.0.0.0:7054" --tls.certfiles /tmp/hyperledger/org1/admin/msp/cacerts/0-0-0-0-7054.pem
现在 CA 服务器应该向需要与链码交互的用户(此处为 userk2)提供用户证书。
我收到来自 CA 服务器的响应:
2021/10/13 12:13:50 [INFO] TLS Enabled
2021/10/13 12:13:50 [INFO] generating key: &{A:ecdsa S:256}
2021/10/13 12:13:50 [INFO] encoded CSR
2021/10/13 12:13:51 [INFO] Stored client certificate at /root/.fabric-ca-client/msp/signcerts/cert.pem
2021/10/13 12:13:51 [INFO] Stored root CA certificate at /root/.fabric-ca-client/msp/cacerts/0-0-0-0-7054.pem
2021/10/13 12:13:51 [INFO] Stored Issuer public key at /root/.fabric-ca-client/msp/IssuerPublicKey
2021/10/13 12:13:51 [INFO] Stored Issuer revocation public key at /root/.fabric-ca-client/msp/IssuerRevocationPublicKey
与链码交互的用户私钥/公钥和信任根是什么? 谢谢!
【问题讨论】:
标签: hyperledger-fabric hyperledger-fabric-ca