jsrp-server-fast
v0.2.3-beta.1
Published
Fast (OpenSSL) JavaScript SRP implementation for node.js only
Readme
jsrp-server-fast
This package is a fork of jsrp which uses
bignum as a big number library instead of
jsbn
Bignum
bignum is not pure JS. It uses OpenSSL as a backend
Pros
- Performance
- Thanks to the native implementation of
powmit's 20-30 times faster then pure JS implementation
- Thanks to the native implementation of
Cons
- It uses OpenSSL big num under the hood, so it can not be used in the browser
Installation
npm install jsrp-server-fastUsage
var jsrp = require('jsrp-server-fast');Example
For an example usage take a look at the original jsrp repo.
You should only use jsrp.server in your code, but jsrp.client is left for test purposes.
API Reference
For the API description take a look at the original jsrp repo.
Testing
First, install the dependencies:
npm installAlso, you will need Mocha and CoffeeScript if you don't have them already:
npm install -g mocha coffee-scriptThen simply run:
npm testThis library uses the same test suite as the original one, but it runs much faster (235ms compared to 6s on my computer) thanks to native OpenSSL bignum library used.
