Well XNU has always been 'open-source' [1] for some time on Intel machines but its just that ARM support remained closed (until 2017) which is why the darwin-on-arm [2] project existed. But I'm assuming that the OP means that the ARM64 code was recently open-sourced in the XNU sources[3] making a possible open-source ARM port much simpler. I still find it quite interesting to see some regained attempts in emulating iOS; with Corellium being the furthest at doing this.
In a way, it seems strange nobody made a full-blown iPhone/iPad iOS emulator yet. Not a simulator like the one Apple makes, but an emulator like for game systems. I would guess the amount of information available about iPhone hardware and software would make it much easier to emulate than e.g. a gamecube, Wii, PS3, etc, especially for older models. Such an emulator could obviously be used for piracy, but could also be an intersting tool for a homebrew scene (custom firmware, developing iOS apps on Linux & Windows, etc.
Is there a practical reason why this would be hard or impossible? Or is it just for fear of Apple's lawyers?
KenanSulayman
It seems Corellium (linked to from the blogpost) has done that. That said, it seems they only run iPhone 6, et al., which was jailbroken (untethered), so it's significantly easier to emulate than trying to run the only unencrypted file (kernel cache) targeting an undocumented CPU with Qemu of an iOS beta that was released a few days ago.
willstrafach
Corellium can run up to iPhone X, and certainly can run iOS 12 (Option is given for jailbroken or not jailbroken too).
Only limit which you may be thinking of is that it only supports 64-bit ARM, so no emulation of the older devices.
rjvbk
It seems strange to me that there are no Chinese OEMs selling mobiles with iOS. I mean, I understand it's hard, but is it THAT hard?
mschuster91
Yeah it is because the CPU and GPU are customized for Apple. You'd have to recreate them (which probably would require a F500 company like Amazon or Google) or write a translation layer similar to WINE (which would need a couple dozen expert coders). Not worth the effort for knockoff phones.
rjvbk
Knockoff iPhones would sell like hot bread.
TomMarius
You can buy them at "the market" in Shenzen. You can even put in original Apple logic board and run iOS - and have crazy things like double storage, memory cards, 3.5mm output, etc. You have to build it from parts though, no one is selling a complete product AFAIK.
They still can't run iOS apps from the App Store. They are encrypted when downloaded and only decrypted at runtime. Decrypted apps can be offloaded from a jailbroken phone and then re-uploaded to a pirate store though.
pvinis
Same like Hackintoshes, right?
ofrzeta
You would probably need to hack the OS to disable updates etc to prevent Apple from remotely bricking your device.
MaxBarraclough
Wrapping it with a firewall would be the easy part.
earenndil
That's be the easiest part. You can just grep the binary for apple domains and replace them with your own.
mirimir
Interesting. I would love virtual iPhones. For testing apps, anonymously. But I doubt that I'd get an invite from Corellium, either :(
Well XNU has always been 'open-source' [1] for some time on Intel machines but its just that ARM support remained closed (until 2017) which is why the darwin-on-arm [2] project existed. But I'm assuming that the OP means that the ARM64 code was recently open-sourced in the XNU sources[3] making a possible open-source ARM port much simpler. I still find it quite interesting to see some regained attempts in emulating iOS; with Corellium being the furthest at doing this.
[1] (https://opensource.apple.com)
[2] (https://github.com/darwin-on-arm/xnu)
[3] (https://github.com/apple/darwin-xnu/search?p=5&q=ARM64&unsco...)
Is there a practical reason why this would be hard or impossible? Or is it just for fear of Apple's lawyers?
Only limit which you may be thinking of is that it only supports 64-bit ARM, so no emulation of the older devices.