Skip to main content

check_envelope

Function check_envelope 

Source
pub fn check_envelope(
    status: u16,
    body: &[u8],
    keys: &Keys,
    request: &Request,
) -> Result<Envelope>
Expand description

Checks a response envelope (5.5) in the order of its procedure: strict JSON, members, HTTP status, the receipt through step 6 of 10.1, the binding to request, then trust and superseded_by. Never touches the network. A not_covered envelope’s fault (spec-0.4.0) is checked and accepted; check_envelope_extras also returns it.