derivePathUnhardened static method

Future<PrivateKey> derivePathUnhardened(
  1. PrivateKey sk,
  2. List<int> path
)

Derive a unhardened private key from a path

Implementation

static Future<PrivateKey> derivePathUnhardened(
    PrivateKey sk, List<int> path) async {
  final Uint32List pathBytes = Uint32List.fromList(path);
  final result = await api.secretKeyDerivePathUnhardened(
    sk: sk.byteList,
    path: pathBytes,
  );
  return PrivateKey(result);
}