如何从Python中的种子生成比特币密钥/地址?

2024-05-15 12:54:54 发布

您现在位置:Python中文网/ 问答频道 /正文

我试图从基于BIP0039的助记符创建一组公钥/私钥。我在用Python工作。在

以下是我目前掌握的代码:

from mnemonic import Mnemonic
mnemon = Mnemonic('english')
words = mnemon.generate(256)
mnemon.check(words)
seed = mnemon.to_seed(words)

在BIP0039中,声明您应该能够使用种子获取密钥,但是我还没有能够在Python中使用bip32utils来解决这个问题。有没有人举个例子来说明如何使用bip32utils将种子转换成私钥/公钥及其各自的地址?在


Tags: 代码fromimportenglish种子助记符mnemonicseed