Why this matters
Ransomware doesn't just encrypt your servers. It hunts for your backups. If the attacker can delete or encrypt the copies you rely on, you have no way back except paying. Cloud backups feel safe because they live off your network, but they're only safe if the ransomware can't reach them with the credentials it stole from your environment.
Most cloud backup tools use the same identity system as the rest of your cloud. A stolen admin key or a compromised sync client can wipe every snapshot and version. Attackers know this. They look for backup service accounts with broad permissions and no deletion protection. Once they have that, recovery becomes a negotiation.
The goal is simple: make sure the copy you need is still there after an attack, even if your main cloud account is fully compromised. That means separate trust boundaries, write-only access from production, and retention that can't be shortened by anyone with a normal admin role.
Protecting backups is not a one-time setup. You need to check it regularly, test restores, and watch for permission drift. The steps below give you a concrete plan you can run through in a few days.
Before you start
List every backup system you run: native cloud snapshots, managed backup services, third-party agents, SaaS export tools, and any scripts that copy data to object storage. For each one, note where the backup lives, which identity writes to it, and who can delete it. This inventory is the basis for everything else.
Decide on a separate backup account or subscription. It should not share administrators, identity provider groups, or root credentials with production. If you use a single cloud organization, create a dedicated account for backups and restrict who can log in. Keep the break-glass credentials offline.
Check whether your storage supports immutability. AWS S3 has Object Lock, Azure Blob Storage has immutable policies and legal holds, Google Cloud Storage has bucket lock and retention policies. Most managed backup services also offer vault lock or immutable retention. Know the exact feature names for your platform before you design the policy.
Agree on retention. How far back do you need to go? Daily backups for 30 days, weekly for 90, monthly for a year is a common starting point. Write it down. You will configure the policy to prevent anyone from deleting data before that window ends.
How to do it
Start by separating duties. The production account should be able to write backups but not delete them. Use a dedicated role with only the permissions needed to put objects or snapshots. Remove delete permissions from that role. If the backup tool requires a delete permission for lifecycle management, move that function to the backup account.
Enable immutability. On object storage, turn on Object Lock in compliance mode or a bucket lock policy. Set the retention period to match your agreed window. In compliance mode, no one, including the root user, can delete or shorten retention. That is the strongest protection. On managed backup services, enable vault lock and set the minimum retention. Read the documentation carefully: governance mode can be bypassed by privileged users, compliance mode cannot.
Use a separate identity provider or at least a separate group for backup administrators. Require multi-factor authentication. Do not let backup admins use the same accounts they use for daily work. If your backup tool supports it, require approval for any policy change.
Test a restore from a clean environment. Spin up a new virtual network, restore a sample volume, and verify the data. Do this at least quarterly. Also test that the backup account cannot be accessed with production credentials. Try to delete a backup object with the production role and confirm it fails.
- Inventory all backup systems. List every backup tool, snapshot policy, and export job. For each, note the storage location, the identity that writes to it, and who can delete it. This gives you the full attack surface.
- Create a separate backup account. Set up a dedicated cloud account or subscription for backups. Do not share administrators or identity groups with production. Keep break-glass credentials offline.
- Restrict write-only access from production. Create a role in the backup account that allows only write actions. Attach it to the production backup job. Remove any delete permissions from that role.
- Enable immutability with compliance mode. Turn on Object Lock, bucket lock, or vault lock in compliance mode. Set the retention period to match your agreed window. Confirm the policy applies to all backup storage.
- Separate backup administrators. Use a different identity provider group for backup admins. Require multi-factor authentication and just-in-time access. Do not let backup admins use daily work accounts.
- Test deletion and restore. Try to delete a backup from production and from a normal admin account. Both should fail. Then restore a sample volume in a clean environment and verify the data.
- Set alerts on backup account changes. Enable logging and alerting for delete attempts, policy changes, and permission updates in the backup account. Send alerts to a channel that is not dependent on production.
- Review permissions monthly. Check who can delete or change backup policies. Remove stale entries. Use access analyzer tools to find unintended access. Document the review.
How to check it worked
Run a deletion test. From the production account, attempt to delete a backup object or snapshot. It should fail with an access denied error. Then try from the backup admin account with a normal user. If immutability is in compliance mode, deletion should also fail until retention expires. Record the results.
Check the audit logs. Every cloud provider logs object-level and bucket-level actions. Look for DeleteObject, DeleteBucket, PutBucketPolicy, and similar events in the backup account. Set alerts for any deletion attempt or policy change. If you see a delete event that succeeded, investigate immediately.
Review permissions monthly. Look for any principal that has delete or policy-change rights on backup storage. Remove stale entries. Use the cloud provider's access analyzer or a simple script to list who can delete backups. The list should be short and known.
Validate retention settings. Confirm that the immutability policy is actually applied to all buckets or vaults. A common mistake is to set it on one bucket and forget the others. Check the retention period and mode. Ensure that lifecycle rules do not conflict with the retention policy.
Mistakes to avoid
Using the same account for production and backups. This is the most common failure. If the attacker gets domain admin in production, they can delete backups too. Always isolate the backup account and limit trust between them.
Relying on governance mode immutability. Governance mode allows users with special permissions to bypass retention. Ransomware operators often gain those permissions. Use compliance mode where available, and understand the trade-off: you cannot shorten retention even for legitimate reasons.
Forgetting about SaaS and endpoint backups. Cloud backups include Microsoft 365, Google Workspace, and endpoint management tools. These often have their own backup and retention settings. Apply the same separation and immutability principles.
Skipping restore tests. A backup you cannot restore is not a backup. Test restores regularly and from a clean environment. Also test that the restore process does not require production credentials that might be compromised. Keep restore documentation offline.
Frequently asked questions
Can ransomware encrypt cloud backups?
Yes, if the attacker has credentials that allow write or delete access to the backup storage. Ransomware can overwrite objects or change retention policies. That is why immutability and separate credentials are critical.
What is immutable backup storage?
Immutable storage prevents deletion or modification for a set period. In the cloud, this is often called Object Lock, bucket lock, or vault lock. Compliance mode makes the retention impossible to shorten, even by administrators.
How often should I test restoring backups?
Test a full restore at least quarterly. Also run a quick deletion test monthly to confirm immutability and permissions are still correct. Document each test and fix any failures immediately.