AuthenticateUser可以作为用户和密码获得“测试”,但在OnApplicationEndRequest中无论如何返回401。我遗漏了什么? var response = HttpContext.Current.Response;
if (response.StatusCode == 401manager.UserTokenProvider = new DataProtectorTokenProvider<ApplicationUser&
我有一个带有基本auth (通过自定义数据库签入代码)的web服务,它在用户凭据错误时返回HTTP 401 + SOAP错误消息。这在我的本地IIS 7中有效,但在Azure不起作用.当我通过Azure将它移到Azure,并插入糟糕的凭据时,我总是收到以下消息:"You do not have permission to view this directory经过几个小时的研究,我发现如果我的代码返回具有HTTP 401状态的响应,Azure就会像上面的消