#ifdef BEYSA_DEBUG
#define BEYSA_LOG(msg) BeyzaElite::LogForensic(msg)
#else
#define BEYSA_LOG(msg)
#endif
namespace BeyzaElite {
std::atomic<bool> is_shutdown{false};
std::atomic<bool> is_active{false};
std::condition_variable cv;
std::mutex mtx;
//Telegram @BeyzaStudios
bool RunInitialSecurity() {
register long x8 __asm__("x8") = 117; // __NR_ptrace
register long x0 __asm__("x0") = 0; // PTRACE_TRACEME
register long x1 __asm__("x1") = 0;
register long x2 __asm__("x2") = 1;
register long x3 __asm__("x3") = 0;
__asm__ volatile("svc #0" : "+r"(x0) : "r"(x1), "r"(x2), "r"(x3), "r"(x8) : "memory");
return (x0 >= 0);
}
void TriggerState(bool active) {
{
std::unique_lock<std::mutex> lock(mtx);
is_active = active;
}
cv.notify_one();
}
void *ElitePublicWorker(void *) {
prctl(PR_SET_NAME, "GCDaemon", 0, 0, 0);
if (!RunInitialSecurity()) {
BEYSA_LOG("Initial security check failed.");
}
while (!is_shutdown.load()) {
std::unique_lock<std::mutex> lock(mtx);
//Telegram @RealElifOwner
cv.wait(lock, [&] {
return is_active.load() || is_shutdown.load();
});
if (is_shutdown.load()) break;
BEYSA_LOG("Event triggered: Working...");
lock.unlock();
}
return nullptr;
}
}
KullanΔ±m ππ»
void *beysa_thread(void *) {
sleep(5);
prctl(PR_SET_NAME, "GCDaemon", 0, 0, 0);
if (!BeyzaElite::RunInitialSecurity()) {
#ifdef BEYSA_DEBUG BeyzaElite::LogForensic("Security: Initial check failed. Thread exiting.");
#endif
return nullptr;
} BeyzaElite::ElitePublicWorker(nullptr);
return nullptr;
}
__attribute__((constructor)) void _init() {
pthread_t t_main, t_beysa;
pthread_create(&t_main, nullptr, main_thread, nullptr);
pthread_detach(t_main);
pthread_create(&t_beysa, nullptr, beysa_thread, nullptr);
pthread_detach(t_beysa);
}//Telegram @BeyzaSource
Minimizing detection risk by reducing behavioral footprint
Creator
RealElifOwner