【发布时间】:2019-09-03 00:20:51
【问题描述】:
我在 Microsoft Dynamics AX 上有 WCF 服务 (AIF)
我可以使用.NET 4.6.1 毫无问题地调用它。但是,当我使用 .NET Core 运行相同的代码时,我收到一个错误,指出
对 SSPI 的调用失败目标主体名称不正确
关于这个错误有很多类似的问题,但解决方案不能解决我的问题。
var service = new MarketplaceGetItemsDataServiceClient();
service.ClientCredentials.Windows.ClientCredential.UserName = "UserName";
service.ClientCredentials.Windows.ClientCredential.Password = "P@ssword";
service.ClientCredentials.Windows.ClientCredential.Domain = "Domain";
var result = service.GetItemsDataAsync(new CallContext(), new SearchOptionsDC() { VendorId = "0000" }).Result;
【问题讨论】:
标签: c# wcf .net-core dynamics-ax-2012 aif