ASP.Net OData not working with SSL termination in LB

I have a problem using HTTPS to access an OData ASP.NET endpoint. An ASP.NET site is hosted through OWIN. I am using the Microsoft.AspNet.WebApi.OData NuGet package for the OData part (v3). The SSL terminal occurs outside the server in a separate load balancer.

Access to OData endpoints with a REST client (such as a postman) works great: https://api.my-domain.com/odata/v3

But when I use an OData client (for example, Excel or PowerBI), access ends with a general message that the host forcibly closed the connection.

Next, I found that when I access the https://api.my-domain.com/odata/v3 endpoint through the mailbox, I get some XML metadata that refers to normal http (see snippet below), which blocked by LB.

<?xml version="1.0" encoding="utf-8"?>
<service xml:base="http://api.my-domain.com/odata/v3" xmlns="http://www.w3.org/2007/app" xmlns:atom="http://www.w3.org/2005/Atom">
<workspace>
   ...

Next, I sniffed the traffic from Excel / PowerBI with Wireshark and found that clients were using the regular http endpoint (as shown in the metadata above) after the initial request with https . I am not familiar with OData protocol data, but, I think, clients determine the address by metadata.

80 LB voila, Excel/PowerBI , , http https .

( http). OData ASP.NET https URI?

+4
1
0

Source: https://habr.com/ru/post/1657969/


All Articles