I do something like this surprisingly often when dealing with iDRAC/IPMI/etc:
sleep 3; xdotool type "abc123" sleep 3; xdotool type "abc123"Alright if you prefer:
read PW; sleep 3; xdotool type "$PW"
Or if it's already on your clipboard: sleep 3; xdotool type "$(xclip -o)" $ export HISTCONTROL=ignoreboth
$ echo 'supersecret' | whateverIt is also the default on fish shell in the same anecdotal experience.