def _get_keyid(keytype, scheme, key_value, hash_algorithm = '<STR_LIT>'):
<EOL>key_meta = format_keyval_to_metadata(keytype, scheme, key_value, private=False)<EOL>key_update_data = securesystemslib.formats.encode_canonical(key_meta)<EOL>digest_object = securesystemslib.hash.digest(hash_algorithm)<EOL>digest_object.update(key_update_data.encode('<STR_LIT:utf-8>'))<EOL>keyid = digest_object.hexdigest()<EOL>return keyid<EOL>
Return the keyid of 'key_value'.