oportunidades 8
tests / ci (push) Canceled after 0s

This commit is contained in:
2026-10-14 08:25:30 +02:00
parent 287e991486
commit ba1c0340ea
9112 changed files with 2199795 additions and 856 deletions
@@ -0,0 +1,20 @@
"use strict";
// Des module.
const des = require("unix-crypt-td-js");
// Hash generation string.
const itoa64 =
"./0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz";
// Salt generation method.
function getSalt() {
return (
itoa64[parseInt(Math.random() * 64)] + itoa64[parseInt(Math.random() * 64)]
);
}
// Exporting old style.
module.exports = (password, salt) => {
return salt ? des(password, salt) : des(password, getSalt());
};