2017-10-22 3 views
0

に照会中: gitのクローンをhttps://github.com/hyperledger/fabric-samples.gitHyperledgerクラッシュ私はHyperledgerファブリックv1.0のを使用していて、次のgitリポジトリにサンプルプロジェクトのfabcarを使用しようとしているときに、私はエラーが直面していますChaincode

私はすべてを開始することができています次のシェルスクリプトを使用してコンテナ:

./startFabric.sh 

ピアとチャネルが作成されますが、私は、コマンドを使用するときに

node query.js 

それは次のエラーでクラッシュ: 私はこのために他のバージョンを使用する必要があるか、エラーがによるものであるか、私はノードのバージョン6.11.4を使用していたクライアントを作成し、ウォレットの場所

Set wallet path, and associate user PeerAdmin with application Check user is enrolled, and set a query URL in the network Make query Assigning transaction_id: 27d48de27350bbeeb3adae69ec5e783d3af1c42af03230877f71c3343bfbc905 error: [client-utils.js]: sendPeersProposal - Promise is rejected: Error: Failed to deserialize creator identity, err The supplied identity is not valid, Verify() returned x509: certificate signed by unknown authority (possibly because of "x509: ECDSA verification failure" while trying to verify candidate authority certificate "ca.org1.example.com") at /home/eres_admin/hyperledger/fabric-samples/fabcar/node_modules/grpc/src/node/src/client.js:554:15 returned from query Query result count = 1 error from query = { Error: Failed to deserialize creator identity, err The supplied identity is not valid, Verify() returned x509: certificate signed by unknown authority (possibly because of "x509: ECDSA verification failure" while trying to verify candidate authority certificate "ca.org1.example.com") at /home/eres_admin/hyperledger/fabric-samples/fabcar/node_modules/grpc/src/node/src/client.js:554:15 code: 2, metadata: Metadata { _internal_repr: {} } } Response is Error: Failed to deserialize creator identity, err The supplied identity is not valid, Verify() returned x509: certificate signed by unknown authority (possibly because of "x509: ECDSA verification failure" while trying to verify candidate authority certificate "ca.org1.example.com")

を設定他の何か。

答えて

1

TL;使用しているドッカーの構成によってCAキーの名前が取得された可能性がありますが、暗号化されたデータを再生成してキーとファイル名を変更しました。

私は全く同じエラーがあり、basic-network/docker-compose.yamlにはCAキーがハードコードされているため、このエラーが発生しています。 cryptomaterialを再生成すると(例えば、basic-networkでgenerate.shを実行すると)、キーファイル名が変更されます。したがって、CAは鍵を見つけられません。

あなたはこの後FABRIC_CA_SERVER_CA_KEYFILE

... 
services: 
    ca.example.com: 
    image: hyperledger/fabric-ca 
    environment: 
     - FABRIC_CA_HOME=/etc/hyperledger/fabric-ca-server 
     - FABRIC_CA_SERVER_CA_NAME=ca.example.com 
     - FABRIC_CA_SERVER_CA_CERTFILE=/etc/hyperledger/fabric-ca-server-config/ca.org1.example.com-cert.pem 
     - FABRIC_CA_SERVER_CA_KEYFILE=/etc/hyperledger/fabric-ca-server-config/4239aa0dcd76daeeb8ba0cda701851d14504d31aad1b2ddddbac6a57365e497c_sk 
... 

を変更する必要があります暗号材料を再生成した後、query.jsはうまく動作します。

関連する問題