Implemented handler for tcp packets including encoder to sent packets