This repository was archived by the owner on Dec 13, 2018. It is now read-only.
  
  
  
  
  
Description
Currently if there is a thick client which targets the same service as the browser, with a custom authorization middleware,  even in case of authorization failure, the client receives a 200.(instead of a 401 or 403).
The reason is that there is no way of specifying the authentication type within the authz service. Since to enable browser based authz, cookie middleware has to be added, even if a custom middleware is added, the response gets redirected to a login page in case of a 401, which results in a 200 response getting sent back to an api based client (windows phone app).
The workaround today is either :
- Have apis and browser based app as separate end points.
 
- Call the cookie middleware within your custom middleware.
 
cc: @Tratcher , @HaoK /