Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

node.js openssl bindings

branch: master

Fetching latest commit…

Octocat-spinner-32-eaf2f5

Cannot retrieve the latest commit at this time

Octocat-spinner-32 docs
Octocat-spinner-32 src
Octocat-spinner-32 test
Octocat-spinner-32 README.md
Octocat-spinner-32 VERSION
Octocat-spinner-32 dcrypt.coffee
Octocat-spinner-32 dcrypt.js
Octocat-spinner-32 package.coffee
Octocat-spinner-32 package.json
Octocat-spinner-32 wscript
README.md
       _|                                            _|      
   _|_|_|    _|_|_|  _|  _|_|  _|    _|  _|_|_|    _|_|_|_|  
 _|    _|  _|        _|_|      _|    _|  _|    _|    _|      
 _|    _|  _|        _|        _|    _|  _|    _|    _|      
   _|_|_|    _|_|_|  _|          _|_|_|  _|_|_|        _|_|  
                                     _|  _|                  
                                   _|_|    _|                  

dcrypt

Openssl bindings for Node.js. Written in Coffeescript.

  • RSA/ECDSA key generation
  • Signing and verification using PEM keys, not only certificates
  • Random bytes using openssl RAND
  • Signing/Verification
  • Hashing

Install

npm install dcrypt

Usage

Create a buffer holding 16 bytes of random data: buffer = dcrypt.random.randomBytes(16)

Create a new RSA Key Pair - no params is 1024 bytes and 65537 exponent default rsa = new dcrypt.keypair.newRSA(1024, 65537)

Create a new ECDSA Key Pair - no params is default secp256k1 curve ecdsa = new dcrypt.keypair.newECDSA('secp256k1')

Verify a signature with just a public key in PEM format verified = verifer.verify(pem_public, signature, signature_format='hex')

TODO

  • Finish porting Cipher/Decipher and HMAC
  • x509 certificates
  • CSR
Something went wrong with that request. Please try again.