How to Delete an iPhone Passcode Through SSH

SSH is a file-system explorer application the allows you to view the file system on a jailbroken iPhone from a computer on the same Wi-Fi network as the device. Almost every aspect of the device can be manipulated from within the device's file system, including the passcode. If you need to remove the lock-screen passcode on your iPhone through the SSH file system explorer, you can do so in a few simple steps.

...
Jailbreaking an iPhone, while completely legal, voids your warranty with Apple.

Step

Tap the "Settings" icon on the iPhone's home screen, followed by the "Wi-Fi" option. Tap the arrow to the right of the Wi-Fi connection your phone is connected to and write down the IP address listed beneath the "IP Address" heading.

Step

Double-click the SSH client icon on the computer. Type the IP address you wrote down in Step 1 in the space labeled "Server." Type "root" in the space labeled "Username" and "alpine" in the space labeled "Password." Click the "Connect" button to connect the SSH server.

Step

Open the "var" folder, followed by the "mobile" folder. Open the "Library" folder, followed by the "Preferences" folder. Delete the file named "com.apple.springboard.plist." This file contains the setting that tells your device the passcode is activated.

Step

Open the "var" folder, followed by the "Keychains" folder. Delete the file titled "keychain-2.db." This file contains the passcode itself.

Step

Click the "Disconnect" button to disconnect the iPhone from the SSH server. Press and hold the iPhone's "Home" button and "Sleep/Wake" button to reboot the device. Once the iPhone reboots, you can access the device without entering the passcode.