Microsoft365DSC icon indicating copy to clipboard operation
Microsoft365DSC copied to clipboard

AADGroupSettings Get-TargetResource expects value NewUnifiedGroupWritebackDefault which does not exist by default in Government tenants

Open mpoulson opened this issue 4 months ago • 0 comments

Description of the issue

MSFT_AADGroupsSettings.psm1 (Line 141) attempts to convert a null value for to Boolean ( [Boolean]::Parse($valueNewUnifiedGroupWritebackDefault.Value)) which throws an exception.

This value does not exist in all GCC-High Azure Government IL4 tenants.

Until it does correct option is to check for null empty before attempting to convert. if (-not [System.String]::IsNulorEmpty($valueNewUnifiedGroupWritebackDefault.Value)) { $result.Add('NewUnifiedGroupWritebackDefault', [Boolean]::Parse($valueNewUnifiedGroupWritebackDefault.Value)) }

Microsoft 365 DSC Version

1.24.1016.1

Which workloads are affected

Azure Active Directory (Entra ID)

The DSC configuration

Export-M365DSCConfiguration -Credential $creds -tenantID .onmicrosoft.us -Component @("AADGroup")

Verbose logs showing the problem

No response

Environment Information + PowerShell Version

No response

mpoulson avatar Oct 20 '24 01:10 mpoulson