def _fingerprint(pubkey): stripped = _OpenSSH_Keyfile_Strip.sub(b'', exportkey.openSSH(pubkey.public_numbers())) decoded = base64.b64decode(stripped) khash = hashlib.md5(decoded).hexdigest() return ':'.join([khash[i:i+2] for i in range(0, len(khash), 2)])
def _pubkeyWireFormat(pubkey): pubk_numbers = pubkey.public_numbers() logger.debug('openssh format publickey:\n%s' % exportkey.openSSH(pubk_numbers)) return quoteURL(_OpenSSH_Keyfile_Strip.sub(b'', exportkey.openSSH(pubk_numbers)))
def _pubkeyWireFormat(pubkey): pubk_numbers = pubkey.public_numbers() logger.debug('openssh format publickey:\n%s' % exportkey.openSSH(pubk_numbers)) return quoteURL( _OpenSSH_Keyfile_Strip.sub(b'', exportkey.openSSH(pubk_numbers)))
def _fingerprint(pubkey): stripped = _OpenSSH_Keyfile_Strip.sub( b'', exportkey.openSSH(pubkey.public_numbers())) decoded = base64.b64decode(stripped) khash = hashlib.md5(decoded).hexdigest() return ':'.join([khash[i:i + 2] for i in range(0, len(khash), 2)])
def _pubkeyWireFormat(pubkey): return quoteURL(_OpenSSH_Keyfile_Strip.sub(b'', exportkey.openSSH(pubkey)))