Mute-Crypto-Helper
Isomorphic API exporting helper functions for mute-crypto
project. It is powered by Web Crypto API for the client side and by node-webcrypto-ossl for NodeJS. The documentation can be found here.
Install
npm install @coast-team/mute-crypto-helper
For NodeJS, node-webcrypto-ossl
peer dependency is also required.
npm install node-webcrypto-oss
Usage
3 objects are exported by the API: asymmetricCrypto
, symmetricCrypto
and keyAgreementCrypto
.
import { asymmetricCrypto, symmetricCrypto, keyAgreementCrypto } from '@coast-team/mute-crypto-helper'
Or
const { asymmetricCrypto, symmetricCrypto, keyAgreementCrypto } = require('@coast-team/mute-crypto-helper')
Tests
Run the test in a browser:
npm run test
Run the test with NodeJS:
npm run test-node
Generate the documentation
npm run doc