IntuneDeviceCompliancePolicyiOs¶
Parameters¶
| Parameter | Attribute | DataType | Description | Allowed Values |
|---|---|---|---|---|
| DisplayName | Key | String | Display name of the iOS device compliance policy. | |
| Id | Write | String | The Id of the policy. | |
| Description | Write | String | Description of the iOS device compliance policy. | |
| RoleScopeTagIds | Write | String[] | List of Scope Tags for this Entity instance. | |
| Assignments | Write | MSFT_DeviceManagementConfigurationPolicyAssignments[] | Assignments of the Intune Policy. | |
| PasscodeBlockSimple | Write | Boolean | PasscodeBlockSimple of the iOS device compliance policy. | |
| PasscodeExpirationDays | Write | UInt32 | PasscodeExpirationDays of the iOS device compliance policy. | |
| PasscodeMinimumLength | Write | UInt32 | PasscodeMinimumLength of the iOS device compliance policy. | |
| PasscodeMinutesOfInactivityBeforeLock | Write | UInt32 | PasscodeMinutesOfInactivityBeforeLock of the iOS device compliance policy. | |
| PasscodeMinutesOfInactivityBeforeScreenTimeout | Write | UInt32 | Minutes of inactivity before the screen times out. | |
| PasscodePreviousPasscodeBlockCount | Write | UInt32 | PasscodePreviousPasscodeBlockCount of the iOS device compliance policy. | |
| PasscodeMinimumCharacterSetCount | Write | UInt32 | PasscodeMinimumCharacterSetCount of the iOS device compliance policy. | |
| PasscodeRequiredType | Write | String | PasscodeRequiredType of the iOS device compliance policy. | deviceDefault, alphanumeric, numeric |
| PasscodeRequired | Write | Boolean | PasscodeRequired of the iOS device compliance policy. | |
| OsMinimumVersion | Write | String | OsMinimumVersion of the iOS device compliance policy. | |
| OsMaximumVersion | Write | String | OsMaximumVersion of the iOS device compliance policy. | |
| OsMinimumBuildVersion | Write | String | Minimum IOS build version. | |
| OsMaximumBuildVersion | Write | String | Maximum IOS build version. | |
| ScheduledActionsForRule | Write | MSFT_ScheduledActionConfigurations[] | Specifies the non-compliance actions. | |
| SecurityBlockJailbrokenDevices | Write | Boolean | SecurityBlockJailbrokenDevices of the iOS device compliance policy. | |
| DeviceThreatProtectionEnabled | Write | Boolean | DeviceThreatProtectionEnabled of the iOS device compliance policy. | |
| DeviceThreatProtectionRequiredSecurityLevel | Write | String | Require Mobile Threat Protection minimum risk level to report noncompliance. | unavailable, secured, low, medium, high, notSet |
| AdvancedThreatProtectionRequiredSecurityLevel | Write | String | MDATP Require Mobile Threat Protection minimum risk level to report noncompliance. | unavailable, secured, low, medium, high, notSet |
| ManagedEmailProfileRequired | Write | Boolean | ManagedEmailProfileRequired of the iOS device compliance policy. | |
| RestrictedApps | Write | MSFT_appListItem[] | Credentials of the Intune Admin | |
| Ensure | Write | String | Present ensures the policy exists, absent ensures it is removed. | Present, Absent |
| Credential | Write | PSCredential | Credentials of the Intune Admin | |
| ApplicationId | Write | String | Id of the Azure Active Directory application to authenticate with. | |
| TenantId | Write | String | Id of the Azure Active Directory tenant used for authentication. | |
| ApplicationSecret | Write | PSCredential | Secret of the Azure Active Directory tenant used for authentication. | |
| CertificateThumbprint | Write | String | Thumbprint of the Azure Active Directory application's authentication certificate to use for authentication. | |
| CertificatePassword | Write | PSCredential | Username can be made up to anything but password will be used for CertificatePassword | |
| CertificatePath | Write | String | Path to certificate used in service principal usually a PFX file. | |
| ManagedIdentity | Write | Boolean | Managed ID being used for authentication. | |
| AccessTokens | Write | String[] | Access token used for authentication. |
Embedded Instances¶
MSFT_DeviceManagementConfigurationPolicyAssignments¶
Parameters¶
| Parameter | Attribute | DataType | Description | Allowed Values |
|---|---|---|---|---|
| dataType | Required | String | The type of the target assignment. | #microsoft.graph.cloudPcManagementGroupAssignmentTarget, #microsoft.graph.groupAssignmentTarget, #microsoft.graph.allLicensedUsersAssignmentTarget, #microsoft.graph.allDevicesAssignmentTarget, #microsoft.graph.exclusionGroupAssignmentTarget, #microsoft.graph.configurationManagerCollectionAssignmentTarget |
| deviceAndAppManagementAssignmentFilterType | Write | String | The type of filter of the target assignment i.e. Exclude or Include. Possible values are:none, include, exclude. | none, include, exclude |
| deviceAndAppManagementAssignmentFilterId | Write | String | The Id of the filter for the target assignment. | |
| deviceAndAppManagementAssignmentFilterDisplayName | Write | String | The display name of the filter for the target assignment. | |
| groupId | Write | String | The group Id that is the target of the assignment. | |
| groupDisplayName | Write | String | The group Display Name that is the target of the assignment. | |
| collectionId | Write | String | The collection Id that is the target of the assignment.(ConfigMgr) |
MSFT_ScheduledActionConfigurations¶
Parameters¶
| Parameter | Attribute | DataType | Description | Allowed Values |
|---|---|---|---|---|
| id | Write | String | The unique identifier of the action configuration. | |
| gracePeriodHours | Write | UInt32 | Number of hours to wait till the action will be enforced. Valid values 0 to 8760. | |
| actionType | Write | String | The action to take. | notification, block, retire, remoteLock, pushNotification |
| notificationTemplateId | Write | String | The notification Message template to use. | |
| notificationMessageCCList | Write | String[] | A list of group IDs to specify who to CC this notification message to. |
MSFT_appListItem¶
Parameters¶
| Parameter | Attribute | DataType | Description | Allowed Values |
|---|---|---|---|---|
| name | Write | String | The application name. | |
| publisher | Write | String | The publisher of the application. | |
| appStoreUrl | Write | String | The Store URL of the application. | |
| appId | Required | String | The application or bundle identifier of the application. |
Description¶
This resource configures the Intune compliance policies for iOs devices.
Permissions¶
Graph¶
To authenticate with the Graph API, this resource requires the following permissions:
Delegated permissions¶
- Read
-
GroupMember.Read.All, DeviceManagementConfiguration.Read.All, DeviceManagementRBAC.Read.All
-
Update
- GroupMember.Read.All, DeviceManagementConfiguration.ReadWrite.All, DeviceManagementRBAC.Read.All
Application permissions¶
- Read
-
GroupMember.Read.All, DeviceManagementConfiguration.Read.All, DeviceManagementRBAC.Read.All
-
Update
- GroupMember.Read.All, DeviceManagementConfiguration.ReadWrite.All, DeviceManagementRBAC.Read.All
Examples¶
Example 1¶
This example creates a new Device Compliance Policy for iOs devices
Configuration Example
{
param
(
[Parameter()]
[System.String]
$ApplicationId,
[Parameter()]
[System.String]
$TenantId,
[Parameter()]
[System.String]
$CertificateThumbprint
)
Import-DscResource -ModuleName Microsoft365DSC
Node localhost
{
IntuneDeviceCompliancePolicyiOs 'IntuneDeviceCompliancePolicyiOs-Example'
{
DisplayName = 'iOS Device Compliance'
Description = 'Baseline compliance requirements for corporate iPhones and iPads'
RoleScopeTagIds = @('0')
Assignments = @(
MSFT_DeviceManagementConfigurationPolicyAssignments{
dataType = '#microsoft.graph.allDevicesAssignmentTarget'
deviceAndAppManagementAssignmentFilterType = 'none'
}
MSFT_DeviceManagementConfigurationPolicyAssignments{
dataType = '#microsoft.graph.exclusionGroupAssignmentTarget'
deviceAndAppManagementAssignmentFilterType = 'none'
groupDisplayName = 'iOS Compliance Exclusions'
}
)
PasscodeBlockSimple = $True
PasscodeExpirationDays = 365
PasscodeMinimumLength = 6
PasscodeMinutesOfInactivityBeforeLock = 5
PasscodeMinutesOfInactivityBeforeScreenTimeout = 5
PasscodePreviousPasscodeBlockCount = 3
PasscodeMinimumCharacterSetCount = 2
PasscodeRequiredType = 'alphanumeric'
PasscodeRequired = $True
OsMinimumVersion = '16.0'
OsMaximumVersion = '18.5'
OsMinimumBuildVersion = '20A362'
OsMaximumBuildVersion = '22F76'
ScheduledActionsForRule = @(
MSFT_ScheduledActionConfigurations{
actionType = 'block'
gracePeriodHours = 24
}
)
SecurityBlockJailbrokenDevices = $True
DeviceThreatProtectionEnabled = $True
DeviceThreatProtectionRequiredSecurityLevel = 'medium'
AdvancedThreatProtectionRequiredSecurityLevel = 'medium'
ManagedEmailProfileRequired = $True
RestrictedApps = @(
MSFT_appListItem{
name = 'Facebook'
publisher = 'Meta Platforms, Inc.'
appStoreUrl = 'https://apps.apple.com/app/facebook/id284882215'
appId = 'com.facebook.Facebook'
}
)
Ensure = 'Present'
ApplicationId = $ApplicationId;
TenantId = $TenantId;
CertificateThumbprint = $CertificateThumbprint;
}
}
}
Example 2¶
This example creates a new Device Compliance Policy for iOs devices
Configuration Example
{
param
(
[Parameter()]
[System.String]
$ApplicationId,
[Parameter()]
[System.String]
$TenantId,
[Parameter()]
[System.String]
$CertificateThumbprint
)
Import-DscResource -ModuleName Microsoft365DSC
Node localhost
{
IntuneDeviceCompliancePolicyiOs 'IntuneDeviceCompliancePolicyiOs-Example'
{
DisplayName = 'iOS Device Compliance'
Description = 'Baseline compliance requirements for corporate iPhones and iPads'
RoleScopeTagIds = @('0')
Assignments = @(
MSFT_DeviceManagementConfigurationPolicyAssignments{
dataType = '#microsoft.graph.allDevicesAssignmentTarget'
deviceAndAppManagementAssignmentFilterType = 'none'
}
MSFT_DeviceManagementConfigurationPolicyAssignments{
dataType = '#microsoft.graph.exclusionGroupAssignmentTarget'
deviceAndAppManagementAssignmentFilterType = 'none'
groupDisplayName = 'iOS Compliance Exclusions'
}
)
PasscodeBlockSimple = $True
PasscodeExpirationDays = 365
PasscodeMinimumLength = 8 # Updated Property
PasscodeMinutesOfInactivityBeforeLock = 5
PasscodeMinutesOfInactivityBeforeScreenTimeout = 5
PasscodePreviousPasscodeBlockCount = 3
PasscodeMinimumCharacterSetCount = 2
PasscodeRequiredType = 'alphanumeric'
PasscodeRequired = $True
OsMinimumVersion = '16.0'
OsMaximumVersion = '18.5'
OsMinimumBuildVersion = '20A362'
OsMaximumBuildVersion = '22F76'
ScheduledActionsForRule = @(
MSFT_ScheduledActionConfigurations{
actionType = 'block'
gracePeriodHours = 24
}
)
SecurityBlockJailbrokenDevices = $True
DeviceThreatProtectionEnabled = $True
DeviceThreatProtectionRequiredSecurityLevel = 'medium'
AdvancedThreatProtectionRequiredSecurityLevel = 'medium'
ManagedEmailProfileRequired = $True
RestrictedApps = @(
MSFT_appListItem{
name = 'Facebook'
publisher = 'Meta Platforms, Inc.'
appStoreUrl = 'https://apps.apple.com/app/facebook/id284882215'
appId = 'com.facebook.Facebook'
}
)
Ensure = 'Present'
ApplicationId = $ApplicationId;
TenantId = $TenantId;
CertificateThumbprint = $CertificateThumbprint;
}
}
}
Example 3¶
This example creates a new Device Compliance Policy for iOs devices
Configuration Example
{
param
(
[Parameter()]
[System.String]
$ApplicationId,
[Parameter()]
[System.String]
$TenantId,
[Parameter()]
[System.String]
$CertificateThumbprint
)
Import-DscResource -ModuleName Microsoft365DSC
Node localhost
{
IntuneDeviceCompliancePolicyiOs 'IntuneDeviceCompliancePolicyiOs-Example'
{
DisplayName = 'iOS Device Compliance'
Ensure = 'Absent'
ApplicationId = $ApplicationId;
TenantId = $TenantId;
CertificateThumbprint = $CertificateThumbprint;
}
}
}