/* no ptrace module fast prevention for kenrel bug (c) 2001 a Lam3rZ odyssey */ #define MODULE #define __KERNEL__ #include #include #include #ifndef KERNEL_VERSION #define KERNEL_VERSION(a,b,c) ((a)*65536+(b)*256+(c)) #endif #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,2,0) #include #endif #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,2,14) #include #endif extern void *sys_call_table[]; int (*orig_ptrace)(int, int, int, int); int no_ptrace (int request, int pid, int addr, int data) {return -1;} int init_module(void) { orig_ptrace = sys_call_table[__NR_ptrace]; sys_call_table[__NR_ptrace]=no_ptrace; return 0; } void cleanup_module(void) { sys_call_table[__NR_ptrace]=orig_ptrace; }