title: HTTP Proxy server in C#
body: <p>My company is experimenting with writing a proxy server using the .NET Fx 3.5 and C#.  From our <a href="http://bytes.com/groups/net-web-services/510683-proxy-server-httplistener" rel="noreferrer">research</a> I have read that HttpListener is not a good candidate for a proxy server though I am unsure as to why.</p>
  
  <p>We are currently working with the <a href="http://www.mentalis.org/soft/projects/proxy/" rel="noreferrer">Mentalis proxy example source code</a> though that will involve, among other things, implementing our own logging and performance counters.  Using HttpListener will wrap Http.sys which will give us some of the performance statistics we require out of the box.</p>
  
  <p>So why is HttpListener a bad candidate for HTTP proxy work?</p>
  
  <p>(And yes we are considering Squid 3.1 by writing or configuring an ICAP server as well.)</p>