Skip to content

Commit

Permalink
Added option to reject/disable interactive passwords
Browse files Browse the repository at this point in the history
  • Loading branch information
trbs committed Mar 4, 2011
1 parent 64eb6c5 commit 1679d7b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
5 changes: 5 additions & 0 deletions fabric/network.py
Expand Up @@ -194,6 +194,11 @@ def connect(user, host, port):

# Otherwise, assume an auth exception, and prompt for new/better
# password.

# If enviroment specified that no interactive password should be asked
# abort directly with corresponding message.
if env.reject_interactive_password:
abort('Rejecting interactive passwords while trying to connect to %s' % host)

# Paramiko doesn't handle prompting for locked private keys (i.e.
# keys with a passphrase and not loaded into an agent) so we have
Expand Down
1 change: 1 addition & 0 deletions fabric/state.py
Expand Up @@ -244,6 +244,7 @@ def _rc_path():
'sudo_prompt': 'sudo password:',
'use_shell': True,
'user': None,
'reject_interactive_password': False,
'version': get_version('short')
})

Expand Down

0 comments on commit 1679d7b

Please sign in to comment.