Fix: 8.6.1 output and formatting in line with recommendation
This commit is contained in:
@@ -36,32 +36,32 @@ function Test-ReportSecurityInTeams {
|
|||||||
$ReportSubmissionPolicy.ReportChatMessageToCustomizedAddressEnabled -and
|
$ReportSubmissionPolicy.ReportChatMessageToCustomizedAddressEnabled -and
|
||||||
-not $ReportSubmissionPolicy.ReportChatMessageEnabled
|
-not $ReportSubmissionPolicy.ReportChatMessageEnabled
|
||||||
|
|
||||||
$faildetailstring = @"
|
$detailsString = @"
|
||||||
The following settings are required for users to report security concerns in Teams:
|
The following settings are required for users to report security concerns in Teams:
|
||||||
|
|
||||||
MS Teams:
|
MS Teams:
|
||||||
AllowSecurityEndUserReporting: True
|
AllowSecurityEndUserReporting: True
|
||||||
|
|
||||||
EXO:
|
EXO:
|
||||||
ReportJunkToCustomizedAddress : True
|
ReportJunkToCustomizedAddress: True
|
||||||
ReportNotJunkToCustomizedAddress : True
|
ReportNotJunkToCustomizedAddress: True
|
||||||
ReportPhishToCustomizedAddress : True
|
ReportPhishToCustomizedAddress: True
|
||||||
ReportJunkAddresses : <security@contoso.com>
|
ReportJunkAddresses: <security@contoso.com>
|
||||||
ReportNotJunkAddresses : <security@contoso.com>
|
ReportNotJunkAddresses: <security@contoso.com>
|
||||||
ReportPhishAddresses : <security@contoso.com>
|
ReportPhishAddresses: <security@contoso.com>
|
||||||
ReportChatMessageEnabled : False
|
ReportChatMessageEnabled: False
|
||||||
ReportChatMessageToCustomizedAddressEnabled : True
|
ReportChatMessageToCustomizedAddressEnabled: True
|
||||||
"@
|
"@
|
||||||
$detailsString = "Users cannot report security concerns in Teams due to one or more incorrect settings:`n`n" +
|
$faildetailstring = "Users cannot report security concerns in Teams due to one or more of the found incorrect settings:`n`n" +
|
||||||
"MSTeams: AllowSecurityEndUserReporting: $($CsTeamsMessagingPolicy.AllowSecurityEndUserReporting); `n" +
|
"MSTeams: `nAllowSecurityEndUserReporting: $($CsTeamsMessagingPolicy.AllowSecurityEndUserReporting); `n`n" +
|
||||||
"EXO: ReportJunkToCustomizedAddress: $($ReportSubmissionPolicy.ReportJunkToCustomizedAddress); `n" +
|
"EXO: `nReportJunkToCustomizedAddress: $($ReportSubmissionPolicy.ReportJunkToCustomizedAddress); `n" +
|
||||||
"EXO: ReportNotJunkToCustomizedAddress: $($ReportSubmissionPolicy.ReportNotJunkToCustomizedAddress); `n" +
|
"ReportNotJunkToCustomizedAddress: $($ReportSubmissionPolicy.ReportNotJunkToCustomizedAddress); `n" +
|
||||||
"EXO: ReportPhishToCustomizedAddress: $($ReportSubmissionPolicy.ReportPhishToCustomizedAddress); `n" +
|
"ReportPhishToCustomizedAddress: $($ReportSubmissionPolicy.ReportPhishToCustomizedAddress); `n" +
|
||||||
"EXO: ReportJunkAddresses: $($ReportSubmissionPolicy.ReportJunkAddresses -join ', '); `n" +
|
"ReportJunkAddresses: $($ReportSubmissionPolicy.ReportJunkAddresses -join ', '); `n" +
|
||||||
"EXO: ReportNotJunkAddresses: $($ReportSubmissionPolicy.ReportNotJunkAddresses -join ', '); `n" +
|
"ReportNotJunkAddresses: $($ReportSubmissionPolicy.ReportNotJunkAddresses -join ', '); `n" +
|
||||||
"EXO: ReportPhishAddresses: $($ReportSubmissionPolicy.ReportPhishAddresses -join ', '); `n" +
|
"ReportPhishAddresses: $($ReportSubmissionPolicy.ReportPhishAddresses -join ', '); `n" +
|
||||||
"EXO: ReportChatMessageEnabled: $($ReportSubmissionPolicy.ReportChatMessageEnabled); `n" +
|
"ReportChatMessageEnabled: $($ReportSubmissionPolicy.ReportChatMessageEnabled); `n" +
|
||||||
"EXO: ReportChatMessageToCustomizedAddressEnabled: $($ReportSubmissionPolicy.ReportChatMessageToCustomizedAddressEnabled); "
|
"ReportChatMessageToCustomizedAddressEnabled: $($ReportSubmissionPolicy.ReportChatMessageToCustomizedAddressEnabled); "
|
||||||
# Prepare failure reasons and details based on compliance
|
# Prepare failure reasons and details based on compliance
|
||||||
$failureReasons = if (-not $securityReportEnabled) {
|
$failureReasons = if (-not $securityReportEnabled) {
|
||||||
$detailsString
|
$detailsString
|
||||||
|
Reference in New Issue
Block a user