From 74c9f530ceb77c71c545fe35b3b70ed9fd528be0 Mon Sep 17 00:00:00 2001 From: Alex Chavkin Date: Mon, 23 Jan 2023 16:41:43 -0500 Subject: Split known host file entries on any whitespace (Not just a single space) OpenSSH is more permissive in documentation and code --- paramiko/hostkeys.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/paramiko/hostkeys.py b/paramiko/hostkeys.py index b189aac6..13a0355d 100644 --- a/paramiko/hostkeys.py +++ b/paramiko/hostkeys.py @@ -337,7 +337,7 @@ class HostKeyEntry: :param str line: a line from an OpenSSH known_hosts file """ log = get_logger("paramiko.hostkeys") - fields = line.split(" ") + fields = line.split() if len(fields) < 3: # Bad number of fields msg = "Not enough fields found in known_hosts in line {} ({!r})" -- cgit v1.2.3