Skip to content

Instantly share code, notes, and snippets.

@antoni
Last active April 25, 2016 09:09
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save antoni/83edb611014b8255a2708f0d3ec5a21a to your computer and use it in GitHub Desktop.
Save antoni/83edb611014b8255a2708f0d3ec5a21a to your computer and use it in GitHub Desktop.
Terminal escape sequences
# Source: https://m.reddit.com/r/netsec/comments/4fi3hn/detecting_the_use_of_curl_bash_server_side/
$ cat > evil.sh <<EOF
echo rm -rf /home; FOO=^M echo "nothing fishy here!"
EOF
$ cat evil.sh
echo "nothing fishy here!"
$ source evil.sh
rm -rf /home
nothing fishy here!
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment