Windows Azure - NetworkInformationException (0x80004005): Access Denied - HttpWebRequest

GetResponse works fine on my local computer, but when deploying to Windows Azure, I get the following exception. My ASP.NET site runs exe, which I created as a new process, and this is the code in exe that encounters the exception below. Can someone suggest possible permission settings that I can look at to solve this problem?

HttpWebRequest request = WebRequest.Create(requestUrl) as HttpWebRequest; request.UserAgent = _userAgent; request.Timeout = 50000; HttpWebResponse response = request.GetResponse() as HttpWebResponse; 

System.Net.NetworkInformation.NetworkInformationException (0x80004005): access is denied in System.Net.NetworkInformation.SystemIPGlobalProperties.GetFixedInfo () in System.Net.NetworkInformation.SystemIPGlobalProperties.get_FixedInfo () in System.Net.NetworkInformation.SystemIPGgetHostPro System.Net.NclUtilities.GuessWhetherHostIsLoopback (host String) in System.Net.ServicePoint.get_ConnectionLimit () in System.Net.ConnectionGroup..ctor (ServicePoint servicePoint, String connName) in System.Net.ServicePoint.SubmitRequest (HttpWebRequest request, String connName) in System.Net.HttpWebRequest.SubmitRequest (ServicePoint servicePoint) in System.Net.HttpWebRequest.GetResponse ()

+4
source share
3 answers

You need more information, but I thought you:

  • Attempting to bind a socket to a privileged port (port <= 1024)
  • Trying to associate a socket with an IP address that you do not have on it.
  • The user who runs your local website has higher permissions than the Windows Azure user (for example, IIS AppPool?) Runs it as
+2
source

Try starting the process from asp.net with specific credentials .. for example, using the credentials of a local user. It is possible that azure is blocking an unauthorized process to access the Internet.

+2
source

All Articles