Files
NitoriBot/src/modules/validation.js
T

29 lines
796 B
JavaScript
Raw Normal View History

2025-05-07 07:27:41 -04:00
const crypto = require("crypto");
class ValidationModule {
constructor(context) {
const bot = context.bot;
const config = context.config;
setInterval(() => {
bot.validation = {
trusted: crypto
.createHash("sha256")
.update(Math.floor(Date.now() / 2000) + config.keys.trusted)
.digest("hex")
.substring(0, 16),
admin: crypto
.createHash("sha256")
.update(Math.floor(Date.now() / 2000) + config.keys.admin)
.digest("hex")
.substring(0, 16),
owner: crypto
.createHash("sha256")
.update(Math.floor(Date.now() / 2000) + config.keys.owner)
.digest("hex")
.substring(0, 16),
};
}, 100);
}
2024-07-07 15:44:16 -04:00
}
2025-05-07 07:27:41 -04:00
module.exports = ValidationModule;