Proof using.
intros. unfold doGenericServer in *.
repeat break_match; find_inversion; subst; intuition;
use_applyEntries_spec; subst; simpl in *; auto.
Qed.

Lemma doGenericServer_preserves_candidateEntries :
forall net gd d h os d' ms e,
nwState net h = (gd, d) ->
doGenericServer h d = (os, d', ms) ->
candidateEntries e (nwState net) ->
candidateEntries e (update name_eq_dec (nwState net) h (gd, d')).