Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- #include <unistd.h>
- int main(int argc, char **argv) {
- if (argc < 2) {
- fprintf(stderr, "Pass the command.\n");
- return -1;
- }
- setuid(0);
- setgid(0);
- return execvp(argv[1], argv + 1);
- }
Add Comment
Please, Sign In to add comment