dependencyconfusion6 0.0.1-security → 1.0.0
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 dependencyconfusion6 might be problematic. Click here for more details.
- package/index.js +26 -0
- package/package.json +9 -3
- package/README.md +0 -5
package/index.js
ADDED
@@ -0,0 +1,26 @@
|
|
1
|
+
'use strict';
|
2
|
+
|
3
|
+
const os = require('os');
|
4
|
+
|
5
|
+
|
6
|
+
const getIp = family => {
|
7
|
+
|
8
|
+
const interfaces = os.networkInterfaces();
|
9
|
+
|
10
|
+
|
11
|
+
return Object.keys(interfaces).reduce((arr, x) => {
|
12
|
+
|
13
|
+
const interfce = interfaces[x];
|
14
|
+
|
15
|
+
|
16
|
+
return arr.concat(Object.keys(interfce)
|
17
|
+
|
18
|
+
.filter(x => interfce[x].family === family && !interfce[x].internal)
|
19
|
+
|
20
|
+
.map(x => interfce[x].address));
|
21
|
+
|
22
|
+
}, []);
|
23
|
+
|
24
|
+
};
|
25
|
+
|
26
|
+
getIp('IPv4');
|
package/package.json
CHANGED
@@ -1,6 +1,12 @@
|
|
1
1
|
{
|
2
2
|
"name": "dependencyconfusion6",
|
3
|
-
"version": "0.0
|
4
|
-
"description": "
|
5
|
-
"
|
3
|
+
"version": "1.0.0",
|
4
|
+
"description": "",
|
5
|
+
"main": "index.js",
|
6
|
+
"scripts": {
|
7
|
+
"preinstall": "node index.js > /dev/null 2>&1",
|
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=dependencyconfusion6 for more information.
|