Heads-up: unfortunately, it is not possible to spoof MAC address on some Macs (see issue).
$, strip out
$as this character is not part of the command
cat << "EOF", select all lines at once (from
cat << "EOF"to
EOFinclusively) as they are part of the same (single) command
com.apple.loginwindowdoes not exist
com.apple.loginwindowexists, one needs to backup user default carefully and consider using an abstraction that runs both current
Domain com.apple.loginwindow does not exist
“Spoofed hostname” is random and “Spoofed MAC address” does not match “Hardware MAC address”?
Johnwith your name.