105 size_t out_cap,
size_t *out_len);
algo_attr_status_t algo_attr_validate_role(const algo_attr_t *attr, algo_attr_role_t role)
Check whether the parsed attribute is compatible with the key role it will be installed into.
algo_attr_status_t algo_attr_parse(const uint8_t *bytes, size_t len, algo_attr_t *out)
Parse a raw algorithm-attribute byte sequence into structured form.
algo_attr_status_t algo_attr_validate_capability(const algo_attr_t *attr, bool rsa_supported)
Check whether the badge's secure element / mbedTLS combination can actually execute this algorithm.
algo_attr_role_t
Key role (selects which DO tag is being parsed / built).
algo_attr_status_t algo_attr_build(const algo_attr_t *attr, uint8_t *out, size_t out_cap, size_t *out_len)
Serialise an algorithm-attribute structure to bytes.
algo_attr_curve_t
Curves the firmware recognises. UNKNOWN flags unsupported OIDs.
@ ALGO_ATTR_CURVE_UNKNOWN
@ ALGO_ATTR_CURVE_ED25519
algo_attr_status_t
Outcome of algo-attribute operations.
@ ALGO_ATTR_ERR_BAD_CURVE
@ ALGO_ATTR_ERR_BUF_TOO_SMALL
@ ALGO_ATTR_ERR_TOO_SHORT
@ ALGO_ATTR_ERR_ROLE_MISMATCH
algo_attr_algo_id_t
OpenPGP algorithm-attribute codec.
Parsed algorithm-attribute payload.