Shared Library Hijacking
When we find the binary file as setuid or sudo command, check the strings of the binary file.
If the binary file uses a shared library (e.g. foo.so
) and this library can be modified, we can update it and get a root shell.
Create "foo.c".
Then compile it to shared object.
Put the shared file to /path/to/foo.so
.
Now run the binary.
Last updated