'RestSharp issues integrating with zscaler product will not work on IIS Server 2012 R2
Our organization is removing our proxy web servers and integrating Zscalar. We were informed that all we had to do is remove the proxy property/settings. So I have removed the proxy setting from my code and it seems to work fine locally but it will not work on our server. Is there something I am missing here? We are also using RestSharp 105.2.30
Dim js As New System.Web.Script.Serialization.JavaScriptSerializer
Dim utils As New Utilities.Common
Dim rc As RestSharp.RestClient
rc = New RestSharp.RestClient("https://www.someendpointurl")
Dim rr As New RestSharp.RestRequest(RestSharp.Method.POST)
rr.AddHeader("Authorization", "Basic " & RetrieveTokens("MSIC"))
Dim rs As New RestSharp.RestResponse()
ServicePointManager.SecurityProtocol = SecurityProtocolType.Tls12
rs = rc.Execute(rr)
dctValues = js.Deserialize(Of Dictionary(Of String, String))(rs.Content)
Solution 1:[1]
After hours of trouble-shooting, turns out in this case it was not a code issue. It was a internet and firewall connection issue on the server. So the code above is valid and works grea
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
Solution | Source |
---|---|
Solution 1 | steveyT |