[riot-notifications] [RIOT-OS/RIOT] sys/credman: add key load functions (#16263)

Leandro Lanzieri notifications at github.com
Thu Sep 16 13:49:27 CEST 2021


@leandrolanzieri commented on this pull request.



> + *
+ * @note To use this functionality include the module `credman_load`. Credman only supports ECDSA
+ *       for now, so [RFC5480](https://tools.ietf.org/html/rfc5480) applies.
+ *
+ * @experimental This API is considered experimental and will probably change without notice!
+ *
+ * @see https://tools.ietf.org/html/rfc5280#section-4.1
+ *
+ * @param[in]  buf          Buffer holding the encoded public key
+ * @param[in]  buf_len      Length of @p buf
+ * @param[out] out          ECDSA public key to populate
+ *
+ * @retval CREDMAN_OK on success
+ * @retval CREDMAN_INVALID if the key is not valid
+ */
+int credman_load_public_key(const uint8_t *buf, size_t buf_len, ecdsa_public_key_t *out);

I think it could make sense, [`credman_buffer_t`](http://doc.riot-os.org/structcredman__buffer__t.html) is already using `void *` so it kind of fits.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/RIOT-OS/RIOT/pull/16263#discussion_r710042112
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.riot-os.org/pipermail/notifications/attachments/20210916/486b5a0c/attachment.htm>


More information about the notifications mailing list