Package Exports
- apache-crypt
- apache-crypt/src/index.js
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (apache-crypt) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
apache-crypt
Node.js package for Apache style password encryption using crypt(3).
Installation
Via git (or downloaded tarball):
$ git clone git://github.com/gevorg/apache-crypt.gitVia npm:
$ npm install apache-cryptUsage
const crypt = require("apache-crypt");
// Encrypting password using auto-generated 2 char salt.
const encryptedPassword = crypt("mypass");
// Should print true.
console.log(crypt("mypass", encryptedPassword) == encryptedPassword);
// Should print false.
console.log(crypt("notmypass", encryptedPassword) == encryptedPassword);Running tests
It uses mocha, so just run following command in package directory:
$ npm testLicense
The MIT License (MIT)