Proof using cei.
start.
eapply candidateEntries_ext; eauto.
repeat find_higher_order_rewrite.
destruct_update.
- simpl in *.
find_eapply_lem_hyp update_elections_data_appendEntries_allEntries_term'; eauto.
intuition.
+ find_apply_hyp_hyp.
unfold candidateEntries in *. break_exists_exists.
destruct_update; [|auto].
simpl. subst. rewrite update_elections_data_appendEntries_cronies.
find_copy_apply_lem_hyp handleAppendEntries_type_term.
intuition; repeat find_rewrite; auto; congruence.
+ subst.
find_eapply_lem_hyp candidate_entries_invariant; eauto.
unfold candidateEntries in *.
break_exists_exists.
destruct_update; [|auto].
simpl. subst. rewrite update_elections_data_appendEntries_cronies.
find_copy_apply_lem_hyp handleAppendEntries_type_term.
intuition; repeat find_rewrite; auto; congruence.
- find_apply_hyp_hyp.
unfold candidateEntries in *. break_exists_exists.
destruct_update; [|auto].
simpl. subst. rewrite update_elections_data_appendEntries_cronies.
find_copy_apply_lem_hyp handleAppendEntries_type_term.
intuition; repeat find_rewrite; auto; congruence.
Qed.

Lemma allEntries_candidateEntries_append_entries_reply :
refined_raft_net_invariant_append_entries_reply allEntries_candidateEntries.