Proof using.
intros. unfold in_applied_entries.
induction (applied_entries (nwState net)); simpl in *; try congruence; intuition.
- break_exists; intuition.
- break_if; try congruence.
do_bool.
break_exists; break_if; try congruence; intuition; do_bool; subst; eauto.
Qed.

(* Specifications: *)
Lemma doGenericServer_applied_entries :
forall ps h sigma os st' ms,
raft_intermediate_reachable (mkNetwork ps sigma) ->
doGenericServer h (sigma h) = (os, st', ms) ->
exists es, applied_entries (update name_eq_dec sigma h st') = (applied_entries sigma) ++ es /\
(forall e, In e es -> exists h, In e (log (sigma h)) /\ eIndex e <= commitIndex (sigma h)).