DscResources/Exchange/Exchange.schema.psm1
# (2024-11-21 01:32:24) Generated using Microsoft365DSC v1.24.1120.1 Configuration 'Exchange' { param ( [Parameter(Mandatory = $true)] [System.String] $ApplicationId, [Parameter(Mandatory = $true)] [System.String] $TenantId, [Parameter(Mandatory = $true)] [System.String] $CertificateThumbprint ) Import-DscResource -ModuleName Microsoft365DSC foreach ($AcceptedDomain in $ConfigurationData.NonNodeData.Exchange.AcceptedDomains) { $resourceTitle = 'EXOAcceptedDomain-{0}' -f $AcceptedDomain.Identity $parameters = $AcceptedDomain $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOAcceptedDomain' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($ActiveSyncDeviceAccessRule in $ConfigurationData.NonNodeData.Exchange.ActiveSyncDeviceAccessRules) { $resourceTitle = 'EXOActiveSyncDeviceAccessRule-{0}' -f $ActiveSyncDeviceAccessRule.Identity $parameters = $ActiveSyncDeviceAccessRule $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOActiveSyncDeviceAccessRule' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($ActiveSyncMailboxPolicy in $ConfigurationData.NonNodeData.Exchange.ActiveSyncMailboxPolicies) { $resourceTitle = 'EXOActiveSyncMailboxPolicy-{0}' -f $ActiveSyncMailboxPolicy.Identity $parameters = $ActiveSyncMailboxPolicy $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOActiveSyncMailboxPolicy' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($AddressBookPolicy in $ConfigurationData.NonNodeData.Exchange.AddressBookPolicies) { $resourceTitle = 'EXOAddressBookPolicy-{0}' -f $AddressBookPolicy.Name $parameters = $AddressBookPolicy $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOAddressBookPolicy' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($AddressList in $ConfigurationData.NonNodeData.Exchange.AddressLists) { $resourceTitle = 'EXOAddressList-{0}' -f $AddressList.Name $parameters = $AddressList $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOAddressList' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($AntiPhishPolicy in $ConfigurationData.NonNodeData.Exchange.AntiPhishPolicies) { $resourceTitle = 'EXOAntiPhishPolicy-{0}' -f $AntiPhishPolicy.Identity $parameters = $AntiPhishPolicy $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOAntiPhishPolicy' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($AntiPhishRule in $ConfigurationData.NonNodeData.Exchange.AntiPhishRules) { $resourceTitle = 'EXOAntiPhishRule-{0}' -f $AntiPhishRule.Identity $parameters = $AntiPhishRule $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOAntiPhishRule' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($ApplicationAccessPolicy in $ConfigurationData.NonNodeData.Exchange.ApplicationAccessPolicies) { $resourceTitle = 'EXOApplicationAccessPolicy-{0}' -f $ApplicationAccessPolicy.Identity $parameters = $ApplicationAccessPolicy $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOApplicationAccessPolicy' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } if ($ConfigurationData.NonNodeData.Exchange.ContainsKey('ArcConfig')) { $resourceTitle = 'ArcConfigDefaults' $parameters = $ConfigurationData.NonNodeData.Exchange.ArcConfig $parameters.IsSingleInstance = 'Yes' $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOArcConfig' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($ATPBuiltInProtectionRule in $ConfigurationData.NonNodeData.Exchange.ATPBuiltInProtectionRules) { $resourceTitle = 'EXOATPBuiltInProtectionRule-{0}' -f $ATPBuiltInProtectionRule.Identity $parameters = $ATPBuiltInProtectionRule $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOATPBuiltInProtectionRule' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } if ($ConfigurationData.NonNodeData.Exchange.ContainsKey('AtpPolicyForO365')) { $resourceTitle = 'AtpPolicyForO365Defaults' $parameters = $ConfigurationData.NonNodeData.Exchange.AtpPolicyForO365 $parameters.IsSingleInstance = 'Yes' $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOAtpPolicyForO365' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($AtpProtectionPolicyRule in $ConfigurationData.NonNodeData.Exchange.AtpProtectionPoliciesRule) { $resourceTitle = 'EXOAtpProtectionPolicyRule-{0}' -f $AtpProtectionPolicyRule.Identity $parameters = $AtpProtectionPolicyRule $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOAtpProtectionPolicyRule' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($AuthenticationPolicy in $ConfigurationData.NonNodeData.Exchange.AuthenticationPolicies) { $resourceTitle = 'EXOAuthenticationPolicy-{0}' -f $AuthenticationPolicy.Identity $parameters = $AuthenticationPolicy $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOAuthenticationPolicy' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($AuthenticationPolicyAssignment in $ConfigurationData.NonNodeData.Exchange.AuthenticationPoliciesAssignment) { $resourceTitle = 'EXOAuthenticationPolicyAssignment-{0}' -f $AuthenticationPolicyAssignment.UserName $parameters = $AuthenticationPolicyAssignment $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOAuthenticationPolicyAssignment' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($AvailabilityAddressSpace in $ConfigurationData.NonNodeData.Exchange.AvailabilityAddressSpaces) { $resourceTitle = 'EXOAvailabilityAddressSpace-{0}' -f $AvailabilityAddressSpace.Identity $parameters = $AvailabilityAddressSpace $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOAvailabilityAddressSpace' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($AvailabilityConfig in $ConfigurationData.NonNodeData.Exchange.AvailabilityConfigs) { $resourceTitle = 'EXOAvailabilityConfig-{0}' -f $AvailabilityConfig.OrgWideAccount $parameters = $AvailabilityConfig $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOAvailabilityConfig' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($CalendarProcessing in $ConfigurationData.NonNodeData.Exchange.CalendarProcessings) { $resourceTitle = 'EXOCalendarProcessing-{0}' -f $CalendarProcessing.Identity $parameters = $CalendarProcessing $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOCalendarProcessing' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($CASMailboxPlan in $ConfigurationData.NonNodeData.Exchange.CASMailboxPlans) { $resourceTitle = 'EXOCASMailboxPlan-{0}' -f $CASMailboxPlan.Identity $parameters = $CASMailboxPlan $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOCASMailboxPlan' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($CASMailboxSettingsItems in $ConfigurationData.NonNodeData.Exchange.CASMailboxSettingsItems) { $resourceTitle = 'EXOCASMailboxSettings-{0}' -f $CASMailboxSettingsItems.Identity $parameters = $CASMailboxSettingsItems $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOCASMailboxSettings' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($ClientAccessRule in $ConfigurationData.NonNodeData.Exchange.ClientAccessRules) { $resourceTitle = 'EXOClientAccessRule-{0}' -f $ClientAccessRule.Identity $parameters = $ClientAccessRule $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOClientAccessRule' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($DataAtRestEncryptionPolicy in $ConfigurationData.NonNodeData.Exchange.DataAtRestEncryptionPolicies) { $resourceTitle = 'EXODataAtRestEncryptionPolicy-{0}' -f $DataAtRestEncryptionPolicy.Identity $parameters = $DataAtRestEncryptionPolicy $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXODataAtRestEncryptionPolicy' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } if ($ConfigurationData.NonNodeData.Exchange.ContainsKey('DataAtRestEncryptionPolicyAssignment')) { $resourceTitle = 'DataAtRestEncryptionPolicyAssignmentDefaults' $parameters = $ConfigurationData.NonNodeData.Exchange.DataAtRestEncryptionPolicyAssignment $parameters.IsSingleInstance = 'Yes' $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXODataAtRestEncryptionPolicyAssignment' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($DataClassification in $ConfigurationData.NonNodeData.Exchange.DataClassifications) { $resourceTitle = 'EXODataClassification-{0}' -f $DataClassification.Identity $parameters = $DataClassification $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXODataClassification' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($DataEncryptionPolicy in $ConfigurationData.NonNodeData.Exchange.DataEncryptionPolicies) { $resourceTitle = 'EXODataEncryptionPolicy-{0}' -f $DataEncryptionPolicy.Identity $parameters = $DataEncryptionPolicy $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXODataEncryptionPolicy' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($DistributionGroup in $ConfigurationData.NonNodeData.Exchange.DistributionGroups) { $resourceTitle = 'EXODistributionGroup-{0}' -f $DistributionGroup.Identity $parameters = $DistributionGroup $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXODistributionGroup' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($DkimSigningConfig in $ConfigurationData.NonNodeData.Exchange.DkimSigningConfigs) { $resourceTitle = 'EXODkimSigningConfig-{0}' -f $DkimSigningConfig.Identity $parameters = $DkimSigningConfig $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXODkimSigningConfig' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($DnssecForVerifiedDomain in $ConfigurationData.NonNodeData.Exchange.DnssecForVerifiedDomains) { $resourceTitle = 'EXODnssecForVerifiedDomain-{0}' -f $DnssecForVerifiedDomain.DomainName $parameters = $DnssecForVerifiedDomain $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXODnssecForVerifiedDomain' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($EmailAddressPolicy in $ConfigurationData.NonNodeData.Exchange.EmailAddressPolicies) { $resourceTitle = 'EXOEmailAddressPolicy-{0}' -f $EmailAddressPolicy.Name $parameters = $EmailAddressPolicy $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOEmailAddressPolicy' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } if ($ConfigurationData.NonNodeData.Exchange.ContainsKey('EmailTenantSettings')) { $resourceTitle = 'EmailTenantSettingsDefaults' $parameters = $ConfigurationData.NonNodeData.Exchange.EmailTenantSettings $parameters.IsSingleInstance = 'Yes' $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOEmailTenantSettings' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($EOPProtectionPolicyRule in $ConfigurationData.NonNodeData.Exchange.EOPProtectionPoliciesRule) { $resourceTitle = 'EXOEOPProtectionPolicyRule-{0}' -f $EOPProtectionPolicyRule.Identity $parameters = $EOPProtectionPolicyRule $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOEOPProtectionPolicyRule' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($ExternalInOutlook in $ConfigurationData.NonNodeData.Exchange.ExternalInOutlooks) { $resourceTitle = 'EXOExternalInOutlook-{0}' -f $ExternalInOutlook.Identity $parameters = $ExternalInOutlook $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOExternalInOutlook' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($FocusedInbox in $ConfigurationData.NonNodeData.Exchange.FocusedInboxs) { $resourceTitle = 'EXOFocusedInbox-{0}' -f $FocusedInbox.Identity $parameters = $FocusedInbox $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOFocusedInbox' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($GlobalAddressList in $ConfigurationData.NonNodeData.Exchange.GlobalAddressLists) { $resourceTitle = 'EXOGlobalAddressList-{0}' -f $GlobalAddressList.Name $parameters = $GlobalAddressList $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOGlobalAddressList' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($GroupSettingsItems in $ConfigurationData.NonNodeData.Exchange.GroupSettingsItems) { $resourceTitle = 'EXOGroupSettings-{0}' -f $GroupSettingsItems.DisplayName $parameters = $GroupSettingsItems $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOGroupSettings' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($HostedConnectionFilterPolicy in $ConfigurationData.NonNodeData.Exchange.HostedConnectionFilterPolicies) { $resourceTitle = 'EXOHostedConnectionFilterPolicy-{0}' -f $HostedConnectionFilterPolicy.Identity $parameters = $HostedConnectionFilterPolicy $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOHostedConnectionFilterPolicy' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($HostedContentFilterPolicy in $ConfigurationData.NonNodeData.Exchange.HostedContentFilterPolicies) { $resourceTitle = 'EXOHostedContentFilterPolicy-{0}' -f $HostedContentFilterPolicy.Identity $parameters = $HostedContentFilterPolicy $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOHostedContentFilterPolicy' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($HostedContentFilterRule in $ConfigurationData.NonNodeData.Exchange.HostedContentFilterRules) { $resourceTitle = 'EXOHostedContentFilterRule-{0}' -f $HostedContentFilterRule.Identity $parameters = $HostedContentFilterRule $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOHostedContentFilterRule' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($HostedOutboundSpamFilterPolicy in $ConfigurationData.NonNodeData.Exchange.HostedOutboundSpamFilterPolicies) { $resourceTitle = 'EXOHostedOutboundSpamFilterPolicy-{0}' -f $HostedOutboundSpamFilterPolicy.Identity $parameters = $HostedOutboundSpamFilterPolicy $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOHostedOutboundSpamFilterPolicy' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($HostedOutboundSpamFilterRule in $ConfigurationData.NonNodeData.Exchange.HostedOutboundSpamFilterRules) { $resourceTitle = 'EXOHostedOutboundSpamFilterRule-{0}' -f $HostedOutboundSpamFilterRule.Identity $parameters = $HostedOutboundSpamFilterRule $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOHostedOutboundSpamFilterRule' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($InboundConnector in $ConfigurationData.NonNodeData.Exchange.InboundConnectors) { $resourceTitle = 'EXOInboundConnector-{0}' -f $InboundConnector.Identity $parameters = $InboundConnector $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOInboundConnector' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($IntraOrganizationConnector in $ConfigurationData.NonNodeData.Exchange.IntraOrganizationConnectors) { $resourceTitle = 'EXOIntraOrganizationConnector-{0}' -f $IntraOrganizationConnector.Identity $parameters = $IntraOrganizationConnector $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOIntraOrganizationConnector' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } if ($ConfigurationData.NonNodeData.Exchange.ContainsKey('IRMConfiguration')) { $resourceTitle = 'IRMConfigurationDefaults' $parameters = $ConfigurationData.NonNodeData.Exchange.IRMConfiguration $parameters.IsSingleInstance = 'Yes' $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOIRMConfiguration' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($JournalRule in $ConfigurationData.NonNodeData.Exchange.JournalRules) { $resourceTitle = 'EXOJournalRule-{0}-{1}' -f $JournalRule.Name,$JournalRule.JournalEmailAddress $parameters = $JournalRule $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOJournalRule' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($MailboxAuditBypassAssociation in $ConfigurationData.NonNodeData.Exchange.MailboxAuditBypassAssociations) { $resourceTitle = 'EXOMailboxAuditBypassAssociation-{0}' -f $MailboxAuditBypassAssociation.Identity $parameters = $MailboxAuditBypassAssociation $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOMailboxAuditBypassAssociation' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($MailboxAutoReplyConfiguration in $ConfigurationData.NonNodeData.Exchange.MailboxAutoReplyConfigurations) { $resourceTitle = 'EXOMailboxAutoReplyConfiguration-{0}' -f $MailboxAutoReplyConfiguration.Identity $parameters = $MailboxAutoReplyConfiguration $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOMailboxAutoReplyConfiguration' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($MailboxCalendarConfiguration in $ConfigurationData.NonNodeData.Exchange.MailboxCalendarConfigurations) { $resourceTitle = 'EXOMailboxCalendarConfiguration-{0}' -f $MailboxCalendarConfiguration.Identity $parameters = $MailboxCalendarConfiguration $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOMailboxCalendarConfiguration' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($MailboxCalendarFolder in $ConfigurationData.NonNodeData.Exchange.MailboxCalendarFolders) { $resourceTitle = 'EXOMailboxCalendarFolder-{0}' -f $MailboxCalendarFolder.Identity $parameters = $MailboxCalendarFolder $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOMailboxCalendarFolder' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($MailboxFolderPermission in $ConfigurationData.NonNodeData.Exchange.MailboxFolderPermissions) { $resourceTitle = 'EXOMailboxFolderPermission-{0}' -f $MailboxFolderPermission.Identity $parameters = $MailboxFolderPermission $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } if ($parameters.ContainsKey('UserPermissions')) { $parameters.UserPermissions = $parameters.UserPermissions | ForEach-Object { if ($_.ContainsKey('UniqueId')) { $_.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'MSFT_EXOMailboxFolderUserPermission' -Properties $_ -NoInvoke).Invoke($_) } } (Get-DscSplattedResource -ResourceName 'EXOMailboxFolderPermission' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($MailboxIRMAccess in $ConfigurationData.NonNodeData.Exchange.MailboxIRMAccesss) { $resourceTitle = 'EXOMailboxIRMAccess-{0}-{1}' -f $MailboxIRMAccess.Identity,$MailboxIRMAccess.User $parameters = $MailboxIRMAccess $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOMailboxIRMAccess' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($MailboxPermission in $ConfigurationData.NonNodeData.Exchange.MailboxPermissions) { $resourceTitle = 'EXOMailboxPermission-{0}-{1}-{2}' -f $MailboxPermission.Identity,$MailboxPermission.User,$MailboxPermission.InheritanceType $parameters = $MailboxPermission $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOMailboxPermission' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($MailboxPlan in $ConfigurationData.NonNodeData.Exchange.MailboxPlans) { $resourceTitle = 'EXOMailboxPlan-{0}' -f $MailboxPlan.Identity $parameters = $MailboxPlan $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOMailboxPlan' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($MailboxSettingsItems in $ConfigurationData.NonNodeData.Exchange.MailboxSettingsItems) { $resourceTitle = 'EXOMailboxSettings-{0}' -f $MailboxSettingsItems.DisplayName $parameters = $MailboxSettingsItems $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOMailboxSettings' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($MailContact in $ConfigurationData.NonNodeData.Exchange.MailContacts) { $resourceTitle = 'EXOMailContact-{0}' -f $MailContact.Name $parameters = $MailContact $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOMailContact' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } if ($ConfigurationData.NonNodeData.Exchange.ContainsKey('MailTips')) { $resourceTitle = 'MailTipsDefaults' $parameters = $ConfigurationData.NonNodeData.Exchange.MailTips $parameters.IsSingleInstance = 'Yes' $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOMailTips' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($MalwareFilterPolicy in $ConfigurationData.NonNodeData.Exchange.MalwareFilterPolicies) { $resourceTitle = 'EXOMalwareFilterPolicy-{0}' -f $MalwareFilterPolicy.Identity $parameters = $MalwareFilterPolicy $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOMalwareFilterPolicy' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($MalwareFilterRule in $ConfigurationData.NonNodeData.Exchange.MalwareFilterRules) { $resourceTitle = 'EXOMalwareFilterRule-{0}' -f $MalwareFilterRule.Identity $parameters = $MalwareFilterRule $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOMalwareFilterRule' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($ManagementRole in $ConfigurationData.NonNodeData.Exchange.ManagementRoles) { $resourceTitle = 'EXOManagementRole-{0}-{1}' -f $ManagementRole.Name,$ManagementRole.Parent $parameters = $ManagementRole $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOManagementRole' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($ManagementRoleAssignment in $ConfigurationData.NonNodeData.Exchange.ManagementRoleAssignments) { $resourceTitle = 'EXOManagementRoleAssignment-{0}-{1}' -f $ManagementRoleAssignment.Name,$ManagementRoleAssignment.Role $parameters = $ManagementRoleAssignment $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOManagementRoleAssignment' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($ManagementRoleEntry in $ConfigurationData.NonNodeData.Exchange.ManagementRoleEntries) { $resourceTitle = 'EXOManagementRoleEntry-{0}' -f $ManagementRoleEntry.Identity $parameters = $ManagementRoleEntry $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOManagementRoleEntry' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($ManagementScope in $ConfigurationData.NonNodeData.Exchange.ManagementScopes) { $resourceTitle = 'EXOManagementScope-{0}' -f $ManagementScope.Identity $parameters = $ManagementScope $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOManagementScope' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($MessageClassification in $ConfigurationData.NonNodeData.Exchange.MessageClassifications) { $resourceTitle = 'EXOMessageClassification-{0}' -f $MessageClassification.Identity $parameters = $MessageClassification $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOMessageClassification' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($Migration in $ConfigurationData.NonNodeData.Exchange.Migrations) { $resourceTitle = 'EXOMigration-{0}' -f $Migration.Identity $parameters = $Migration $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOMigration' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($MigrationEndpoint in $ConfigurationData.NonNodeData.Exchange.MigrationEndpoints) { $resourceTitle = 'EXOMigrationEndpoint-{0}' -f $MigrationEndpoint.Identity $parameters = $MigrationEndpoint $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOMigrationEndpoint' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($MobileDeviceMailboxPolicy in $ConfigurationData.NonNodeData.Exchange.MobileDeviceMailboxPolicies) { $resourceTitle = 'EXOMobileDeviceMailboxPolicy-{0}' -f $MobileDeviceMailboxPolicy.Name $parameters = $MobileDeviceMailboxPolicy $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOMobileDeviceMailboxPolicy' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($OfflineAddressBook in $ConfigurationData.NonNodeData.Exchange.OfflineAddressBooks) { $resourceTitle = 'EXOOfflineAddressBook-{0}' -f $OfflineAddressBook.Name $parameters = $OfflineAddressBook $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOOfflineAddressBook' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($OMEConfiguration in $ConfigurationData.NonNodeData.Exchange.OMEConfigurations) { $resourceTitle = 'EXOOMEConfiguration-{0}' -f $OMEConfiguration.Identity $parameters = $OMEConfiguration $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOOMEConfiguration' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($OnPremisesOrganization in $ConfigurationData.NonNodeData.Exchange.OnPremisesOrganizations) { $resourceTitle = 'EXOOnPremisesOrganization-{0}' -f $OnPremisesOrganization.Identity $parameters = $OnPremisesOrganization $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOOnPremisesOrganization' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } if ($ConfigurationData.NonNodeData.Exchange.ContainsKey('OrganizationConfig')) { $resourceTitle = 'OrganizationConfigDefaults' $parameters = $ConfigurationData.NonNodeData.Exchange.OrganizationConfig $parameters.IsSingleInstance = 'Yes' $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOOrganizationConfig' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($OrganizationRelationship in $ConfigurationData.NonNodeData.Exchange.OrganizationRelationships) { $resourceTitle = 'EXOOrganizationRelationship-{0}' -f $OrganizationRelationship.Name $parameters = $OrganizationRelationship $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOOrganizationRelationship' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($OutboundConnector in $ConfigurationData.NonNodeData.Exchange.OutboundConnectors) { $resourceTitle = 'EXOOutboundConnector-{0}' -f $OutboundConnector.Identity $parameters = $OutboundConnector $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOOutboundConnector' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($OwaMailboxPolicy in $ConfigurationData.NonNodeData.Exchange.OwaMailboxPolicies) { $resourceTitle = 'EXOOwaMailboxPolicy-{0}' -f $OwaMailboxPolicy.Name $parameters = $OwaMailboxPolicy $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOOwaMailboxPolicy' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($PartnerApplication in $ConfigurationData.NonNodeData.Exchange.PartnerApplications) { $resourceTitle = 'EXOPartnerApplication-{0}' -f $PartnerApplication.Name $parameters = $PartnerApplication $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOPartnerApplication' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } if ($ConfigurationData.NonNodeData.Exchange.ContainsKey('PerimeterConfiguration')) { $resourceTitle = 'PerimeterConfigurationDefaults' $parameters = $ConfigurationData.NonNodeData.Exchange.PerimeterConfiguration $parameters.IsSingleInstance = 'Yes' $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOPerimeterConfiguration' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($PhishSimOverrideRule in $ConfigurationData.NonNodeData.Exchange.PhishSimOverrideRules) { $resourceTitle = 'EXOPhishSimOverrideRule-{0}' -f $PhishSimOverrideRule.Identity $parameters = $PhishSimOverrideRule $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOPhishSimOverrideRule' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($Place in $ConfigurationData.NonNodeData.Exchange.Places) { $resourceTitle = 'EXOPlace-{0}' -f $Place.Identity $parameters = $Place $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOPlace' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($PolicyTipConfig in $ConfigurationData.NonNodeData.Exchange.PoliciesTipConfig) { $resourceTitle = 'EXOPolicyTipConfig-{0}' -f $PolicyTipConfig.Name $parameters = $PolicyTipConfig $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOPolicyTipConfig' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($QuarantinePolicy in $ConfigurationData.NonNodeData.Exchange.QuarantinePolicies) { $resourceTitle = 'EXOQuarantinePolicy-{0}' -f $QuarantinePolicy.Identity $parameters = $QuarantinePolicy $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOQuarantinePolicy' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($RecipientPermission in $ConfigurationData.NonNodeData.Exchange.RecipientPermissions) { $resourceTitle = 'EXORecipientPermission-{0}-{1}' -f $RecipientPermission.Identity,$RecipientPermission.Trustee $parameters = $RecipientPermission $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXORecipientPermission' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($RemoteDomain in $ConfigurationData.NonNodeData.Exchange.RemoteDomains) { $resourceTitle = 'EXORemoteDomain-{0}' -f $RemoteDomain.Identity $parameters = $RemoteDomain $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXORemoteDomain' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } if ($ConfigurationData.NonNodeData.Exchange.ContainsKey('ReportSubmissionPolicy')) { $resourceTitle = 'ReportSubmissionPolicyDefaults' $parameters = $ConfigurationData.NonNodeData.Exchange.ReportSubmissionPolicy $parameters.IsSingleInstance = 'Yes' $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOReportSubmissionPolicy' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } if ($ConfigurationData.NonNodeData.Exchange.ContainsKey('ReportSubmissionRule')) { $resourceTitle = 'ReportSubmissionRuleDefaults' $parameters = $ConfigurationData.NonNodeData.Exchange.ReportSubmissionRule $parameters.IsSingleInstance = 'Yes' $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOReportSubmissionRule' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } if ($ConfigurationData.NonNodeData.Exchange.ContainsKey('ResourceConfiguration')) { $resourceTitle = 'ResourceConfigurationDefaults' $parameters = $ConfigurationData.NonNodeData.Exchange.ResourceConfiguration $parameters.IsSingleInstance = 'Yes' $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOResourceConfiguration' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($RetentionPolicy in $ConfigurationData.NonNodeData.Exchange.RetentionPolicies) { $resourceTitle = 'EXORetentionPolicy-{0}' -f $RetentionPolicy.Identity $parameters = $RetentionPolicy $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXORetentionPolicy' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($RoleAssignmentPolicy in $ConfigurationData.NonNodeData.Exchange.RoleAssignmentPolicies) { $resourceTitle = 'EXORoleAssignmentPolicy-{0}' -f $RoleAssignmentPolicy.Name $parameters = $RoleAssignmentPolicy $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXORoleAssignmentPolicy' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($RoleGroup in $ConfigurationData.NonNodeData.Exchange.RoleGroups) { $resourceTitle = 'EXORoleGroup-{0}' -f $RoleGroup.Name $parameters = $RoleGroup $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXORoleGroup' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($SafeAttachmentPolicy in $ConfigurationData.NonNodeData.Exchange.SafeAttachmentPolicies) { $resourceTitle = 'EXOSafeAttachmentPolicy-{0}' -f $SafeAttachmentPolicy.Identity $parameters = $SafeAttachmentPolicy $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOSafeAttachmentPolicy' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($SafeAttachmentRule in $ConfigurationData.NonNodeData.Exchange.SafeAttachmentRules) { $resourceTitle = 'EXOSafeAttachmentRule-{0}' -f $SafeAttachmentRule.Identity $parameters = $SafeAttachmentRule $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOSafeAttachmentRule' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($SafeLinksPolicy in $ConfigurationData.NonNodeData.Exchange.SafeLinksPolicies) { $resourceTitle = 'EXOSafeLinksPolicy-{0}' -f $SafeLinksPolicy.Identity $parameters = $SafeLinksPolicy $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOSafeLinksPolicy' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($SafeLinksRule in $ConfigurationData.NonNodeData.Exchange.SafeLinksRules) { $resourceTitle = 'EXOSafeLinksRule-{0}' -f $SafeLinksRule.Identity $parameters = $SafeLinksRule $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOSafeLinksRule' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($SecOpsOverrideRule in $ConfigurationData.NonNodeData.Exchange.SecOpsOverrideRules) { $resourceTitle = 'EXOSecOpsOverrideRule-{0}' -f $SecOpsOverrideRule.Identity $parameters = $SecOpsOverrideRule $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOSecOpsOverrideRule' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($ServicePrincipal in $ConfigurationData.NonNodeData.Exchange.ServicePrincipals) { $resourceTitle = 'EXOServicePrincipal-{0}' -f $ServicePrincipal.AppName $parameters = $ServicePrincipal $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOServicePrincipal' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($SharedMailbox in $ConfigurationData.NonNodeData.Exchange.SharedMailboxs) { $resourceTitle = 'EXOSharedMailbox-{0}' -f $SharedMailbox.DisplayName $parameters = $SharedMailbox $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOSharedMailbox' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($SharingPolicy in $ConfigurationData.NonNodeData.Exchange.SharingPolicies) { $resourceTitle = 'EXOSharingPolicy-{0}' -f $SharingPolicy.Name $parameters = $SharingPolicy $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOSharingPolicy' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($SweepRule in $ConfigurationData.NonNodeData.Exchange.SweepRules) { $resourceTitle = 'EXOSweepRule-{0}' -f $SweepRule.Name $parameters = $SweepRule $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOSweepRule' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($TenantAllowBlockListItems in $ConfigurationData.NonNodeData.Exchange.TenantAllowBlockListItemss) { $resourceTitle = 'EXOTenantAllowBlockListItems-{0}-{1}-{2}' -f $TenantAllowBlockListItems.Action,$TenantAllowBlockListItems.Value,$TenantAllowBlockListItems.ListType $parameters = $TenantAllowBlockListItems $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOTenantAllowBlockListItems' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($TenantAllowBlockListSpoofItems in $ConfigurationData.NonNodeData.Exchange.TenantAllowBlockListSpoofItemss) { $resourceTitle = 'EXOTenantAllowBlockListSpoofItems-{0}' -f $TenantAllowBlockListSpoofItems.SpoofedUser $parameters = $TenantAllowBlockListSpoofItems $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOTenantAllowBlockListSpoofItems' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } if ($ConfigurationData.NonNodeData.Exchange.ContainsKey('TransportConfig')) { $resourceTitle = 'TransportConfigDefaults' $parameters = $ConfigurationData.NonNodeData.Exchange.TransportConfig $parameters.IsSingleInstance = 'Yes' $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOTransportConfig' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } foreach ($TransportRule in $ConfigurationData.NonNodeData.Exchange.TransportRules) { $resourceTitle = 'EXOTransportRule-{0}' -f $TransportRule.Name $parameters = $TransportRule $parameters.ApplicationId = $ApplicationId $parameters.TenantId = $TenantId $parameters.CertificateThumbprint = $CertificateThumbprint if ($parameters.ContainsKey('UniqueId')) { $parameters.Remove('UniqueId') } (Get-DscSplattedResource -ResourceName 'EXOTransportRule' -ExecutionName $resourceTitle -Properties $parameters -NoInvoke).Invoke($parameters) } } |