Enter-PSSession -ComputerName 10.15.29.8 -Credential $crd
$crd = Get-Credential
$crd
не останется. $crd = Get-Credential
$crd.Password | ConvertFrom-SecureString | Set-Content pass.txt
$user = ″domain\administrator″
$password = Get-Content pass.txt | ConvertTo-SecureString
$cred = New-Object -TypeName System.Management.Automation.PSCredential -ArgumentList $user, $password
Enter-PSSession -ComputerName 10.15.29.8 -Credential $cred