fcash-ecies

1.0.4 • Public • Published

fcash-base ecies

# ECIES for fcash-base

NPM Package Build Status Coverage Status

A module for fcash-base that implements the Elliptic Curve Integrated Encryption Scheme (ECIES). Uses ECIES symmetric key negotiation from public keys to encrypt arbitrarily long data streams.

See the main fcash-base repo or the fcash-base guide on ECIES for more information.

Credit to @ryanxcharles for the original implementation.

Getting started

ECIES will allow to securely encrypt and decrypt messages using ECDSA key pairs (bitcoin cryptography).

var alice = ECIES()
  .privateKey(aliceKey)
  .publicKey(bobKey.publicKey);

var message = 'some secret message';
var encrypted = alice.encrypt(message);

// encrypted will contain an encrypted buffer only Bob can decrypt

var bob = ECIES()
  .privateKey(bobKey)
  .publicKey(aliceKey.publicKey);
var decrypted = bob
  .decrypt(encrypted)
  .toString();
// decrypted will be 'some secret message'

Contributing

See CONTRIBUTING.md on the main fcash-base repo for information about how to contribute.

License

Code released under the MIT license.

Copyright 2013-2015 Fcash, Inc. Fcash is a trademark maintained by Fcash, Inc.

Package Sidebar

Install

npm i fcash-ecies

Weekly Downloads

2

Version

1.0.4

License

MIT

Unpacked Size

24.4 kB

Total Files

17

Last publish

Collaborators

  • happyuc