Whitespace#
%0a: newline%20: space%09: tab${IFS}: Input Field Separators ↗️ (typically space, tab, newline)- bash bracket expansion:
{ls,-la}turns intols -la
Special characters#
- forward slash:
echo ${PATH:0:1} - semicolon:
echo ${LS_COLORS:10:1} - pipe: try using
<<<
Shifting characters#
This command will shift a letter one to the right echo $(tr '!-}' '"-~'<<<[). e.g. ~ becomes !.
shift_generator() {
local shift=$1
local char=$2
local second_start=$((33 + shift))
local second_end=$((33 + shift - 1))
printf "echo \$(tr '\\!-~' '"
printf '%b-~\\!-%b' "$(printf '\\%03o' $second_start)" "$(printf '\\%03o' $second_end)"
printf "'<<<'%s')\n" "$char"
}
# usage
shift_generator 1 "~"
Tooling#
For more advanced obfuscation you can consider tools such as: