Apple’s USB Restricted Mode – your iPhone’s latest security feature
Apple quietly introduced a significant privacy safeguard as part of the new iOS 11.4.1 update that was released on July 9th. USB Restricted Mode prevents USB accessories that plug into the Lightning port from making data connections with an iPhone, iPad, or iPod Touch if your iOS device has been locked for over an hour.
USB Restricted Mode works like this: after an hour of your iPhone, iPad, or iPod Touch sitting without being unlocked, iOS will basically cut off the Lightning port and limit it to charging only. This hour timeout should theoretically stop devices like GrayKey (which plugs into an iPhone and cracks the passcode within a few hours) from working successfully.
If you’re not concerned about someone potentially breaking their way into your iOS device, you can disable the new security measure immediately. Just go to Settings —> Face ID (or Touch ID) & Passcode —> USB Accessories. Toggle this option to on (green) and your accessories will function the exact same way they did before iOS 11.4.1.