There are config files like wpa_supplicant.conf that can contain plaintext passwords. Sometimes I want to edit such files on my laptop while sitting in a public place, so it would be bad to show my password to everyone.
Is there an editor that can hide the password while I'm editing? Or a wrapper script that takes a regex and a path to a configfile, patches out all lines matching the regex, launches an editor on the resulting copy, patches the lines back in and writes everything back?