# pbkdf2-wrapper

> A wrapper around the inbuilt pbkdf2 crypto function for password hashing

Latest version **2.0.0** (published 2022-09-07) · MIT license · 0 weekly downloads

## Install

```sh
npm install pbkdf2-wrapper
pnpm add pbkdf2-wrapper
yarn add pbkdf2-wrapper
bun add pbkdf2-wrapper
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 2.0.0 |
| Published | 2022-09-07 |
| First published | 2019-11-07 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 4.9 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | Mark Wylde |
| Maintainers | markwylde |
| Keywords | pbkdf2, kdf, salt, hash, password, verify, compare, hex |

## Links

- npm: https://www.npmjs.com/package/pbkdf2-wrapper
- Repository: https://github.com/markwylde/pbkdf2-wrapper
- Homepage: https://github.com/markwylde/pbkdf2-wrapper#readme
- Issues: https://github.com/markwylde/pbkdf2-wrapper/issues
- npm.io page: https://npm.io/package/pbkdf2-wrapper

## Alternatives

- [@gemini-wallet/core](https://npm.io/package/@gemini-wallet/core.md) — 515.6K weekly downloads
- [utility](https://npm.io/package/utility.md) — 416.6K weekly downloads
- [@primno/dpapi](https://npm.io/package/@primno/dpapi.md) — 7.2K weekly downloads
- [pi-readseek](https://npm.io/package/pi-readseek.md) — 3.7K weekly downloads
- [@emilia-protocol/verify](https://npm.io/package/@emilia-protocol/verify.md) — 1.1K weekly downloads

## Recent versions

- 2.0.0 (latest) — 2022-09-07
- 1.1.2 (hash) — 2019-11-08
- 1.3.4 — 2021-06-21
- 1.3.3 — 2021-06-21
- 1.3.2 — 2020-09-27
- 1.3.1 — 2020-04-20
- 1.3.0 — 2020-04-20
- 1.2.2 — 2019-11-21
- 1.2.1 — 2019-11-13
- 1.2.0 — 2019-11-13
- 1.1.3 — 2019-11-08
- 1.1.1 — 2019-11-08
- 1.1.0 — 2019-11-08
- 1.0.2 — 2019-11-07
- 1.0.1 — 2019-11-07
- … 1 more at https://npm.io/package/pbkdf2-wrapper/versions

## README

# pbkdf2-wrapper
![GitHub code size in bytes](https://img.shields.io/github/languages/code-size/markwylde/pbkdf2-wrapper)
[![GitHub package.json version](https://img.shields.io/github/package-json/v/markwylde/pbkdf2-wrapper)](https://github.com/markwylde/pbkdf2-wrapper/releases)
[![GitHub](https://img.shields.io/github/license/markwylde/pbkdf2-wrapper)](https://github.com/markwylde/pbkdf2-wrapper/blob/master/LICENSE)

A light wrapper around the native inbuilt pbkdf2 crypto functions used for password hashing, exposing promises and callbacks.

## Installation
```bash
npm install --save pbkdf2-wrapper
```

## Example Usage
```javascript
import hashText from 'pbkdf2-wrapper/hashText';
import verifyHash from 'pbkdf2-wrapper/verifyHash';

// config is optional, if not passed will use the following as defaults
const config = {
  encoding: 'hex',
  digest: 'sha256',
  hashBytes: 32,
  saltBytes: 16,
  iterations: 372791
};

const hash = await hashText('test-password', config);
const equality = await verifyHash('test-password', hash, config);
```

## License
This project is licensed under the terms of the MIT license.

---
_Source: https://npm.io/package/pbkdf2-wrapper · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
