sonyxperiadev / pygerrit

MIT License
52 stars 52 forks source link

Add support for automatically adding known_hosts #41

Closed copland closed 5 years ago

copland commented 5 years ago

Currently, if a server is not in the known_hosts file then the client will fail with an error like:

paramiko.SSHException: Server '[]:' not found in known_hosts

This change allows users to configure paramiko with the AutoAddPolicy(). It should be noted that using this policy opens users to man-in-the-middle attacks, which is why it is an optional setting and defaults to False.

copland commented 5 years ago

It seems like #40 may have been abandoned so I submitted this alternate PR.

dpursehouse commented 5 years ago

Thanks!