diff --git a/CHANGELOG.md b/CHANGELOG.md index 4275060b..008e37db 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,17 +5,21 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] +### Added + +- xExchOwaVirtualDirectoryInternal + - Added parameters `ExternalDownloadHostName` and `InternalDownloadHostName`. + ### Changed - xExchange - Update the pipeline files from the latest template in Sampler. - xExchPopSettings - - Add missing ProtocolLogEnabled parameter + - Add missing ProtocolLogEnabled parameter. - xExchWebServicesVirtualDirectory - - Fixed Typo - + - Fixed typo. - xExchangeHelper - - Fixed module import error ([Issue #481](https://github.com/dsccommunity/xExchange/issues/481)) + - Fixed module import error ([issue #481](https://github.com/dsccommunity/xExchange/issues/481)). ## [1.33.0] - 2021-10-31 diff --git a/README.md b/README.md index 973bc0c2..43b88988 100644 --- a/README.md +++ b/README.md @@ -1464,9 +1464,11 @@ parameters. - **DigestAuthentication** - **DomainController** - **ExternalAuthenticationMethods** +- **ExternalDownloadHostName** - **ExternalUrl** - **FormsAuthentication** - **GzipLevel** +- **InternalDownloadHostName** - **InternalUrl** - **InstantMessagingEnabled** - **InstantMessagingCertificateThumbprint** diff --git a/source/DSCResources/MSFT_xExchOwaVirtualDirectory/MSFT_xExchOwaVirtualDirectory.psm1 b/source/DSCResources/MSFT_xExchOwaVirtualDirectory/MSFT_xExchOwaVirtualDirectory.psm1 index bd9cd88f..ac9cd62a 100644 --- a/source/DSCResources/MSFT_xExchOwaVirtualDirectory/MSFT_xExchOwaVirtualDirectory.psm1 +++ b/source/DSCResources/MSFT_xExchOwaVirtualDirectory/MSFT_xExchOwaVirtualDirectory.psm1 @@ -47,6 +47,10 @@ function Get-TargetResource [System.String[]] $ExternalAuthenticationMethods, + [Parameter()] + [System.String] + $ExternalDownloadHostName, + [Parameter()] [System.String] $ExternalUrl, @@ -77,6 +81,10 @@ function Get-TargetResource [System.String] $InstantMessagingType, + [Parameter()] + [System.String] + $InternalDownloadHostName, + [Parameter()] [System.String] $InternalUrl, @@ -143,6 +151,7 @@ function Get-TargetResource DefaultDomain = [System.String] $OwaVdir.DefaultDomain DigestAuthentication = [System.Boolean] $OwaVdir.DigestAuthentication ExternalAuthenticationMethods = [System.String[]] $OwaVdir.ExternalAuthenticationMethods + ExternalDownloadHostName = [System.String] $OwaVdir.ExternalDownloadHostName ExternalUrl = [System.String] $OwaVdir.ExternalUrl.AbsoluteUri FormsAuthentication = [System.Boolean] $OwaVdir.FormsAuthentication GzipLevel = [System.String] $OwaVdir.GzipLevel @@ -150,6 +159,7 @@ function Get-TargetResource InstantMessagingEnabled = [System.Boolean] $OwaVdir.InstantMessagingEnabled InstantMessagingServerName = [System.String] $OwaVdir.InstantMessagingServerName InstantMessagingType = [System.String] $OwaVdir.InstantMessagingType + InternalDownloadHostName = [System.String] $OwaVdir.InternalDownloadHostName InternalUrl = [System.String] $OwaVdir.InternalUrl.AbsoluteUri LogonFormat = [System.String] $OwaVdir.LogonFormat LogonPageLightSelectionEnabled = [System.Boolean] $OwaVdir.LogonPageLightSelectionEnabled @@ -212,6 +222,10 @@ function Set-TargetResource [System.String[]] $ExternalAuthenticationMethods, + [Parameter()] + [System.String] + $ExternalDownloadHostName, + [Parameter()] [System.String] $ExternalUrl, @@ -242,6 +256,10 @@ function Set-TargetResource [System.String] $InstantMessagingType, + [Parameter()] + [System.String] + $InternalDownloadHostName, + [Parameter()] [System.String] $InternalUrl, @@ -363,6 +381,10 @@ function Test-TargetResource [System.String[]] $ExternalAuthenticationMethods, + [Parameter()] + [System.String] + $ExternalDownloadHostName, + [Parameter()] [System.String] $ExternalUrl, @@ -393,6 +415,10 @@ function Test-TargetResource [System.String] $InstantMessagingType, + [Parameter()] + [System.String] + $InternalDownloadHostName, + [Parameter()] [System.String] $InternalUrl, @@ -580,6 +606,16 @@ function Test-TargetResource { $testResults = $false } + + if (!(Test-ExchangeSetting -Name 'ExternalDownloadHostName' -Type 'String' -ExpectedValue $ExternalDownloadHostName -ActualValue $OwaVdir.ExternalDownloadHostName -PSBoundParametersIn $PSBoundParameters -Verbose:$VerbosePreference)) + { + $testResults = $false + } + + if (!(Test-ExchangeSetting -Name 'InternalDownloadHostName' -Type 'String' -ExpectedValue $InternalDownloadHostName -ActualValue $OwaVdir.InternalDownloadHostName -PSBoundParametersIn $PSBoundParameters -Verbose:$VerbosePreference)) + { + $testResults = $false + } } return $testResults @@ -632,6 +668,10 @@ function Get-OwaVirtualDirectoryInternal [System.String[]] $ExternalAuthenticationMethods, + [Parameter()] + [System.String] + $ExternalDownloadHostName, + [Parameter()] [System.String] $ExternalUrl, @@ -662,6 +702,10 @@ function Get-OwaVirtualDirectoryInternal [System.String] $InstantMessagingType, + [Parameter()] + [System.String] + $InternalDownloadHostName, + [Parameter()] [System.String] $InternalUrl, diff --git a/source/DSCResources/MSFT_xExchOwaVirtualDirectory/MSFT_xExchOwaVirtualDirectory.schema.mof b/source/DSCResources/MSFT_xExchOwaVirtualDirectory/MSFT_xExchOwaVirtualDirectory.schema.mof index c3f1aaae..7c91b936 100644 --- a/source/DSCResources/MSFT_xExchOwaVirtualDirectory/MSFT_xExchOwaVirtualDirectory.schema.mof +++ b/source/DSCResources/MSFT_xExchOwaVirtualDirectory/MSFT_xExchOwaVirtualDirectory.schema.mof @@ -15,9 +15,11 @@ class MSFT_xExchOwaVirtualDirectory : OMI_BaseResource [Write] Boolean DigestAuthentication; [Write] String DomainController; [Write] String ExternalAuthenticationMethods[]; + [Write] String ExternalDownloadHostName; [Write] String ExternalUrl; [Write] Boolean FormsAuthentication; [Write, ValueMap{"Off", "Low", "High", "Error"}, Values{"Off", "Low", "High", "Error"}] String GzipLevel; + [Write] String InternalDownloadHostName; [Write] String InternalUrl; [Write] Boolean InstantMessagingEnabled; [Write] String InstantMessagingCertificateThumbprint; @@ -34,6 +36,3 @@ class MSFT_xExchOwaVirtualDirectory : OMI_BaseResource [Write] String DefaultDomain; [Write] Boolean SetPhotoEnabled; }; - - - diff --git a/tests/Integration/MSFT_xExchOwaVirtualDirectory.Integration.Tests.ps1 b/tests/Integration/MSFT_xExchOwaVirtualDirectory.Integration.Tests.ps1 index 45e69a50..fb8e3b90 100644 --- a/tests/Integration/MSFT_xExchOwaVirtualDirectory.Integration.Tests.ps1 +++ b/tests/Integration/MSFT_xExchOwaVirtualDirectory.Integration.Tests.ps1 @@ -58,6 +58,7 @@ if ($exchangeInstalled) BasicAuthentication = $true ChangePasswordEnabled = $true DigestAuthentication = $false + ExternalDownloadHostName = 'downloaddomain.contoso.local' ExternalUrl = "https://$($serverFqdn)/owa" FormsAuthentication = $true GzipLevel = 'Off' @@ -65,6 +66,7 @@ if ($exchangeInstalled) InstantMessagingCertificateThumbprint = '' InstantMessagingServerName = '' InstantMessagingType = 'None' + InternalDownloadHostName = 'downloaddomain.contoso.local' InternalUrl = "https://$($serverFqdn)/owa" LogonPagePublicPrivateSelectionEnabled = $true LogonPageLightSelectionEnabled = $true @@ -84,6 +86,7 @@ if ($exchangeInstalled) ActionForUnknownFileAndMIMETypes = 'ForceSave' ChangePasswordEnabled = $true DigestAuthentication = $false + ExternalDownloadHostName = 'downloaddomain.contoso.local' ExternalUrl = "https://$($serverFqdn)/owa" FormsAuthentication = $true GzipLevel = 'Off' @@ -91,6 +94,7 @@ if ($exchangeInstalled) InstantMessagingCertificateThumbprint = '' InstantMessagingServerName = '' InstantMessagingType = 'None' + InternalDownloadHostName = 'downloaddomain.contoso.local' InternalUrl = "https://$($serverFqdn)/owa" LogonPagePublicPrivateSelectionEnabled = $true LogonPageLightSelectionEnabled = $true @@ -114,6 +118,7 @@ if ($exchangeInstalled) BasicAuthentication = $false ChangePasswordEnabled = $false DigestAuthentication = $true + ExternalDownloadHostName = '' ExternalUrl = '' FormsAuthentication = $false GzipLevel = 'High' @@ -121,6 +126,7 @@ if ($exchangeInstalled) InstantMessagingCertificateThumbprint = $imCertThumbprint InstantMessagingServerName = $env:COMPUTERNAME InstantMessagingType = 'Ocs' + InternalDownloadHostName = '' InternalUrl = '' LogonPagePublicPrivateSelectionEnabled = $false LogonPageLightSelectionEnabled = $false @@ -140,6 +146,7 @@ if ($exchangeInstalled) BasicAuthentication = $false ChangePasswordEnabled = $false DigestAuthentication = $true + ExternalDownloadHostName = '' ExternalUrl = '' FormsAuthentication = $false GzipLevel = 'High' @@ -147,6 +154,7 @@ if ($exchangeInstalled) InstantMessagingCertificateThumbprint = $imCertThumbprint InstantMessagingServerName = $env:COMPUTERNAME InstantMessagingType = 'Ocs' + InternalDownloadHostName = '' InternalUrl = '' LogonPagePublicPrivateSelectionEnabled = $false LogonPageLightSelectionEnabled = $false diff --git a/tests/Unit/MSFT_xExchOwaVirtualDirectory.tests.ps1 b/tests/Unit/MSFT_xExchOwaVirtualDirectory.tests.ps1 index 62f1e267..a3e5cdec 100644 --- a/tests/Unit/MSFT_xExchOwaVirtualDirectory.tests.ps1 +++ b/tests/Unit/MSFT_xExchOwaVirtualDirectory.tests.ps1 @@ -33,6 +33,7 @@ try DefaultDomain = [System.String] '' DigestAuthentication = [System.Boolean] $false ExternalAuthenticationMethods = [System.String[]] @() + ExternalDownloadHostName = [System.String] '' ExternalUrl = [System.String] '' FormsAuthentication = [System.Boolean] $false GzipLevel = [System.String] '' @@ -40,6 +41,7 @@ try InstantMessagingEnabled = [System.Boolean] $false InstantMessagingServerName = [System.String] '' InstantMessagingType = [System.String] '' + InternalDownloadHostName = [System.String] '' InternalUrl = [System.String] '' LogonFormat = [System.String] '' LogonPageLightSelectionEnabled = [System.Boolean] $false @@ -65,4 +67,3 @@ finally { Invoke-TestCleanup } -