forked from ansible/ansible
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ConfigureRemotingForAnsible: RSA 1024 to RSA 4096 (ansible#23684)
- Loading branch information
1 parent
33d7c12
commit a40450d
Showing
1 changed file
with
5 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -31,6 +31,7 @@ | |
# Updated by Chris Church <[email protected]> | ||
# Updated by Michael Crilly <[email protected]> | ||
# Updated by Anton Ouzounov <[email protected]> | ||
# Updated by Nicolas Simond <[email protected]> | ||
# Updated by Dag Wieërs <[email protected]> | ||
# Updated by Jordan Borean <[email protected]> | ||
# | ||
|
@@ -40,13 +41,14 @@ | |
# Version 1.3 - 2016-04-04 | ||
# Version 1.4 - 2017-01-05 | ||
# Version 1.5 - 2017-02-09 | ||
# Version 1.6 - 2017-04-18 | ||
|
||
# Support -Verbose option | ||
[CmdletBinding()] | ||
|
||
Param ( | ||
[string]$SubjectName = $env:COMPUTERNAME, | ||
[int]$CertValidityDays = 365, | ||
[int]$CertValidityDays = 1095, | ||
[switch]$SkipNetworkProfileCheck, | ||
$CreateSelfSignedCert = $true, | ||
[switch]$ForceNewSSLCert, | ||
|
@@ -77,7 +79,7 @@ Function New-LegacySelfSignedCert | |
{ | ||
Param ( | ||
[string]$SubjectName, | ||
[int]$ValidDays = 365 | ||
[int]$ValidDays = 1095 | ||
) | ||
|
||
$name = New-Object -COM "X509Enrollment.CX500DistinguishedName.1" | ||
|
@@ -86,7 +88,7 @@ Function New-LegacySelfSignedCert | |
$key = New-Object -COM "X509Enrollment.CX509PrivateKey.1" | ||
$key.ProviderName = "Microsoft RSA SChannel Cryptographic Provider" | ||
$key.KeySpec = 1 | ||
$key.Length = 1024 | ||
$key.Length = 4096 | ||
$key.SecurityDescriptor = "D:PAI(A;;0xd01f01ff;;;SY)(A;;0xd01f01ff;;;BA)(A;;0x80120089;;;NS)" | ||
$key.MachineContext = 1 | ||
$key.Create() | ||
|