0.1.1 • Published 5 years ago

taptrust-auth v0.1.1

Weekly downloads
2
License
MIT
Repository
github
Last release
5 years ago

TapTrust Auth

A library for the following:

  • createKeyPair: create private/public keypairs with a username, password, and a randomly generated third factor used as a seed for key derivation.
  • restoreKeyPair: provide a username, password and public key from a previously generated keypair, and this function will cycle through each possible random value until it generates the correct keypair (if one can be found).

Installation

npm install @taptrust/auth

Usage

```
var taptrustAuth = require('@taptrust/auth');

var keyPair = taptrustAuth.createKeyPair(username, password);
var restoredKeyPair = taptrustAuth.restoreKeyPair(username, password, keyPair.publicKey);
```

Tests

npm test