ASP.NET ODATA fails in LB through SSL

I have a problem using HTTPS to access ASP.NET OData endpoints. The ASP.NET site is hosted via OWIN. I am using the NuGet package Microsoft.AspNet.WebApi.OData as OData (v3) Part. SSL termination occurs outside the server in a separate load balancer.

Using a REST client (e.g. postman) to access the OData endpoint works fine: https://api.my-domain. com/odata/v3

But when I use an OData client (such as Excel or PowerBI), the access fails with a general message, and the host forcibly closes the connection.

In addition, I found When I access the endpoint https://api.my-domain.com/odata/v3 through Postman, I receive some XML metadata, which refers to the normal http endpoint (see code snippet below), which is LB Block.




...

In addition, I used Wireshark to sniff traffic from Excel/PowerBI and found that the client was using normal http endpoints (such as The metadata shown above). I am not familiar with the details of the OData protocol, but I guess the client is determining the address through the metadata.

To verify that I unblock port 80 in LB, whether I am Using http or https as the initial request, both Excel/PowerBI can successfully connect.

But how to solve this problem (I don’t want to allow traffic on http). Is it possible to instruct ASP.NET OData middleware to use https URI Generate metadata?

It seems that a similar problem has been raised and solved here: Override host of webapi odata links. Is this Solved your problem?

I have a problem using HTTPS to access the ASP.NET OData endpoint. The ASP.NET site is hosted via OWIN. I am using the NuGet package Microsoft.AspNet.WebApi.OData as OData (v3) Part. SSL termination occurs outside the server in a separate load balancer.

Using a REST client (e.g. postman) to access the OData endpoint works fine: https://api.my-domain. com/odata/v3

But when I use an OData client (such as Excel or PowerBI), the access fails with a general message, and the host forcibly closes the connection.

In addition, I found When I access the endpoint https://api.my-domain.com/odata/v3 through Postman, I receive some XML metadata, which refers to the normal http endpoint (see code snippet below), which is LB Block.




...

In addition, I used Wireshark to sniff traffic from Excel/PowerBI and found that the client was using normal http endpoints (such as The metadata shown above). I am not familiar with the details of the OData protocol, but I guess the client is determining the address through the metadata.

To verify that I unblock port 80 in LB, whether I am Using http or https as the initial request, both Excel/PowerBI can successfully connect.

But how to solve this problem (I don’t want to allow traffic on http). Is it possible to instruct ASP.NET OData middleware to use https URI Generate metadata?

It seems that a similar problem was raised and solved here: Override host of webapi odata links. Did this solve your problem?

WordPress database error: [Table 'yf99682.wp_s6mz6tyggq_comments' doesn't exist]
SELECT SQL_CALC_FOUND_ROWS wp_s6mz6tyggq_comments.comment_ID FROM wp_s6mz6tyggq_comments WHERE ( comment_approved = '1' ) AND comment_post_ID = 2067 ORDER BY wp_s6mz6tyggq_comments.comment_date_gmt ASC, wp_s6mz6tyggq_comments.comment_ID ASC

Leave a Comment

Your email address will not be published.