#[unsafe(no_mangle)]pub unsafe extern "C" fn pamoja_delegation_open(
bytes: *const u8,
len: usize,
anchor_public_key: *const u8,
out_delegation: *mut PamojaDelegation,
) -> PamojaStatusExpand description
Opens a signed delegation against the anchor that should have signed it.
§Arguments
bytes- the signed delegation envelope.len- the length ofbytes.anchor_public_key- thePAMOJA_KEY_LEN-byte anchor key.out_delegation- receives the verified delegation.
§Returns
PamojaStatus::Ok if the delegation is from the anchor, or
PamojaStatus::Auth if it is not.
§Safety
bytes must point to at least len readable bytes or be null when len is
0, anchor_public_key must point to at least PAMOJA_KEY_LEN readable
bytes, and out_delegation must be writable.