anchor.diff:                       erlang:get(renewal_counter)}),
       State;
   
  +on({set_message_filter, F, Owner, Pid}, State) ->
  +    erlang:put(message_filter, F),
  +    erlang:put(owner, Owner),
  +    comm:send_local(Pid, {set_message_filter_response}),
  +    State;
  +
  +on({reset_message_filter, Pid}, State) ->
  +    erlang:put(message_filter, fun(_Msg) -> false end),
  +    erlang:put(owner, undefined),
  +    comm:send_local(Pid, {reset_message_filter_response}),
  +    State;
  +
   % get from dht_node_state
   on({get, Key, Pid}, State) ->
       comm:send_local(Pid,
  
positive.code: 
  % intercept l_on_cseq messages
  on(Msg, State) when element(1, Msg) =:= l_on_cseq ->
      Intercept = erlang:get(message_filter),
      if
          Intercept ->
              intercept_message(Msg, State);
  
negative.code:              List
      end.
  
  -spec set_message_filter(F::fun((comm:message()) -> boolean()),
                           Owner::comm:mypid()) -> ok.
  set_message_filter(F, Owner) ->
      comm:send_local(get_mock_pid(), {set_message_filter, F, Owner, self()}),
      receive
          {set_message_filter_response} ->
               ok
      end.
  
  -spec reset_message_filter() -> ok.
  reset_message_filter() ->
      comm:send_local(get_mock_pid(), {reset_message_filter, self()}),
      receive
          {reset_message_filter_response} ->
               ok
      end.
  
  %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  % Message Loop
  %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
  