rocket::mtls::x509::der_parser::ber

Function parse_ber_bool

Source
pub fn parse_ber_bool(i: &[u8]) -> Result<(&[u8], BerObject<'_>), Err<Error>>
Available on crate feature mtls only.
Expand description

Read a boolean value

The encoding of a boolean value shall be primitive. The contents octets shall consist of a single octet.

If the boolean value is FALSE, the octet shall be zero. If the boolean value is TRUE, the octet shall be one byte, and have all bits set to one (0xff).