-
Notifications
You must be signed in to change notification settings - Fork 342
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #2222 from microsoft/NovSU
Nov 24 SU
- Loading branch information
Showing
15 changed files
with
254 additions
and
74 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
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
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
55 changes: 55 additions & 0 deletions
55
Diagnostics/HealthChecker/Analyzer/Security/Invoke-AnalyzerSecurityCve-2024-49040.ps1
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 |
---|---|---|
@@ -0,0 +1,55 @@ | ||
# Copyright (c) Microsoft Corporation. | ||
# Licensed under the MIT License. | ||
|
||
. $PSScriptRoot\..\Add-AnalyzedResultInformation.ps1 | ||
function Invoke-AnalyzerSecurityCve-2024-49040 { | ||
[CmdletBinding()] | ||
param( | ||
[Parameter(Mandatory = $true)] | ||
[ref]$AnalyzeResults, | ||
|
||
[Parameter(Mandatory = $true)] | ||
[object]$SecurityObject, | ||
|
||
[Parameter(Mandatory = $true)] | ||
[object]$DisplayGroupingKey | ||
) | ||
begin { | ||
Write-Verbose "Calling: $($MyInvocation.MyCommand)" | ||
$exchangeInformation = $SecurityObject.ExchangeInformation | ||
$organizationInformation = $SecurityObject.OrgInformation | ||
$exchangeBuild = $exchangeInformation.BuildInformation.VersionInformation.BuildVersion | ||
# cSpell:disable | ||
# Need to disable cSpell because this is the name of the override | ||
$filterParameterName = "AddDisclaimerforRegexMatch" | ||
# cSpell:enable | ||
} | ||
process { | ||
$params = @{ | ||
ExchangeSettingOverride = $exchangeInformation.SettingOverrides | ||
GetSettingOverride = $organizationInformation.GetSettingOverride | ||
FilterServer = $exchangeInformation.GetExchangeServer.Name | ||
FilterServerVersion = $exchangeBuild | ||
FilterComponentName = "Transport" | ||
FilterSectionName = "NonCompliantSenderSettings" | ||
FilterParameterName = $filterParameterName | ||
} | ||
[array]$nonCompliantSenderSettings = Get-FilteredSettingOverrideInformation @params | ||
|
||
$overrideDisabled = $nonCompliantSenderSettings.Count -gt 0 -and | ||
($null -ne ($nonCompliantSenderSettings | Where-Object { $_.ParameterValue -eq "false" })) | ||
$isSuApplied = (Test-ExchangeBuildGreaterOrEqualThanSecurityPatch -CurrentExchangeBuild $SecurityObject.BuildInformation -SUName "Nov24SU") | ||
|
||
if (-not $isSuApplied -or $overrideDisabled) { | ||
$params = @{ | ||
AnalyzedInformation = $AnalyzeResults | ||
DisplayGroupingKey = $DisplayGroupingKey | ||
Name = "Security Vulnerability" | ||
Details = ("{0} - Override Is Set: $overrideDisabled`r`n`t`tSee: https://portal.msrc.microsoft.com/security-guidance/advisory/{0} for more information." -f "CVE-2024-49040") | ||
DisplayWriteType = "Red" | ||
DisplayTestingValue = "CVE-2024-49040" | ||
} | ||
Add-AnalyzedResultInformation @params | ||
} | ||
} | ||
} |
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
Oops, something went wrong.