Last post Apr 25, 2014 02:05 AM by peterjc2007
Apr 24, 2014 09:08 AM|peterjc2007|LINK
Hi, I have another question to do with Web-API and OWIN. I am "playing" with it, trying to learn about it, and I wanted to see if I could intercept a 401 on the "way back" from the web api.
So, I have the following in my Startup..
app.Use(async (environment, next) =>
HttpConfiguration config = new HttpConfiguration();
I then do a GET (in a browser) using an invalid URI so that I get a 401 result. I expected to see this as the status code written out in the
However, all I see (in dev studio output window , as I am running IIS express) is
I really expected to the the 401 in there.
Does anyone know why we don't see the 401 coming back?
I have looked through the Response, and cannot see it anywhere.
Thanks in advance for any help!
Apr 24, 2014 09:56 AM|damienBod|LINK
Your not authorised to see this resource. Either remove the authorization attribute or login to the server
Apr 25, 2014 02:05 AM|peterjc2007|LINK
Oh, I had an erorr in the title! (I meant 404) - fixed it now, but questions still remains