Skip to content

Commit 4e0a403

Browse files
Merge pull request #6398 from FabienTschanz/fix/aadcrosstenant-export
Fix export of cross tenant access policy
2 parents a35d5e0 + 9c6526d commit 4e0a403

File tree

2 files changed

+11
-9
lines changed

2 files changed

+11
-9
lines changed

CHANGELOG.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,9 @@
44

55
* AADApplication
66
* Fixed an issue where not all properties were exported.
7+
* AADCrossTenantAccessPolicyConfigurationDefault
8+
* Fixed an issue where the export returns an invalid value for `Targets`.
9+
FIXES [#6397](https://github.com/microsoft/Microsoft365DSC/issues/6397)
710
* AADServicePrincipal
811
* Fixes for retrieving instance by name.
912
* AADUser

Modules/Microsoft365DSC/DSCResources/MSFT_AADCrossTenantAccessPolicyConfigurationDefault/MSFT_AADCrossTenantAccessPolicyConfigurationDefault.psm1

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -101,11 +101,11 @@ function Get-TargetResource
101101
$B2BCollaborationInboundValue = @{
102102
Applications = @{
103103
AccessType = $getValue.B2BCollaborationInbound.Applications.AccessType
104-
Targets = [System.String[]] $getValue.B2BCollaborationInbound.Applications.Targets
104+
Targets = [System.Array]$getValue.B2BCollaborationInbound.Applications.Targets
105105
}
106106
UsersAndGroups =@{
107107
AccessType = $getValue.B2BCollaborationInbound.UsersAndGroups.AccessType
108-
Targets = [System.String[]] $getValue.B2BCollaborationInbound.UsersAndGroups.Targets
108+
Targets = [System.Array] $getValue.B2BCollaborationInbound.UsersAndGroups.Targets
109109
}
110110
}
111111
}
@@ -114,11 +114,11 @@ function Get-TargetResource
114114
$B2BCollaborationOutboundValue = @{
115115
Applications = @{
116116
AccessType = $getValue.B2BCollaborationOutbound.Applications.AccessType
117-
Targets = [System.String[]] $getValue.B2BCollaborationOutbound.Applications.Targets
117+
Targets = [System.Array] $getValue.B2BCollaborationOutbound.Applications.Targets
118118
}
119119
UsersAndGroups =@{
120120
AccessType = $getValue.B2BCollaborationOutbound.UsersAndGroups.AccessType
121-
Targets = [System.String[]] $getValue.B2BCollaborationOutbound.UsersAndGroups.Targets
121+
Targets = [System.Array] $getValue.B2BCollaborationOutbound.UsersAndGroups.Targets
122122
}
123123
}
124124
}
@@ -127,11 +127,11 @@ function Get-TargetResource
127127
$B2BDirectConnectInboundValue = @{
128128
Applications = @{
129129
AccessType = $getValue.B2BDirectConnectInbound.Applications.AccessType
130-
Targets = [System.String[]] $getValue.B2BDirectConnectInbound.Applications.Targets
130+
Targets = [System.Array] $getValue.B2BDirectConnectInbound.Applications.Targets
131131
}
132132
UsersAndGroups =@{
133133
AccessType = $getValue.B2BDirectConnectInbound.UsersAndGroups.AccessType
134-
Targets = [System.String[]] $getValue.B2BDirectConnectInbound.UsersAndGroups.Targets
134+
Targets = [System.Array] $getValue.B2BDirectConnectInbound.UsersAndGroups.Targets
135135
}
136136
}
137137
}
@@ -140,11 +140,11 @@ function Get-TargetResource
140140
$B2BDirectConnectOutboundValue = @{
141141
Applications = @{
142142
AccessType = $getValue.B2BDirectConnectOutbound.Applications.AccessType
143-
Targets = [System.String[]] $getValue.B2BDirectConnectOutbound.Applications.Targets
143+
Targets = [System.Array] $getValue.B2BDirectConnectOutbound.Applications.Targets
144144
}
145145
UsersAndGroups =@{
146146
AccessType = $getValue.B2BDirectConnectOutbound.UsersAndGroups.AccessType
147-
Targets = [System.String[]] $getValue.B2BDirectConnectOutbound.UsersAndGroups.Targets
147+
Targets = [System.Array] $getValue.B2BDirectConnectOutbound.UsersAndGroups.Targets
148148
}
149149
}
150150
}
@@ -837,4 +837,3 @@ function Get-M365DSCAADCrossTenantAccessPolicyInboundTrust
837837
}
838838

839839
Export-ModuleMember -Function *-TargetResource
840-

0 commit comments

Comments
 (0)