Practical guide
Recover Intune configuration after a compromise from a known-good backup
To recover Intune configuration after a compromise, restore from a backup that predates the attacker's first change and that the attacker could not reach. With that backup, TenuVault shows what was changed, restores the policies you approve and leaves you a short list of things to remove by hand. A restore does not delete what the attacker added, wiped devices have to be enrolled again and Entra accounts are repaired in Entra.
Also for Mac: Apple silicon · Intel
For Apple silicon Macs.Intel Mac? Get the Intel build
Also for Windows: direct download · Microsoft Store
Send yourself the link and install TenuVault on your computer.
Windows: direct download · Microsoft Store
Mac: Apple silicon · Intel
For Apple silicon Macs.Intel Mac? Get the Intel build
Free to download. Every new tenant starts with 14 days of Pro, with no card and no email. Plans and features
At a glance
- A backup is known-good because you chose one that predates the first malicious change. TenuVault does not detect malicious changes; it saves what the tenant held on the day.
- The default Run Backup scope in TenuVault 0.5.4 is Everything except apps, so choose Everything if an attacker could have added or changed an app.
- View Changes compares a backup with the one before it, Drift Detection compares two backups you pick, and neither compares the live tenant. Only the Review step of Replace in place checks your selection against the tenant as it is now.
- A restore puts an edited policy back, recreates a deleted one with its original name and a new ID and returns a changed assignment to the backed-up group. It never deletes the scripts, apps and role assignments an attacker added.
- Assignments on built-in Intune roles are not part of a TenuVault backup, so review them in Intune.
What makes a backup known-good?
Three properties, and the tool can only vouch for one of them. The backup has to predate the first malicious change, it has to sit where the attacker could not change or delete it, and it has to open and compare cleanly.
Date the first malicious change from the Intune audit log, then pick the newest backup before it. Keep enough history to reach back past a long period of undetected access, because a backup taken after the attacker started contains their changes as if they were yours.
Which backup scope should I use?
The first backup and the default in Run Backup use Everything except apps, which covers policies, scripts, updates, enrollment and tenant settings. An app that an attacker adds, or changes, only appears in backups that use the Everything scope, which adds app details and assignments. Installer files are never part of it.
When the scope you choose differs from the saved one, Run Backup offers to use it for automatic backups too. Use that for the backup of the current state in an incident, and consider it for your schedule, so the next comparison can see apps.
How do I recover step by step?
Start only after the compromised account is contained, as in the first-hour list of the incident guide. The labels below are those of TenuVault 0.5.4.
- Back up the current state: Backup and Restore, Run Backup, scope Everything. It is your evidence and the newer side of the comparison.
- Open Backup History, whose timeline lists each backup by date and time with its scope, and select the last backup from before the first malicious change.
- Find what changed. On the first backup after the attack, View Changes lists what was added, changed and deleted since the backup before it. In Drift Detection, set the known-good backup as Baseline (older) and your current-state backup as Comparison (newer).
- Select Restore from this backup and move through Items, Options, Review and Restore. Pick the affected items, and leave Restore method on Create copies first, which creates a [Restored] copy of each item without assignments and changes nothing that exists.
- Inspect the copies, then restore for real with Replace in place. Tick Restore assignments only for items whose targeting must come back, because it is off by default. Both Replace in place and Restore assignments are Pro and MSP features.
- Read the Review step before you confirm. It checks your selection against the tenant as it is now and labels each item: Overwrite the current version, Recreate: deleted from the tenant, or Skip: already matches the backup. The first write in a tenant also asks you to accept a disclaimer.
- Delete what the attacker added. Everything the comparison lists as Added is yours to remove in Intune, because a restore only writes from the backup.
- Check Intune role assignments in Intune, where built-in roles are listed, then enroll wiped devices again and complete installers and tokens.
- Run a fresh backup of the recovered state and write down the backup you used, the order of the steps and the IDs of items that were recreated.
What does a comparison show, and what does it miss?
The results below come from a rehearsal on 29 November 2026 in a lab tenant with TenuVault 0.5.4: a known-good backup, then six changes, then a second backup with the Everything scope.
| Change made | Shown by View Changes and Drift Detection |
|---|---|
| A new PowerShell script | Yes, as Added in Windows PowerShell scripts |
| A new app | Yes, as Added in apps, with an Everything backup |
| A deleted settings catalog policy | Yes, as Deleted |
| An edited setting in a policy | Yes, with the changed setting |
| A changed assignment on a compliance policy | Yes, as the old and new group ID |
| A new role assignment on a built-in Intune role | No, and it is in no backup |
What happens to the items after the restore?
In the same rehearsal, Replace in place with Restore assignments put the edited policy's setting back, recreated the deleted policy under its original name with a new ID and its assignment, and returned the compliance policy to its original group, removing the attacker's group instead of merging it. The added script, the added app and the added role assignment were all still there afterwards.
Plan for that last part. The cleanup list is the Added items of your comparison plus your own review of role assignments.
What if Multi Admin Approval protects the policies?
A restore of a protected item sends an approval request to a second administrator instead of writing at once, and assignments need a further approval. Plan the approvers into your recovery, and avoid a situation where the only approvers are the accounts under suspicion.
What can a restore not do?
Everything else in the incident, including how to contain it, is in the guide on what to do when a tenant is compromised.
- Undo a device wipe, retire or delete: the device is enrolled again, and a deleted managed device record cannot be restored.
- Repair Entra: TenuVault does not back up Entra users, and sessions, roles and credentials are handled in Entra.
- Remove what the attacker added, or decide which change was malicious: the comparison lists differences and you judge them.
- Restore masked secrets: a value Graph returned as asterisks needs a new backup while the profile exists.
Read the technical guides
Product scope reviewed . Check your installed release and the current plan table before using a workflow.
Frequently asked questions
What is the best way to recover Intune after a hack?+
Contain the account, then restore Intune configuration from a backup that predates the first malicious change and sits outside the tenant, using a comparison to see what changed. Delete what the attacker added, review role assignments and enroll wiped devices again.
Does a restore remove what the attacker added?+
No. A restore writes items from the backup and deletes nothing. New scripts and apps show as Added in View Changes or Drift Detection, and you delete them in Intune.
Why did my comparison not show an app the attacker added?+
The default backup scope is Everything except apps. Apps appear only in backups made with the Everything scope, so run the backup of the current state with that scope.
Can I recover from a backup stored in Azure?+
Yes, if the storage account was out of the attacker's reach. Azure backups are plain JSON, and TenuVault restores what it finds in the container, so restrict write access to it like Intune administrator access.
