fix problems with the use of a passphrase, add option to use a key instead of passphrase