xref: /linux/crypto/asymmetric_keys/asymmetric_keys.h (revision ca55b2fef3a9373fcfc30f82fd26bc7fccbda732)
1 /* Internal definitions for asymmetric key type
2  *
3  * Copyright (C) 2012 Red Hat, Inc. All Rights Reserved.
4  * Written by David Howells (dhowells@redhat.com)
5  *
6  * This program is free software; you can redistribute it and/or
7  * modify it under the terms of the GNU General Public Licence
8  * as published by the Free Software Foundation; either version
9  * 2 of the Licence, or (at your option) any later version.
10  */
11 
12 extern struct asymmetric_key_id *asymmetric_key_hex_to_key_id(const char *id);
13 
14 extern int __asymmetric_key_hex_to_key_id(const char *id,
15 					  struct asymmetric_key_id *match_id,
16 					  size_t hexlen);
17 static inline
18 const struct asymmetric_key_ids *asymmetric_key_ids(const struct key *key)
19 {
20 	return key->type_data.p[1];
21 }
22