Skip to main content

refusal_close_code

Function refusal_close_code 

pub fn refusal_close_code(error: &CratestackError) -> u32
Expand description

The close code a refusal ends the session with, from the error’s HTTP status: 401 → 4401 and 403 → 4403, as on REST; a malformed Init → 4400; and a provider that could not decide (5xx: a key server down) → 4500, which is not a verdict on the credentials — a client must retry later rather than sign the user out.