How worm0x1/k4gen1nja works
Project Type and Purpose
• This is a static, front‐end–only demonstration site (index.html + script.js) hosted on a static-file host (e.g., Vercel).
• Its goal is to show how a malicious page can request camera/microphone/keyboard/GPS permissions and send the collected media/info to a Telegram Bot via simple HTTP calls.
Main Components
a. Client (User’s Browser)
• index.html + script.js loaded over HTTPS.
• Executes JavaScript to prompt for permissions, capture media and device/browser info.
b. Static Host (Vercel or equivalent)
• Serves index.html, script.js, and any static assets.
c. Public/Private Code API Endpoints
• Serverless functions (e.g., /video-f.html, /video-b.html, /main.html) that accept token & chat ID parameters.
• Relay the captured blobs and metadata to Telegram via the Bot API.
d. Telegram Bot Service
• External service endpoint (api.telegram.org) which receives HTTP requests from the Code API and delivers messages/media to the attacker’s chat.
Data Flows & Interactions
1. User navigates to the malicious link → Browser requests index.html and script.js from the Static Host.
2. script.js prompts for permissions (camera, mic, GPS, keyboard info).
3. If granted, media streams or snapshots are captured; otherwise, browser+OS info is collected.
4. script.js posts the data (via HTTP GET/POST) to one of the Code API endpoints, passing the attacker’s Telegram Bot token & chat ID as query parameters.
5. The Code API serverless function calls Telegram’s Bot API (https://api.telegram.org/bot<TOKEN>/sendPhoto or sendVideo/sendMessage) to forward the data.
6. Telegram delivers content to the attacker’s chat.
Architectural Patterns & Principles
• Single‐page static front end + serverless “backend” (thin relay).
• Separation of concerns: static hosting for UI/UX vs. serverless functions for messaging.
• External‐service integration: Telegram Bot API as a third‐party messaging service.