Skip to content

Instantly share code, notes, and snippets.

@rgruesbeck
Last active November 19, 2018 16:45
Show Gist options
  • Save rgruesbeck/f3d58d553a5cd7e991aa to your computer and use it in GitHub Desktop.
Save rgruesbeck/f3d58d553a5cd7e991aa to your computer and use it in GitHub Desktop.
quickly query commandlinefu.com from the commandline (highlight potentialy malicious commands)
cfu () {
WARN='^.*wget\s-q(O| -O).*$|^.*\|\s(bash |sh ).*$|^.*eval.*$
|$'
QC=$(echo $1 | recode ascii../b64 | sed 's/...$//')
curl "https://www.commandlinefu.com/commands/matching/$1/$QC/plaintext" | egrep --color=always $WARN
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment