From 64a463b29785be9ceff465a894a388856a3ea8f9 Mon Sep 17 00:00:00 2001 From: BNWEIN Date: Thu, 2 Jan 2025 18:41:43 +0000 Subject: [PATCH] Removed Comments and Fixed Roles Removed Comments and Fixed Roles --- .../Email-Exchange/Invoke-AddConnectionFilter.ps1 | 2 +- .../Email-Exchange/Invoke-AddConnectionFilterTemplate.ps1 | 2 +- .../Email-Exchange/Invoke-ListConnectionFilter.ps1 | 6 +----- .../Email-Exchange/Invoke-ListConnectionFilterTemplates.ps1 | 2 +- .../Public/Invoke-RemoveConnectionfilterTemplate.ps1 | 2 +- 5 files changed, 5 insertions(+), 9 deletions(-) diff --git a/Modules/CIPPCore/Public/Entrypoints/HTTP Functions/Email-Exchange/Invoke-AddConnectionFilter.ps1 b/Modules/CIPPCore/Public/Entrypoints/HTTP Functions/Email-Exchange/Invoke-AddConnectionFilter.ps1 index 1f0edd5c5999..e36aaea55402 100644 --- a/Modules/CIPPCore/Public/Entrypoints/HTTP Functions/Email-Exchange/Invoke-AddConnectionFilter.ps1 +++ b/Modules/CIPPCore/Public/Entrypoints/HTTP Functions/Email-Exchange/Invoke-AddConnectionFilter.ps1 @@ -5,7 +5,7 @@ Function Invoke-AddConnectionFilter { .FUNCTIONALITY Entrypoint .ROLE - Exchange.SpamFilter.ReadWrite + Exchange.ConnectionFilter.ReadWrite #> [CmdletBinding()] param($Request, $TriggerMetadata) diff --git a/Modules/CIPPCore/Public/Entrypoints/HTTP Functions/Email-Exchange/Invoke-AddConnectionFilterTemplate.ps1 b/Modules/CIPPCore/Public/Entrypoints/HTTP Functions/Email-Exchange/Invoke-AddConnectionFilterTemplate.ps1 index 6246cf8e1069..17b1fd994f4b 100644 --- a/Modules/CIPPCore/Public/Entrypoints/HTTP Functions/Email-Exchange/Invoke-AddConnectionFilterTemplate.ps1 +++ b/Modules/CIPPCore/Public/Entrypoints/HTTP Functions/Email-Exchange/Invoke-AddConnectionFilterTemplate.ps1 @@ -5,7 +5,7 @@ Function Invoke-AddConnectionFilterTemplate { .FUNCTIONALITY Entrypoint .ROLE - Exchange.Spamfilter.ReadWrite + Exchange.ConnectionFilter.ReadWrite #> [CmdletBinding()] param($Request, $TriggerMetadata) diff --git a/Modules/CIPPCore/Public/Entrypoints/HTTP Functions/Email-Exchange/Invoke-ListConnectionFilter.ps1 b/Modules/CIPPCore/Public/Entrypoints/HTTP Functions/Email-Exchange/Invoke-ListConnectionFilter.ps1 index ce2740708283..61c62cef6d78 100644 --- a/Modules/CIPPCore/Public/Entrypoints/HTTP Functions/Email-Exchange/Invoke-ListConnectionFilter.ps1 +++ b/Modules/CIPPCore/Public/Entrypoints/HTTP Functions/Email-Exchange/Invoke-ListConnectionFilter.ps1 @@ -5,7 +5,7 @@ Function Invoke-ListConnectionFilter { .FUNCTIONALITY Entrypoint .ROLE - Exchange.SpamFilter.Read + Exchange.ConnectionFilter.Read #> [CmdletBinding()] param($Request, $TriggerMetadata) @@ -16,20 +16,16 @@ Function Invoke-ListConnectionFilter { try { $Policies = New-ExoRequest -tenantid $Tenantfilter -cmdlet 'Get-HostedConnectionFilterPolicy' | Select-Object * -ExcludeProperty *odata*, *data.type* - #$RuleState = New-ExoRequest -tenantid $Tenantfilter -cmdlet 'Get-HostedContentFilterRule' | Select-Object * -ExcludeProperty *odata*, *data.type* - #$GraphRequest = $Policies | Select-Object *, @{l = 'ruleState'; e = { $name = $_.name; ($RuleState | Where-Object name -EQ $name).State } }, @{l = 'rulePrio'; e = { $name = $_.name; ($RuleState | Where-Object name -EQ $name).Priority } } $StatusCode = [HttpStatusCode]::OK } catch { $ErrorMessage = Get-NormalizedError -Message $_.Exception.Message $StatusCode = [HttpStatusCode]::Forbidden - #$GraphRequest = $ErrorMessage $Policies = $ErrorMessage } # Associate values to output bindings by calling 'Push-OutputBinding'. Push-OutputBinding -Name Response -Value ([HttpResponseContext]@{ StatusCode = $StatusCode - #Body = @($GraphRequest) Body = @($Policies) }) diff --git a/Modules/CIPPCore/Public/Entrypoints/HTTP Functions/Email-Exchange/Invoke-ListConnectionFilterTemplates.ps1 b/Modules/CIPPCore/Public/Entrypoints/HTTP Functions/Email-Exchange/Invoke-ListConnectionFilterTemplates.ps1 index 36ffdbf69e5d..b11f7c512fa8 100644 --- a/Modules/CIPPCore/Public/Entrypoints/HTTP Functions/Email-Exchange/Invoke-ListConnectionFilterTemplates.ps1 +++ b/Modules/CIPPCore/Public/Entrypoints/HTTP Functions/Email-Exchange/Invoke-ListConnectionFilterTemplates.ps1 @@ -5,7 +5,7 @@ Function Invoke-ListConnectionFilterTemplates { .FUNCTIONALITY Entrypoint .ROLE - Exchange.SpamFilter.Read + Exchange.ConnectionFilter.Read #> [CmdletBinding()] param($Request, $TriggerMetadata) diff --git a/Modules/CIPPCore/Public/Invoke-RemoveConnectionfilterTemplate.ps1 b/Modules/CIPPCore/Public/Invoke-RemoveConnectionfilterTemplate.ps1 index 5d4a13cca820..19526772e1e6 100644 --- a/Modules/CIPPCore/Public/Invoke-RemoveConnectionfilterTemplate.ps1 +++ b/Modules/CIPPCore/Public/Invoke-RemoveConnectionfilterTemplate.ps1 @@ -5,7 +5,7 @@ Function Invoke-RemoveConnectionfilterTemplate { .FUNCTIONALITY Entrypoint .ROLE - Exchange.Spamfilter.ReadWrite + Exchange.ConnectionFilter.ReadWrite #> [CmdletBinding()] param($Request, $TriggerMetadata)