pub struct IntegerFmt;Expand description
ASN.1 INTEGER contents format.
Trait Implementations§
Source§impl<'i> ByteLen<Integer<'i>> for IntegerFmt
impl<'i> ByteLen<Integer<'i>> for IntegerFmt
Source§impl Clone for IntegerFmt
impl Clone for IntegerFmt
Source§fn clone(&self) -> IntegerFmt
fn clone(&self) -> IntegerFmt
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 Consistency for IntegerFmt
impl Consistency for IntegerFmt
Source§impl<'a> DerOrd<Integer<'a>> for IntegerFmt
impl<'a> DerOrd<Integer<'a>> for IntegerFmt
Source§proof fn lemma_der_serialize_len(&self, value: int)
proof fn lemma_der_serialize_len(&self, value: int)
Source§open spec fn der_remaining(&self, value: int, state: IntegerDerState) -> Seq<u8>
open spec fn der_remaining(&self, value: int, state: IntegerDerState) -> Seq<u8>
{ self.spec_serialize(value).skip(state.pos as int) }Source§open spec fn der_state_valid(&self, value: int, state: IntegerDerState) -> bool
open spec fn der_state_valid(&self, value: int, state: IntegerDerState) -> bool
{
&&& state.pos <= state.len
&&& state.len == self.spec_serialize(value).len()
&&& state.small == (i64::MIN as int <= value <= i64::MAX as int)
&&& state.small
==> {
&&& state.len <= 9
&&& state.bytes@.take(state.len as int) == self.spec_serialize(value)
}
}Source§exec fn der_start(&self, i: &Integer<'a>) -> state : IntegerDerState
exec fn der_start(&self, i: &Integer<'a>) -> state : IntegerDerState
Source§impl DerState for IntegerFmt
impl DerState for IntegerFmt
type State = IntegerDerState
Source§impl EquivSerializers for IntegerFmt
impl EquivSerializers for IntegerFmt
Source§impl GoodSerializer for IntegerFmt
impl GoodSerializer for IntegerFmt
Source§proof fn lemma_serialize_len(&self, v: Self::SVal)
proof fn lemma_serialize_len(&self, v: Self::SVal)
Source§fn serialize_inv(&self) -> bool
fn serialize_inv(&self) -> bool
Source§impl NonMalleable for IntegerFmt
impl NonMalleable for IntegerFmt
Source§proof fn lemma_parse_non_malleable(&self, buf1: Seq<u8>, buf2: Seq<u8>)
proof fn lemma_parse_non_malleable(&self, buf1: Seq<u8>, buf2: Seq<u8>)
Source§fn nonmal_inv(&self) -> bool
fn nonmal_inv(&self) -> bool
Source§impl<'i> Parser<&'i [u8]> for IntegerFmt
impl<'i> Parser<&'i [u8]> for IntegerFmt
Source§impl<'i> Prepare<Integer<'i>> for IntegerFmt
impl<'i> Prepare<Integer<'i>> for IntegerFmt
Source§impl Productive for IntegerFmt
impl Productive for IntegerFmt
Source§proof fn lemma_productive(&self, s: Seq<u8>)
proof fn lemma_productive(&self, s: Seq<u8>)
Source§fn productive_inv(&self) -> bool
fn productive_inv(&self) -> bool
Source§impl SPRoundTripDps for IntegerFmt
impl SPRoundTripDps for IntegerFmt
Source§proof fn theorem_serialize_dps_parse_roundtrip(&self, v: Self::T, obuf: Seq<u8>)
proof fn theorem_serialize_dps_parse_roundtrip(&self, v: Self::T, obuf: Seq<u8>)
Source§fn unambiguous(&self) -> bool
fn unambiguous(&self) -> bool
Source§impl SafeParser for IntegerFmt
impl SafeParser for IntegerFmt
Source§impl<'i, Output: OutputBuf> Serializer<Output, Integer<'i>> for IntegerFmt
impl<'i, Output: OutputBuf> Serializer<Output, Integer<'i>> for IntegerFmt
Source§exec fn serialize_into(&self, v: &Integer<'i>, obuf: &mut Output)
exec fn serialize_into(&self, v: &Integer<'i>, obuf: &mut Output)
Source§impl SoundParser for IntegerFmt
impl SoundParser for IntegerFmt
Source§impl SpecByteLen for IntegerFmt
impl SpecByteLen for IntegerFmt
Source§impl SpecParser for IntegerFmt
impl SpecParser for IntegerFmt
Source§impl SpecSerializer for IntegerFmt
impl SpecSerializer for IntegerFmt
Source§impl SpecSerializerDps for IntegerFmt
impl SpecSerializerDps for IntegerFmt
impl Copy for IntegerFmt
Auto Trait Implementations§
impl Freeze for IntegerFmt
impl RefUnwindSafe for IntegerFmt
impl Send for IntegerFmt
impl Sync for IntegerFmt
impl Unpin for IntegerFmt
impl UnsafeUnpin for IntegerFmt
impl UnwindSafe for IntegerFmt
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> PSRoundTrip for C
impl<C> PSRoundTrip for C
Source§open spec fn ps_roundtrip_inv(&self) -> bool
open spec fn ps_roundtrip_inv(&self) -> bool
{ self.safe_inv() && self.sound_inv() && self.nonmal_inv() && self.sp_roundtrip_inv() }Source§proof fn theorem_parse_serialize_roundtrip(&self, ibuf: Seq<u8>)
proof fn theorem_parse_serialize_roundtrip(&self, ibuf: Seq<u8>)
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() }