How to Control USB Restricted Mode on iPhone XR and XS
With iOS 11.4.1, Apple introduced a security measure called USB Restricted Mode that limits the period of time during which external USB accessories can connect to your iPhone. On the default setting, if your device has been locked for over an hour, USB accessories won't be able to communicate with it. You can turn this off, however, enabling accessories to interface with your phone even if it's been locked for an indeterminate amount of time.
The feature continues in iOS 12, and has drawn criticism from law enforcement officials because it theoretically prevents them from using devices like the infamous GrayKey to crack passcodes and passwords. Apple also notes that this safeguard may not allow some gadgets to recharge your iPhone until the handset has been unlocked first.
That said, USB Restricted Mode is a valuable security measure because it lessens the chance that thieves will have access sensitive personal data on your phone in the unfortunate scenario that it falls into the wrong hands. Here's how to find and control it on the iPhone XS, XR and X.—Adam Ismail
1. Navigate to Face ID & Passcode inside the Settings app.
2. Input your passcode when asked.
3. Scroll down to USB Accessories, under the Allow Access When Locked grouping. By default the toggle is off, meaning your iPhone will be unable to communicate with external USB accessories once it's been locked for an hour or more. If you switch this on, your iPhone and all its contents will be available to USB accessories no matter how long it has been locked, and you won't have to unlock it first to allow the two devices to connect.