Also, if this is to be run on the command line, why don't you just ask for the password to be entered?