Type Alias riot_sys::bindgen::cose_key_t

source ·
pub type cose_key_t = cose_key;
Expand description

@name COSE key object

For signing, only the d parameter is required and the x and y coordinates can be set to NULL. For verification the d part can be set to NULL. For Eddsa, the y part is not used and must be NULL.

@{

Aliased Type§

struct cose_key_t {
    pub kty: u8,
    pub algo: i8,
    pub crv: u8,
    pub kid: *mut u8,
    pub kid_len: u32,
    pub x: *mut u8,
    pub y: *mut u8,
    pub d: *mut u8,
}

Fields§

§kty: u8

< Key type

§algo: i8

< Key algorithm restriction with this key

§crv: u8

< Curve, algo is derived from this for now

§kid: *mut u8

< Key identifier

§kid_len: u32

< length of the key identifier

§x: *mut u8

< Public key part 1, must match the expected size of the algorithm

§y: *mut u8

< Public key part 2, when not NULL, must match the expected size of the algorithm

§d: *mut u8

< Private or secret key, must match the expected size of the algorithm

Layout§

Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...) attributes. Please see the Rust Reference's “Type Layout” chapter for details on type layout guarantees.

Size: 24 bytes