Skip to content

Repository files navigation

<blox-scrypt>

Build Status

A web component that exposes the scrypt password-based KDF

Install the Polymer-CLI

First, make sure you have the Polymer CLI and npm (packaged with Node.js) installed. Run npm install to install your element's dependencies, then run polymer serve to serve your element locally.

Install blox-scrypt

$ npm install blox-scrypt

Viewing Your Element

$ polymer serve

Running Tests

$ polymer test

Import

$ import 'blox-scrypt';

Basic Use

<blox-scrypt
    password="secret!!"
    result="{{result}}"
    error="{{error}}"
    salt="psv5lvsrnaw3">
</blox-scrypt>

Advanced Use

<blox-scrypt
    password="secret!!"
    result="{{result}}"
    error="{{error}}"
    salt="psv5lvsrnaw3"
    password-length=8
    memoryCost=16384
    blocksize=8
    parallelization=1
    dkLen=16
    encoding='hex'></blox-scrypt>

Javascript Use

<blox-scrypt id="bloxScrypt"></blox-scrypt>
<script>
    this.$.bloxScrypt.scrypt('secret!!')
    .then((hash) => {
        // Do Something
    })
    .catch((err) => {
        // Do Something
    })
</script>

About

A web component that exposes the scrypt password-based KDF

Topics

Resources

Stars

1 star

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages