(*Processing time: 18mins. (master: 5min)*)
Require sha.sha.
Require sha.SHA256.
Local Open Scope logic.

(* Specifications: *)
Lemma withspacer_refl: forall sh a P, withspacer sh a a P = P.
Lemma finalbodyproof Espec c md wsh shmd gv buf (h1 : hmacabs)
(Hwsh: writable_share wsh)
(SH : writable_share shmd):
@semax CompSpecs Espec (func_tycontext f_HMAC_Final HmacVarSpecs HmacFunSpecs nil)
(PROP  ()
LOCAL  (lvar _buf (tarray tuchar 32) buf; temp _md md;
temp _ctx c; gvars gv)
SEP  (data_at_ Tsh (tarray tuchar 32) buf; hmacstate_ wsh h1 c;
K_vector gv; memory_block shmd 32 md))
(Ssequence (fn_body f_HMAC_Final) (Sreturn None))
(frame_ret_assert
(function_body_ret_assert tvoid
(PROP  ()
LOCAL ()
SEP  (K_vector gv; hmacstate_PostFinal wsh (fst (hmacFinal h1)) c;
data_block shmd (snd (hmacFinal h1)) md)))
(stackframe_of f_HMAC_Final)%assert).