What to do when you forgot your iOS Restrictions passcode

The problem

It’s a bloody nightmare. You set a Restrictions password but you can’t remember it. Not to worry. If it’s only a few numerical digits, it *can* be cracked successfully. I’ve tried it and here’s how.

In brief

– We are going to make an unencrypted iTunes backup of the iOS device.

– We will then explore the backup with a third party app called iMazing.

– We will find the setting that contains the encryption keys for the passcode.

– We will use the encryption keys and run a decipher.

– We will wait for the decipher to find the passcode by ‘brute force’ (repeated automated attempts).

The solution

(1) Make an unencrypted iOS backup in iTunes. To do this launch iTunes, connect the iOS device, and ‘Back Up Now’ to ‘This computer’ with ‘Encrypt’ *unticked*.

(2) Download, install and launch iMazing.

(3) Under Backups, select the backup that you have just made. Then choose File System.

(4) Once loaded, go into: HomeDomain > Library > Preferences.

(5) Find “com.apple.restrictionspassword.plist” and “Copy to Mac”.

(6) Look at the file you just inspected and identify the two bits of ‘data’ (one’s long and one’s shorter).

(7) Go to the iOS Restrictions Passcode Cracker and input the two keys (RestrictionsPasswordKey and RestrictionsPasswordSalt).

(8) Click “Search for Code” and wait for the Javascript application to find your code. Hooray. It was just my mum’s birthday.

(9) Head back to the phone and using the recovered passcode, change the passcode to something easier to remember!

[Tested with iOS 11, MacOS 10.13, iTunes 12, iMazing 2.]

Hat Tip

Jim Karpen