Skip to content

Commit

Permalink
Add Intune Group.Read.All permissions to generated permissions
Browse files Browse the repository at this point in the history
  • Loading branch information
FabienTschanz committed Oct 22, 2024
1 parent 7653231 commit a6fab10
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion ResourceGenerator/M365DSCResourceGenerator.psm1
Original file line number Diff line number Diff line change
Expand Up @@ -967,7 +967,15 @@ class MSFT_DeviceManagementConfigurationPolicyAssignments
-Workload $Workload `
-CmdLetNoun $CmdLetNoun `
-ApiVersion $ApiVersion `
-UpdateVerb $updateVerb).permissions | ConvertTo-Json -Depth 20
-UpdateVerb $updateVerb).permissions
if ($ResourceName -like "Intune*")
{
$resourcePermissions.application.read += @{ name = 'Group.Read.All' }
$resourcePermissions.application.update += @{ name = 'Group.Read.All' }
$resourcePermissions.delegated.read += @{ name = 'Group.Read.All' }
$resourcePermissions.delegated.update += @{ name = 'Group.Read.All' }
}
$resourcePermissions = $resourcePermissions | ConvertTo-Json -Depth 20
$resourcePermissions = ' ' + $resourcePermissions
Write-TokenReplacement -Token '<ResourceFriendlyName>' -Value $ResourceName -FilePath $settingsFilePath
Write-TokenReplacement -Token '<ResourceDescription>' -Value $resourceDescription -FilePath $settingsFilePath
Expand Down

0 comments on commit a6fab10

Please sign in to comment.