Solnet icon indicating copy to clipboard operation
Solnet copied to clipboard

Added a static method to initialize a Account class instance from a Base58 Secret Key("Private Key")

Open BifrostTitan opened this issue 3 years ago • 0 comments

| Status | Type | ⚠️ Core Change | Issue | | Ready | Feature | Yes |https://github.com/bmresearch/Solnet/issues/418

Problem

What problem are you trying to solve?

Account class objects could not be created by using a base58 secret key (private key). The secret key is exported by popular wallets like phantom. Referenced it as a secret key because technically the true private key is the seed and the secret key is a combination of the precursor seed (private key) & public key which is encoded in base58. Encapsulated Seed/Private Key/Secret Key whatever you want to call it haha

Solution

How did you solve the problem?

Added static method to the account class that returns an initialized account object based on the private/secret key provided

BifrostTitan avatar Nov 21 '22 23:11 BifrostTitan