CNAMES, файлы хостов и PowerShell Remoting - PullRequest
2 голосов
/ 10 марта 2011

Кто-нибудь получил удаленное взаимодействие powershell для работы с CNAMES или файлами хоста.

способ проверить, создать PSsession против localhost, чтобы убедиться, что он работает нормально ... затем вызвать запись хоста на 127.0.0.1, а затем попытаться создать pssession против этого.

Я получаю такую ​​ошибку

[funkymonkey] Connecting to remote server failed with the following error message : WinRM cannot pr
ocess the request. The following error occured while using Kerberos authentication: The network pat
h was not found.
 Possible causes are:
  -The user name or password specified are invalid.
  -Kerberos is used when no authentication method and no user name are specified.
  -Kerberos accepts domain user names, but not local user names.
  -The Service Principal Name (SPN) for the remote computer name and port does not exist.
  -The client and remote computers are in different domains and there is no trust between the two d
omains.
 After checking for the above issues, try the following:
  -Check the Event Viewer for events related to authentication.
  -Change the authentication method; add the destination computer to the WinRM TrustedHosts configu
ration setting or use HTTPS transport.
 Note that computers in the TrustedHosts list might not be authenticated.
   -For more information about WinRM configuration, run the following command: winrm help config. F
or more information, see the about_Remote_Troubleshooting Help topic.
    + CategoryInfo          : OpenError: (System.Manageme....RemoteRunspace:RemoteRunspace) [], PS
   RemotingTransportException
    + FullyQualifiedErrorId : PSSessionOpenFailed

1 Ответ

1 голос
/ 10 марта 2011

Если NTLM не работает, я думаю, вы попадаете под проверку петлевой проверки, добавленную в winsrv 2003 sp1 +. Вы можете добавить CNAME в специальный раздел реестра, который будет включать их в список исключений (который уже включает localhost.)

ps> new-itemproperty hklm: \ system \ currentcontrolset \ control \ Lsa \ MSV1_0 BackConnectionHostNames ` -propertyType multistring -val "cname1", "cname1.local"

Некоторые люди просто полностью его отключают (проверка зацикливания), устанавливая dable DisableLoopbackCheck (Google google), но вам действительно нужно контролировать его более жестко с помощью первого метода, а не идти по ленивому маршруту.

IIRC, эта функция безопасности предотвращает кражу учетных данных определенного типа, называемую «атака отражения». Я не помню методологию, но я уверен, что вы могли бы найти ее в Интернете.

...