使用 WCAT 和 NTLM 时出现意外的 HTTP 状态代码
有谁知道在测试使用 NTLM 身份验证的 Web 应用程序时如何避免 WCAT 记录意外的“401 未经授权”HTTP 状态代码?我用于请求的代码示例如下:
request
{
url = "http://server";
authentication = NTLM;
username = "user";
password = "xxxx";
statuscode = 200;
}
为了澄清,该脚本工作正常并且确实能够检索内容,但是当针对 IIS7 服务器运行时,NTLM 协商(我相信)意味着记录了初始 401 代码以及最终的 200 代码。
这意味着测试后报告显示的 401 代码数量与 200 代码数量相同,不幸的是 401 被记录为意外代码/错误。
我意识到这与之前提出的问题类似,但这个问题专门询问是否有一种方法可以避免意外的状态代码。
谢谢!
Does anyone know how to avoid WCAT recording unexpected "401 Unauthorized" HTTP Status codes when testing a web application that uses NTLM authentication? An example of the code I am using for a request is below:
request
{
url = "http://server";
authentication = NTLM;
username = "user";
password = "xxxx";
statuscode = 200;
}
To clarify, this script works fine and does manage to retrieve the content but when ran against an IIS7 server the NTLM negotiation (I believe) means that the initial 401 code is recorded as well as the final 200 code.
This means that after a test the report shows the same amount of 401 codes as 200 codes, and unfortunately the 401s are recorded as unexpected codes/errors.
I realise this is a similar question to one asked earlier, but this one is specifically asking if there is a way to avoid the unexpected status codes.
Thanks!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您需要的(我认为)是一个
transaction { ... }
,其中包含许多request { ... }
元素,其中一些需要 401 状态代码:What you need (I think) is a
transaction { ... }
with a number ofrequest { ... }
elements inside, some of which expect a 401 statuscode: