1.0.7 • Published 6 years ago

@pacificdatascience/cipher v1.0.7

Weekly downloads
1
License
ISC
Repository
github
Last release
6 years ago

Asynchronous Strong Hashing Package

This package uses asynchronous scrypt along with a random salt to create secure hashes.

Installation

npm install @pacificdatascience/cipher

Usage

const cipher = require('@pacificdatascience/cipher')

const hash = await cipher.hash('some text')

return await cipher.compare('some text', hash)

const encrypted = await cipher.encrypt('password', 'salt', { id: 1234, title: 'Sample text' })

const decrypted = await cipher.decrypt('password', 'salt', encrypted)
1.0.7

6 years ago

1.0.6

6 years ago

1.0.5

6 years ago

1.0.4

6 years ago

1.0.3

6 years ago

1.0.2

6 years ago

1.0.1

6 years ago

1.0.0

6 years ago