pub struct BerOctetStringFmt<const LIMIT: usize>(pub Tag);Expand description
BER OCTET STRING with bounded recursive nesting and a configurable outer tag identity.
Use Self::universal for an ordinary OCTET STRING or Self::implicit for an
IMPLICIT-tagged value. The stored tag’s constructed bit is normalized away: parsing accepts
either primitive or constructed form and serialization always emits primitive definite form.
Tuple Fields§
§0: TagImplementations§
Trait Implementations§
Source§impl<const LIMIT: usize> ByteLen<Vec<u8>> for BerOctetStringFmt<LIMIT>
Available on crate feature alloc only.
impl<const LIMIT: usize> ByteLen<Vec<u8>> for BerOctetStringFmt<LIMIT>
Available on crate feature
alloc only.Source§impl<const LIMIT: usize> Clone for BerOctetStringFmt<LIMIT>
impl<const LIMIT: usize> Clone for BerOctetStringFmt<LIMIT>
Source§fn clone(&self) -> BerOctetStringFmt<LIMIT>
fn clone(&self) -> BerOctetStringFmt<LIMIT>
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl<const LIMIT: usize> Consistency for BerOctetStringFmt<LIMIT>
impl<const LIMIT: usize> Consistency for BerOctetStringFmt<LIMIT>
Source§impl<const LIMIT: usize> EquivSerializers for BerOctetStringFmt<LIMIT>
impl<const LIMIT: usize> EquivSerializers for BerOctetStringFmt<LIMIT>
Source§impl<const LIMIT: usize> EquivSerializersGeneral for BerOctetStringFmt<LIMIT>
impl<const LIMIT: usize> EquivSerializersGeneral for BerOctetStringFmt<LIMIT>
Source§proof fn lemma_serialize_equiv(&self, value: Seq<u8>, obuf: Seq<u8>)
proof fn lemma_serialize_equiv(&self, value: Seq<u8>, obuf: Seq<u8>)
Source§fn equiv_general_inv(&self) -> bool
fn equiv_general_inv(&self) -> bool
Source§impl<const LIMIT: usize> GoodSerializer for BerOctetStringFmt<LIMIT>
impl<const LIMIT: usize> GoodSerializer for BerOctetStringFmt<LIMIT>
Source§proof fn lemma_serialize_len(&self, value: Seq<u8>)
proof fn lemma_serialize_len(&self, value: Seq<u8>)
Source§fn serialize_inv(&self) -> bool
fn serialize_inv(&self) -> bool
Source§impl<const LIMIT: usize> HasAsn1Start for BerOctetStringFmt<LIMIT>
Recursive BER OCTET STRING accepts primitive and constructed forms of one tag identity.
impl<const LIMIT: usize> HasAsn1Start for BerOctetStringFmt<LIMIT>
Recursive BER OCTET STRING accepts primitive and constructed forms of one tag identity.
Source§open spec fn asn1_start(&self) -> Asn1StartDomain
open spec fn asn1_start(&self) -> Asn1StartDomain
{ asn1_start_identity_uint(self.0.class, tag_num_to_uint(self.0.number)) }Source§proof fn lemma_parse_implies_asn1_start(&self, input: Seq<u8>)
proof fn lemma_parse_implies_asn1_start(&self, input: Seq<u8>)
Source§impl<const LIMIT: usize> NonTailFmt for BerOctetStringFmt<LIMIT>
impl<const LIMIT: usize> NonTailFmt for BerOctetStringFmt<LIMIT>
Source§proof fn lemma_serialize_dps_prepend(&self, value: Seq<u8>, obuf: Seq<u8>)
proof fn lemma_serialize_dps_prepend(&self, value: Seq<u8>, obuf: Seq<u8>)
Source§proof fn lemma_serialize_dps_len(&self, value: Seq<u8>, obuf: Seq<u8>)
proof fn lemma_serialize_dps_len(&self, value: Seq<u8>, obuf: Seq<u8>)
Source§fn serialize_dps_inv(&self) -> bool
fn serialize_dps_inv(&self) -> bool
Source§impl<'i, const LIMIT: usize> Parser<&'i [u8]> for BerOctetStringFmt<LIMIT>
Available on crate feature alloc only.
impl<'i, const LIMIT: usize> Parser<&'i [u8]> for BerOctetStringFmt<LIMIT>
Available on crate feature
alloc only.Source§impl<const LIMIT: usize> Prepare<Vec<u8>> for BerOctetStringFmt<LIMIT>
Available on crate feature alloc only.
impl<const LIMIT: usize> Prepare<Vec<u8>> for BerOctetStringFmt<LIMIT>
Available on crate feature
alloc only.Source§impl<const LIMIT: usize> Productive for BerOctetStringFmt<LIMIT>
impl<const LIMIT: usize> Productive for BerOctetStringFmt<LIMIT>
Source§proof fn lemma_productive(&self, ibuf: Seq<u8>)
proof fn lemma_productive(&self, ibuf: Seq<u8>)
Source§fn productive_inv(&self) -> bool
fn productive_inv(&self) -> bool
Source§impl<const LIMIT: usize> Retaggable for BerOctetStringFmt<LIMIT>
Supports IMPLICIT tagging of recursive BER OCTET STRING values.
impl<const LIMIT: usize> Retaggable for BerOctetStringFmt<LIMIT>
Supports IMPLICIT tagging of recursive BER OCTET STRING values.
The stored tag is normalized to the primitive form with the replacement class and number; this
is fine since the parser permits both primitive and constructed forms.
Recursive fragments keep universal tag 4 (see BerOctetStringFmt).
Source§impl<const LIMIT: usize> SPRoundTripDps for BerOctetStringFmt<LIMIT>
impl<const LIMIT: usize> SPRoundTripDps for BerOctetStringFmt<LIMIT>
Source§proof fn theorem_serialize_dps_parse_roundtrip(&self, value: Seq<u8>, obuf: Seq<u8>)
proof fn theorem_serialize_dps_parse_roundtrip(&self, value: Seq<u8>, obuf: Seq<u8>)
Source§fn unambiguous(&self) -> bool
fn unambiguous(&self) -> bool
Source§impl<const LIMIT: usize> SafeParser for BerOctetStringFmt<LIMIT>
impl<const LIMIT: usize> SafeParser for BerOctetStringFmt<LIMIT>
Source§impl<const LIMIT: usize, Output: OutputBuf> Serializer<Output, [u8]> for BerOctetStringFmt<LIMIT>
impl<const LIMIT: usize, Output: OutputBuf> Serializer<Output, [u8]> for BerOctetStringFmt<LIMIT>
Source§exec fn serialize_into(&self, value: &[u8], obuf: &mut Output)
exec fn serialize_into(&self, value: &[u8], obuf: &mut Output)
Source§impl<const LIMIT: usize, Output: OutputBuf> Serializer<Output, Vec<u8>> for BerOctetStringFmt<LIMIT>
Available on crate feature alloc only.
impl<const LIMIT: usize, Output: OutputBuf> Serializer<Output, Vec<u8>> for BerOctetStringFmt<LIMIT>
Available on crate feature
alloc only.Source§impl<const LIMIT: usize> SpecByteLen for BerOctetStringFmt<LIMIT>
impl<const LIMIT: usize> SpecByteLen for BerOctetStringFmt<LIMIT>
Source§impl<const LIMIT: usize> SpecParser for BerOctetStringFmt<LIMIT>
impl<const LIMIT: usize> SpecParser for BerOctetStringFmt<LIMIT>
Source§impl<const LIMIT: usize> SpecSerializer for BerOctetStringFmt<LIMIT>
impl<const LIMIT: usize> SpecSerializer for BerOctetStringFmt<LIMIT>
Source§impl<const LIMIT: usize> SpecSerializerDps for BerOctetStringFmt<LIMIT>
impl<const LIMIT: usize> SpecSerializerDps for BerOctetStringFmt<LIMIT>
impl<const LIMIT: usize> Copy for BerOctetStringFmt<LIMIT>
Auto Trait Implementations§
impl<const LIMIT: usize> Freeze for BerOctetStringFmt<LIMIT>
impl<const LIMIT: usize> RefUnwindSafe for BerOctetStringFmt<LIMIT>
impl<const LIMIT: usize> Send for BerOctetStringFmt<LIMIT>
impl<const LIMIT: usize> Sync for BerOctetStringFmt<LIMIT>
impl<const LIMIT: usize> Unpin for BerOctetStringFmt<LIMIT>
impl<const LIMIT: usize> UnsafeUnpin for BerOctetStringFmt<LIMIT>
impl<const LIMIT: usize> UnwindSafe for BerOctetStringFmt<LIMIT>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T, VERUS_SPEC__A> FromSpec<T> for VERUS_SPEC__Awhere
VERUS_SPEC__A: From<T>,
impl<T, VERUS_SPEC__A> FromSpec<T> for VERUS_SPEC__Awhere
VERUS_SPEC__A: From<T>,
fn obeys_from_spec() -> bool
fn from_spec(v: T) -> VERUS_SPEC__A
§impl<T, VERUS_SPEC__A> IntoSpec<T> for VERUS_SPEC__Awhere
VERUS_SPEC__A: Into<T>,
impl<T, VERUS_SPEC__A> IntoSpec<T> for VERUS_SPEC__Awhere
VERUS_SPEC__A: Into<T>,
fn obeys_into_spec() -> bool
fn into_spec(self) -> T
§impl<T, U> IntoSpecImpl<U> for Twhere
U: From<T>,
impl<T, U> IntoSpecImpl<U> for Twhere
U: From<T>,
fn obeys_into_spec() -> bool
fn into_spec(self) -> U
Source§impl<C> NonAmbiguous for Cwhere
C: SPRoundTrip,
impl<C> NonAmbiguous for Cwhere
C: SPRoundTrip,
Source§open spec fn nonamb_inv(&self) -> bool
open spec fn nonamb_inv(&self) -> bool
{ self.sp_roundtrip_inv() }Source§proof fn lemma_serialize_injective(
&self,
v1: <C as Consistency>::Val,
v2: <C as Consistency>::Val,
)
proof fn lemma_serialize_injective( &self, v1: <C as Consistency>::Val, v2: <C as Consistency>::Val, )
Source§impl<C> SPRoundTrip for C
impl<C> SPRoundTrip for C
Source§open spec fn sp_roundtrip_inv(&self) -> bool
open spec fn sp_roundtrip_inv(&self) -> bool
{ self.serialize_inv() && self.equiv_inv() && self.unambiguous() }