gracenode-encrypt
v0.1.2
Published
encrypt of module for gracenode framework
Downloads
1
Maintainers
Readme
Encrypt Module
Encrypt module for gracenode framework.
This is designed to function within gracenode framework.
How to include it in my project
To add this package as your gracenode module, add the following to your package.json:
"dependencies": {
"gracenode": "",
"gracenode-encrypt": ""
}
To use this module in your application, add the following to your gracenode bootstrap code:
var gracenode = require('gracenode');
// this tells gracenode to load the module
gracenode.use('gracenode-encrypt');
To access the module:
// the prefix gracenode- will be removed automatically
gracenode.encrypt
Access
Configurations N/A
###API: createHash
Creates a hash with salt from sourceStr
This function uses bcrypt module and it is based on blowfish encryption.
Bigger the cost the slower this function will become.
###API: validateHash
Validates a hash and str
###API: uuid
Creates a uuid. This module uses node-uuid module.
Possible values for version are 1 or 4
Version 1 is timestamp-base and version 4 is random-base