How to intercept Http traffic

c#, http, intercept

Solution

Thanks everyone for your suggestions, here is the answer.

I have used Fiddler2 from Eric Lawrence to act as a proxy for me. I then wrote a Fiddler extension which intercepted the particular Http request I was interested in and voila.

Problem

I am trying to develop a C# application that will intercept an outgoing Http request and return a result to an old system. We have a legacy system that makes an Http request to a discontinued web service. I need to intercept the out going request and send it to a new web service. When the response comes back I need to manipulate it then send it on to the legacy system. All the code needs to sit on the client machine. I thought something along the lines of http listener would work but I am not getting anywhere with that, any suggestions would be greatly appreciated.

Original source