mirror of
https://github.com/Ylianst/MeshCentral.git
synced 2025-03-09 15:40:18 +00:00
Cleaned up deprecation warning on NodeJS 10.x.
This commit is contained in:
parent
5d6bd55249
commit
d7b60ccb07
19 changed files with 97 additions and 89 deletions
2
pass.js
2
pass.js
|
@ -53,7 +53,7 @@ exports.iishash = function (type, pwd, salt, fn) {
|
|||
fn(null, pwd);
|
||||
} else if (type == 1) {
|
||||
const hash = crypto.createHash('sha1');
|
||||
hash.update(Buffer.concat([new Buffer(salt, 'base64'), new Buffer(pwd, 'utf16le')]));
|
||||
hash.update(Buffer.concat([Buffer.from(salt, 'base64'), Buffer.from(pwd, 'utf16le')]));
|
||||
fn(null, hash.digest().toString('base64'));
|
||||
} else {
|
||||
fn('invalid type');
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue