From c87a6b0f77a8d57c0995f9caf0a25515c6d6d37b Mon Sep 17 00:00:00 2001 From: Bram Mittendorff Date: Thu, 18 Oct 2018 13:08:19 +0200 Subject: [PATCH] Updated SSHException to meetup with conform python 3.x Since you are using Python 3.x., you should actually be using the newer str.format method. Though % and , formatting is not officially deprecated (yet), it is discouraged in favor of str.format and will most likely be removed from the language in a coming version (Python 4 maybe?). --- CVE-2018-10933.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CVE-2018-10933.py b/CVE-2018-10933.py index 17b0bc8..5abc7d5 100644 --- a/CVE-2018-10933.py +++ b/CVE-2018-10933.py @@ -29,7 +29,7 @@ def main(hostname="127.0.0.1", port=22): cmd_channel = transport.open_session() cmd_channel.invoke_shell() except SSHException as e: - print(f'SSH Exception: {e}', file=sys.stdout) + print('SSH Exception: {}'.format(e)) return 1