WEB API 2, Selfhost, access denied for everything except "localhost",

In the WEB API 2 OWIN stand-alone host project, I get an “Access Deprived” exception for something other than local:

string baseUrl = http://localhost:2500; WebApp.Start<Startup>(baseUrl); 

If I use 127.0.0.1 or the actual IP address of the machine, I get this exception. No one ever mentions this issue on their self-service blogs owin 2 web api.

What is the problem and how to solve it?

I found this Self posted by OWIN and urlacl , but I get the same exception throw.

+6
source share
1 answer

It worked for me

What URL does OWIN recognize for ipv6 self-hosting?

 WebApp.Start<Startup>("http://+:43666"); 

I still think this should be mentioned and discussed in the WEB API 2 OWIN tutorials!

+3
source

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


All Articles