anchor.diff:  socket_send({dtls, Socket}, Data) ->
       ssl:send(Socket, Data).
   
  +stop_trace(undefined) ->
  +    ok;
  +stop_trace(Trace) ->
  +    lager:stop_trace(Trace).
  +
   socket_close({udp, Socket}) ->
       capwap_udp:close(Socket);
   socket_close({dtls, Socket}) ->
  
positive.code:     State1 = send_request(Header1, station_configuration_request, ReqElements, State),
      next_state(run, State1);
  
  run(Event, State) ->
      lager:warning("in RUN got unexpexted: ~p~n", [Event]),
      next_state(run, State).
  
negative.code: 	    end,
  	    capwap_wtp_reg:register(CommonName),
  
  	    EventLogBasePath = application:get_env(capwap, event_log_base_path, "."),
  	    EventLogPath = filename:join([EventLogBasePath, ["events-", erlang:binary_to_list(CommonName), ".log"]]),
  	    lager:info("EventLogP: ~w", [EventLogPath]),
  
  	    {ok, EventLog} = lager:trace_file(EventLogPath, [{class, wtp_statistics}], debug),
  	    State1 = State#state{event_log=EventLog, socket = {dtls, SslSocket}, session = Session, id = CommonName},
  	    %% TODO: find old connection instance, take over their StationState and stop them
  	    next_state(idle, State1);
  	Other ->
  	    lager:error("ssl_accept failed: ~p~n", [Other]),
  	    {stop, normal, State}
  