Set-RDCertificate
適用対象: Windows 10, Windows Server Technical Preview
Set-RDCertificate
Imports and secures a certificate to use with an RDS role.
構文
Parameter Set: Reapply
Set-RDCertificate [-Role] <RDCertificateRole> {RDGateway | RDWebAccess | RDRedirector | RDPublishing} [-ConnectionBroker <String> ] [-Force] [-InformationAction <System.Management.Automation.ActionPreference> {SilentlyContinue | Stop | Continue | Inquire | Ignore | Suspend} ] [-InformationVariable <System.String> ] [-Password <SecureString> ] [ <CommonParameters>]
Parameter Set: Import
Set-RDCertificate [-Role] <RDCertificateRole> {RDGateway | RDWebAccess | RDRedirector | RDPublishing} [-ConnectionBroker <String> ] [-Force] [-ImportPath <String> ] [-InformationAction <System.Management.Automation.ActionPreference> {SilentlyContinue | Stop | Continue | Inquire | Ignore | Suspend} ] [-InformationVariable <System.String> ] [-Password <SecureString> ] [ <CommonParameters>]
詳細説明
The Set-RDCertificate cmdlet imports a certificate to use with a Remote Desktop Services (RDS) role. The cmldet helps secure a certificate by using a secure string supplied by the user. You can use this cmdlet to apply a new secure string for an existing certificate.
パラメーター
-ConnectionBroker<String>
Specifies the Remote Desktop Connection Broker (RD Connection Broker) server for a Remote Desktop deployment. If you do not specify a value, the cmdlet uses the fully qualified domain name (FQDN) of the local computer.
Aliases |
none |
必須/オプション |
false |
位置 |
named |
既定値 |
none |
パイプライン入力の受け入れ |
false |
ワイルドカード文字の受け入れ |
false |
-Force
Performs the action without a confirmation message.
Aliases |
none |
必須/オプション |
false |
位置 |
named |
既定値 |
none |
パイプライン入力の受け入れ |
false |
ワイルドカード文字の受け入れ |
false |
-ImportPath<String>
Specifies the location of a certificate as a file that has a .pfx extension.
Aliases |
none |
必須/オプション |
false |
位置 |
named |
既定値 |
none |
パイプライン入力の受け入れ |
false |
ワイルドカード文字の受け入れ |
false |
-InformationAction<System.Management.Automation.ActionPreference>
Specifies how this cmdlet responds to an information event. The acceptable values for this parameter are:
-- SilentlyContinue
-- Stop
-- Continue
-- Inquire
-- Ignore
-- Suspend
Aliases |
infa |
必須/オプション |
false |
位置 |
named |
既定値 |
none |
パイプライン入力の受け入れ |
false |
ワイルドカード文字の受け入れ |
false |
-InformationVariable<System.String>
Specifies a variable in which to store an information event message.
Aliases |
iv |
必須/オプション |
false |
位置 |
named |
既定値 |
none |
パイプライン入力の受け入れ |
false |
ワイルドカード文字の受け入れ |
false |
-Password<SecureString>
Specifies a secure string used to help secure the certificate. See the Examples section.
Aliases |
none |
必須/オプション |
false |
位置 |
named |
既定値 |
none |
パイプライン入力の受け入れ |
false |
ワイルドカード文字の受け入れ |
false |
-Role<RDCertificateRole>
Specifies a certificate type associated with an RDS server role. このパラメーターに指定できる値は、次のとおりです。
-- RDGateway
-- RDWebAccess
-- RDRedirector
-- RDPublishing
Aliases |
none |
必須/オプション |
true |
位置 |
1 |
既定値 |
none |
パイプライン入力の受け入れ |
false |
ワイルドカード文字の受け入れ |
false |
<CommonParameters>
このコマンドレットは共通のパラメーターをサポートしています(-Verbose、-Debug、-ErrorAction、-ErrorVariable、-OutBuffer、および -OutVariable)。詳細については、TechNet の「 「about_CommonParameters」 (https://go.microsoft.com/fwlink/p/?LinkID=113216) を参照してください。
入力
入力型は、コマンドレットにパイプできるオブジェクトの型です。
出力
出力型は、コマンドレットが出力するオブジェクトの型です。
- Null
使用例
Example 1: Import a certificate to use with RDS
This example imports a certificate to use with an RDS role.
The first command uses the ConvertTo-SecureString cmdlet to create a secure string based on a string that the user supplies, and stores it in the $Password variable. For more information, type Get-Help ConvertTo-SecureString
.
The second command specifies the file name of the certificate to use for the redirector role for the RD Connection Broker named RDCB.Contoso.com. The command uses the secure string stored in the $Password variable to help secure the certificate.
PS C:\> $Password = ConvertTo-SecureString -String "Cups34Horses&&" -AsPlainText -Force
PS C:\> Set-RDCertificate -Role RDRedirector -ImportPath "C:\Certificates\Redirector07.pfx" -Password $Password -ConnectionBroker "RDCB.Contoso.com"
Example 2: Apply a secure string to a certificate
This example applies a new secure string to a certificate used for an RDS role.
The first command uses the ConvertTo-SecureString cmdlet to create a secure string based on a string that the user supplies, and stores it in the $Password variable.
The second command uses the secure string stored in the $Password variable to secure the certificate used for the redirector role for the RD Connection Broker named RDCB.Contoso.com.
PS C:\> $Password = ConvertTo-SecureString -String "Wings%%83Potato" -AsPlainText -Force
PS C:\> Set-RDCertificate -Role RDRedirector -Password $Password -ConnectionBroker "RDCB.Contoso.com"