Skip to content

Wallet class should have an algorithm / key type property #3190

@mDuo13

Description

@mDuo13

To reliably re-create the same wallet from seed, you need to know the algorithm that was used. Using the default algorithm can get you in trouble—for example, it changed between xrpl.js versions, so code that used to work will generate the wrong address from the same input after you update. So it's pretty helpful to know what algorithm your key pair uses, but if you do client.fundWallet() or Wallet.generate() with the default options, the object you get back doesn't tell you what the default algorithm it used was.

To fix this, the Wallet class should have a property that reports the algorithm that was used in instantiating it. I suggest the following:

Property Name Type Value
algorithm Enum: ECDSA The cryptographic key derivation algorithm that was used to instantiate this wallet.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions