[英]Failed Error: Private key missing from key store. Can not establish the signing identity for user admin
Generating the public key but not able to generate the private key of admin user while registering a new user through REST services in blockchain network and also getting below mentioned error.在通过区块链网络中的 REST 服务注册新用户时,生成公钥但无法生成管理员用户的私钥,并且还出现以下错误。
Error:Failed Error: Private key missing from key store.错误:失败 错误:密钥库中缺少私钥。 Can not establish the signing identity for user admin.无法为用户 admin 建立签名身份。
Followed the below steps :遵循以下步骤:
Created new a node application to publish the rest services by referring the existing "balance-transfer" application.通过引用现有的“余额转移”应用程序,创建新的节点应用程序以发布其余服务。
Then started the node application.然后启动节点应用程序。
Testing the rest services url in postman tool.在邮递员工具中测试其余服务 url。
Getting the above mentioned error while testing the url http://localhost:4000/users in Postman tool.在 Postman 工具中测试 url http://localhost:4000/users 时出现上述错误。
Error at code level: app.js--->helper.js代码级错误: app.js--->helper.js
let adminUserObj = await client.setUserContext({username: admins[0].username, password: admins[0].secret});
Please suggest.请建议。
Remove the folders holding key-value store for organizations -> fabric-client-kv-* from the balance-transfer fabric sample.从余额转移结构示例中删除保存组织键值存储的文件夹 -> fabric-client-kv-*。
rm -rf fabric-client-kv-* rm -rf 结构客户端-kv-*
Then create the network again.然后再次创建网络。 This resolved the issue for me.这为我解决了这个问题。
have you tried to restart the network completely?您是否尝试过完全重新启动网络? (by using the "runApp.sh" script for that?) Take a look inside this script to the restartNetwork() function, where the "fabric-client-kv-org" folders in your balance-transfer folder are removed. (为此使用“runApp.sh”脚本?)查看该脚本的 restartNetwork() 函数,其中删除了 balance-transfer 文件夹中的“fabric-client-kv-org”文件夹。
Does it work?它有效吗?
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.