锚点:如何要求Nodejs后端在不使用血清的Multisig的情况下从前端共同签名交易?
理想情况下,我希望我的nodejs后端(可以确保按键)与Frontend应用程序共同签名交易(假设用户将使用他 /她的Solana Wallet签署交易)。后端的Pubkey也将作为锚定计划的签名帐户包括在内。
我看不到Anchor这样做的任何教程,希望这是有道理的。我当时认为前端将称为后端API传递序列化参数,后端将在该参数上签名,并将用其公共密钥将签名返回前端。
我不知道:
- 用于签名交易的正确锚 /索拉纳Web3是什么,
- 我该如何将(后端的)返回签名添加到
我最初不想使用Multisig使用此方法的交易中,因为它只会胜过事情。在提交交易之前只需要从后端进行一些确认即可。
Ideally, I want my Nodejs backend (which secures a keypair) to co-sign a transaction coming from the frontend app (assuming the user will sign the transaction using his / her Solana wallet). The pubkey of the backend will be also included as a signer account to the anchor program.
I can't see any tutorial from Anchor doing this, hopefully it makes sense. I was thinking that the frontend will call a backend API passing down the serialize parameters, on which the backend will sign, and will return a signature to the frontend with its public key.
I have no idea on:
- What's the correct Anchor / Solana web3 to use to sign the transaction
- How can I add the returning signature (of the backend) to the transaction
I initially don't want to use Multisig with this approach as it will just overcomplicate things. Just need some confirmation from the backend before submitting the transaction.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您可能想做这样的事情(后端):
然后从前端开始:
You probably want to do something like this (backend):
Then from the frontend: