Section GhostLogCorrectProof.
Context {orig_base_params : BaseParams}.
Context {one_node_params : OneNodeParams orig_base_params}.
Context {raft_params : RaftParams orig_base_params}.
Context {rmri : raft_msg_refinement_interface}.
Context {nisi : nextIndex_safety_interface}.
Context {rlmli : refined_log_matching_lemmas_interface}.
Definition lifted_nextIndex_safety net : Prop :=
forall h h',
type (snd (nwState net h)) = Leader ->
pred (getNextIndex (snd (nwState net h)) h') <= maxIndex (log (snd (nwState net h))).

Lemma lifted_nextIndex_safety_invariant :
forall (net : @network _ raft_msg_refined_multi_params),
msg_refined_raft_intermediate_reachable net ->
lifted_nextIndex_safety net.