Introduction

TCPMonPlus (src here) takes the tcpmon application from Apache and adds some functionality, namely the ability to display uncompressed ZLIB HTTP requests without interfering with the original data stream.

TCPMonPlus does this by using:

  • net.metasimian.utilities.network.SocketListener - passively intercepts the data and sends it to another OutputStream using a org.apache.commons.io.input.TeeInputStream and a StreamPumpThread
  • net.metasimian.utilities.io.StreamPumpThread - redirects data from a InputStream to another OutputStream
  • net.metasimian.utilities.network.io.HTTPOutputStreamWrapper - an abstract class that wraps the intercepted OutputStream data and pre-processes it before applying the normal OutputStream methods.
  • net.metasimian.utilities.network.io.HTTPInflaterOutputStreamWrapper - extends HTTPOutputStreamWrapper to inflate/uncompress the intercepted HTTP message.
  • net.metasimian.utilities.io.JTextAreaOutputStreamWrapper - wraps the original tcpmon JTextArea component as an OutputStream