diff options
author | Sascha Hauer <s.hauer@pengutronix.de> | 2022-05-04 11:49:28 +0200 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2022-05-04 15:12:31 +0200 |
commit | b2f33a4b95af0566c735cfc188dc8758636c2263 (patch) | |
tree | f1393092fe111ddebcf3c71ff482dcf2f4a840ee /include | |
parent | a05ac5545c43a5420757e0f5529edea95230ced5 (diff) | |
download | barebox-b2f33a4b95af0566c735cfc188dc8758636c2263.tar.gz barebox-b2f33a4b95af0566c735cfc188dc8758636c2263.tar.xz |
rsa: Collect keys on list
Currently there is no way to iterate over all available RSA keys.
This patch collects all keys on a list so we can add an iterator
in the next step.
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'include')
-rw-r--r-- | include/rsa.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/include/rsa.h b/include/rsa.h index 803660d19a..4ef16ea5a8 100644 --- a/include/rsa.h +++ b/include/rsa.h @@ -29,6 +29,7 @@ struct rsa_public_key { uint32_t *rr; /* R^2 as little endian array */ uint64_t exponent; /* public exponent */ char *key_name_hint; + struct list_head list; }; /** @@ -52,6 +53,6 @@ int rsa_verify(const struct rsa_public_key *key, const uint8_t *sig, struct rsa_public_key *rsa_of_read_key(struct device_node *node); void rsa_key_free(struct rsa_public_key *key); -struct rsa_public_key *rsa_get_key(const char *name); +const struct rsa_public_key *rsa_get_key(const char *name); #endif |