Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/riaf/node-php-password

Compatibility with the password_* functions on PHP
https://github.com/riaf/node-php-password

javascript node password php

Last synced: 1 day ago
JSON representation

Compatibility with the password_* functions on PHP

Awesome Lists containing this project

README

        

node-php-password
=================

Compatibility with the password_* functions on PHP

Installation
------------

```sh
$ npm install php-password
```

Usage
-----

```javascript
var phpPassword = require('php-password');

// Example password
var password = 'passw0rd';

// Create hashed password
var hashedPassword = phpPassword.hash(password);

// Verify the password
if (phpPassword.verify(password, hashedPassword)) {
console.log('Success');
} else {
console.log('Failed');
}
```