Ever since Apple unveiled the iPhone X with FaceID, people have been asking the same, very pertinent question. What if some mugger or unscrupulous cop snatches the device out of your hands and points the depth-sensing camera at your face? According to an email purportedly from Apple's Craig Federighi, there's a built-in safeguard for such an event.
Keith Krimbel was sufficiently moved by the worries about how FaceID could be abused that he emailed the Apple executive. He posted the response to his Twitter, where Federighi explains that there are two different ways that the FaceID system can be stifled. Firstly, if you don't stare at the phone, it won't unlock, and presumably that means you need to have your eyes open.
The second is that if you squeeze the power and volume buttons on either side of the device before handing it over, FaceID will be temporarily disabled. It's not clear how long you need to squeeze them for, or how long FaceID will be blocked once you do so, but Apple has, at least, thought about the situation somewhat. We've reached out to Apple to confirm if Federighi's email is genuine, and will update this if we hear back.
Although it's worth mentioning that some of the concerns surrounding FaceID were already resolved with TouchID, which first popped up in the iPhone 5S. For instance, a Court in Virginia Beach ruled in 2014 that while passcodes are protected by the Fifth Amendment, fingerprints are not. As a consequence, law enforcement officials in several other instances have placed suspects fingers on phones to unlock them. It's likely, therefore, that your face would be as equally fair game.
It is worth noting, however, that while law enforcement officers can unlock your phone without your consent, they can't search it without a warrant. Although it's hard to wonder how many will simply start scrolling anyway if they feel their cause is sufficiently just.
Krimbel's email also asked if FaceID would work with sunglasses, given that you don't really want to have to take them off every time you wanna unlock your phone. Federighi explained that it will with "most, but not all," saying that since the majority of sunglasses will allow infra-red light to pass, it'll still be able to scan your face.