In short
Microsoft Intune configuration export: the file Microsoft Intune writes of its own settings, which a configuration review reads setting by setting without connecting to Microsoft Intune.
How to export the Microsoft Intune configuration, step by step, what the review checks in the file (32 checks run), and what it does not read.
| The file | JSON, one file named intune.json: { "configurationProfiles": [ … ], "compliancePolicies": [ … ], "appProtectionPolicies": [ … ] }, each entry as Microsoft Graph v1.0 returns it |
|---|---|
| Checks run on it | 32 |
| Highest grade its findings reach | OBSERVED |
| Feeds attack paths | No |
| Not read from this export | 2 areas, listed below |
Sources: Microsoft Intune documentation (1); Microsoft Intune documentation (2); Microsoft Intune documentation (3); the vendor table.
How to export it
- Who can pull it
- An account with the Intune built-in role Read Only Operator, signing in with the two Microsoft Graph delegated permissions DeviceManagementConfiguration.Read.All and DeviceManagementApps.Read.All. The role is needed to see the policies: "Read Only Operators view user, device, enrollment, configuration and application information and cannot make changes to Intune." The two permissions are the lowest ones in Microsoft’s tables for these four lists; Microsoft marks both as needing an administrator’s consent. Scope tags limit what the account sees: "If a role assignment has no scope tag, that IT admin can see all objects based on the IT admins permissions." With scope tags, the file holds just the policies that carry a matching tag.
- Time
- About 10 minutes; about 10 more on a computer or in a tenant that has not run these steps before, to install the module and get an administrator’s consent.
- The file
- JSON, one file named intune.json: { "configurationProfiles": [ … ], "compliancePolicies": [ … ], "appProtectionPolicies": [ … ] }, each entry as Microsoft Graph v1.0 returns it
No console export: In the Intune admin center, Microsoft documents a file export for a Windows settings catalog policy (the policy’s context menu > Export JSON), which the review does not read. For the three lists this guide needs, use the PowerShell steps.
From the command line
Once per computer (skip if it is already installed):
The vendor's page, checked 2026-11-11Install-Module Microsoft.Graph.Authentication -Scope CurrentUser -Repository PSGallery(If PowerShell says running scripts is disabled, or that the command "was found in the module … but the module could not be loaded", runSet-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser(no administrator rights needed) and then this line again)
The vendor's page, checked 2026-11-11Connect-MgGraph -Scopes "DeviceManagementConfiguration.Read.All", "DeviceManagementApps.Read.All"Define a helper that reads one Microsoft Graph list page by page, following @odata.nextLink until there is none:
The vendor's page, checked 2026-11-11function Get-GraphList($u) { $all = @(); while ($u) { $r = Invoke-MgGraphRequest -Method GET -Uri $u; $all += @($r.value); $u = $r.'@odata.nextLink' }; $all }Read the device configuration profiles:
The vendor's page, checked 2026-11-11$profiles = @(Get-GraphList 'https://graph.microsoft.com/v1.0/deviceManagement/deviceConfigurations')Read the device compliance policies:
The vendor's page, checked 2026-11-11$compliance = @(Get-GraphList 'https://graph.microsoft.com/v1.0/deviceManagement/deviceCompliancePolicies')Read the iOS app protection policies:
The vendor's page, checked 2026-11-11$ios = @(Get-GraphList 'https://graph.microsoft.com/v1.0/deviceAppManagement/iosManagedAppProtections')Read the Android app protection policies:
The vendor's page, checked 2026-11-11$android = @(Get-GraphList 'https://graph.microsoft.com/v1.0/deviceAppManagement/androidManagedAppProtections')Write the three lists to one file:
The vendor's page, checked 2026-11-11ConvertTo-Json -InputObject @{ configurationProfiles = $profiles; compliancePolicies = $compliance; appProtectionPolicies = $ios + $android } -Depth 20 | Out-File -Encoding utf8 intune.jsonAfter the upload has gone through, sign out:
The vendor's page, checked 2026-11-11Disconnect-MgGraph(Microsoft: "Use Disconnect-MgGraph to sign out.")
What the file looks like
JSON, one file named intune.json: { "configurationProfiles": [ … ], "compliancePolicies": [ … ], "appProtectionPolicies": [ … ] }, each entry as Microsoft Graph v1.0 returns it. It varies with the number of profiles and policies in the tenant and with how many settings each one holds: Microsoft documents no size. The upload takes files up to 10 MB.
What it holds: Device configuration profiles (including Windows update rings), device compliance policies, and app protection policies for iOS and Android, with their settings as Microsoft Graph v1.0 returns them.
intune.json is saved in the folder PowerShell shows before the > (usually C:\Users\<you> on Windows). It holds three lists as Microsoft Graph v1.0 returns them: configurationProfiles, compliancePolicies and appProtectionPolicies (iOS and Android). The helper asks for the next page until Microsoft Graph returns no @odata.nextLink, so each list is complete. -Depth 20 keeps the nested settings (ConvertTo-Json stops at 2 levels by default). Out-File -Encoding utf8 writes UTF-8: without -Encoding, Out-File in Windows PowerShell 5.1 writes UTF-16, which the upload refuses. A Microsoft Graph list holds no assignments and no list of the apps a policy covers. They are not in the file, so the review raises no finding about them and does not count them as passed.
Afterwards
Run Disconnect-MgGraph and delete intune.json. If you set the execution policy for this export: Set-ExecutionPolicy -ExecutionPolicy Undefined -Scope CurrentUser . To remove the consent grant, a Cloud Application Administrator opens the Microsoft Entra admin center: Entra ID > Enterprise apps > All applications > Microsoft Graph Command Line Tools > Permissions > Admin consent > ... > Revoke permission.
If the export goes wrong
| What you see | The fix |
|---|---|
| Windows PowerShell will not run Install-Module or Connect-MgGraph, or does not know the commands Connect-MgGraph and Invoke-MgGraphRequest. | Microsoft: "The PowerShell script execution policy must be set to remote signed or less restrictive." Run Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser , then run the Install-Module step again (Install-Module Microsoft.Graph.Authentication -Scope CurrentUser -Repository PSGallery), open a new PowerShell window and start again from Connect-MgGraph. |
| The sign-in stops with a message that the application "needs permission to access resources in your organization that only an admin can grant". | Both permissions need an administrator’s consent. Ask an administrator who may grant consent to sign in with the same Connect-MgGraph line and approve it, then sign in again yourself. Microsoft: the check box that gives consent "on behalf of the entire tenant" shows "for at least the Privileged Role Administrator role"; ticking it grants the two read permissions for every user of this application in your tenant. |
| Invoke-MgGraphRequest stops with 403 Forbidden, or intune.json holds fewer policies than the Intune admin center shows. | Microsoft Graph answers 403 when "The user does not have enough permission or does not have a required license"; fewer policies points to scope tags. Ask an administrator with the Intune Role Administrator role to open the Intune admin center, Tenant administration > Roles > All roles > Read Only Operator > Assignments > + Assign, add your group and leave the scope tags empty (Microsoft: "Admins that have no scope tags essentially have all scope tags."). Then run Connect-MgGraph again. |
What we read from it
- Checks run
- 32 + 3 guidance items, not counted
- Formats read
- Configuration profile JSON export
- Releases
- 2024.1 to current
Checks run is the number of checks that reached a result on this system's own export in our tests, as the vendor table shows it.
The areas checked
- Device configuration profiles: password rules (required, length, simple passwords, reuse, expiry, idle lock), the firewall default for inbound connections, and the BitLocker cipher for removable drives
- Windows update rings: the quality update deferral
- Compliance policies: BitLocker, Secure Boot, code integrity, storage encryption, password rules, jailbroken or rooted devices, and the required threat protection level
- App protection policies for iOS and Android: simple personal identification number (PIN), PIN length and retries, data transfer in and out, save-as and backup, printing, contact sync, encryption of app data, screen capture on Android, the managed browser, the offline wipe and offline access intervals, and whether device compliance is required
The grade its findings reach
Observed Findings from this file are OBSERVED: read from the system's own export and cited to the setting.
Its findings stay in the review and its reports. Microsoft Intune does not feed attack paths.
Attack paths, the one change and dollar figures are MODELED. How each grade is worked out is on the method page.
What we do not read from this export
- Assignments: a Microsoft Graph list does not hold them, so the review raises no finding about them
- The apps each app protection policy covers: not in this export, so the review raises no finding about them
- Settings catalog policies and endpoint security policies (antivirus, disk encryption, firewall, attack surface reduction, account protection): not in this export, and not read
- Security baselines: not in this export (Microsoft Graph lists them among the configuration policies, a separate beta call)
- Enrolment restrictions: not in this export (a separate Microsoft Graph list with its own permission)
- Windows compliance settings that the Microsoft Graph v1.0 resource does not list (tpmRequired, antivirusRequired, antiSpywareRequired, defenderEnabled, signatureOutOfDate, activeFirewallRequired): not in this export
- iOS passcode rules in compliance policies: in the file, not read (Microsoft Graph names them passcode…)
- Defender, SmartScreen and removable storage settings inside device restriction profiles: in the file, not read
- Actions for noncompliance and their grace periods: not in this export
- Which devices fall short under each policy
- Assignment filter expressions
Limits of the reader
- Findings stay in the review. They do not feed attack paths.
- The checks of this system are not counted: a check counts once a test shows it firing on a file in the layout the vendor documents.
A finding never comes from what the file does not hold: live traffic, running hosts and logs are not in a configuration export.
Questions
Who can export the Microsoft Intune configuration?
An account with the Intune built-in role Read Only Operator, signing in with the two Microsoft Graph delegated permissions DeviceManagementConfiguration.Read.All and DeviceManagementApps.Read.All. The role is needed to see the policies: "Read Only Operators view user, device, enrollment, configuration and application information and cannot make changes to Intune." The two permissions are the lowest ones in Microsoft’s tables for these four lists; Microsoft marks both as needing an administrator’s consent. Scope tags limit what the account sees: "If a role assignment has no scope tag, that IT admin can see all objects based on the IT admins permissions." With scope tags, the file holds just the policies that carry a matching tag.
Does the export change anything?
Signing in adds a consent grant in your tenant for the Microsoft app "Microsoft Graph Command Line Tools" (two read permissions), unless it is already there. The steps install the Microsoft.Graph.Authentication module for your user and, if you ran that line, set your execution policy. The Graph calls are GET reads.
Does the file hold passwords or keys?
The file holds the settings of each exported profile and policy as clear-text JSON: names, IDs, excluded paths and processes, firewall and BitLocker choices, and the values of custom profiles. Microsoft Graph documents a preSharedKey property on Wi-Fi profiles; its documentation does not say whether a list answer returns the key. Treat the file as confidential. With redaction on (the default), the passwords, keys and tokens the review recognises are replaced with a placeholder before anything is stored; the check before upload shows how many it found.