1

我有使用 winrm 连接到其他机器的 ac# 应用程序。为了使它工作,我需要运行 powershell 命令:

Set-Item WSMan:\localhost\Client\TrustedHosts -Value $ip -Force

或 winrm 命令:

winrm set winrm/config/client '@{TrustedHosts="10.0.5.35"}'

我想知道c#中的等价物是什么?

4

0 回答 0