At import time, getpass will be bound to the appropriate
platform-specific function. If the platform's echo-disabler is not
available, default_getpass, which prints the warning, will be used
Windows. If sys.stdin doesn't appear to be a real file (characterized
by having a working fileno()), don't use any console specific methods
-- go straight to the default.
the tty and the caller can deal with the interrupt.
In the windows version, recognize ^C and raise KeyboardInterrupt (not
sure if this is needed, but can't hurt).