This is the built-in help made by Microsoft for the command 'New-CimSessionOption', in PowerShell version 4 - as retrieved from
Windows version 'Microsoft Windows 8.1 Enterprise' PowerShell help files on 2016-06-23.
For PowerShell version 3 and up, where you have Update-Help, this command was run just before creating the web pages from the help files.
Specifies advanced options for the New-CimSession cmdlet.
New-CimSessionOption [-Protocol] {Dcom | Default | Wsman} [-Culture <CultureInfo>] [-UICulture <CultureInfo>] [<CommonParameters>]
New-CimSessionOption [-Culture <CultureInfo>] [-EncodePortInServicePrincipalName] [-Encoding <PacketEncoding>] [-HttpPrefix <Uri>] [-MaxEnvelopeSizeKB <UInt32>] [-NoE
ncryption] [-ProxyAuthentication <PasswordAuthenticationMechanism>] [-ProxyCertificateThumbprint <String>] [-ProxyCredential <PSCredential>] [-ProxyType <ProxyType>]
[-SkipCACheck] [-SkipCNCheck] [-SkipRevocationCheck] [-UICulture <CultureInfo>] [-UseSsl] [<CommonParameters>]
New-CimSessionOption [-Culture <CultureInfo>] [-Impersonation <ImpersonationType>] [-PacketIntegrity] [-PacketPrivacy] [-UICulture <CultureInfo>] [<CommonParameters>]
The New-CimSessionOption cmdlet creates an instance of a CIM session options object. You use a CIM session options object as input to the New-CimSession cmdlet to spe
cify the options for a CIM session.
This cmdlet has two parameter sets, one for WsMan options and one for Distributed Component Object Model (DCOM) options. Depending on which parameters you use, the cm
dlet returns either an instance of DCOM session options or returns WsMan session options.
<
Get-ChildItem
Get-Credential
Get-Culture
Get-Item
New-CimSession
<
Example 1: Create a CIM session options object for DCOM
PS C:\>$so = New-CimSessionOption -Protocol DCOM
PS C:\>New-CimSession -ComputerName Server01 -SessionOption $so
This set of commands creates a CIM session options object for the DCOM protocol and stores it in a variable named $so. The contents of the variable are then passed to
the New-CimSession cmdlet. New-CimSession then creates a new CIM session with the remote server named Server01, using the options defined in the variable.
Example 2: Create a CIM session options object for WsMan
PS C:\>New-CimSessionOption -ProxyAuthentication Kerberos -ProxyCredential $cred -SkipCACheck -SkipCNCheck -UseSsl
This command creates a CIM session options object for the WsMan protocol. The object contains configuration for the authentication mode of Kerberos specified by the P
roxyAuthentication parameter, the credentials specified by the ProxyCredential parameter, and specifies that the command is to skip the CA check, skip the CN check, a
nd use SSL.
Example 3: Create a CIM session options object with the culture specified
PS C:\>New-CimSessionOption -Culture Fr-Fr –Protocol Wsman
This command specifies the culture that is used for the CIM session. By default, the culture of the client is used when performing operations. However, the default cu
lture can be overridden using the Culture parameter.