Struct der::Decoder [−][src]
pub struct Decoder<'a> { /* fields omitted */ }Expand description
DER decoder.
Implementations
Decode a value which impls the Decodable trait.
Return an error with the given ErrorKind, annotating it with
context about where the error occurred.
Return an error for an invalid value with the given tag.
Finish decoding, returning the given value if there is no remaining data, or an error otherwise
Have we decoded all of the bytes in this Decoder?
Returns false if we’re not finished decoding or if a fatal error
has occurred.
Attempt to decode an OPTIONAL ASN.1 ANY value.
This is supported on crate feature bigint only.
bigint only.Attempt to decode an ASN.1 INTEGER as a UIntBytes.
Attempt to decode an ASN.1 BIT STRING.
Attempt to decode an ASN.1 CONTEXT-SPECIFIC field with the
provided TagNumber.
This method has the following behavior which is designed to simplify
handling of extension fields, which are denoted in an ASN.1 schema
using the ... ellipsis extension marker:
- Skips over
ContextSpecificfields with a tag number lower than the current one, consuming and ignoring them. - Returns
Ok(None)if aContextSpecificfield with a higher tag number is encountered. These fields are not consumed in this case, allowing a field with a lower tag number to be omitted, then the higher numbered field consumed as a follow-up. - Returns
Ok(None)if anything other than aContextSpecificfield is encountered.
Attempt to decode an ASN.1 GeneralizedTime.
Attempt to decode an ASN.1 IA5String.
Attempt to decode an ASN.1 OCTET STRING.
This is supported on crate feature oid only.
oid only.Attempt to decode an ASN.1 OBJECT IDENTIFIER.
Attempt to decode an ASN.1 OPTIONAL value.
Attempt to decode an ASN.1 PrintableString.
Attempt to decode an ASN.1 UTF8String.