【发布时间】:2021-06-14 16:01:53
【问题描述】:
我将 SoapCore 1.1.0.8 与 .NetCore 3.1 一起使用
有谁知道如何使用 SoapCore 从信封中访问 XML 标头?
例如像下面这样的信封
<SOAP:Header xmlns='http://www.acompany.com/gsd'>
<ns0:AuthenticationInfo xmlns:ns0='http://customheader.com'>
<ns0:userName>Dummy_User</ns0:userName>
<ns0:password>Dummy_Pwd</ns0:password>
</ns0:AuthenticationInfo>
</SOAP:Header>
<SOAP:Body xmlns='http://www.acompany.com/gsd'>
<MsgReq xmlns='http://www.acompany.com/gsd' xmlns:soapenv='http://schemas.xmlsoap.org/soap/envelope/'>
<MethodName>Identify</MethodName>
<MethodID>IS_001_01</MethodID>
.
.
</MsgReq>
</SOAP:Body>
</SOAP:Envelope>
您如何访问用户名和密码元素?
【问题讨论】:
标签: xml asp.net-core header soapcore