How thorthehacker111/curse_rat works
Purpose and Entrypoints
CURSE RAT is an Android remote-administration/C2 system with a Node.js server, browser dashboard, APK builder, and Java Android client. The operational server entry point is server/server.js; APK modification/build orchestration is server/builder.js. The Android application begins through its manifest and UI/service lifecycle in client/app/src/main/AndroidManifest.xml, client/app/src/main/java/com/curse/rat/MainActivity.java, and client/app/src/main/java/com/curse/rat/MainService.java.
C2 Server and Dashboard
The Node.js server hosts the C2/control-plane functions and serves the THOR browser dashboard. Dashboard pages cover connected-client management, deployment/building, logs, and settings:
• server/server.js
• server/public/index.html
• server/public/UI/clients.html
• server/public/client.js
This is the main boundary between operators and enrolled Android clients. It manages listener/client state, relays commands, and exposes telemetry and operational status to the UI.
Payload Build Pipeline
The builder subsystem produces or patches Android payloads, including package/manifest/resource changes described by the README. It is separated from the live C2 server but likely invoked through the deployment dashboard.
• server/builder.js
• server/public/UI/build.html
• client/app/src/main/AndroidManifest.xml
Its external tool boundary is the local host environment: apktool, Java signing tools (jarsigner), and Android SDK zipalign. Generated APKs are intended for an output location, though that directory is not present in the supplied tree.
Android Runtime Persistence and Connectivity
The Android client combines an activity-facing entry point with a long-running service responsible for background operation and server connectivity.
• client/app/src/main/java/com/curse/rat/MainActivity.java
• client/app/src/main/java/com/curse/rat/MainService.java
• client/app/src/main/java/com/curse/rat/ConnectionManager.java
ConnectionManager is the client-side C2 transport boundary. MainService is the central runtime coordinator for receiving work and maintaining execution outside the visible activity, subject to Android foreground-service and permission constraints.
Command Dispatch and Capability Modules
Incoming C2 work is routed through a command-processing layer into focused device-capability managers:
• client/app/src/main/java/com/curse/rat/CommandProcessor.java
• client/app/src/main/java/com/curse/rat/FileManager.java
• client/app/src/main/java/com/curse/rat/DeviceInfoManager.java
Additional modules isolate sensitive collection or device-control domains: contacts/SMS/location, camera/microphone/screen capture, notifications, and keylogging. This modularity makes CommandProcessor the principal control-flow junction and confines Android API interactions to dedicated managers.
Media and Device Data Flows
The client gathers device state or media through managers, sends results over the connection layer, and presents received data/state through the server dashboard. Screen capture has a distinct activity, reflecting Android’s user-mediated capture APIs:
• client/app/src/main/java/com/curse/rat/CameraManager.java
• client/app/src/main/java/com/curse/rat/ScreenCastActivity.java
• client/app/src/main/java/com/curse/rat/LocManager.java
High-volume camera/screen streams are materially different from discrete command responses such as device information, files, messages, contacts, or location; the server/dashboard must therefore handle both live telemetry and result-oriented data.
Runtime and Platform Boundaries
Server runtime requirements are Node.js 16+ and npm; the Android project uses Gradle, Java 11, and the Android SDK:
• server/package.json
• client/app/build.gradle
• client/app/src/main/res/xml/accessibility_service_config.xml
Android permissions and service declarations in the manifest define the platform-security boundary for background execution, accessibility-related features, capture, sensors, storage, and communications. The browser dashboard is static frontend content served by the Node process rather than a separate web-service project.
Main entry points: ConnectionManager.java C2 transport · CommandProcessor.java Command dispatcher · index.html THOR dashboard · AndroidManifest.xml App manifest
Components 21
Operator UI
- Operator browser
- THOR dashboard · Served by the Node.js process.
server/public/index.html - Client management
server/public/UI/clients.html - Deployment builder UI
server/public/UI/build.html - Dashboard client logic
server/public/client.js
Node.js C2
- C2 server · Maintains client state, relays commands, and serves telemetry.
server/server.js - APK builder · Patches and packages Android payloads.
server/builder.js
Android Client
- App manifest · Defines permissions, services, and application entry configuration.
client/app/src/main/AndroidManifest.xml - Main activity
client/app/src/main/java/com/curse/rat/MainActivity.java - Main service · Maintains operation and executes work beyond the visible activity.
client/app/src/main/java/com/curse/rat/MainService.java - C2 transport · Client-side transport boundary to the server.
client/app/src/main/java/com/curse/rat/ConnectionManager.java - Command dispatcher · Routes incoming C2 work to capability modules.
client/app/src/main/java/com/curse/rat/CommandProcessor.java - File operations
client/app/src/main/java/com/curse/rat/FileManager.java - Device information
client/app/src/main/java/com/curse/rat/DeviceInfoManager.java - Camera capture · Produces high-volume media telemetry.
client/app/src/main/java/com/curse/rat/CameraManager.java - Screen capture consent · Handles user-mediated screen capture APIs.
client/app/src/main/java/com/curse/rat/ScreenCastActivity.java - Location collection
client/app/src/main/java/com/curse/rat/LocManager.java
Build & Platform
- APK/signing tools · apktool, jarsigner, and zipalign execute outside Node.js.
- Server runtime
server/package.json - Android build · Builds with Java 11 and the Android SDK.
client/app/build.gradle - Accessibility config · Declares accessibility-service behavior.
client/app/src/main/res/xml/accessibility_service_config.xml
Connections 28
- Operator browser → THOR dashboard: loads
- THOR dashboard → Client management: navigates to
- THOR dashboard → Deployment builder UI: navigates to
- THOR dashboard → Dashboard client logic: runs
- Dashboard client logic → C2 server: control and status requests
- C2 server → THOR dashboard: serves
- Deployment builder UI → APK builder: requests payload build
- APK builder → APK/signing tools: invokes
- APK builder → App manifest: patches package metadata
- Server runtime → C2 server: runs
- Android build → App manifest: packages
- App manifest → Main activity: launches
- App manifest → Main service: declares
- App manifest → Accessibility config: references
- Main activity → Main service: starts
- Main service → C2 transport: maintains connectivity
- C2 transport → C2 server: C2 commands and telemetry · Carries both discrete results and live media streams.
- C2 transport → Command dispatcher: delivers commands
- Command dispatcher → File operations: dispatches
- Command dispatcher → Device information: dispatches
- Command dispatcher → Camera capture: dispatches
- Command dispatcher → Screen capture consent: dispatches
- Command dispatcher → Location collection: dispatches
- File operations → C2 transport: returns results
- Device information → C2 transport: returns telemetry
- Camera capture → C2 transport: streams media
- Screen capture consent → C2 transport: streams capture
- Location collection → C2 transport: returns location