@plugnet/util-crypto
Version:
A collection of useful crypto utilities for @plugnet
17 lines (16 loc) • 505 B
TypeScript
import { Keypair } from '../../types';
/**
* @name naclKeypairFromSeed
* @summary Creates a new public/secret keypair from a seed.
* @description
* Returns a object containing a `publicKey` & `secretKey` generated from the supplied seed.
* @example
* <BR>
*
* ```javascript
* import { naclKeypairFromSeed } from '@plugnet/util-crypto';
*
* naclKeypairFromSeed(...); // => { secretKey: [...], publicKey: [...] }
* ```
*/
export default function naclKeypairFromSeed(seed: Uint8Array): Keypair;