gpt4 book ai didi

在SoapUI上进行带有用户名身份验证的WCF Web服务

转载 作者:行者123 更新时间:2023-12-04 05:07:43 24 4
gpt4 key购买 nike

我有带有UserName身份验证的WCF WebService,无法使用SoapUI对其进行测试。
在这里,您有web.config:

<behaviors>
<serviceBehaviors>
<behavior name="FHPBusinessLogicService.ServiceBehavior">
<serviceCredentials type="FHPBusinessLogicService.Security.PasswordServiceCredentials, FHPBusinessLogicService">
<userNameAuthentication userNamePasswordValidationMode="Custom" />
</serviceCredentials>
<serviceMetadata httpGetEnabled="true" httpsGetEnabled="true"/>
<serviceDebug includeExceptionDetailInFaults="true"/>
<serviceAuthorization principalPermissionMode="Custom" />
</behavior>
</serviceBehaviors>
</behaviors>
<bindings>
<basicHttpBinding>
<binding name="ServiceConf" maxReceivedMessageSize="65536" >
<readerQuotas maxStringContentLength="65536" maxArrayLength="65536" maxBytesPerRead="65536" />
<security mode="TransportWithMessageCredential" >
<message clientCredentialType="UserName" />

</security>

</binding>
</basicHttpBinding>
</bindings>
在SoapUI上,我收到:

An error occurred when verifying security for the message


我正在本地计算机IIS 7服务器上对其进行测试。
有什么建议么?

最佳答案

在SoapUI的“请求密码类型”部分的“请求属性”中,只需选择选项“ PasswordText ”。那会做的事

关于在SoapUI上进行带有用户名身份验证的WCF Web服务,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/13359629/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com