o365:pshellconnect
Differences
This shows you the differences between two versions of the page.
Next revision | Previous revisionLast revisionBoth sides next revision | ||
o365:pshellconnect [2014/03/28 11:49] – created gfsadministrator | o365:pshellconnect [2014/04/09 18:46] – gfsadministrator | ||
---|---|---|---|
Line 1: | Line 1: | ||
+ | > | ||
+ | >< | ||
+ | |||
====== Connessione alla PowerShell ====== | ====== Connessione alla PowerShell ====== | ||
+ | Questo codice farà comparire il popup di richiesta password per l' | ||
<file ps PShell-Start.ps1> | <file ps PShell-Start.ps1> | ||
$UserCredential = Get-Credential -Credential utente@dominio.tld | $UserCredential = Get-Credential -Credential utente@dominio.tld | ||
$Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https:// | $Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https:// | ||
+ | Import-PSSession $Session | ||
+ | </ | ||
+ | |||
+ | ====== Connessione alla PowerShell con un file password ====== | ||
+ | Questo codice farà si autenticherà alla console Exchange senza l' | ||
+ | |||
+ | <file ps PShell-Start.ps1> | ||
+ | $User = " | ||
+ | $PWord = Get-Content C: | ||
+ | $Credential = New-Object –TypeName System.Management.Automation.PSCredential –ArgumentList $User, $PWord | ||
+ | $Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https:// | ||
Import-PSSession $Session | Import-PSSession $Session | ||
</ | </ |
o365/pshellconnect.txt · Last modified: 2014/04/14 09:34 by gfsadministrator