Skip to content

Going from a string representation from a privatekey to a public key #639

Open
@BlackTurtle123

Description

@BlackTurtle123

I am trying to create a library for some crypto project.
They however require to be able to generate the public key, and the address from a privatekey string (which users would input), how is this done? I don't see any option for this currently is this right?

privKey = SigningKey(accountSeedHash) pubKey = privKey.verify_key self.privateKey = base58.b58encode(privKey._signing_key)

This self.privateteKey has a value in the test case from '5rUDHu3Kf8LaLeW2Z2KJsLFMj3b8qzbJyn3GDxGJcxo8XDP1tj16aggSmdoQfVf45QB3uSby2J54Wbe3iKffVCxZ'

Now I would like to go from this value to the public key, in our test case:
'FinzVngQspEkHZSWn5BPJ5PSMJQjNW7oonqfHFXurgXs'

How would one do this?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions