Proof using tsi rmri.
intros.
enough (no_entries_past_current_term_host (deghost (mgv_deghost net))) by
(unfold no_entries_past_current_term_host, lifted_no_entries_past_current_term_host, deghost, mgv_deghost in *;
simpl in *;
repeat break_match; simpl in *; auto).
apply msg_lift_prop_all_the_way; eauto.
intros.
eapply no_entries_past_current_term_invariant; eauto.
Qed.

Lemma ghost_log_sorted :
forall net p,
msg_refined_raft_intermediate_reachable net ->
In p (nwPackets net) ->
sorted (fst (pBody p)).