From f6558b83758ee50575e6d86457f6ad0a611f4c38 Mon Sep 17 00:00:00 2001 From: Swampen Date: Mon, 21 Dec 2020 13:18:16 -0800 Subject: [PATCH 01/21] Removed depricated options from EXOHostedContentFilterPolicy --- .../MSFT_EXOHostedContentFilterPolicy.psm1 | 125 +++++++----------- ...FT_EXOHostedContentFilterPolicy.schema.mof | 2 - .../readme.md | 5 +- 3 files changed, 50 insertions(+), 82 deletions(-) diff --git a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.psm1 b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.psm1 index 074091ad69..d63788979a 100644 --- a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.psm1 +++ b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.psm1 @@ -58,15 +58,6 @@ function Get-TargetResource [System.Boolean] $EnableRegionBlockList = $false, - [Parameter()] - [ValidatePattern("^$|^[a-zA-Z0-9.!£#$%&'^_`{}~-]+@[a-zA-Z0-9-]+(?:\.[a-zA-Z0-9-]+)*$")] - [System.String] - $EndUserSpamNotificationCustomFromAddress, - - [Parameter()] - [System.String] - $EndUserSpamNotificationCustomFromName, - [Parameter()] [System.String] $EndUserSpamNotificationCustomSubject, @@ -290,56 +281,54 @@ function Get-TargetResource else { $result = @{ - Ensure = 'Present' - Identity = $Identity - AddXHeaderValue = $HostedContentFilterPolicy.AddXHeaderValue - AdminDisplayName = $HostedContentFilterPolicy.AdminDisplayName - AllowedSenderDomains = $HostedContentFilterPolicy.AllowedSenderDomains - AllowedSenders = $HostedContentFilterPolicy.AllowedSenders - BlockedSenderDomains = $HostedContentFilterPolicy.BlockedSenderDomains - BlockedSenders = $HostedContentFilterPolicy.BlockedSenders - BulkSpamAction = $HostedContentFilterPolicy.BulkSpamAction - BulkThreshold = $HostedContentFilterPolicy.BulkThreshold - DownloadLink = $HostedContentFilterPolicy.DownloadLink - EnableEndUserSpamNotifications = $HostedContentFilterPolicy.EnableEndUserSpamNotifications - EnableLanguageBlockList = $HostedContentFilterPolicy.EnableLanguageBlockList - EnableRegionBlockList = $HostedContentFilterPolicy.EnableRegionBlockList - EndUserSpamNotificationCustomFromAddress = $HostedContentFilterPolicy.EndUserSpamNotificationCustomFromAddress - EndUserSpamNotificationCustomFromName = $HostedContentFilterPolicy.EndUserSpamNotificationCustomFromName - EndUserSpamNotificationCustomSubject = $HostedContentFilterPolicy.EndUserSpamNotificationCustomSubject - EndUserSpamNotificationFrequency = $HostedContentFilterPolicy.EndUserSpamNotificationFrequency - EndUserSpamNotificationLanguage = $HostedContentFilterPolicy.EndUserSpamNotificationLanguage - HighConfidenceSpamAction = $HostedContentFilterPolicy.HighConfidenceSpamAction - InlineSafetyTipsEnabled = $HostedContentFilterPolicy.InlineSafetyTipsEnabled - IncreaseScoreWithBizOrInfoUrls = $HostedContentFilterPolicy.IncreaseScoreWithBizOrInfoUrls - IncreaseScoreWithImageLinks = $HostedContentFilterPolicy.IncreaseScoreWithImageLinks - IncreaseScoreWithNumericIps = $HostedContentFilterPolicy.IncreaseScoreWithNumericIps - IncreaseScoreWithRedirectToOtherPort = $HostedContentFilterPolicy.IncreaseScoreWithRedirectToOtherPort - LanguageBlockList = $HostedContentFilterPolicy.LanguageBlockList - MakeDefault = $false - MarkAsSpamBulkMail = $HostedContentFilterPolicy.MarkAsSpamBulkMail - MarkAsSpamEmbedTagsInHtml = $HostedContentFilterPolicy.MarkAsSpamEmbedTagsInHtml - MarkAsSpamEmptyMessages = $HostedContentFilterPolicy.MarkAsSpamEmptyMessages - MarkAsSpamFormTagsInHtml = $HostedContentFilterPolicy.MarkAsSpamFormTagsInHtml - MarkAsSpamFramesInHtml = $HostedContentFilterPolicy.MarkAsSpamFramesInHtml - MarkAsSpamFromAddressAuthFail = $HostedContentFilterPolicy.MarkAsSpamFromAddressAuthFail - MarkAsSpamJavaScriptInHtml = $HostedContentFilterPolicy.MarkAsSpamJavaScriptInHtml - MarkAsSpamNdrBackscatter = $HostedContentFilterPolicy.MarkAsSpamNdrBackscatter - MarkAsSpamObjectTagsInHtml = $HostedContentFilterPolicy.MarkAsSpamObjectTagsInHtml - MarkAsSpamSensitiveWordList = $HostedContentFilterPolicy.MarkAsSpamSensitiveWordList - MarkAsSpamSpfRecordHardFail = $HostedContentFilterPolicy.MarkAsSpamSpfRecordHardFail - MarkAsSpamWebBugsInHtml = $HostedContentFilterPolicy.MarkAsSpamWebBugsInHtml - ModifySubjectValue = $HostedContentFilterPolicy.ModifySubjectValue - PhishSpamAction = $HostedContentFilterPolicy.PhishSpamAction - QuarantineRetentionPeriod = $HostedContentFilterPolicy.QuarantineRetentionPeriod - RedirectToRecipients = $HostedContentFilterPolicy.RedirectToRecipients - RegionBlockList = $HostedContentFilterPolicy.RegionBlockList - SpamAction = $HostedContentFilterPolicy.SpamAction - TestModeAction = $HostedContentFilterPolicy.TestModeAction - TestModeBccToRecipients = $HostedContentFilterPolicy.TestModeBccToRecipients - PhishZapEnabled = $HostedContentFilterPolicy.PhishZapEnabled - SpamZapEnabled = $HostedContentFilterPolicy.SpamZapEnabled - GlobalAdminAccount = $GlobalAdminAccount + Ensure = 'Present' + Identity = $Identity + AddXHeaderValue = $HostedContentFilterPolicy.AddXHeaderValue + AdminDisplayName = $HostedContentFilterPolicy.AdminDisplayName + AllowedSenderDomains = $HostedContentFilterPolicy.AllowedSenderDomains + AllowedSenders = $HostedContentFilterPolicy.AllowedSenders + BlockedSenderDomains = $HostedContentFilterPolicy.BlockedSenderDomains + BlockedSenders = $HostedContentFilterPolicy.BlockedSenders + BulkSpamAction = $HostedContentFilterPolicy.BulkSpamAction + BulkThreshold = $HostedContentFilterPolicy.BulkThreshold + DownloadLink = $HostedContentFilterPolicy.DownloadLink + EnableEndUserSpamNotifications = $HostedContentFilterPolicy.EnableEndUserSpamNotifications + EnableLanguageBlockList = $HostedContentFilterPolicy.EnableLanguageBlockList + EnableRegionBlockList = $HostedContentFilterPolicy.EnableRegionBlockList + EndUserSpamNotificationCustomSubject = $HostedContentFilterPolicy.EndUserSpamNotificationCustomSubject + EndUserSpamNotificationFrequency = $HostedContentFilterPolicy.EndUserSpamNotificationFrequency + EndUserSpamNotificationLanguage = $HostedContentFilterPolicy.EndUserSpamNotificationLanguage + HighConfidenceSpamAction = $HostedContentFilterPolicy.HighConfidenceSpamAction + InlineSafetyTipsEnabled = $HostedContentFilterPolicy.InlineSafetyTipsEnabled + IncreaseScoreWithBizOrInfoUrls = $HostedContentFilterPolicy.IncreaseScoreWithBizOrInfoUrls + IncreaseScoreWithImageLinks = $HostedContentFilterPolicy.IncreaseScoreWithImageLinks + IncreaseScoreWithNumericIps = $HostedContentFilterPolicy.IncreaseScoreWithNumericIps + IncreaseScoreWithRedirectToOtherPort = $HostedContentFilterPolicy.IncreaseScoreWithRedirectToOtherPort + LanguageBlockList = $HostedContentFilterPolicy.LanguageBlockList + MakeDefault = $false + MarkAsSpamBulkMail = $HostedContentFilterPolicy.MarkAsSpamBulkMail + MarkAsSpamEmbedTagsInHtml = $HostedContentFilterPolicy.MarkAsSpamEmbedTagsInHtml + MarkAsSpamEmptyMessages = $HostedContentFilterPolicy.MarkAsSpamEmptyMessages + MarkAsSpamFormTagsInHtml = $HostedContentFilterPolicy.MarkAsSpamFormTagsInHtml + MarkAsSpamFramesInHtml = $HostedContentFilterPolicy.MarkAsSpamFramesInHtml + MarkAsSpamFromAddressAuthFail = $HostedContentFilterPolicy.MarkAsSpamFromAddressAuthFail + MarkAsSpamJavaScriptInHtml = $HostedContentFilterPolicy.MarkAsSpamJavaScriptInHtml + MarkAsSpamNdrBackscatter = $HostedContentFilterPolicy.MarkAsSpamNdrBackscatter + MarkAsSpamObjectTagsInHtml = $HostedContentFilterPolicy.MarkAsSpamObjectTagsInHtml + MarkAsSpamSensitiveWordList = $HostedContentFilterPolicy.MarkAsSpamSensitiveWordList + MarkAsSpamSpfRecordHardFail = $HostedContentFilterPolicy.MarkAsSpamSpfRecordHardFail + MarkAsSpamWebBugsInHtml = $HostedContentFilterPolicy.MarkAsSpamWebBugsInHtml + ModifySubjectValue = $HostedContentFilterPolicy.ModifySubjectValue + PhishSpamAction = $HostedContentFilterPolicy.PhishSpamAction + QuarantineRetentionPeriod = $HostedContentFilterPolicy.QuarantineRetentionPeriod + RedirectToRecipients = $HostedContentFilterPolicy.RedirectToRecipients + RegionBlockList = $HostedContentFilterPolicy.RegionBlockList + SpamAction = $HostedContentFilterPolicy.SpamAction + TestModeAction = $HostedContentFilterPolicy.TestModeAction + TestModeBccToRecipients = $HostedContentFilterPolicy.TestModeBccToRecipients + PhishZapEnabled = $HostedContentFilterPolicy.PhishZapEnabled + SpamZapEnabled = $HostedContentFilterPolicy.SpamZapEnabled + GlobalAdminAccount = $GlobalAdminAccount } if ($HostedContentFilterPolicy.IsDefault) @@ -437,15 +426,6 @@ function Set-TargetResource [System.Boolean] $EnableRegionBlockList = $false, - [Parameter()] - [ValidatePattern("^$|^[a-zA-Z0-9.!£#$%&'^_`{}~-]+@[a-zA-Z0-9-]+(?:\.[a-zA-Z0-9-]+)*$")] - [System.String] - $EndUserSpamNotificationCustomFromAddress, - - [Parameter()] - [System.String] - $EndUserSpamNotificationCustomFromName, - [Parameter()] [System.String] $EndUserSpamNotificationCustomSubject, @@ -741,15 +721,6 @@ function Test-TargetResource [System.Boolean] $EnableRegionBlockList = $false, - [Parameter()] - [ValidatePattern("^$|^[a-zA-Z0-9.!£#$%&'^_`{}~-]+@[a-zA-Z0-9-]+(?:\.[a-zA-Z0-9-]+)*$")] - [System.String] - $EndUserSpamNotificationCustomFromAddress, - - [Parameter()] - [System.String] - $EndUserSpamNotificationCustomFromName, - [Parameter()] [System.String] $EndUserSpamNotificationCustomSubject, diff --git a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.schema.mof b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.schema.mof index 86b8c97ef2..ca622ef8b0 100644 --- a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.schema.mof +++ b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.schema.mof @@ -14,8 +14,6 @@ class MSFT_EXOHostedContentFilterPolicy : OMI_BaseResource [Write, Description("The EnableEndUserSpamNotification parameter enables for disables sending end-user spam quarantine notification messages. Valid input for this parameter is $true or $false. The default value is $false.")] Boolean EnableEndUserSpamNotifications; [Write, Description("The EnableLanguageBlockList parameter enables or disables blocking email messages that are written in specific languages, regardless of the message contents. Valid input for this parameter is $true or $false. The default value is $false.")] Boolean EnableLanguageBlockList; [Write, Description("The EnableRegionBlockList parameter enables or disables blocking email messages that are sent from specific countries or regions, regardless of the message contents. Valid input for this parameter is $true or $false. The default value is $false.")] Boolean EnableRegionBlockList; - [Write, Description("The EndUserSpamNotificationCustomFromAddress parameter specifies a custom From address for end-user spam notification messages. Valid input for this parameter is an SMTP email address or an empty string.")] String EndUserSpamNotificationCustomFromAddress; - [Write, Description("The EndUserSpamNotificationCustomFromName parameter specifies a custom display name in the From field for end-user spam notification messages. ")] String EndUserSpamNotificationCustomFromName; [Write, Description("The EndUserSpamNotificationCustomSubject parameter specifies a custom subject for end-user spam notification messages.")] String EndUserSpamNotificationCustomSubject; [Write, Description("The EndUserSpamNotificationFrequency parameter specifies the repeat interval in days that end-user spam notification messages are sent. Valid input for this parameter is an integer between 1 and 15. The default value is 3.")] UInt32 EndUserSpamNotificationFrequency; [Write, Description("The EndUserSpamNotificationLanguage parameter specifies the language of end-user spam notification messages. The default value is Default. This means the default language of end-user spam notification messages is the default language of the cloud-based organization."), ValueMap{"Default","English","French","German","Italian","Japanese","Spanish","Korean","Portuguese","Russian","ChineseSimplified","ChineseTraditional","Amharic","Arabic","Bulgarian","BengaliIndia","Catalan","Czech","Cyrillic","Danish","Greek","Estonian","Basque","Farsi","Finnish","Filipino","Galician","Gujarati","Hebrew","Hindi","Croatian","Hungarian","Indonesian","Icelandic","Kazakh","Kannada","Lithuanian","Latvian","Malayalam","Marathi","Malay","Dutch","NorwegianNynorsk","Norwegian","Oriya","Polish","PortuguesePortugal","Romanian","Slovak","Slovenian","SerbianCyrillic","Serbian","Swedish","Swahili","Tamil","Telugu","Thai","Turkish","Ukrainian","Urdu","Vietnamese"}, Values{"Default","English","French","German","Italian","Japanese","Spanish","Korean","Portuguese","Russian","ChineseSimplified","ChineseTraditional","Amharic","Arabic","Bulgarian","BengaliIndia","Catalan","Czech","Cyrillic","Danish","Greek","Estonian","Basque","Farsi","Finnish","Filipino","Galician","Gujarati","Hebrew","Hindi","Croatian","Hungarian","Indonesian","Icelandic","Kazakh","Kannada","Lithuanian","Latvian","Malayalam","Marathi","Malay","Dutch","NorwegianNynorsk","Norwegian","Oriya","Polish","PortuguesePortugal","Romanian","Slovak","Slovenian","SerbianCyrillic","Serbian","Swedish","Swahili","Tamil","Telugu","Thai","Turkish","Ukrainian","Urdu","Vietnamese"}] String EndUserSpamNotificationLanguage; diff --git a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/readme.md b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/readme.md index 2f90ecab70..00efbc356f 100644 --- a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/readme.md +++ b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/readme.md @@ -68,8 +68,6 @@ EXOHostedContentFilterPolicy TestHostedContentFilterPolicy { DownloadLink = $false EnableRegionBlockList = $true EnableLanguageBlockList = $true - EndUserSpamNotificationCustomFromAddress = 'Spam@contoso.com' - EndUserSpamNotificationCustomFromName = 'Spam Notification' EndUserSpamNotificationCustomSubject = 'This is SPAM' EndUserSpamNotificationLanguage = 'Default' BulkThreshold = 5 @@ -77,8 +75,9 @@ EXOHostedContentFilterPolicy TestHostedContentFilterPolicy { AllowedSenderDomains = @('contoso.com', 'fabrikam.com') BlockedSenders = @('me@privacy.net', 'thedude@contoso.com') BlockedSenderDomains = @('privacy.net', 'facebook.com') - ZapEnabled = $true InlineSafetyTipsEnabled = $true + PhishZapEnabled = $true + SpamZapEnabled = $true BulkSpamAction = 'MoveToJmf' PhishSpamAction = 'Quarantine' MakeDefault = $false From 900189b8e3ad384e0d835f1badd92bc59535b1f6 Mon Sep 17 00:00:00 2001 From: Swampen Date: Tue, 22 Dec 2020 05:21:55 -0800 Subject: [PATCH 02/21] Added option to sort properties in DSC report --- .../Microsoft365DSC/Modules/M365DSCReport.psm1 | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/Modules/Microsoft365DSC/Modules/M365DSCReport.psm1 b/Modules/Microsoft365DSC/Modules/M365DSCReport.psm1 index 258af2bc03..340d7f6f80 100644 --- a/Modules/Microsoft365DSC/Modules/M365DSCReport.psm1 +++ b/Modules/Microsoft365DSC/Modules/M365DSCReport.psm1 @@ -8,7 +8,11 @@ function New-M365DSCConfigurationToHTML [Parameter(Mandatory = $true)] [System.String] - $OutputPath + $OutputPath, + + [Parameter()] + [Switch] + $SortProperties ) $TemplateFile = Get-Item $ConfigurationPath @@ -29,7 +33,16 @@ function New-M365DSCConfigurationToHTML $partHTML += "" + $resource.ResourceName + "" $partHTML += "" - foreach ($property in $resource.Keys) + if ($SortProperties) + { + $properties = $resource.Keys | Sort-Object + } + else + { + $properties = $resource.Keys + } + + foreach ($property in $properties) { if ($property -ne "ResourceName" -and $property -ne "GlobalAdminAccount") { From a8cce80fc73f5da4bb08b32414f463b32ee73936 Mon Sep 17 00:00:00 2001 From: Swampen Date: Tue, 22 Dec 2020 07:38:42 -0800 Subject: [PATCH 03/21] Added parameters back to Get-TargetResource --- .../MSFT_EXOHostedContentFilterPolicy.psm1 | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.psm1 b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.psm1 index d63788979a..101dc12613 100644 --- a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.psm1 +++ b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.psm1 @@ -58,6 +58,15 @@ function Get-TargetResource [System.Boolean] $EnableRegionBlockList = $false, + [Parameter()] + [ValidatePattern("^$|^[a-zA-Z0-9.!£#$%&'^_`{}~-]+@[a-zA-Z0-9-]+(?:\.[a-zA-Z0-9-]+)*$")] + [System.String] + $EndUserSpamNotificationCustomFromAddress, + + [Parameter()] + [System.String] + $EndUserSpamNotificationCustomFromName, + [Parameter()] [System.String] $EndUserSpamNotificationCustomSubject, From 3cad73d5a53efbfcabff35f111dcb56ce2b118bf Mon Sep 17 00:00:00 2001 From: Swampen Date: Tue, 22 Dec 2020 07:40:35 -0800 Subject: [PATCH 04/21] Added parameters back to Set-TargetResource --- .../MSFT_EXOHostedContentFilterPolicy.psm1 | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.psm1 b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.psm1 index 101dc12613..0127ef03bd 100644 --- a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.psm1 +++ b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.psm1 @@ -435,6 +435,15 @@ function Set-TargetResource [System.Boolean] $EnableRegionBlockList = $false, + [Parameter()] + [ValidatePattern("^$|^[a-zA-Z0-9.!£#$%&'^_`{}~-]+@[a-zA-Z0-9-]+(?:\.[a-zA-Z0-9-]+)*$")] + [System.String] + $EndUserSpamNotificationCustomFromAddress, + + [Parameter()] + [System.String] + $EndUserSpamNotificationCustomFromName, + [Parameter()] [System.String] $EndUserSpamNotificationCustomSubject, From b067a0671425fa5217b4fe857f69682f736a1c80 Mon Sep 17 00:00:00 2001 From: Swampen Date: Tue, 22 Dec 2020 07:44:54 -0800 Subject: [PATCH 05/21] Removed parameters from the parameter set in Set-TargetResource --- .../MSFT_EXOHostedContentFilterPolicy.psm1 | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.psm1 b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.psm1 index 0127ef03bd..5230adea1e 100644 --- a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.psm1 +++ b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.psm1 @@ -651,6 +651,9 @@ function Set-TargetResource $HostedContentFilterPolicyParams.Remove('GlobalAdminAccount') | Out-Null $HostedContentFilterPolicyParams.Remove('MakeDefault') | Out-Null + $HostedContentFilterPolicyParams.Remove('EndUserSpamNotificationCustomFromAddress') | Out-Null + $HostedContentFilterPolicyParams.Remove('EndUserSpamNotificationCustomFromName') | Out-Null + if (('Present' -eq $Ensure ) -and ($null -eq $HostedContentFilterPolicy)) { $HostedContentFilterPolicyParams += @{ From ef7d97cc8ca4cb3c27aa007c4b5b827a290713f0 Mon Sep 17 00:00:00 2001 From: Swampen Date: Tue, 22 Dec 2020 08:01:30 -0800 Subject: [PATCH 06/21] Added logging for removal of depricated --- .../MSFT_EXOHostedContentFilterPolicy.psm1 | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.psm1 b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.psm1 index 5230adea1e..b99d252101 100644 --- a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.psm1 +++ b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.psm1 @@ -651,8 +651,16 @@ function Set-TargetResource $HostedContentFilterPolicyParams.Remove('GlobalAdminAccount') | Out-Null $HostedContentFilterPolicyParams.Remove('MakeDefault') | Out-Null - $HostedContentFilterPolicyParams.Remove('EndUserSpamNotificationCustomFromAddress') | Out-Null - $HostedContentFilterPolicyParams.Remove('EndUserSpamNotificationCustomFromName') | Out-Null + if ($HostedContentFilterPolicyParams.Contains('EndUserSpamNotificationCustomFromAddress')) + { + $HostedContentFilterPolicyParams.Remove('EndUserSpamNotificationCustomFromAddress') | Out-Null + Write-Verbose -Message "The EndUserSpamNotificationCustomFromAddress parameter is no longer available and will be depricated." + } + if ($HostedContentFilterPolicyParams.Contains('EndUserSpamNotificationCustomFromAddress')) + { + $HostedContentFilterPolicyParams.Remove('EndUserSpamNotificationCustomFromName') | Out-Null + Write-Verbose -Message "The EndUserSpamNotificationCustomFromName parameter is no longer available and will be depricated." + } if (('Present' -eq $Ensure ) -and ($null -eq $HostedContentFilterPolicy)) { From a452405db680b9f8e1124e524f52d0c272f84bb0 Mon Sep 17 00:00:00 2001 From: Swampen Date: Tue, 22 Dec 2020 08:06:32 -0800 Subject: [PATCH 07/21] Added parameters back in Test-TargetResource --- .../MSFT_EXOHostedContentFilterPolicy.psm1 | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.psm1 b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.psm1 index b99d252101..ef752d7d05 100644 --- a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.psm1 +++ b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.psm1 @@ -750,6 +750,15 @@ function Test-TargetResource [System.Boolean] $EnableRegionBlockList = $false, + [Parameter()] + [ValidatePattern("^$|^[a-zA-Z0-9.!£#$%&'^_`{}~-]+@[a-zA-Z0-9-]+(?:\.[a-zA-Z0-9-]+)*$")] + [System.String] + $EndUserSpamNotificationCustomFromAddress, + + [Parameter()] + [System.String] + $EndUserSpamNotificationCustomFromName, + [Parameter()] [System.String] $EndUserSpamNotificationCustomSubject, From 10ab352ec39b972480327394754eb3a281563521 Mon Sep 17 00:00:00 2001 From: Swampen Date: Tue, 22 Dec 2020 08:07:15 -0800 Subject: [PATCH 08/21] Removed parameters to be evaluated --- .../MSFT_EXOHostedContentFilterPolicy.psm1 | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.psm1 b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.psm1 index ef752d7d05..c9fe2d5e1b 100644 --- a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.psm1 +++ b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.psm1 @@ -962,6 +962,8 @@ function Test-TargetResource $ValuesToCheck = $PSBoundParameters $ValuesToCheck.Remove('GlobalAdminAccount') | Out-Null + $ValuesToCheck.Remove('EndUserSpamNotificationCustomFromAddress') | Out-Null + $ValuesToCheck.Remove('EndUserSpamNotificationCustomFromName') | Out-Null $TestResult = Test-M365DSCParameterState -CurrentValues $CurrentValues ` -Source $($MyInvocation.MyCommand.Source) ` From 98de2b778a5e80ba860001817072e21033f82b22 Mon Sep 17 00:00:00 2001 From: Ole-Martin Heggen Date: Tue, 5 Jan 2021 12:28:24 +0100 Subject: [PATCH 09/21] Changed check for SharingAllow/BlockDomainList --- .../MSFT_SPOSharingSettings/MSFT_SPOSharingSettings.psm1 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Modules/Microsoft365DSC/DSCResources/MSFT_SPOSharingSettings/MSFT_SPOSharingSettings.psm1 b/Modules/Microsoft365DSC/DSCResources/MSFT_SPOSharingSettings/MSFT_SPOSharingSettings.psm1 index 9d0d2aa623..ffcaf566cb 100644 --- a/Modules/Microsoft365DSC/DSCResources/MSFT_SPOSharingSettings/MSFT_SPOSharingSettings.psm1 +++ b/Modules/Microsoft365DSC/DSCResources/MSFT_SPOSharingSettings/MSFT_SPOSharingSettings.psm1 @@ -419,7 +419,7 @@ function Set-TargetResource Write-Verbose -Message "Configuring Tenant with: $value" } - if ($null -ne $SharingAllowedDomainList) + if ($null -ne $CurrentParameters["SharingAllowedDomainList"]) { foreach ($allowedDomain in $SharingAllowedDomainList) { @@ -429,7 +429,7 @@ function Set-TargetResource $CurrentParameters["SharingAllowedDomainList"] = $allowed.trim() } - if ($null -ne $SharingBlockedDomainList) + if ($null -ne $CurrentParameters["SharingBlockedDomainList"]) { foreach ($blockedDomain in $SharingBlockedDomainList) { From 385eb3cd2319b2143393faca6d806fae988fc78a Mon Sep 17 00:00:00 2001 From: Swampen Date: Wed, 6 Jan 2021 07:33:42 -0800 Subject: [PATCH 10/21] Updated description for depricated parameters --- .../MSFT_EXOHostedContentFilterPolicy.schema.mof | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.schema.mof b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.schema.mof index ca622ef8b0..ce1706ec31 100644 --- a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.schema.mof +++ b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOHostedContentFilterPolicy/MSFT_EXOHostedContentFilterPolicy.schema.mof @@ -14,6 +14,8 @@ class MSFT_EXOHostedContentFilterPolicy : OMI_BaseResource [Write, Description("The EnableEndUserSpamNotification parameter enables for disables sending end-user spam quarantine notification messages. Valid input for this parameter is $true or $false. The default value is $false.")] Boolean EnableEndUserSpamNotifications; [Write, Description("The EnableLanguageBlockList parameter enables or disables blocking email messages that are written in specific languages, regardless of the message contents. Valid input for this parameter is $true or $false. The default value is $false.")] Boolean EnableLanguageBlockList; [Write, Description("The EnableRegionBlockList parameter enables or disables blocking email messages that are sent from specific countries or regions, regardless of the message contents. Valid input for this parameter is $true or $false. The default value is $false.")] Boolean EnableRegionBlockList; + [Write, Description("This parameter has been deprecated and is no longer used. The EndUserSpamNotificationCustomFromAddress parameter specifies a custom From address for end-user spam notification messages. Valid input for this parameter is an SMTP email address or an empty string.")] String EndUserSpamNotificationCustomFromAddress; + [Write, Description("This parameter has been deprecated and is no longer used. The EndUserSpamNotificationCustomFromName parameter specifies a custom display name in the From field for end-user spam notification messages. ")] String EndUserSpamNotificationCustomFromName; [Write, Description("The EndUserSpamNotificationCustomSubject parameter specifies a custom subject for end-user spam notification messages.")] String EndUserSpamNotificationCustomSubject; [Write, Description("The EndUserSpamNotificationFrequency parameter specifies the repeat interval in days that end-user spam notification messages are sent. Valid input for this parameter is an integer between 1 and 15. The default value is 3.")] UInt32 EndUserSpamNotificationFrequency; [Write, Description("The EndUserSpamNotificationLanguage parameter specifies the language of end-user spam notification messages. The default value is Default. This means the default language of end-user spam notification messages is the default language of the cloud-based organization."), ValueMap{"Default","English","French","German","Italian","Japanese","Spanish","Korean","Portuguese","Russian","ChineseSimplified","ChineseTraditional","Amharic","Arabic","Bulgarian","BengaliIndia","Catalan","Czech","Cyrillic","Danish","Greek","Estonian","Basque","Farsi","Finnish","Filipino","Galician","Gujarati","Hebrew","Hindi","Croatian","Hungarian","Indonesian","Icelandic","Kazakh","Kannada","Lithuanian","Latvian","Malayalam","Marathi","Malay","Dutch","NorwegianNynorsk","Norwegian","Oriya","Polish","PortuguesePortugal","Romanian","Slovak","Slovenian","SerbianCyrillic","Serbian","Swedish","Swahili","Tamil","Telugu","Thai","Turkish","Ukrainian","Urdu","Vietnamese"}, Values{"Default","English","French","German","Italian","Japanese","Spanish","Korean","Portuguese","Russian","ChineseSimplified","ChineseTraditional","Amharic","Arabic","Bulgarian","BengaliIndia","Catalan","Czech","Cyrillic","Danish","Greek","Estonian","Basque","Farsi","Finnish","Filipino","Galician","Gujarati","Hebrew","Hindi","Croatian","Hungarian","Indonesian","Icelandic","Kazakh","Kannada","Lithuanian","Latvian","Malayalam","Marathi","Malay","Dutch","NorwegianNynorsk","Norwegian","Oriya","Polish","PortuguesePortugal","Romanian","Slovak","Slovenian","SerbianCyrillic","Serbian","Swedish","Swahili","Tamil","Telugu","Thai","Turkish","Ukrainian","Urdu","Vietnamese"}] String EndUserSpamNotificationLanguage; From 1c17cffa84099abe77e444be41a0ad786637fc34 Mon Sep 17 00:00:00 2001 From: Nik Charlebois Date: Thu, 7 Jan 2021 15:46:04 -0500 Subject: [PATCH 11/21] Updated Microsoft.PowerApps.Administration.PowerShell --- CHANGELOG.md | 6 ++++++ Modules/Microsoft365DSC/Microsoft365DSC.psd1 | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 1ab60c5672..cff0bce255 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,11 @@ # Change log for Microsoft365DSC +# 1.21.113.1 + +* DEPENDENCIES + * Updated Microsoft.PowerApps.Administration.PowerShell + to 2.0.102; + # 1.20.1223.1 * SPOHubSite diff --git a/Modules/Microsoft365DSC/Microsoft365DSC.psd1 b/Modules/Microsoft365DSC/Microsoft365DSC.psd1 index d5bc651020..c1eeaa97f6 100644 --- a/Modules/Microsoft365DSC/Microsoft365DSC.psd1 +++ b/Modules/Microsoft365DSC/Microsoft365DSC.psd1 @@ -89,7 +89,7 @@ }, @{ ModuleName = "Microsoft.PowerApps.Administration.PowerShell" - RequiredVersion = "2.0.99" + RequiredVersion = "2.0.102" }, @{ ModuleName = "MicrosoftTeams" From 01bbb3ae0f66f402ca812c83dec9888f2d0d469e Mon Sep 17 00:00:00 2001 From: Swampen Date: Fri, 8 Jan 2021 09:53:21 -0800 Subject: [PATCH 12/21] Fixed TargetedUserActionRecipients parameter not being set --- .../MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.psm1 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.psm1 b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.psm1 index d748eae862..8dfe4b3c4c 100644 --- a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.psm1 +++ b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.psm1 @@ -192,7 +192,7 @@ function Get-TargetResource MakeDefault = $AntiPhishPolicy.MakeDefault PhishThresholdLevel = $PhishThresholdLevelValue TargetedDomainActionRecipients = $AntiPhishPolicy.TargetedDomainActionRecipients - TargetedDomainProtectionAction = $TargetedDomainProtectionAction + TargetedDomainProtectionAction = $AntiPhishPolicy.TargetedDomainProtectionAction TargetedDomainsToProtect = $AntiPhishPolicy.TargetedDomainsToProtect TargetedUserActionRecipients = $AntiPhishPolicy.TargetedUserActionRecipients TargetedUserProtectionAction = $TargetedUserProtectionActionValue From d7591aa0167a5ee38f56374c6125f0eebe0fdc6a Mon Sep 17 00:00:00 2001 From: Swampen Date: Fri, 8 Jan 2021 10:01:09 -0800 Subject: [PATCH 13/21] Added EnableMailboxIntelligenceProtection parameter --- .../MSFT_EXOAntiPhishPolicy.psm1 | 13 +++++++++++++ .../MSFT_EXOAntiPhishPolicy.schema.mof | 1 + 2 files changed, 14 insertions(+) diff --git a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.psm1 b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.psm1 index 8dfe4b3c4c..7af8dad5a4 100644 --- a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.psm1 +++ b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.psm1 @@ -29,6 +29,10 @@ function Get-TargetResource [System.Boolean] $EnableMailboxIntelligence = $true, + [Parameter()] + [System.Boolean] + $EnableMailboxIntelligenceProtection = $true, + [Parameter()] [System.Boolean] $EnableOrganizationDomainsProtection = $false, @@ -181,6 +185,7 @@ function Get-TargetResource Enabled = $AntiPhishPolicy.Enabled EnableAntispoofEnforcement = $AntiPhishPolicy.EnableAntispoofEnforcement EnableMailboxIntelligence = $AntiPhishPolicy.EnableMailboxIntelligence + EnableMailboxIntelligenceProtection = $AntiPhishPolicy.EnableMailboxIntelligenceProtection EnableOrganizationDomainsProtection = $AntiPhishPolicy.EnableOrganizationDomainsProtection EnableSimilarDomainsSafetyTips = $AntiPhishPolicy.EnableSimilarDomainsSafetyTips EnableSimilarUsersSafetyTips = $AntiPhishPolicy.EnableSimilarUsersSafetyTips @@ -262,6 +267,10 @@ function Set-TargetResource [System.Boolean] $EnableMailboxIntelligence = $true, + [Parameter()] + [System.Boolean] + $EnableMailboxIntelligenceProtection = $true, + [Parameter()] [System.Boolean] $EnableOrganizationDomainsProtection = $false, @@ -430,6 +439,10 @@ function Test-TargetResource [System.Boolean] $EnableMailboxIntelligence = $true, + [Parameter()] + [System.Boolean] + $EnableMailboxIntelligenceProtection = $true, + [Parameter()] [System.Boolean] $EnableOrganizationDomainsProtection = $false, diff --git a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.schema.mof b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.schema.mof index 14c69cd179..867b3caae8 100644 --- a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.schema.mof +++ b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.schema.mof @@ -11,6 +11,7 @@ class MSFT_EXOAntiPhishPolicy : OMI_BaseResource [Write, Description("Specify if this policy should be enabled. Default is $true.")] Boolean Enabled; [Write, Description("The EnableAntispoofEnforcement parameter specifies whether to enable or disable antispoofing protection for the policy.")] Boolean EnableAntispoofEnforcement; [Write, Description("The EnableMailboxIntelligence parameter specifies whether to enable or disable mailbox intelligence (the first contact graph) in domain and user impersonation protection.")] Boolean EnableMailboxIntelligence; + [Write, Description("The EnableMailboxIntelligenceProtection specifies whether to enable or disable enhanced impersonation results based on each user's individual sender map. This intelligence allows Microsoft 365 to customize user impersonation detection and better handle false positives.")] Boolean EnableMailboxIntelligenceProtection; [Write, Description("The EnableOrganizationDomainsProtection parameter specifies whether to enable domain impersonation protection for all registered domains in the Office 365 organization.")] Boolean EnableOrganizationDomainsProtection; [Write, Description("The EnableSimilarDomainsSafetyTips parameter specifies whether to enable safety tips that are shown to recipients in messages for domain impersonation detections.")] Boolean EnableSimilarDomainsSafetyTips; [Write, Description("The EnableSimilarUsersSafetyTips parameter specifies whether to enable safety tips that are shown to recipients in messages for user impersonation detections.")] Boolean EnableSimilarUsersSafetyTips; From 9390b9b0c5999104a6f2320ca26c635cd98a5604 Mon Sep 17 00:00:00 2001 From: Swampen Date: Fri, 8 Jan 2021 10:10:11 -0800 Subject: [PATCH 14/21] Added EnableSpoofIntelligence parameter --- .../MSFT_EXOAntiPhishPolicy.psm1 | 13 +++++++++++++ .../MSFT_EXOAntiPhishPolicy.schema.mof | 1 + 2 files changed, 14 insertions(+) diff --git a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.psm1 b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.psm1 index 7af8dad5a4..5241029fb9 100644 --- a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.psm1 +++ b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.psm1 @@ -45,6 +45,10 @@ function Get-TargetResource [System.Boolean] $EnableSimilarUsersSafetyTips = $false, + [Parameter()] + [System.Boolean] + $EnableSpoofIntelligence = $true, + [Parameter()] [System.Boolean] $EnableTargetedDomainsProtection = $false, @@ -189,6 +193,7 @@ function Get-TargetResource EnableOrganizationDomainsProtection = $AntiPhishPolicy.EnableOrganizationDomainsProtection EnableSimilarDomainsSafetyTips = $AntiPhishPolicy.EnableSimilarDomainsSafetyTips EnableSimilarUsersSafetyTips = $AntiPhishPolicy.EnableSimilarUsersSafetyTips + EnableSpoofIntelligence = $AntiPhishPolicy.EnableSpoofIntelligence EnableTargetedDomainsProtection = $AntiPhishPolicy.EnableTargetedDomainsProtection EnableTargetedUserProtection = $AntiPhishPolicy.EnableTargetedUserProtection EnableUnusualCharactersSafetyTips = $AntiPhishPolicy.EnableUnusualCharactersSafetyTips @@ -283,6 +288,10 @@ function Set-TargetResource [System.Boolean] $EnableSimilarUsersSafetyTips = $false, + [Parameter()] + [System.Boolean] + $EnableSpoofIntelligence = $true, + [Parameter()] [System.Boolean] $EnableTargetedDomainsProtection = $false, @@ -455,6 +464,10 @@ function Test-TargetResource [System.Boolean] $EnableSimilarUsersSafetyTips = $false, + [Parameter()] + [System.Boolean] + $EnableSpoofIntelligence = $true, + [Parameter()] [System.Boolean] $EnableTargetedDomainsProtection = $false, diff --git a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.schema.mof b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.schema.mof index 867b3caae8..0e941e7000 100644 --- a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.schema.mof +++ b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.schema.mof @@ -15,6 +15,7 @@ class MSFT_EXOAntiPhishPolicy : OMI_BaseResource [Write, Description("The EnableOrganizationDomainsProtection parameter specifies whether to enable domain impersonation protection for all registered domains in the Office 365 organization.")] Boolean EnableOrganizationDomainsProtection; [Write, Description("The EnableSimilarDomainsSafetyTips parameter specifies whether to enable safety tips that are shown to recipients in messages for domain impersonation detections.")] Boolean EnableSimilarDomainsSafetyTips; [Write, Description("The EnableSimilarUsersSafetyTips parameter specifies whether to enable safety tips that are shown to recipients in messages for user impersonation detections.")] Boolean EnableSimilarUsersSafetyTips; + [Write, Description("The EnableSpoofIntelligence parameter specifies whether to enable or disable antispoofing protection for the policy.")] Boolean EnableSpoofIntelligence; [Write, Description("The EnableTargetedDomainsProtection parameter specifies whether to enable domain impersonation protection for a list of specified domains.")] Boolean EnableTargetedDomainsProtection; [Write, Description("The EnableTargetedUserProtection parameter specifies whether to enable user impersonation protection for the users specified by the TargetedUsersToProtect parameter")] Boolean EnableTargetedUserProtection; [Write, Description("The EnableUnusualCharactersSafetyTips parameter specifies whether to enable safety tips that are shown to recipients in messages for unusual characters in domain and user impersonation detections.")] Boolean EnableUnusualCharactersSafetyTips; From b3d6207799956d078461ed2587cf50e476017814 Mon Sep 17 00:00:00 2001 From: Swampen Date: Fri, 8 Jan 2021 10:10:58 -0800 Subject: [PATCH 15/21] Fixed EnableMailboxIntelligenceProtection default value --- .../MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.psm1 | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.psm1 b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.psm1 index 5241029fb9..da9ebb6182 100644 --- a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.psm1 +++ b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.psm1 @@ -31,7 +31,7 @@ function Get-TargetResource [Parameter()] [System.Boolean] - $EnableMailboxIntelligenceProtection = $true, + $EnableMailboxIntelligenceProtection = $false, [Parameter()] [System.Boolean] @@ -274,7 +274,7 @@ function Set-TargetResource [Parameter()] [System.Boolean] - $EnableMailboxIntelligenceProtection = $true, + $EnableMailboxIntelligenceProtection = $false, [Parameter()] [System.Boolean] @@ -450,7 +450,7 @@ function Test-TargetResource [Parameter()] [System.Boolean] - $EnableMailboxIntelligenceProtection = $true, + $EnableMailboxIntelligenceProtection = $false, [Parameter()] [System.Boolean] From 97de736441ef73fa52ff0858692609df81ff5e57 Mon Sep 17 00:00:00 2001 From: Swampen Date: Fri, 8 Jan 2021 10:15:24 -0800 Subject: [PATCH 16/21] Added EnableUnauthenticatedSender parameter --- .../MSFT_EXOAntiPhishPolicy.psm1 | 13 +++++++++++++ .../MSFT_EXOAntiPhishPolicy.schema.mof | 1 + 2 files changed, 14 insertions(+) diff --git a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.psm1 b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.psm1 index da9ebb6182..91ff165649 100644 --- a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.psm1 +++ b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.psm1 @@ -57,6 +57,10 @@ function Get-TargetResource [System.Boolean] $EnableTargetedUserProtection = $false, + [Parameter()] + [System.Boolean] + $EnableUnauthenticatedSender = $true, + [Parameter()] [System.Boolean] $EnableUnusualCharactersSafetyTips = $false, @@ -196,6 +200,7 @@ function Get-TargetResource EnableSpoofIntelligence = $AntiPhishPolicy.EnableSpoofIntelligence EnableTargetedDomainsProtection = $AntiPhishPolicy.EnableTargetedDomainsProtection EnableTargetedUserProtection = $AntiPhishPolicy.EnableTargetedUserProtection + EnableUnauthenticatedSender = $AntiPhishPolicy.EnableUnauthenticatedSender EnableUnusualCharactersSafetyTips = $AntiPhishPolicy.EnableUnusualCharactersSafetyTips ExcludedDomains = $AntiPhishPolicy.ExcludedDomains ExcludedSenders = $AntiPhishPolicy.ExcludedSenders @@ -300,6 +305,10 @@ function Set-TargetResource [System.Boolean] $EnableTargetedUserProtection = $false, + [Parameter()] + [System.Boolean] + $EnableUnauthenticatedSender = $true, + [Parameter()] [System.Boolean] $EnableUnusualCharactersSafetyTips = $false, @@ -476,6 +485,10 @@ function Test-TargetResource [System.Boolean] $EnableTargetedUserProtection = $false, + [Parameter()] + [System.Boolean] + $EnableUnauthenticatedSender = $true, + [Parameter()] [System.Boolean] $EnableUnusualCharactersSafetyTips = $false, diff --git a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.schema.mof b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.schema.mof index 0e941e7000..91daedc663 100644 --- a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.schema.mof +++ b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.schema.mof @@ -18,6 +18,7 @@ class MSFT_EXOAntiPhishPolicy : OMI_BaseResource [Write, Description("The EnableSpoofIntelligence parameter specifies whether to enable or disable antispoofing protection for the policy.")] Boolean EnableSpoofIntelligence; [Write, Description("The EnableTargetedDomainsProtection parameter specifies whether to enable domain impersonation protection for a list of specified domains.")] Boolean EnableTargetedDomainsProtection; [Write, Description("The EnableTargetedUserProtection parameter specifies whether to enable user impersonation protection for the users specified by the TargetedUsersToProtect parameter")] Boolean EnableTargetedUserProtection; + [Write, Description("The EnableUnauthenticatedSender parameter enables or disables unauthenticated sender identification in Outlook.")] Boolean EnableUnauthenticatedSender; [Write, Description("The EnableUnusualCharactersSafetyTips parameter specifies whether to enable safety tips that are shown to recipients in messages for unusual characters in domain and user impersonation detections.")] Boolean EnableUnusualCharactersSafetyTips; [Write, Description("Make this the default antiphishing policy")] Boolean MakeDefault; [Write, Description("The ExcludedDomains parameter specifies trusted domains that are excluded from scanning by antiphishing protection. You can specify multiple domains separated by commas.")] String ExcludedDomains[]; From 07cb9da65525e6dbf204710b0c41fdd3be6e6667 Mon Sep 17 00:00:00 2001 From: Swampen Date: Fri, 8 Jan 2021 10:26:35 -0800 Subject: [PATCH 17/21] Added ImpersonationProtectionState parameter --- .../MSFT_EXOAntiPhishPolicy.psm1 | 16 ++++++++++++++++ .../MSFT_EXOAntiPhishPolicy.schema.mof | 1 + 2 files changed, 17 insertions(+) diff --git a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.psm1 b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.psm1 index 91ff165649..0fc9eeb133 100644 --- a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.psm1 +++ b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.psm1 @@ -78,6 +78,11 @@ function Get-TargetResource [System.String[]] $ExcludedSenders = @(), + [Parameter()] + [ValidateSet('Automatic', 'Manual', 'Off')] + [System.String] + $ImpersonationProtectionState = 'Automatic', + [Parameter()] [System.Boolean] $MakeDefault = $false, @@ -204,6 +209,7 @@ function Get-TargetResource EnableUnusualCharactersSafetyTips = $AntiPhishPolicy.EnableUnusualCharactersSafetyTips ExcludedDomains = $AntiPhishPolicy.ExcludedDomains ExcludedSenders = $AntiPhishPolicy.ExcludedSenders + ImpersonationProtectionState = $AntiPhishPolicy.ImpersonationProtectionState MakeDefault = $AntiPhishPolicy.MakeDefault PhishThresholdLevel = $PhishThresholdLevelValue TargetedDomainActionRecipients = $AntiPhishPolicy.TargetedDomainActionRecipients @@ -326,6 +332,11 @@ function Set-TargetResource [System.String[]] $ExcludedSenders = @(), + [Parameter()] + [ValidateSet('Automatic', 'Manual', 'Off')] + [System.String] + $ImpersonationProtectionState = 'Automatic', + [Parameter()] [System.Boolean] $MakeDefault = $false, @@ -506,6 +517,11 @@ function Test-TargetResource [System.String[]] $ExcludedSenders = @(), + [Parameter()] + [ValidateSet('Automatic', 'Manual', 'Off')] + [System.String] + $ImpersonationProtectionState = 'Automatic', + [Parameter()] [System.Boolean] $MakeDefault = $false, diff --git a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.schema.mof b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.schema.mof index 91daedc663..aa7c3b342a 100644 --- a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.schema.mof +++ b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.schema.mof @@ -23,6 +23,7 @@ class MSFT_EXOAntiPhishPolicy : OMI_BaseResource [Write, Description("Make this the default antiphishing policy")] Boolean MakeDefault; [Write, Description("The ExcludedDomains parameter specifies trusted domains that are excluded from scanning by antiphishing protection. You can specify multiple domains separated by commas.")] String ExcludedDomains[]; [Write, Description("The ExcludedSenders parameter specifies a list of trusted sender email addresses that are excluded from scanning by antiphishing protection. You can specify multiple email addresses separated by commas.")] String ExcludedSenders[]; + [Write, Description("The ImpersonationProtectionState parameter specifies the configuration of impersonation protection.")] String ImpersonationProtectionState; [Write, Description("The TargetedDomainActionRecipients parameter specifies the recipients to add to detected domain impersonation messages when the TargetedDomainProtectionAction parameter is set to the value Redirect or BccMessage. A valid value for this parameter is an email address. You can specify multiple email addresses separated by commas.")] String TargetedDomainActionRecipients[]; [Write, Description("The TargetedDomainsToProtect parameter specifies the domains that are included in domain impersonation protection when the EnableTargetedDomainsProtection parameter is set to $true.")] String TargetedDomainsToProtect[]; [Write, Description("The TargetedUserActionRecipients parameter specifies the replacement or additional recipients for detected user impersonation messages when the TargetedUserProtectionAction parameter is set to the value Redirect or BccMessage. A valid value for this parameter is an email address. You can specify multiple email addresses separated by commas.")] String TargetedUserActionRecipients[]; From a3198b330a7507d07be642c70d6c17e70dab0bcc Mon Sep 17 00:00:00 2001 From: Swampen Date: Fri, 8 Jan 2021 10:47:41 -0800 Subject: [PATCH 18/21] Added MailboxIntelligenceProtectionAction and MailboxIntelligenceProtectionActionRecipients parameter --- .../MSFT_EXOAntiPhishPolicy.psm1 | 85 +++++++++++++------ .../MSFT_EXOAntiPhishPolicy.schema.mof | 2 + 2 files changed, 59 insertions(+), 28 deletions(-) diff --git a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.psm1 b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.psm1 index 0fc9eeb133..dae871b827 100644 --- a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.psm1 +++ b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.psm1 @@ -83,6 +83,15 @@ function Get-TargetResource [System.String] $ImpersonationProtectionState = 'Automatic', + [Parameter()] + [ValidateSet('BccMessage', 'Delete', 'MoveToJmf', 'NoAction', 'Quarantine', 'Redirect')] + [System.String] + $MailboxIntelligenceProtectionAction = 'NoAction', + + [Parameter()] + [System.String[]] + $MailboxIntelligenceProtectionActionRecipients = @(), + [Parameter()] [System.Boolean] $MakeDefault = $false, @@ -192,34 +201,36 @@ function Get-TargetResource } $result = @{ - Identity = $Identity - AdminDisplayName = $AntiPhishPolicy.AdminDisplayName - AuthenticationFailAction = $AntiPhishPolicy.AuthenticationFailAction - Enabled = $AntiPhishPolicy.Enabled - EnableAntispoofEnforcement = $AntiPhishPolicy.EnableAntispoofEnforcement - EnableMailboxIntelligence = $AntiPhishPolicy.EnableMailboxIntelligence - EnableMailboxIntelligenceProtection = $AntiPhishPolicy.EnableMailboxIntelligenceProtection - EnableOrganizationDomainsProtection = $AntiPhishPolicy.EnableOrganizationDomainsProtection - EnableSimilarDomainsSafetyTips = $AntiPhishPolicy.EnableSimilarDomainsSafetyTips - EnableSimilarUsersSafetyTips = $AntiPhishPolicy.EnableSimilarUsersSafetyTips - EnableSpoofIntelligence = $AntiPhishPolicy.EnableSpoofIntelligence - EnableTargetedDomainsProtection = $AntiPhishPolicy.EnableTargetedDomainsProtection - EnableTargetedUserProtection = $AntiPhishPolicy.EnableTargetedUserProtection - EnableUnauthenticatedSender = $AntiPhishPolicy.EnableUnauthenticatedSender - EnableUnusualCharactersSafetyTips = $AntiPhishPolicy.EnableUnusualCharactersSafetyTips - ExcludedDomains = $AntiPhishPolicy.ExcludedDomains - ExcludedSenders = $AntiPhishPolicy.ExcludedSenders - ImpersonationProtectionState = $AntiPhishPolicy.ImpersonationProtectionState - MakeDefault = $AntiPhishPolicy.MakeDefault - PhishThresholdLevel = $PhishThresholdLevelValue - TargetedDomainActionRecipients = $AntiPhishPolicy.TargetedDomainActionRecipients - TargetedDomainProtectionAction = $AntiPhishPolicy.TargetedDomainProtectionAction - TargetedDomainsToProtect = $AntiPhishPolicy.TargetedDomainsToProtect - TargetedUserActionRecipients = $AntiPhishPolicy.TargetedUserActionRecipients - TargetedUserProtectionAction = $TargetedUserProtectionActionValue - TargetedUsersToProtect = $AntiPhishPolicy.TargetedUsersToProtect - GlobalAdminAccount = $GlobalAdminAccount - Ensure = 'Present' + Identity = $Identity + AdminDisplayName = $AntiPhishPolicy.AdminDisplayName + AuthenticationFailAction = $AntiPhishPolicy.AuthenticationFailAction + Enabled = $AntiPhishPolicy.Enabled + EnableAntispoofEnforcement = $AntiPhishPolicy.EnableAntispoofEnforcement + EnableMailboxIntelligence = $AntiPhishPolicy.EnableMailboxIntelligence + EnableMailboxIntelligenceProtection = $AntiPhishPolicy.EnableMailboxIntelligenceProtection + EnableOrganizationDomainsProtection = $AntiPhishPolicy.EnableOrganizationDomainsProtection + EnableSimilarDomainsSafetyTips = $AntiPhishPolicy.EnableSimilarDomainsSafetyTips + EnableSimilarUsersSafetyTips = $AntiPhishPolicy.EnableSimilarUsersSafetyTips + EnableSpoofIntelligence = $AntiPhishPolicy.EnableSpoofIntelligence + EnableTargetedDomainsProtection = $AntiPhishPolicy.EnableTargetedDomainsProtection + EnableTargetedUserProtection = $AntiPhishPolicy.EnableTargetedUserProtection + EnableUnauthenticatedSender = $AntiPhishPolicy.EnableUnauthenticatedSender + EnableUnusualCharactersSafetyTips = $AntiPhishPolicy.EnableUnusualCharactersSafetyTips + ExcludedDomains = $AntiPhishPolicy.ExcludedDomains + ExcludedSenders = $AntiPhishPolicy.ExcludedSenders + ImpersonationProtectionState = $AntiPhishPolicy.ImpersonationProtectionState + MailboxIntelligenceProtectionAction = $AntiPhishPolicy.MailboxIntelligenceProtectionAction + MailboxIntelligenceProtectionActionRecipients = $AntiPhishPolicy.MailboxIntelligenceProtectionActionRecipients + MakeDefault = $AntiPhishPolicy.MakeDefault + PhishThresholdLevel = $PhishThresholdLevelValue + TargetedDomainActionRecipients = $AntiPhishPolicy.TargetedDomainActionRecipients + TargetedDomainProtectionAction = $AntiPhishPolicy.TargetedDomainProtectionAction + TargetedDomainsToProtect = $AntiPhishPolicy.TargetedDomainsToProtect + TargetedUserActionRecipients = $AntiPhishPolicy.TargetedUserActionRecipients + TargetedUserProtectionAction = $TargetedUserProtectionActionValue + TargetedUsersToProtect = $AntiPhishPolicy.TargetedUsersToProtect + GlobalAdminAccount = $GlobalAdminAccount + Ensure = 'Present' } Write-Verbose -Message "Found AntiPhishPolicy $($Identity)" @@ -337,6 +348,15 @@ function Set-TargetResource [System.String] $ImpersonationProtectionState = 'Automatic', + [Parameter()] + [ValidateSet('BccMessage', 'Delete', 'MoveToJmf', 'NoAction', 'Quarantine', 'Redirect')] + [System.String] + $MailboxIntelligenceProtectionAction = 'NoAction', + + [Parameter()] + [System.String[]] + $MailboxIntelligenceProtectionActionRecipients = @(), + [Parameter()] [System.Boolean] $MakeDefault = $false, @@ -522,6 +542,15 @@ function Test-TargetResource [System.String] $ImpersonationProtectionState = 'Automatic', + [Parameter()] + [ValidateSet('BccMessage', 'Delete', 'MoveToJmf', 'NoAction', 'Quarantine', 'Redirect')] + [System.String] + $MailboxIntelligenceProtectionAction = 'NoAction', + + [Parameter()] + [System.String[]] + $MailboxIntelligenceProtectionActionRecipients = @(), + [Parameter()] [System.Boolean] $MakeDefault = $false, diff --git a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.schema.mof b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.schema.mof index aa7c3b342a..64fcdba84a 100644 --- a/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.schema.mof +++ b/Modules/Microsoft365DSC/DSCResources/MSFT_EXOAntiPhishPolicy/MSFT_EXOAntiPhishPolicy.schema.mof @@ -24,6 +24,8 @@ class MSFT_EXOAntiPhishPolicy : OMI_BaseResource [Write, Description("The ExcludedDomains parameter specifies trusted domains that are excluded from scanning by antiphishing protection. You can specify multiple domains separated by commas.")] String ExcludedDomains[]; [Write, Description("The ExcludedSenders parameter specifies a list of trusted sender email addresses that are excluded from scanning by antiphishing protection. You can specify multiple email addresses separated by commas.")] String ExcludedSenders[]; [Write, Description("The ImpersonationProtectionState parameter specifies the configuration of impersonation protection.")] String ImpersonationProtectionState; + [Write, Description("The MailboxIntelligenceProtectionAction parameter specifies what to do with messages that fail mailbox intelligence protection.")] String MailboxIntelligenceProtectionAction; + [Write, Description("The MailboxIntelligenceProtectionActionRecipients parameter specifies the recipients to add to detected messages when the MailboxIntelligenceProtectionAction parameter is set to the value Redirect or BccMessage.")] String MailboxIntelligenceProtectionActionRecipients[]; [Write, Description("The TargetedDomainActionRecipients parameter specifies the recipients to add to detected domain impersonation messages when the TargetedDomainProtectionAction parameter is set to the value Redirect or BccMessage. A valid value for this parameter is an email address. You can specify multiple email addresses separated by commas.")] String TargetedDomainActionRecipients[]; [Write, Description("The TargetedDomainsToProtect parameter specifies the domains that are included in domain impersonation protection when the EnableTargetedDomainsProtection parameter is set to $true.")] String TargetedDomainsToProtect[]; [Write, Description("The TargetedUserActionRecipients parameter specifies the replacement or additional recipients for detected user impersonation messages when the TargetedUserProtectionAction parameter is set to the value Redirect or BccMessage. A valid value for this parameter is an email address. You can specify multiple email addresses separated by commas.")] String TargetedUserActionRecipients[]; From 4a39f88d5c8aeed9e6e43578383109d83dcc2285 Mon Sep 17 00:00:00 2001 From: Derek Smay Date: Fri, 8 Jan 2021 14:31:00 -0500 Subject: [PATCH 19/21] Added error message for Skype locations --- .../MSFT_SCRetentionCompliancePolicy.psm1 | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Modules/Microsoft365DSC/DSCResources/MSFT_SCRetentionCompliancePolicy/MSFT_SCRetentionCompliancePolicy.psm1 b/Modules/Microsoft365DSC/DSCResources/MSFT_SCRetentionCompliancePolicy/MSFT_SCRetentionCompliancePolicy.psm1 index 3bfc875058..b75f0a1d47 100644 --- a/Modules/Microsoft365DSC/DSCResources/MSFT_SCRetentionCompliancePolicy/MSFT_SCRetentionCompliancePolicy.psm1 +++ b/Modules/Microsoft365DSC/DSCResources/MSFT_SCRetentionCompliancePolicy/MSFT_SCRetentionCompliancePolicy.psm1 @@ -303,6 +303,11 @@ function Set-TargetResource throw "You need to specify at least one Location for this Policy." } + if ($null -ne $SkypeLocation -and $SkypeLocation.ToLower() -eq "all") + { + throw "Skype Location must be a any value that uniquely identifies the user.Ex Name, email address, GUID" + } + Write-Verbose -Message "Setting configuration of RetentionCompliancePolicy for $Name" #region Telemetry $ResourceName = $MyInvocation.MyCommand.ModuleName.Replace("MSFT_", "") From 808bbb40c3d697a807900050aa76106f28bd4ce6 Mon Sep 17 00:00:00 2001 From: Nik Charlebois Date: Fri, 8 Jan 2021 15:11:31 -0500 Subject: [PATCH 20/21] Initial --- CHANGELOG.md | 3 +++ .../MSFT_AADRoleDefinition/MSFT_AADRoleDefinition.psm1 | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index cff0bce255..e57a4eea89 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,9 @@ # 1.21.113.1 +* AADRoleDefinition + * Filters out role definitions without any assigned permissions. + Fixes Issue #1007; * DEPENDENCIES * Updated Microsoft.PowerApps.Administration.PowerShell to 2.0.102; diff --git a/Modules/Microsoft365DSC/DSCResources/MSFT_AADRoleDefinition/MSFT_AADRoleDefinition.psm1 b/Modules/Microsoft365DSC/DSCResources/MSFT_AADRoleDefinition/MSFT_AADRoleDefinition.psm1 index f1960d3b30..13edc7477d 100644 --- a/Modules/Microsoft365DSC/DSCResources/MSFT_AADRoleDefinition/MSFT_AADRoleDefinition.psm1 +++ b/Modules/Microsoft365DSC/DSCResources/MSFT_AADRoleDefinition/MSFT_AADRoleDefinition.psm1 @@ -383,7 +383,7 @@ function Export-TargetResource } $Results = Get-TargetResource @Params - if ($Results.Ensure -eq 'Present') + if ($Results.Ensure -eq 'Present' -and ([array]$results.RolePermissions).Length -gt 0) { $Results = Update-M365DSCExportAuthenticationResults -ConnectionMode $ConnectionMode ` -Results $Results From 16bd2cb74571bf4fc42e81845c85a9ffdb524c29 Mon Sep 17 00:00:00 2001 From: Nik Charlebois Date: Thu, 14 Jan 2021 06:32:08 -0500 Subject: [PATCH 21/21] Release 1.21.113.1 --- CHANGELOG.md | 2 +- Modules/Microsoft365DSC/Microsoft365DSC.psd1 | 31 ++++++-------------- 2 files changed, 10 insertions(+), 23 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index e57a4eea89..0e466c4e4c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,7 +7,7 @@ Fixes Issue #1007; * DEPENDENCIES * Updated Microsoft.PowerApps.Administration.PowerShell - to 2.0.102; + to 2.0.104; # 1.20.1223.1 diff --git a/Modules/Microsoft365DSC/Microsoft365DSC.psd1 b/Modules/Microsoft365DSC/Microsoft365DSC.psd1 index c1eeaa97f6..7937b3a2fe 100644 --- a/Modules/Microsoft365DSC/Microsoft365DSC.psd1 +++ b/Modules/Microsoft365DSC/Microsoft365DSC.psd1 @@ -3,7 +3,7 @@ # # Generated by: Microsoft Corporation # -# Generated on: 2020-12-23 +# Generated on: 2021-01-14 @{ @@ -11,7 +11,7 @@ # RootModule = '' # Version number of this module. - ModuleVersion = '1.20.1223.1' + ModuleVersion = '1.21.113.1' # Supported PSEditions # CompatiblePSEditions = @() @@ -89,7 +89,7 @@ }, @{ ModuleName = "Microsoft.PowerApps.Administration.PowerShell" - RequiredVersion = "2.0.102" + RequiredVersion = "2.0.104" }, @{ ModuleName = "MicrosoftTeams" @@ -180,25 +180,12 @@ IconUri = 'https://github.com/microsoft/Microsoft365DSC/blob/Dev/Modules/Microsoft365DSC/Dependencies/Images/Logo.png?raw=true' # ReleaseNotes of this module - ReleaseNotes = "* SPOHubSite - * Changed Export logic to make the url parameterized - * Updated Get method to prevent throwing an exception - when the specified site doesn't exist - * SPOSite - * Updated logic to not process the HubUrl parameter - when this is equal to the Url parameter. - * Updated export logic to not export the HubUrl - parameter when this is equal to the Url parameter. - * Fixed issue with incorrectly applying the LocaleId - * SPOSiteAuditSettings - * Changed Export logic to make the url parameterized - * SPOSiteGroup - * Changed Export logic to make the url parameterized - * Updated logic to output more explainable troubleshooting - messages - * M365DscReverse - * Added the GlobalAccount Parameter to the example - that is outputted after using the Export GUI" + ReleaseNotes = "* AADRoleDefinition + * Filters out role definitions without any assigned permissions. + Fixes Issue #1007; + * DEPENDENCIES + * Updated Microsoft.PowerApps.Administration.PowerShell + to 2.0.104;" # Flag to indicate whether the module requires explicit user acceptance for install/update # RequireLicenseAcceptance = $false