mirror of
https://github.com/hexahigh/nodejs-hash-antivirus.git
synced 2025-12-11 20:05:07 +01:00
update
This commit is contained in:
parent
7c076caa80
commit
b34c8fecd6
@ -5,7 +5,7 @@ var crypto = require('crypto');
|
||||
var os = require("os");
|
||||
|
||||
let arraynumber = 1
|
||||
let filetoadd2 = nil
|
||||
let filetoadd2 = 0
|
||||
|
||||
const filetoadd = prompt("Enter path/name of file/folder to be added: ");
|
||||
|
||||
@ -16,7 +16,7 @@ function delay(milliseconds) {
|
||||
});
|
||||
}
|
||||
|
||||
fs.readdir(filetoadd, (err, files) => {
|
||||
const test1 = fs.readdir(filetoadd, (err, files) => {
|
||||
if (err) {
|
||||
console.error(`Error reading directory: ${err}`);
|
||||
return;
|
||||
@ -31,9 +31,11 @@ fs.readdir(filetoadd, (err, files) => {
|
||||
|
||||
console.log(fileNamesAndExtensions);
|
||||
});
|
||||
|
||||
while(true) {
|
||||
let filetoadd2 = fileNamesAndExtensions[arraynumber]
|
||||
console.log(test1)
|
||||
loop1()
|
||||
function loop1() {
|
||||
while (true) {
|
||||
filetoadd2 = fileNamesAndExtensions[arraynumber]
|
||||
let buff = fs.readFileSync(filetoadd2);
|
||||
let outputdata0 = crypto.createHash("md5").update(buff).digest("hex");
|
||||
let outputdata = outputdata0.toString().toUpperCase();
|
||||
@ -55,4 +57,5 @@ while(true) {
|
||||
});
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
11
node_modules/.package-lock.json
generated
vendored
11
node_modules/.package-lock.json
generated
vendored
@ -12,17 +12,6 @@
|
||||
"node": ">=6"
|
||||
}
|
||||
},
|
||||
"node_modules/crypto": {
|
||||
"version": "1.0.1",
|
||||
"resolved": "https://registry.npmjs.org/crypto/-/crypto-1.0.1.tgz",
|
||||
"integrity": "sha512-VxBKmeNcqQdiUQUW2Tzq0t377b54N2bMtXO/qiLa+6eRRmmC4qT3D4OnTGoT/U6O9aklQ/jTwbOtRMTTY8G0Ig==",
|
||||
"deprecated": "This package is no longer supported. It's now a built-in Node module. If you've depended on crypto, you should switch to the one that's built-in."
|
||||
},
|
||||
"node_modules/fs": {
|
||||
"version": "0.0.1-security",
|
||||
"resolved": "https://registry.npmjs.org/fs/-/fs-0.0.1-security.tgz",
|
||||
"integrity": "sha512-3XY9e1pP0CVEUCdj5BmfIZxRBTSDycnbqhIOGec9QYtmVH2fbLpj86CFWkrNOkt/Fvty4KZG5lTglL9j/gJ87w=="
|
||||
},
|
||||
"node_modules/prompt-sync": {
|
||||
"version": "4.2.0",
|
||||
"resolved": "https://registry.npmjs.org/prompt-sync/-/prompt-sync-4.2.0.tgz",
|
||||
|
||||
23
package-lock.json
generated
23
package-lock.json
generated
@ -9,8 +9,6 @@
|
||||
"version": "1.0.0",
|
||||
"license": "ISC",
|
||||
"dependencies": {
|
||||
"crypto": "^1.0.1",
|
||||
"fs": "^0.0.1-security",
|
||||
"prompt-sync": "^4.2.0"
|
||||
}
|
||||
},
|
||||
@ -22,17 +20,6 @@
|
||||
"node": ">=6"
|
||||
}
|
||||
},
|
||||
"node_modules/crypto": {
|
||||
"version": "1.0.1",
|
||||
"resolved": "https://registry.npmjs.org/crypto/-/crypto-1.0.1.tgz",
|
||||
"integrity": "sha512-VxBKmeNcqQdiUQUW2Tzq0t377b54N2bMtXO/qiLa+6eRRmmC4qT3D4OnTGoT/U6O9aklQ/jTwbOtRMTTY8G0Ig==",
|
||||
"deprecated": "This package is no longer supported. It's now a built-in Node module. If you've depended on crypto, you should switch to the one that's built-in."
|
||||
},
|
||||
"node_modules/fs": {
|
||||
"version": "0.0.1-security",
|
||||
"resolved": "https://registry.npmjs.org/fs/-/fs-0.0.1-security.tgz",
|
||||
"integrity": "sha512-3XY9e1pP0CVEUCdj5BmfIZxRBTSDycnbqhIOGec9QYtmVH2fbLpj86CFWkrNOkt/Fvty4KZG5lTglL9j/gJ87w=="
|
||||
},
|
||||
"node_modules/prompt-sync": {
|
||||
"version": "4.2.0",
|
||||
"resolved": "https://registry.npmjs.org/prompt-sync/-/prompt-sync-4.2.0.tgz",
|
||||
@ -59,16 +46,6 @@
|
||||
"resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.1.tgz",
|
||||
"integrity": "sha512-ILlv4k/3f6vfQ4OoP2AGvirOktlQ98ZEL1k9FaQjxa3L1abBgbuTDAdPOpvbGncC0BTVQrl+OM8xZGK6tWXt7g=="
|
||||
},
|
||||
"crypto": {
|
||||
"version": "1.0.1",
|
||||
"resolved": "https://registry.npmjs.org/crypto/-/crypto-1.0.1.tgz",
|
||||
"integrity": "sha512-VxBKmeNcqQdiUQUW2Tzq0t377b54N2bMtXO/qiLa+6eRRmmC4qT3D4OnTGoT/U6O9aklQ/jTwbOtRMTTY8G0Ig=="
|
||||
},
|
||||
"fs": {
|
||||
"version": "0.0.1-security",
|
||||
"resolved": "https://registry.npmjs.org/fs/-/fs-0.0.1-security.tgz",
|
||||
"integrity": "sha512-3XY9e1pP0CVEUCdj5BmfIZxRBTSDycnbqhIOGec9QYtmVH2fbLpj86CFWkrNOkt/Fvty4KZG5lTglL9j/gJ87w=="
|
||||
},
|
||||
"prompt-sync": {
|
||||
"version": "4.2.0",
|
||||
"resolved": "https://registry.npmjs.org/prompt-sync/-/prompt-sync-4.2.0.tgz",
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user