File tree Expand file tree Collapse file tree 6 files changed +12
-12
lines changed Expand file tree Collapse file tree 6 files changed +12
-12
lines changed Original file line number Diff line number Diff line change 6
6
# Forces TLS 1.2
7
7
[Net.ServicePointManager ]::SecurityProtocol = [Net.SecurityProtocolType ]::Tls12
8
8
9
- # Find latest version from Github
9
+ # Find latest version from GitHub
10
10
$LatestVersion = ((Invoke-WebRequest $NCPAVersionURL.Uri - UseBasicParsing).Content).TrimEnd(' ' )
11
11
$CurrentVersion = $NCPAExe.VersionInfo.ProductVersion
12
12
@@ -18,12 +18,12 @@ if (!(Test-Path $NCPAExe)) {
18
18
} elseif ($CurrentVersion -eq $LatestVersion ) {
19
19
Write-Output ' OK: NCPA is up to date'
20
20
Write-Output " Latest Version: $LatestVersion "
21
- Write-Output " Current Verison : $CurrentVersion "
21
+ Write-Output " Current Version : $CurrentVersion "
22
22
$LASTEXITCODE = 0
23
23
} elseif ($CurrentVersion -ne $LatestVersion ) {
24
24
Write-Output ' WARNING: NCPA is out of date'
25
25
Write-Output " Latest Version: $LatestVersion "
26
- Write-Output " Current Verison : $CurrentVersion "
26
+ Write-Output " Current Version : $CurrentVersion "
27
27
$LASTEXITCODE = 1
28
28
} else {
29
29
Write-Output ' UNKNOWN: Unknown issue'
Original file line number Diff line number Diff line change 1
- # Check each powershell plugin in the plugins folder to see when script signing cert will expire
1
+ # Check each PowerShell plugin in the plugins folder to see when script signing cert will expire
2
2
3
3
$PluginsFolder = " $env: ProgramFiles \Nagios\NCPA\plugins"
4
4
# $PluginsFolder = 'C:\\Program Files\\Nagios\NCPA\\plugins'
Original file line number Diff line number Diff line change 1
- # Check if latest Teamviewer version is installed
1
+ # Check if latest TeamViewer version is installed
2
2
3
3
[System.UriBuilder ]$LatestVersionURL = ' https://www.teamviewer.com/en-us/download/windows/'
4
4
@@ -17,7 +17,7 @@ if ($TVExe.Exists -eq $false) {
17
17
[System.IO.FileInfo ]$TVExe = ${env: ProgramFiles(x86)} + ' \' + ' TeamViewer' + ' \' + ' TeamViewer.exe'
18
18
}
19
19
if ($TVExe.Exists -eq $false ) {
20
- Write-Output ' UNKNOWN: Teamviewer not found or not installed'
20
+ Write-Output ' UNKNOWN: TeamViewer not found or not installed'
21
21
exit 3
22
22
}
23
23
@@ -37,7 +37,7 @@ $LatestVersion = $LatestVersion.Trim('<span data-dl-version-label>').trim('</')
37
37
$LatestVersion = ($LatestVersion -split ' \.' | Select-Object - First 3 ) -join ' .'
38
38
[version ]$LatestVersion = $LatestVersion
39
39
40
- # Compare newest verison and current version
40
+ # Compare newest version and current version
41
41
[string ]$InstalledVersion = $TVExe.VersionInfo.FileVersion
42
42
$InstalledVersion = ($InstalledVersion -split ' \.' | Select-Object - First 3 ) -join ' .'
43
43
[version ]$InstalledVersion = $InstalledVersion
Original file line number Diff line number Diff line change @@ -19,7 +19,7 @@ if (!(Test-Path $WazuhVersionFile)) {
19
19
# Forces TLS 1.2
20
20
[Net.ServicePointManager ]::SecurityProtocol = [Net.SecurityProtocolType ]::Tls12
21
21
22
- # Find latest version from Github
22
+ # Find latest version from GitHub
23
23
$WebPage = New-Object - ComObject " HTMLFile"
24
24
$Content = (Invoke-WebRequest - Uri $LatestVersionURL.Uri - UseBasicParsing).Content.ToString()
25
25
$WebPage.write ([ref ]$Content )
Original file line number Diff line number Diff line change @@ -17,7 +17,7 @@ $ShouldBeEnabledAccounts = @(
17
17
' Administrator'
18
18
)
19
19
# Group names also work for the $ShouldBeAdminAccounts variable
20
- # It includes the $ComputerName and $Domain variables in front because the get command for local groups returns user accounts with the domain or computername in front
20
+ # It includes the $ComputerName and $Domain variables in front because the get command for local groups returns user accounts with the domain or computer name in front
21
21
$ShouldBeAdminAccounts = @ (
22
22
" $ComputerName \Administrator" ,
23
23
" $Domain \Domain Admins"
Original file line number Diff line number Diff line change @@ -29,7 +29,7 @@ Various Nagios plugins
29
29
- Also measured in total hours
30
30
- Will also return
31
31
- A CRITICAL value if any Error or Critical level event is found
32
- - A WARNING value if any Warninng level event is found
32
+ - A WARNING value if any Warning level event is found
33
33
- Errors detected (Non info) in events will override uptime settings
34
34
- See example
35
35
- Nagios Exchange page: https://exchange.nagios.org/directory/Plugins/System-Metrics/Uptime/CheckForRestartsAndUptime/details
@@ -55,7 +55,7 @@ Various Nagios plugins
55
55
56
56
## [ CheckNCPAVersion.ps1] ( ./CheckNCPAVersion.ps1 )
57
57
58
- - Checks if current NCPA installed is up to date based on the latest github release
58
+ - Checks if current NCPA installed is up to date based on the latest GitHub release
59
59
- Nagios Exchange page: https://exchange.nagios.org/directory/Plugins/Software/CheckNCPAVersion/details
60
60
61
61
### Arguments
@@ -90,7 +90,7 @@ Various Nagios plugins
90
90
91
91
## [ CheckTeamviewerVersion.ps1] ( ./CheckTeamviewerVersion.ps1 )
92
92
93
- - Checks if computer is running an outdated Teamviewer
93
+ - Checks if computer is running an outdated TeamViewer
94
94
- Inside script there is a variable for $MaxMinorDif with a default value of '4'
95
95
- This will determine the number of revisions between the latest version and the installed version
96
96
- If it is more than 4 minor revisions behind, or 1+ major release behind, it reports CRITICAL
You can’t perform that action at this time.
0 commit comments