Create a gist now

Instantly share code, notes, and snippets.

What would you like to do?
-static void DisableGDB() {
- void *handle = dlopen(0, RTLD_GLOBAL | RTLD_NOW);
- ptrace_ptr_t ptrace_ptr = dlsym(handle, "ptrace");
- ptrace_ptr(PT_DENY_ATTACH, 0, 0, 0);
- dlclose(handle);
-}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment