# Symlink Trickery

Symlinks can sometimes be used to creatively subvert the expectations of a program and escalate privileges.&#x20;

For example, let's say a cronjob is backing up files from a directory and making them world readable. If you can delete that directory and replace it with a symlink to a system folder, then you can read the system files.

Symlinks can also be useful when exploiting [SUID executables](https://heinosass.gitbook.io/leet-sheet/post-exploitation/linux/linux-privilege-escalation/suid-bit) and especially [wildcard injections](https://heinosass.gitbook.io/leet-sheet/post-exploitation/linux/wildcard-injection#chmod-chown-privilege-hijack).
