fix for Debian's fucking braindead packagers
This commit is contained in:
parent
6543b230d4
commit
77b22b8b8a
@ -115,7 +115,10 @@ tstamp = int(datetime.datetime.utcnow().timestamp())
|
|||||||
# nmap --script ssh2-enum-algos -PN -sV -p22 <host>
|
# nmap --script ssh2-enum-algos -PN -sV -p22 <host>
|
||||||
magic_ver = 6.5
|
magic_ver = 6.5
|
||||||
ssh_ver = subprocess.run(['ssh', '-V'], stderr = subprocess.PIPE).stderr.decode('utf-8').strip().split()[0]
|
ssh_ver = subprocess.run(['ssh', '-V'], stderr = subprocess.PIPE).stderr.decode('utf-8').strip().split()[0]
|
||||||
ssh_ver = float(re.sub('^(Open|Sun_)SSH_([0-9\.]+)(p[0-9]+)?,.*$', '\g<2>', ssh_ver))
|
# FUCK YOU, DEBIAN. FUCK YOU AND ALL OF YOUR DERIVATIVES. YOU'RE FUCKING TRASH.
|
||||||
|
# YOU BELONG NOWHERE NEAR A DATACENTER.
|
||||||
|
#ssh_ver = float(re.sub('^(Open|Sun_)SSH_([0-9\.]+)(p[0-9]+)?,.*$', '\g<2>', ssh_ver))
|
||||||
|
ssh_ver = float(re.sub('^(?:Open|Sun_)SSH_([0-9\.]+)(?:p[0-9]+)?(?:,|\s+).*$', '\g<1>', ssh_ver))
|
||||||
if ssh_ver >= magic_ver:
|
if ssh_ver >= magic_ver:
|
||||||
has_ed25519 = True
|
has_ed25519 = True
|
||||||
supported_keys = ('ed25519', 'rsa')
|
supported_keys = ('ed25519', 'rsa')
|
||||||
|
Loading…
Reference in New Issue
Block a user