chg: [Keys] detect ssh2 private key

This commit is contained in:
Terrtia 2018-08-01 16:04:06 +02:00
parent f7f4422ff1
commit 67b0d973af
No known key found for this signature in database
GPG key ID: 1E1B1F50D84613D0

View file

@ -71,6 +71,14 @@ def search_key(paste):
p.populate_set_out(msg, 'Tags') p.populate_set_out(msg, 'Tags')
find = True find = True
if '---- BEGIN SSH2 ENCRYPTED PRIVATE KEY ----' in content:
publisher.warning('{} has an openssh private key message'.format(paste.p_name))
print('SSH2 private key message found')
msg = 'infoleak:automatic-detection="private-ssh-key";{}'.format(message)
p.populate_set_out(msg, 'Tags')
find = True
if '-----BEGIN OpenVPN Static key V1-----' in content: if '-----BEGIN OpenVPN Static key V1-----' in content:
publisher.warning('{} has an openssh private key message'.format(paste.p_name)) publisher.warning('{} has an openssh private key message'.format(paste.p_name))
print('OpenVPN Static key message found') print('OpenVPN Static key message found')