Epoch fail —

64-bit iPhones and iPads get stuck in a loop when set to January 1, 1970

A great new prank to upset friends and family.

Zach Straley demonstrates the problem on an iPhone.

Take a 64-bit iOS device—iPhone 5S or newer, iPad Air or newer, iPad Mini 2 or newer, sixth generation iPod touch or newer—laboriously set its date to January 1, 1970, and reboot. Congratulations: you now have a shiny piece of high-tech hardware that's stuck at the boot screen, showing nothing more than the Apple logo... forever.

Posted on Reddit and subsequently demonstrated on YouTube, it appears that iOS has a rather embarrassing software flaw. Redditors testing the bug have found themselves with unusable phones, and there are reports that vandals have been resetting the clocks of display devices in Apple stores.

So far, taking advantage of this bug requires a few minutes of physical access, as it takes a while to wind the date back 46 years in the settings app. There is concern that Wi-Fi devices could be vulnerable to malicious data from NTP (network time protocol) servers. NTP is used by many operating systems to set the time and date of a device, and its data is both unencrypted and unauthenticated, making spoofing relatively straightforward. NTP clients should not generally change the time and date by such large amounts, so this may not be an issue, but iOS's behavior in this regard is currently unknown.

January 1, 1970 is the first day of the Unix epoch; Unix-like systems measure times and dates as the number of seconds since that day. This is traditionally stored as a 32-bit number (which is going to cause some trouble in 2038), and it's currently speculated that 64-bit iPhones are doing something peculiar when handling system times that are close to zero.

Devices afflicted with this issue can't even be recovered by going into DFU mode and reflashing them. Though this wipes out all your data, it retains the bad date and subsequent boot loop. The faulty date does get reset when the battery goes completely flat, however, so discharging the phone (or disconnecting the battery, if you're brave) fixes it.

With 2016 being a leap year, we doubt that this will be the last date-related bug to rear its head.

Channel Ars Technica