net Core 8 MVC application When Is added proxy there is error - probably should not possible to use Proxy and DefaultProxy true
I make the some console test
var transport = new HttpsTransportBindingElement();
if (!string.IsNullOrEmpty(ProxyAddress))
{
transport.ProxyAddress = new Uri(ProxyAddress);
transport.UseDefaultWebProxy = false;
Console.WriteLine($"Proxy ustawiony na: {ProxyAddress}");
}
else
{
Console.WriteLine("Proxy nie jest ustawiony.");
}
var customBinding = new CustomBinding(encoding, transport);
_gusServices.Endpoint.Binding = customBinding;
net Core 8 MVC application When Is added proxy there is error - probably should not possible to use Proxy and DefaultProxy true
I make the some console test
var transport = new HttpsTransportBindingElement();
if (!string.IsNullOrEmpty(ProxyAddress))
{
transport.ProxyAddress = new Uri(ProxyAddress);
transport.UseDefaultWebProxy = false;
Console.WriteLine($"Proxy ustawiony na: {ProxyAddress}");
}
else
{
Console.WriteLine("Proxy nie jest ustawiony.");
}
var customBinding = new CustomBinding(encoding, transport);
_gusServices.Endpoint.Binding = customBinding;