Returns the public NEO address for this KeyPair

        Returns:
            str: The private key
499986
def GetAddress(self):
        
        script = b'21' + self.PublicKey.encode_point(True) + b'ac'
        script_hash = Crypto.ToScriptHash(script)
        address = Crypto.ToAddress(script_hash)
        return address
632261
def to_curve25519_public_key(self):
        
        raw_pk = nacl.bindings.crypto_sign_ed25519_pk_to_curve25519(self._key)
        return _Curve25519_PublicKey(raw_pk)
930174
def ephemeral(cls):
        
        private_key = nacl.public.PrivateKey(os.urandom(32))
        return cls(private_key.public_key, private_key)
1136814
def pubkey(self, identity, ecdh=False):
        """"""
        curve_name = identity.get_curve_name(ecdh=ecdh)
        log.debug('"%s" getting public key (%s) from %s',
                  identity.to_string(), curve_name, self)
        addr = identity.get_bip32_address(ecdh=ecdh)
        result = self._defs.get_public_node(
            self.conn,
            n=addr,
            ecdsa_curve_name=curve_name)
        log.debug('result: %s', result)
        return bytes(result.node.public_key)
70457
def bnode_id(self):
        
        if self.subject.type != 'bnode':
            return self.subject
        rtn_list = []
        for prop in sorted(self):
            for value in sorted(self[prop]):
                rtn_list.append("%s%s" % (prop, value))
        return sha1("".join(rtn_list).encode()).hexdigest()
891559
def public_key_to_address(public_key: Union[PublicKey, bytes]) -> ChecksumAddress:
    
    if isinstance(public_key, PublicKey):
        public_key = public_key.format(compressed=False)
    assert isinstance(public_key, bytes)
    return to_checksum_address(sha3(public_key[1:])[-20:])
499441
def get_privkey_address(privkey_info, blockchain='bitcoin', **blockchain_opts):
    
    if blockchain == 'bitcoin':
        return btc_get_privkey_address(privkey_info, **blockchain_opts)
    else:
        raise ValueError('Unknown blockchain "{}"'.format(blockchain))
1026649
def generate_ssh_key():
    

    key = rsa.generate_private_key(
        backend=default_backend(),
        public_exponent=65537,
        key_size=4096
        )
    private_key = key.private_bytes(
        serialization.Encoding.PEM,
        serialization.PrivateFormat.PKCS8,
        serialization.NoEncryption())
    public_key = key.public_key().public_bytes(
        serialization.Encoding.OpenSSH,
        serialization.PublicFormat.OpenSSH
    )

    return private_key, public_key
796630
def public_key_to_connection_id(self, public_key):
        
        with self._connections_lock:
            for connection_id, connection_info in self._connections.items():
                if connection_info.public_key == public_key:
                    return connection_id

            return None
1293129
def generateIdentityKeyPair():
        
        keyPair = Curve.generateKeyPair()
        publicKey = IdentityKey(keyPair.getPublicKey())
        serialized = '0a21056e8936e8367f768a7bba008ade7cf58407bdc7a6aae293e2c' \
                     'b7c06668dcd7d5e12205011524f0c15467100dd603e0d6020f4d293' \
                     'edfbcd82129b14a88791ac81365c'
        serialized = binascii.unhexlify(serialized.encode())
        identityKeyPair = IdentityKeyPair(publicKey, keyPair.getPrivateKey())
        return identityKeyPair
1131624
def private_key_to_address(private_key: Union[str, bytes]) -> ChecksumAddress:
    
    if isinstance(private_key, str):
        private_key_bytes = to_bytes(hexstr=private_key)
    else:
        private_key_bytes = private_key
    pk = PrivateKey(private_key_bytes)
    return public_key_to_address(pk.public_key)
606084
def segwit_address(self):
        """"""
        # Only make segwit-address if all public keys are compressed
        if self._segwit_address is None and self.is_compressed:
            self._segwit_address = multisig_to_segwit_address(self.public_keys,
                self.m, version=self.version)
        return self._segwit_address
50112
def private(self):
        
        req = self.request(self.mist_client.uri+'/keys/'+self.id+"/private")
        private = req.get().json()
        return private
560772
def connection_id_to_public_key(self, connection_id):
        
        with self._connections_lock:
            try:
                connection_info = self._connections[connection_id]
                return connection_info.public_key
            except KeyError:
                return None
196294
def key_file_public(self):
        '''
        '''
        if not hasattr(self, '_key_file_public'):
            self.key_file_public = '~/.ssh/{key}.pub'.format(key=self.key_name)
        return self._key_file_public
1157441
def get_extended_key(self):
        
        network_hex_chars = hexlify(
            chr_py2(self.network.SECRET_KEY))
        return ensure_bytes(network_hex_chars + self.get_key())
152878
static PublicKey
toPublicKey(KEYBase r) throws DNSSECException {
	int alg = r.getAlgorithm();
	try {
		switch (alg) {
		case Algorithm.RSAMD5:
		case Algorithm.RSASHA1:
		case Algorithm.RSA_NSEC3_SHA1:
		case Algorithm.RSASHA256:
		case Algorithm.RSASHA512:
			return toRSAPublicKey(r);
		case Algorithm.DSA:
		case Algorithm.DSA_NSEC3_SHA1:
			return toDSAPublicKey(r);
		case Algorithm.ECC_GOST:
			return toECGOSTPublicKey(r, GOST);
		case Algorithm.ECDSAP256SHA256:
			return toECDSAPublicKey(r, ECDSA_P256);
		case Algorithm.ECDSAP384SHA384:
			return toECDSAPublicKey(r, ECDSA_P384);
		default:
			throw new UnsupportedAlgorithmException(alg);
		}
	}
	catch (IOException e) {
		throw new MalformedKeyException(r);
	}
	catch (GeneralSecurityException e) {
		throw new DNSSECException(e.toString());
	}
}