我目前在做一个防止设备使用的位置是虚拟的,目前通过苹果的api无法直接判断位置来源于真实或虚拟。请问我该如何去判断它呢?
如何防止虚拟定位?
Question:
I am currently making a virtual position to prevent the use of the device. At present, it is impossible to directly judge whether the location is real or virtual through Apple's api. Excuse me, how can I judge it?
CLLocation
has a .sourceInformation
property which will indicate whether the location is coming from an external source or simulated by software.
Argun Tekant / DTS Engineer / Core Technologies
在使用硬件改变定位时,我尝试过使用sourceInformation中的isProducedByAccessory,并不能检测位置来源于硬件。而且有的硬件修改虚拟定位后可以拔掉,这样就不能通过isProducedByAccessory去检测了