Skip to content

Commit 5d9072b

Browse files
committed
sort __init__.py and blacken openssh.py
1 parent d52c045 commit 5d9072b

File tree

2 files changed

+30
-20
lines changed

2 files changed

+30
-20
lines changed

cve_bin_tool/checkers/__init__.py

Lines changed: 13 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,21 @@
11
""" CVE Checkers """
22
__all__ = [
3+
"bluez",
34
"curl",
4-
"node",
5-
"xml2",
65
"expat",
7-
"openssl",
8-
"tiff",
9-
"zlib",
6+
"icu",
7+
"kerberos",
8+
"libgcrypt",
9+
"libjpeg",
1010
"libnss",
11+
"node",
12+
"openssh",
13+
"openssl",
1114
"png",
12-
"xerces",
13-
"libjpeg",
14-
"xerces",
15-
"libgcrypt",
16-
"systemd",
1715
"sqlite",
18-
"kerberos",
19-
"icu",
20-
"openssh",
21-
"bluez",
16+
"systemd",
17+
"tiff",
18+
"xerces",
19+
"xml2",
20+
"zlib",
2221
]

cve_bin_tool/checkers/openssh.py

Lines changed: 17 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,12 @@
1010

1111
import sys, re
1212

13+
1314
def get_version(lines, filename):
1415
"""
1516
Get the version and return it for OpenSSH server or client
1617
17-
VPkg: openssh
18+
VPkg: openbsd, openssh
1819
"""
1920
regex = re.compile("OpenSSH_([0-9]+\.[0-9]+[0-9a-z\s]*)")
2021
version_info = dict()
@@ -23,11 +24,21 @@ def get_version(lines, filename):
2324
for l in lines:
2425
if regex.match(l):
2526
version_info["version"] = regex.match(l).groups()[0]
26-
break # The binary seems to contain many version strings and the
27-
#first one matches the binary in question
28-
29-
if filename in ["scp", "sftp", "ssh", "ssh-add", "ssh-agent", "ssh-argv0", \
30-
"ssh-copy-id", "ssh-keygen", "ssh-keyscan", "slogin"]:
27+
break # The binary seems to contain many version strings and the
28+
# first one matches the binary in question
29+
30+
if filename in [
31+
"scp",
32+
"sftp",
33+
"ssh",
34+
"ssh-add",
35+
"ssh-agent",
36+
"ssh-argv0",
37+
"ssh-copy-id",
38+
"ssh-keygen",
39+
"ssh-keyscan",
40+
"slogin",
41+
]:
3142
version_info["is_or_contains"] = "is"
3243
version_info["modulename"] = "openssh-client"
3344
elif filename in ["sshd"]:

0 commit comments

Comments
 (0)