Skip to content

Fixed ssh-key auth#281

Merged
shermdog merged 3 commits into
Juniper:masterfrom
shermdog:sshident
Jul 17, 2014
Merged

Fixed ssh-key auth#281
shermdog merged 3 commits into
Juniper:masterfrom
shermdog:sshident

Conversation

@shermdog
Copy link
Copy Markdown
Contributor

Added the ability to use IdentityFile from .ssh/config file
Also re-enabled default of underlying ncclient allow_agent and look_for_keys
By default ncclient will:
1. Try passed in keyfile
2. Look for keys loaded in agent
3. Look for default keys in user home
4. Try passed in user/pass combo

Added the ability to use IdentityFile from .ssh/config file
Also re-enabled default of underlying ncclient allow_agent and look_for_keys
By default ncclient will:
	1. Try passed in keyfile
	2. Look for keys loaded in agent
	3. Look for default keys in user home
	4. Try passed in user/pass combo
@shermdog
Copy link
Copy Markdown
Contributor Author

I should also note, with this change if a key file is present but requires a password it can be passed in Device(host='host', passwd='key_password')

@coveralls
Copy link
Copy Markdown

Coverage Status

Coverage increased (+0.0%) when pulling 9ccc274 on shermdog:sshident into 733921e on Juniper:master.

@jeremyschulman
Copy link
Copy Markdown
Contributor

@shermdog - the prior code was designed such that when running the program the user was not presented with a popup dialog prompting for a sshkey password. I like the addition of supporting the ssh key files as we discussed. I see that you re-enabled the flags in the underlying ncclient connect that caused the "popup". So long as your new changes ensure "no popup" I think you are A-OK. I spent a bit of time testing all the scenarios before; so please add the necessary test/unit moch test cases so that you don't have to keep doing it manually. Thank you!

@coveralls
Copy link
Copy Markdown

Coverage Status

Coverage increased (+0.0%) when pulling 7abe593 on shermdog:sshident into 733921e on Juniper:master.

@coveralls
Copy link
Copy Markdown

Coverage Status

Coverage increased (+0.0%) when pulling 9f32d68 on shermdog:sshident into 733921e on Juniper:master.

shermdog added a commit that referenced this pull request Jul 17, 2014
@shermdog shermdog merged commit 32323fb into Juniper:master Jul 17, 2014
shermdog added a commit to shermdog/py-junos-eznc that referenced this pull request May 20, 2015
@vincentbernat
Copy link
Copy Markdown
Contributor

Please, have a look at #648 as I wasn't happy with it was decided if the agent should be used.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants