val hkdfLabel_context_finalize (#rrel: _) (#rel: _) (input: LL.slice rrel rel) (pos: U32.t) (len: U32.t) : HST.Stack U32.t

  (requires (fun h ->
    LL.live_slice h input /\
    0 <= U32.v len /\ U32.v len <= 255 /\
    U32.v pos + 1 + U32.v len <= U32.v input.LL.len /\
    LL.writable input.LL.base (U32.v pos) (U32.v pos + 1) h
  ))
  (ensures (fun h pos' h' ->
    let pos_payload = pos `U32.add` 1ul in
    B.modifies (LL.loc_slice_from_to input pos pos_payload) h h' /\
    LL.valid_content_pos hkdfLabel_context_parser h' input pos (BY.hide (LL.bytes_of_slice_from_to h input pos_payload (pos_payload `U32.add` len))) pos' /\
    U32.v pos' == U32.v pos_payload + U32.v len
  ))
let hkdfLabel_context_finalize #_ #_ input pos len =
  [@inline_let] let _ = assert_norm (hkdfLabel_context == LP.parse_bounded_vlbytes_t 0 255) in
  LL.finalize_bounded_vlbytes 0 255 input pos len
val hkdfLabel_context_finalize (#rrel: _) (#rel: _) (input: LL.slice rrel rel) (pos: U32.t) (len: U32.t) : HST.Stack U32.t

  (requires (fun h ->
    LL.live_slice h input /\
    0 <= U32.v len /\ U32.v len <= 255 /\
    U32.v pos + 1 + U32.v len <= U32.v input.LL.len /\
    LL.writable input.LL.base (U32.v pos) (U32.v pos + 1) h
  ))
  (ensures (fun h pos' h' ->
    let pos_payload = pos `U32.add` 1ul in
    B.modifies (LL.loc_slice_from_to input pos pos_payload) h h' /\
    LL.valid_content_pos hkdfLabel_context_parser h' input pos (BY.hide (LL.bytes_of_slice_from_to h input pos_payload (pos_payload `U32.add` len))) pos' /\
    U32.v pos' == U32.v pos_payload + U32.v len
  ))
let hkdfLabel_context_finalize #_ #_ input pos len =
[@@ inline_let ]let _ = assert_norm (hkdfLabel_context == LP.parse_bounded_vlbytes_t 0 255) in
LL.finalize_bounded_vlbytes 0 255 input pos len
Parsers.HKDF.HkdfLabel_context.fst.checked
prims.fst.checked LowStar.Buffer.fst.checked LowParse.TacLib.fst.checked LowParse.Spec.AllIntegers.fst.checked LowParse.Spec.fst.checked LowParse.SLow.fst.checked LowParse.Low.fst.checked FStar.UInt8.fsti.checked FStar.UInt64.fsti.checked FStar.UInt32.fsti.checked FStar.UInt16.fsti.checked FStar.Seq.fst.checked FStar.Pervasives.fsti.checked FStar.List.Tot.fst.checked FStar.HyperStack.ST.fsti.checked FStar.HyperStack.fst.checked FStar.Bytes.fsti.checked
Parsers.HKDF.HkdfLabel_context.fst
LowParse.Slice.srel LowParse.Bytes.byte LowParse.Slice.slice FStar.UInt32.t LowParse.Low.Bytes.finalize_bounded_vlbytes Prims.unit FStar.Pervasives.assert_norm Prims.eq2 Parsers.HKDF.HkdfLabel_context.hkdfLabel_context LowParse.Spec.Bytes.parse_bounded_vlbytes_t
module Parsers.HKDF.HkdfLabel_context

(* This file has been automatically generated by EverParse. *)
open FStar.Bytes
module U8 = FStar.UInt8
module U16 = FStar.UInt16
module U32 = FStar.UInt32
module U64 = FStar.UInt64
module LP = LowParse.Spec
module LT = LowParse.TacLib
module LS = LowParse.SLow
module LSZ = LowParse.SLow
module LPI = LowParse.Spec.AllIntegers
module LL = LowParse.Low
module L = FStar.List.Tot
module B = LowStar.Buffer
module BY = FStar.Bytes
module HS = FStar.HyperStack
module HST = FStar.HyperStack.ST

#reset-options "--using_facts_from '* -FStar.Tactics -FStar.Reflection' --z3rlimit 16 --z3cliopt smt.arith.nl=false --max_fuel 2 --max_ifuel 2"

noextract let hkdfLabel_context_parser = LP.parse_bounded_vlbytes 0 255

noextract let hkdfLabel_context_serializer = LP.serialize_bounded_vlbytes 0 255

let hkdfLabel_context_bytesize (x:hkdfLabel_context) : GTot nat = Seq.length (hkdfLabel_context_serializer x)

let hkdfLabel_context_bytesize_eq x = ()

let hkdfLabel_context_parser32 = LS.parse32_bounded_vlbytes 0 0ul 255 255ul

let hkdfLabel_context_serializer32 = LS.serialize32_bounded_vlbytes 0 255

let hkdfLabel_context_size32 = LSZ.size32_bounded_vlbytes 0 255

let hkdfLabel_context_validator = LL.validate_bounded_vlbytes 0 255

let hkdfLabel_context_jumper = LL.jump_bounded_vlbytes 0 255

let hkdfLabel_context_bytesize_eqn x = LP.length_serialize_bounded_vlbytes 0 255 x

let hkdfLabel_context_length #_ #_ input pos =
  [@inline_let] let _ = assert_norm (hkdfLabel_context == LP.parse_bounded_vlbytes_t 0 255) in
  LL.bounded_vlbytes_payload_length 0 255 input pos
val hkdfLabel_context_finalize (#rrel: _) (#rel: _) (input: LL.slice rrel rel) (pos: U32.t) (len: U32.t) : HST.Stack U32.t

  (requires (fun h ->
    LL.live_slice h input /\
    0 <= U32.v len /\ U32.v len <= 255 /\
    U32.v pos + 1 + U32.v len <= U32.v input.LL.len /\
    LL.writable input.LL.base (U32.v pos) (U32.v pos + 1) h
  ))
  (ensures (fun h pos' h' ->
    let pos_payload = pos `U32.add` 1ul in
    B.modifies (LL.loc_slice_from_to input pos pos_payload) h h' /\
    LL.valid_content_pos hkdfLabel_context_parser h' input pos (BY.hide (LL.bytes_of_slice_from_to h input pos_payload (pos_payload `U32.add` len))) pos' /\
    U32.v pos' == U32.v pos_payload + U32.v len
  ))
input: LowParse.Slice.slice rrel rel -> pos: FStar.UInt32.t -> len: FStar.UInt32.t
  -> FStar.HyperStack.ST.Stack FStar.UInt32.t