问题标签 [amazon-managed-blockchain]

For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.

0 投票
1 回答
40 浏览

amazon-web-services - AWS 托管的超级账本结构 v1.4.7 区块链 - 连接到结构网络时出现证书错误错误

我已经部署了一个AWS 管理的 Hyperledger Fabric v1.4.7 区块链。HLF 区块链网络和 EC2 实例(hlf-client)在同一个 VPC 中,一切似乎都运行良好,因为我能够使用cli容器调用事务。

我有我的客户端应用程序,它使用fabric-sdk-go 网关 API连接到使用connection-profile.yaml调用/查询区块链的结构网络。cli此客户端应用程序在与具有所有必要安全配置的容器相同的 EC2 实例上的 docker 容器中运行。客户端应用程序无法连接到结构网络,因为bad certificate error

客户端应用程序上的错误日志是:

对应的对等日志为:

[36m2021-11-02 10:07:17.789 UTC [grpc] handleRawConn -> DEBU 39501a[0m grpc: Server.Serve failed to complete security handshake from "10.0.2.131:39100": remote error: tls: bad certificate

[31m2021-11-02 10:10:17.809 UTC [core.comm] ServerHandshake -> ERRO 395322[0m TLS handshake failed with error remote error: tls: bad certificate server=PeerServer remoteaddress=10.0.2.131:12696

cli在使用相同的证书文件调用事务时。谁能告诉我这里的设置有什么问题或者我错过了任何其他配置?

我已经生成了ccp (connection-profile.yaml),如下所示:

0 投票
0 回答
31 浏览

amazon-web-services - 创建对等通道 Amazon Managed Blockchain Hyperledger Fabric v1.4 时出错

我希望有人可以帮助我解决以下问题。

我将 Amazon Managed Blockchain 与框架 Hyperledge Fabric v1.4 一起使用,并遵循此文档https://docs.aws.amazon.com/managed-blockchain/latest/hyperledger-fabric-dev/get-started-create-channel .html

这是我尝试使用该命令行创建频道时遇到的错误:

  • 命令行: docker exec cli peer channel create -c mychannel -f /opt/home/mychannel.pb -o $ORDERER --cafile /opt/home/managedblockchain-tls-chain.pem --tls

  • 错误:2022-01-17 10:34:47.356 UTC [channelCmd] InitCmdFactory -> INFO 001 Endorser 和 orderer 连接已初始化错误:出现意外状态:BAD_REQUEST - 验证新通道“mychannel”的通道创建事务时出错,无法成功将更新应用于模板配置:授权更新错误:验证 DeltaSet 时出错:[组]/频道/应用程序的策略不满足:隐式策略评估失败 - 满足 0 个子策略,但此策略需要 1 个“管理员”子策略满足的政策

管理员证书位于文件夹“admin-msp”中。

我的 configxt.yaml(使用“docker exec cli configtxgen -outputCreateChannelTx /opt/home/mychannel.pb -profile OneOrgChannel -channelID mychannel --configPath /opt/home/”执行上一步时没有收到任何错误):

组织:

能力:

频道:&ChannelDefaults

应用程序:&ApplicationDefaults

配置文件:OneOrgChannel:<<:*ChannelDefaults 联盟:AWSSystemConsortium 应用程序:<<:*ApplicationDefaults 组织:-<<:*Org1

我的 docker-compose-cli.yaml 文件:

版本:'2'

服务:

客户端:

提前致谢 :)。

0 投票
0 回答
10 浏览

amazon-managed-blockchain - 如何捆绑一个简单的 node.js 应用程序

我正在亚马逊管理的区块链上使用 hyperledger-fabric。在那里,我用 node.js 编写了链代码。问题是,亚马逊托管区块链的对等点不支持我使用的依赖项。这就是为什么我需要将我的链码与节点模块捆绑在一起。我该怎么做?

0 投票
0 回答
15 浏览

blockchain - 如何使用链码从 AWS 托管区块链获取查询交易 ID

我无法使用链码的stub.getState(key)方法从 AWS 托管区块链获取交易 ID。请建议..