title: Why HttpWebRequest.GetResponse() fails after connecting to a VPN?
body: <p>I am trying to control a computer in another room over a local LAN and not the internet which is an important distinction in this case.  This is done by sending <code>HttpWebRequests</code> with query strings that command the remote computer to do certain things. One of commands is to tell the remote computer to connect to a VPN using Cisco's AnyConnect client.  When it connects, it should send back a reply to the controlling computer that it successfully connected.  </p>
  
  <p>For some reason, the reply which is a <code>HttpWebRequest</code> will time out.  The strange thing is that I can send <code>HttpWebRequests</code> over the internet with no problem, so it seems to be only a local LAN issue.  To get around this issue, I have created a separate console app that is called just to send the replys.  I am not sure what is different about it, but it works.  </p>
  
  <p>Here is the code from the console app and those are two same lines used in the main program that fail to work.</p>
  
  <pre><code> static void Main(string[] args)
      {
          // args[0] contains query string ie ?reply=VPNSuccess
          HttpWebRequest httpWebReq = (HttpWebRequest)WebRequest.Create(new  Uri("http://192.168.1.11:1000" + args[0]));
          HttpWebResponse httpWebResp = (HttpWebResponse)httpWebReq.GetResponse();
  
      }
  </code></pre>