makes ssh plugin resilient against invalid entries in hosts file

fixes #10238
This commit is contained in:
Brian Coca 2015-07-30 23:33:09 -04:00
parent e349004325
commit 496186f5de

View file

@ -243,6 +243,8 @@ class Connection(ConnectionBase):
tokens = line.split()
if not tokens:
continue
if isinstance(tokens, list) and tokens: # skip invalid hostlines
if tokens[0].find(self.HASHED_KEY_MAGIC) == 0:
# this is a hashed known host entry
try: