Skip to content

Commit f7f420e

Browse files
authored
Update Get-TLSRegistryKeys.ps1
1 parent d3a33de commit f7f420e

1 file changed

Lines changed: 32 additions & 18 deletions

File tree

Powershell/Get-TLSRegistryKeys.ps1

Lines changed: 32 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,29 @@
1+
<#
2+
.SYNOPSIS
3+
Check TLS Settings for SCOM
4+
.DESCRIPTION
5+
Gathers TLS settings from the registry.
6+
.PARAMETER Servers
7+
The servers you would like to run this script to check TLS settings for Operations Manager.
8+
.EXAMPLE
9+
Local Machine:
10+
PS C:\> .\Get-TLSRegistryKeys.ps1
11+
Remote Machine
12+
PS C:\> .\Get-TLSRegistryKeys.ps1 -Servers MS01-2019.contoso.com, MS02-2019.contoso.com
13+
.NOTES
14+
Original Author: Mike Kallhoff
15+
Author: Blake Drumm (blakedrumm@microsoft.com)
16+
Modified: July 29th, 2022
17+
Hosted here: https://github.com/blakedrumm/SCOM-Scripts-and-SQL/blob/master/Powershell/Get-TLSRegistryKeys.ps1
18+
#>
19+
param
20+
(
21+
[Parameter(Mandatory = $false)]
22+
[array]$Servers
23+
)
24+
125
Function Get-TLSRegistryKeys
226
{
3-
<#
4-
.SYNOPSIS
5-
Check TLS Settings for SCOM
6-
.DESCRIPTION
7-
Gathers TLS settings from the registry.
8-
.PARAMETER Servers
9-
The servers you would like to run this script to check TLS settings for Operations Manager.
10-
.EXAMPLE
11-
Local Machine:
12-
PS C:\> .\Get-TLSRegistryKeys.ps1
13-
Remote Machine
14-
PS C:\> .\Get-TLSRegistryKeys.ps1 -Servers MS01-2019.contoso.com, MS02-2019.contoso.com
15-
.NOTES
16-
Original Author: Mike Kallhoff
17-
Author: Blake Drumm (blakedrumm@microsoft.com)
18-
Modified: July 15th, 2022
19-
Hosted here: https://github.com/blakedrumm/SCOM-Scripts-and-SQL/blob/master/Powershell/Get-TLSRegistryKeys.ps1
20-
#>
2127
[CmdletBinding()]
2228
Param
2329
(
@@ -371,3 +377,11 @@ Function Get-TLSRegistryKeys
371377
}
372378
$scriptOut | Out-String -Width 4096
373379
}
380+
if ($Servers)
381+
{
382+
Get-TLSRegistryKeys -Servers $Servers
383+
}
384+
else
385+
{
386+
Get-TLSRegistryKeys
387+
}

0 commit comments

Comments
 (0)