c# - How to configure outgoing connections from an SQL stored procedure? -


I am working on a .NET project that uses Microsoft SQL Server. In this project, I need a CLR stored procedure (written in C #) which uses a remote web service. Therefore, when the stored procedure is executed on SQL Server, it creates a web service call and thus sends packets to a remote location. The problem is that when I execute the SP: "System.Net.WebException: Request failed with HTTP status 403: is prohibited."

Database user has full permissions, CLR assembly and SP are deployed, even marked "unsafe", I tried to point it out so that not causing any of these problems Used to be.

When I'm executing a lot of C # code, but SP instead of a simple console application, it all works well so I had to doubt a network related problem and the SP and console app A packet sniffer was running while executing the version.

The fact that I realized was that there were different destination IP addresses sent to the packet: The console app sent the packet directly to the web service IP, while the SP sent the packet to the proxy server that we used to use in our company Were. Due to network policies, the latter is not allowed and which states the "403 prohibited" exception.

So my question is: How do I configure SP / MS SQL Server to not use a proxy? I want to send this packet directly to the web service IP, such as the test console app (again, the C # code is identical, so it's not about programming).

I have disabled all proxy settings in Internet Explorer when the SQL Server receives these settings or anything but no luck.

Any help would be greatly appreciated!

Best regards, Peter

HTTP from SQL CLR Web Do not call.

Call all web services out of the process outside unless you want to store your production server in the starvation starter with all threads blocked in CRR incidents. you have been warned.


Comments