{"id":280802,"date":"2016-11-11T14:35:03","date_gmt":"2016-11-11T11:35:03","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=280802"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=280802","title":{"rendered":"\u043c\u043e\u0434\u0443\u043b\u044c Posh-SSH \u043f\u0440\u043e\u0441\u0442\u043e\u0439 \u0434\u043e\u0441\u0442\u0443\u043f \u043a SSH \u0438 SCP \u0438\u0437 PowerShell"},"content":{"rendered":"<p>\u0434\u043b\u044f powershell \u0435\u0441\u0442\u044c \u043c\u043e\u0434\u0443\u043b\u044c <b>Posh-SSH<\/b> \u0440\u0435\u0430\u043b\u0438\u0437\u0443\u044e\u0449\u0438\u0439 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u0443 \u043f\u0440\u043e\u0442\u043e\u043a\u043e\u043b\u043e\u0432 <b>SSH, SFTP, SCP<\/b> \u0432 PowerShell. \u0417\u0434\u0435\u0441\u044c \u043e\u043f\u0438\u0441\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u043a\u0430\u043a \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c, \u0438 \u0431\u0430\u0437\u043e\u0432\u044b\u0435 \u0437\u0430\u043c\u0435\u0442\u043a\u0438 \u043f\u043e \u0440\u0430\u0431\u043e\u0442\u0435. \u041f\u043e \u0441\u0443\u0442\u0438 \u044d\u0442\u043e \u0432\u044b\u0436\u0438\u043c\u043a\u0430 \u0438\u0437 \u0430\u043d\u0433\u043b\u043e\u044f\u0437\u044b\u0447\u043d\u044b\u0445 \u0441\u0442\u0430\u0442\u044c\u0438 \u043f\u0440\u0438\u0432\u0435\u0434\u0435\u043d\u043d\u043e\u0439 \u043d\u0438\u0436\u0435.<\/p>\n<p>  \u043f\u043e \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u043d\u043e\u043c\u0443 \u0441\u043e\u0431\u044b\u0442\u0438\u044e \u043f\u043e\u043d\u0430\u0434\u043e\u0431\u0438\u043b\u043e\u0441\u044c \u0441\u0431\u0440\u0430\u0441\u044b\u0432\u0430\u0442\u044c \u0441\u0435\u0442\u0435\u0432\u043e\u0439 \u043f\u043e\u0440\u0442 \u043d\u0430 \u043a\u043e\u043c\u043c\u0443\u0442\u0430\u0442\u043e\u0440\u0435. \u041a\u043e\u043c\u043c\u0443\u0442\u0430\u0442\u043e\u0440 \u0438\u043c\u0435\u0435\u0442 command line \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441 cisco. \u041f\u0435\u0440\u0435\u0434 \u0442\u0435\u043c \u043a\u0430\u043a \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0438\u0437 \u043a\u043e\u043c\u0430\u043d\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0438 putty \u0431\u044b\u043b\u043e \u0440\u0435\u0448\u0435\u043d\u043e \u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0442 \u043b\u0438 \u043c\u043e\u0434\u0443\u043b\u0438 \u0434\u043b\u044f \u0440\u0430\u0431\u043e\u0442\u044b \u043f\u043e ssh \u043d\u0430\u043f\u0440\u044f\u043c\u0443\u044e \u0438\u0437 powershell. \u041f\u043e\u0438\u0441\u043a\u0438 \u0434\u0430\u043b\u0438 \u043c\u043e\u0434\u0443\u043b\u044c <a href=\"https:\/\/github.com\/darkoperator\/Posh-SSH\">Posh-SSH \u043d\u0430 github<\/a>.<\/p>\n<p>  \u043c\u043e\u0434\u0443\u043b\u044c \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442:  <\/p>\n<ul>\n<li>\u0443\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0442\u044c \u0441\u0435\u0441\u0441\u0438\u0438 SSH \u0438 SFTP \u043f\u043e \u043a\u0440\u0435\u0434\u0438\u0442\u0430\u043b\u0430\u043c \u0438\u043b\u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044f OpenSSH \u043a\u043b\u044e\u0447<\/li>\n<li>\u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0430\u0442\u044c\u0441\u044f \u0447\u0435\u0440\u0435\u0437 SOCKS \u0438 HTTP \u043f\u0440\u043e\u043a\u0441\u0438 \u0434\u043b\u044f \u043e\u0431\u043e\u0438\u0445 \u0432\u0438\u0434\u043e\u0432 SSH \u0438 SFTP \u0441\u0435\u0441\u0441\u0438\u0439<\/li>\n<li>\u0438\u0441\u043f\u043e\u043b\u043d\u044f\u0442\u044c \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u043f\u043e \u043e\u0434\u0438\u043d\u043e\u0447\u043a\u0435 \u043f\u043e\u0441\u044b\u043b\u0430\u044f \u0438\u0445 \u0432 SSH<\/li>\n<li>\u0437\u0430\u0433\u0440\u0443\u0436\u0430\u0442\u044c \u0438 \u0441\u043a\u0430\u0447\u0438\u0432\u0430\u0442\u044c \u0444\u0430\u0439\u043b\u044b \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e SCP \u0438 SFTP \u043f\u0440\u043e\u0442\u043e\u043a\u043e\u043b\u044b<\/li>\n<\/ul>\n<p>  \u0414\u043b\u044f SSH \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u0435\u0442\u0441\u044f \u0430\u0443\u0442\u0435\u043d\u0442\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u044f \u043f\u043e \u043a\u043b\u044e\u0447\u0443, \u043b\u043e\u0433\u0438\u043d\u0443\\\u043f\u0430\u0440\u043e\u043b\u044e, \u0432\u0432\u043e\u0434 \u0441 \u043a\u043b\u0430\u0432\u0438\u0430\u0442\u0443\u0440\u044b. \u041f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u044e\u0442\u0441\u044f \u0440\u0430\u0437\u043d\u044b\u0435 \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c\u044b \u0448\u0438\u0444\u0440\u043e\u0432\u0430\u043d\u0438\u044f, \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u044e\u0442\u0441\u044f \u043f\u0440\u043e\u043a\u0441\u0438<\/p>\n<p>  \u041c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u044b\u0435 \u0442\u0440\u0435\u0431\u043e\u0432\u0430\u043d\u0438\u044f PowerShell 3.0 \u0438 .NET 4.0<br \/>  <a href=\"http:\/\/www.powershellmagazine.com\/2014\/07\/03\/posh-ssh-open-source-ssh-powershell-module\/\">\u043e\u043f\u0438\u0441\u0430\u043d\u0438\u0435 \u043c\u043e\u0434\u0443\u043b\u044f \u043d\u0430 \u043e\u0444\u0438\u0446\u0438\u0430\u043b\u044c\u043d\u043e\u0439 \u0441\u0442\u0440\u0430\u043d\u0438\u0447\u043a\u0435<\/a><br \/>  <a name=\"habracut\"><\/a>  <\/p>\n<h4>\u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430<\/h4>\n<p>  \u043f\u0440\u043e\u0441\u0442\u0435\u0439\u0448\u0438\u0439 \u0441\u043f\u043e\u0441\u043e\u0431 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438 \u0438\u0437 \u0430\u0434\u043c\u0438\u043d\u0441\u043a\u043e\u0439 \u043a\u043e\u043d\u0441\u043e\u043b\u0438 \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u044c \u043a\u043e\u043c\u0430\u043d\u0434\u0443:  <\/p>\n<pre><code>iex (New-Object Net.WebClient).DownloadString(&quot;https:\/\/gist.github.com\/darkoperator\/6152630\/raw\/c67de4f7cd780ba367cccbc2593f38d18ce6df89\/instposhsshdev&quot;) <\/code><\/pre>\n<p>  \u0435\u0441\u043b\u0438 \u0443 \u0432\u0430\u0441 \u0441\u0442\u043e\u0438\u0442 PowerShell 5  <\/p>\n<pre><code>Find-Module Posh-SSH | Install-Module <\/code><\/pre>\n<p>  \u043f\u0440\u043e\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u0432 \u043c\u043e\u0434\u0443\u043b\u0435 \u043c\u043e\u0436\u043d\u043e \u0442\u0430\u043a:  <\/p>\n<pre><code>Get-Command -Module Posh-SSH <\/code><\/pre>\n<h4>\u041a\u0430\u043a \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0441 SSH<\/h4>\n<p>  1. \u0421\u043d\u0430\u0447\u0430\u043b\u0430 \u0441\u043e\u0437\u0434\u0430\u0435\u043c SSH \u0441\u0435\u0441\u0441\u0438\u044e  <\/p>\n<pre><code>Import-Module Posh-SSH $SSHSession = New-SSHSession -ComputerName 192.168.1.1 -Credential $(Get-Credential) -Verbose<\/code><\/pre>\n<p>  \u041f\u0440\u0438 \u043f\u0435\u0440\u0432\u043e\u043c \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0438 \u043c\u043e\u0434\u0443\u043b\u044c \u0441\u043f\u0440\u043e\u0441\u0438\u0442 \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u043b\u0438 \u0443\u0434\u0430\u043b\u0435\u043d\u043d\u044b\u0439 \u0445\u043e\u0441\u0442 \u0432 \u0441\u043f\u0438\u0441\u043e\u043a \u0434\u043e\u0432\u0435\u0440\u0435\u043d\u043d\u044b\u0445. \u041c\u043e\u0436\u043d\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u043e\u0434\u0438\u043d \u0440\u0430\u0437 \u0437\u0430\u043f\u0443\u0441\u043a <b>New-SSHSession<\/b> \u0438\u0437 \u043a\u043e\u043d\u0441\u043e\u043b\u0438 \u0438 \u043d\u0430\u0436\u0430\u0442\u044c <b>Y<\/b>. \u0412 \u043f\u043e\u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u043c \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0430\u0442\u044c\u0441\u044f \u0431\u0443\u0434\u0435\u0442 \u0431\u0435\u0437 \u0432\u043e\u043f\u0440\u043e\u0441\u043e\u0432.  <\/p>\n<div class=\"spoiler\"><b class=\"spoiler_title\">\u0434\u043e\u0432\u0435\u0440\u0435\u043d\u043d\u044b\u0435 \u0445\u043e\u0441\u0442\u044b<\/b><\/p>\n<div class=\"spoiler_text\">\u0434\u043b\u044f \u043f\u0440\u043e\u0441\u043c\u043e\u0442\u0440\u0430 \u0438 \u0443\u0434\u0430\u043b\u0435\u043d\u0438\u044f \u0434\u043e\u0432\u0435\u0440\u0435\u043d\u043d\u044b\u0445 \u0445\u043e\u0441\u0442\u043e\u0432 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e\u0442\u0441\u044f \u043a\u043e\u043c\u0430\u043d\u0434\u043b\u0435\u0442\u044b  <\/p>\n<ul>\n<li> Get-SSHTrustedHost<\/li>\n<li> Get-SSHSession<\/li>\n<li> Remove-SSHSession<\/li>\n<\/ul>\n<p>  <\/div>\n<\/div>\n<p>  2. \u0441\u043e\u0437\u0434\u0430\u0435\u043c \u0448\u0435\u043b\u043b  <\/p>\n<pre><code>$SSH = $SSHSession | New-SSHShellStream<\/code><\/pre>\n<p>  \u0432\u0441\u0435, \u0442\u0435\u043f\u0435\u0440\u044c \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u0441\u044b\u043b\u0430\u0442\u044c \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u0438 \u0441\u0447\u0438\u0442\u044b\u0432\u0430\u0442\u044c \u043e\u0442\u0432\u0435\u0442<\/p>\n<pre><code># \u043e\u0442\u043f\u0440\u0430\u0432\u043b\u044f\u0435\u0442 \u043a\u043e\u043c\u0430\u043d\u0434\u0443 $SSH.WriteLine( &quot;enable&quot; )  # \u0441\u0447\u0438\u0442\u044b\u0432\u0430\u0435\u043c \u043e\u0442\u0432\u0435\u0442 $SSH.read() <\/code><\/pre>\n<p>  3. \u0417\u0430\u0432\u0435\u0440\u0448\u0435\u043d\u0438\u0435 \u0440\u0430\u0431\u043e\u0442\u044b  <\/p>\n<pre><code>$sshSession | Remove-SSHSession <\/code><\/pre>\n<p>  \u043f\u0440\u043e\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c \u0441\u0435\u0441\u0441\u0438\u0438 \u043c\u043e\u0436\u043d\u043e \u043a\u043e\u043c\u0430\u043d\u0434\u043e\u0439 <b>Get-SSHSession<\/b><\/p>\n<p>  \u043d\u0438\u0436\u0435 \u043f\u0440\u0438\u043c\u0435\u0440 \u0440\u0430\u0431\u043e\u0442\u044b:  <\/p>\n<ul>\n<li>\u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0430\u0435\u043c\u0441\u044f \u043f\u043e SSH<\/li>\n<li>\u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0438\u043c \u0432 enable \u0440\u0435\u0436\u0438\u043c<\/li>\n<li>\u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0438\u043c \u0432 \u0440\u0435\u0436\u0438\u043c \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u0438 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u0430<\/li>\n<li>\u0440\u0435\u0441\u0435\u0442\u0438\u043c \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441<\/li>\n<\/ul>\n<p>  <\/p>\n<div class=\"spoiler\"><b class=\"spoiler_title\">\u043f\u0440\u0438\u043c\u0435\u0440 \u0440\u0430\u0431\u043e\u0442\u044b \u0441 \u043a\u043e\u043c\u043c\u0443\u0442\u0430\u0442\u043e\u0440\u043e\u043c \u043f\u043e SSH<\/b><\/p>\n<div class=\"spoiler_text\">\n<pre><code>$SwitchIP = '10.10.3.2' $SwitchPort = 4  $Cred = Get-Credential admin $SSHSession = New-SSHSession -ComputerName $SwitchIP -Credential $Cred -Verbose  if ($($sshSession.Connected) -eq $true) {     Write-Host &quot;SSH session opened&quot; -ForegroundColor Green          Write-Host &quot; &quot;     Write-Host &quot;     open shell&quot; -ForegroundColor Green     ### \u0441\u0435\u0441\u0441\u0438\u044f \u043e\u0442\u043a\u0440\u044b\u0442\u0430 \u0443\u0441\u043f\u0435\u0448\u043d\u043e, \u043d\u0430\u0447\u0438\u043d\u0430\u0435\u043c \u0441\u0431\u0440\u043e\u0441 \u043f\u043e\u0440\u0442\u0430     $ssh = $sshSession | New-SSHShellStream     Start-Sleep -Seconds 1      # \u0440\u0435\u0441\u0435\u0442\u0438\u043c \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441     $ssh.read()      Start-Sleep -Seconds 1     $ssh.WriteLine( &quot;enable&quot; )     $ssh.read()     Write-Host &quot;     \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0438\u043c \u0432 \u043f\u0440\u0438\u0432\u0435\u043b\u0438\u0433\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0439 \u0440\u0435\u0436\u0438\u043c&quot; -ForegroundColor Green      Start-Sleep -Seconds 1     $ssh.WriteLine( &quot;password&quot; )     $ssh.read()     Write-Host &quot;     \u0432\u0432\u043e\u0434\u0438\u043c \u043f\u0430\u0440\u043e\u043b\u044c&quot; -ForegroundColor Green      Start-Sleep -Seconds 1     $ssh.WriteLine( &quot;configure&quot; )     $ssh.read()     Write-Host &quot;     \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0438\u043c \u0432 \u0440\u0435\u0436\u0438\u043c \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u0438&quot; -ForegroundColor Green      Start-Sleep -Seconds 1     $ssh.WriteLine( &quot;interface gigabitEthernet 1\/0\/$SwitchPort&quot; )     $ssh.read()     Write-Host &quot;     \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0438\u043c \u043a \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u0438 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u0430    interface gigabitEthernet 1\/0\/$SwitchPort&quot; -ForegroundColor Green      Start-Sleep -Seconds 1     $ssh.WriteLine( &quot;shutdown&quot; )     $ssh.read()     Write-Host &quot;     \u043e\u0442\u043a\u043b\u044e\u0447\u0430\u0435\u043c \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441&quot; -ForegroundColor Green      Start-Sleep -Seconds 3     $ssh.WriteLine( &quot;no shutdown&quot; )     $ssh.read()     Write-Host &quot;     \u0432\u043a\u043b\u044e\u0447\u0430\u0435\u043c \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441&quot; -ForegroundColor Green      Write-Host &quot;     \u043e\u0442\u0440\u0430\u0431\u043e\u0442\u0430\u043b\u0438, \u0437\u0430\u0432\u0435\u0440\u0448\u0430\u0435\u043c\u0441\u044f&quot; -ForegroundColor Green } else {     Write-Host &quot;SSH session cannot be established&quot; -ForegroundColor Red     Write-Host &quot;script terminate&quot; -ForegroundColor Red     exit }   if ( $($sshSession | Remove-SSHSession) -eq $true) {     Write-Host &quot;SSH session closed&quot; -ForegroundColor Green } else{     Write-Host &quot;SSH session NOT closed&quot; -ForegroundColor Red     Write-Host &quot;please check manual&quot; -ForegroundColor Red          Get-SSHSession } <\/code><\/pre>\n<p>  \u043a\u0430\u043a \u0432\u0438\u0434\u043d\u043e \u0438\u0437 \u043f\u0440\u0438\u043c\u0435\u0440\u0430 \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u043b\u0443\u0447\u0430\u0442\u044c \u043e\u0431\u0440\u0430\u0442\u043d\u043e \u0432\u044b\u0432\u043e\u0434 \u043a\u043e\u043d\u0441\u043e\u043b\u0438 \u0438 \u043f\u0430\u0440\u0441\u0438\u0442\u044c \u043f\u0440\u0438 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e\u0441\u0442\u0438<br \/>  \u043c\u0435\u0442\u043e\u0434\u0430 \u043e\u0442\u043f\u0440\u0430\u0432\u043a\u0438 2 \u2014 Write \u0438 WriteLine \u043f\u0435\u0440\u0432\u044b\u0439 \u043f\u0435\u0447\u0430\u0442\u0430\u0435\u0442 \u0432 \u043a\u043e\u043d\u0441\u043e\u043b\u044c, \u0432\u0442\u043e\u0440\u043e\u0439 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0432\u0435\u043d\u043d\u043e \u043f\u0435\u0447\u0430\u0442\u0430\u0435\u0442 \u0438 \u043d\u0430\u0436\u0438\u043c\u0430\u0435\u0442 Enter  <\/div>\n<\/div>\n<h4>\u043f\u0440\u0435\u0434\u0430\u0447\u0430 \u0444\u0430\u0439\u043b\u043e\u0432 \u043f\u043e SCP<\/h4>\n<p>  \u0442\u0443\u0442 \u0432\u0441\u0435 \u0435\u0449\u0435 \u043f\u0440\u043e\u0449\u0435. \u043f\u0440\u0438\u0432\u043e\u0436\u0443 \u043f\u0440\u0438\u043c\u0435\u0440 \u0441 \u043e\u0444\u0438\u0446\u0438\u0430\u043b\u044c\u043d\u043e\u0439 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b<br \/>  \u0437\u0430\u043a\u0430\u0447\u043a\u0430 \u0444\u0430\u0439\u043b\u0430  <\/p>\n<pre><code>Set-SCPFile -LocalFile .\\Downloads\\VMware-PowerCLI-5.5.0-1671586.exe -RemoteFile &quot;\/tmp\/powercliinstaller.exe&quot; -ComputerName 192.168.10.3 -Credential (Get-Credential root)<\/code><\/pre>\n<p>  \u0441\u043a\u0430\u0447\u0438\u0432\u0430\u043d\u0438\u0435 \u0444\u0430\u0439\u043b\u0430  <\/p>\n<pre><code>Get-SCPFile -LocalFile .\\Downloads\\VMware-PowerCLI.exe -RemoteFile &quot;\/tmp\/powercliinstaller.exe&quot; -ComputerName 192.168.10.3 -Credential (Get-Credential root)<\/code><\/pre>\n<p>  \u043e\u0444\u0438\u0446\u0438\u0430\u043b\u044c\u043d\u0430\u044f \u0441\u0442\u0440\u0430\u043d\u0438\u0447\u043a\u0430 \u043e\u0442 \u0441\u043e\u0437\u0434\u0430\u0442\u0435\u043b\u044f \u043c\u043e\u0434\u0443\u043b\u044f<br \/>  <a href=\"http:\/\/www.powershellmagazine.com\/2014\/07\/03\/posh-ssh-open-source-ssh-powershell-module\/\">www.powershellmagazine.com\/2014\/07\/03\/posh-ssh-open-source-ssh-powershell-module<\/a><\/p>\n<p>  \u043f\u043e\u043b\u0435\u0437\u043d\u044b\u0435 \u0441\u0441\u044b\u043b\u043a\u0438<br \/>  <a href=\"http:\/\/www.powershelladmin.com\/wiki\/SSH_from_PowerShell_using_the_SSH.NET_library\">www.powershelladmin.com\/wiki\/SSH_from_PowerShell_using_the_SSH.NET_library<\/a><br \/>  <a href=\"https:\/\/blogs.msdn.microsoft.com\/powershell\/2015\/06\/03\/looking-forward-microsoft-support-for-secure-shell-ssh\/\">blogs.msdn.microsoft.com\/powershell\/2015\/06\/03\/looking-forward-microsoft-support-for-secure-shell-ssh<\/a><br \/> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"https:\/\/habrahabr.ru\/post\/314990\/\"> https:\/\/habrahabr.ru\/post\/314990\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u0434\u043b\u044f powershell \u0435\u0441\u0442\u044c \u043c\u043e\u0434\u0443\u043b\u044c <b>Posh-SSH<\/b> \u0440\u0435\u0430\u043b\u0438\u0437\u0443\u044e\u0449\u0438\u0439 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u0443 \u043f\u0440\u043e\u0442\u043e\u043a\u043e\u043b\u043e\u0432 <b>SSH, SFTP, SCP<\/b> \u0432 PowerShell. \u0417\u0434\u0435\u0441\u044c \u043e\u043f\u0438\u0441\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u043a\u0430\u043a \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c, \u0438 \u0431\u0430\u0437\u043e\u0432\u044b\u0435 \u0437\u0430\u043c\u0435\u0442\u043a\u0438 \u043f\u043e \u0440\u0430\u0431\u043e\u0442\u0435. \u041f\u043e \u0441\u0443\u0442\u0438 \u044d\u0442\u043e \u0432\u044b\u0436\u0438\u043c\u043a\u0430 \u0438\u0437 \u0430\u043d\u0433\u043b\u043e\u044f\u0437\u044b\u0447\u043d\u044b\u0445 \u0441\u0442\u0430\u0442\u044c\u0438 \u043f\u0440\u0438\u0432\u0435\u0434\u0435\u043d\u043d\u043e\u0439 \u043d\u0438\u0436\u0435.<\/p>\n<p>  \u043f\u043e \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u043d\u043e\u043c\u0443 \u0441\u043e\u0431\u044b\u0442\u0438\u044e \u043f\u043e\u043d\u0430\u0434\u043e\u0431\u0438\u043b\u043e\u0441\u044c \u0441\u0431\u0440\u0430\u0441\u044b\u0432\u0430\u0442\u044c \u0441\u0435\u0442\u0435\u0432\u043e\u0439 \u043f\u043e\u0440\u0442 \u043d\u0430 \u043a\u043e\u043c\u043c\u0443\u0442\u0430\u0442\u043e\u0440\u0435. \u041a\u043e\u043c\u043c\u0443\u0442\u0430\u0442\u043e\u0440 \u0438\u043c\u0435\u0435\u0442 command line \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441 cisco. \u041f\u0435\u0440\u0435\u0434 \u0442\u0435\u043c \u043a\u0430\u043a \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0438\u0437 \u043a\u043e\u043c\u0430\u043d\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0438 putty \u0431\u044b\u043b\u043e \u0440\u0435\u0448\u0435\u043d\u043e \u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0442 \u043b\u0438 \u043c\u043e\u0434\u0443\u043b\u0438 \u0434\u043b\u044f \u0440\u0430\u0431\u043e\u0442\u044b \u043f\u043e ssh \u043d\u0430\u043f\u0440\u044f\u043c\u0443\u044e \u0438\u0437 powershell. \u041f\u043e\u0438\u0441\u043a\u0438 \u0434\u0430\u043b\u0438 \u043c\u043e\u0434\u0443\u043b\u044c <a href=\"https:\/\/github.com\/darkoperator\/Posh-SSH\">Posh-SSH \u043d\u0430 github<\/a>.<\/p>\n<p>  \u043c\u043e\u0434\u0443\u043b\u044c \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442:  <\/p>\n<ul>\n<li>\u0443\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0442\u044c \u0441\u0435\u0441\u0441\u0438\u0438 SSH \u0438 SFTP \u043f\u043e \u043a\u0440\u0435\u0434\u0438\u0442\u0430\u043b\u0430\u043c \u0438\u043b\u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044f OpenSSH \u043a\u043b\u044e\u0447<\/li>\n<li>\u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0430\u0442\u044c\u0441\u044f \u0447\u0435\u0440\u0435\u0437 SOCKS \u0438 HTTP \u043f\u0440\u043e\u043a\u0441\u0438 \u0434\u043b\u044f \u043e\u0431\u043e\u0438\u0445 \u0432\u0438\u0434\u043e\u0432 SSH \u0438 SFTP \u0441\u0435\u0441\u0441\u0438\u0439<\/li>\n<li>\u0438\u0441\u043f\u043e\u043b\u043d\u044f\u0442\u044c \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u043f\u043e \u043e\u0434\u0438\u043d\u043e\u0447\u043a\u0435 \u043f\u043e\u0441\u044b\u043b\u0430\u044f \u0438\u0445 \u0432 SSH<\/li>\n<li>\u0437\u0430\u0433\u0440\u0443\u0436\u0430\u0442\u044c \u0438 \u0441\u043a\u0430\u0447\u0438\u0432\u0430\u0442\u044c \u0444\u0430\u0439\u043b\u044b \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e SCP \u0438 SFTP \u043f\u0440\u043e\u0442\u043e\u043a\u043e\u043b\u044b<\/li>\n<\/ul>\n<p>  \u0414\u043b\u044f SSH \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u0435\u0442\u0441\u044f \u0430\u0443\u0442\u0435\u043d\u0442\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u044f \u043f\u043e \u043a\u043b\u044e\u0447\u0443, \u043b\u043e\u0433\u0438\u043d\u0443\\\u043f\u0430\u0440\u043e\u043b\u044e, \u0432\u0432\u043e\u0434 \u0441 \u043a\u043b\u0430\u0432\u0438\u0430\u0442\u0443\u0440\u044b. \u041f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u044e\u0442\u0441\u044f \u0440\u0430\u0437\u043d\u044b\u0435 \u0430\u043b\u0433\u043e\u0440\u0438\u0442\u043c\u044b \u0448\u0438\u0444\u0440\u043e\u0432\u0430\u043d\u0438\u044f, \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u044e\u0442\u0441\u044f \u043f\u0440\u043e\u043a\u0441\u0438<\/p>\n<p>  \u041c\u0438\u043d\u0438\u043c\u0430\u043b\u044c\u043d\u044b\u0435 \u0442\u0440\u0435\u0431\u043e\u0432\u0430\u043d\u0438\u044f PowerShell 3.0 \u0438 .NET 4.0<br \/>  <a href=\"http:\/\/www.powershellmagazine.com\/2014\/07\/03\/posh-ssh-open-source-ssh-powershell-module\/\">\u043e\u043f\u0438\u0441\u0430\u043d\u0438\u0435 \u043c\u043e\u0434\u0443\u043b\u044f \u043d\u0430 \u043e\u0444\u0438\u0446\u0438\u0430\u043b\u044c\u043d\u043e\u0439 \u0441\u0442\u0440\u0430\u043d\u0438\u0447\u043a\u0435<\/a>  <\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-280802","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/280802","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=280802"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/280802\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=280802"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=280802"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=280802"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}