Created
April 1, 2019 12:59
-
-
Save vikiival/ae2e3af4bec9b65547250c26ba0c8c81 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
int main() { | |
int id; | |
__asm__( | |
"mov $0x02000004, %%eax;" | |
"syscall;\n" | |
: "=a"(id) | |
); | |
// application gets user id | |
// you can find system call http://shell-storm.org/shellcode/files/syscalls.html | |
return 0 | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment