Affiliate Disclosure
If you buy through our links, we may get a commission. Read our ethics policy.

Now-fixed Apple code crashed iOS devices when users typed 'Taiwan'

A blog post on Tuesday illustrates the sometimes inadvertent ill effects of modifying or adding code to a major operating system for no other purpose than to placate a certain market's government. Apple did just that when it removed the Taiwan flag emoji from circulation in China.

Patrick Wardle, chief research officer of Digita Security, discussed the issue that caused certain iOS devices to crash in a lengthy and somewhat technical post to his personal blog, Objective-See.

As Wardle explains, iOS 11.3 and below contained a bug that for some iPhone and iPad users resulted in constant crashes when the word "Taiwan" was entered in both first- and third-party app text fields.

The remote flaw would also trigger a crash event when attempting to display the Taiwanese flag emoji on certain devices. The process was repeatable in iMessage, Facebook and WhatsApp.

Apple patched the bug in iOS 11.4.1, citing a bug report filed by Wardle earlier this year.

Certain aspects of the bug are unclear, but Wardle narrowed the negative effect down to a "null" pointer dereference. In particular, the problem presented itself when a removeEmoji operation led to a system instruction that checked a device's region settings. An ensuing function crashed under certain conditions related to Chinese region settings.

As noted by Emojipedia, iOS hides the Taiwanese flag on devices set to the China region. This process includes expunging the emoji from both the keyboard and rendered data like incoming text messages.

While the code worked for Chinese iPhones, it caused trouble for some iOS devices set to other regions, or more accurately an "unsupported region-less state."

The ordeal underscores the lengths to which Apple and other companies will go to appease China's government. China and Taiwan have a long and contentious relationship that dates back to well before the Chinese Civil War. Taiwan views itself as a sovereign state called the Republic of China, while the People's Republic of China (mainland China) considers Taiwan part of its territory and sensitive to issues regarding the island's identity.

China (the People's Republic of China) is a vital market for Apple. Although the company publicly touts a strong stance on against censorship and government snooping, it has played nice with the Chinese government's oft-bemoaned laws.

Last year, for example, Apple caught flak for pulling the NYT app from the Chinese App Store, a move that was followed by the removal of certain VPN apps in compliance with Chinese regulations.

Most recently, the company transferred Chinese iCloud data and cryptographic keys to local servers run by Guizhou-Cloud Big Data Industry Co. Ltd., a decision decried by privacy advocates. For its part, Apple says it advocated against iCloud being subject to China's cyber laws, but chalked up compliance as a cost of doing business in the country.



23 Comments

Rayz2016 8 Years · 6957 comments

Not reeeaaaalllly feeling the sympathy for them on this one. 

ascii 19 Years · 5930 comments

If the Chinese people ever overthrow the CCP and establish a democracy, what are they going to think of the American companies who helped censor them when the communists were in power? Would Apple ever sell an iPhone there again?

jcallows 17 Years · 150 comments

ah yes, programming 101:  never dereference a null pointer

mbenz1962 7 Years · 174 comments

ascii said:
If the Chinese people ever overthrow the CCP and establish a democracy, what are they going to think of the American companies who helped censor them when the communists were in power? Would Apple ever sell an iPhone there again?

History has an unfortunately short memory.  Most Americans or citizens of other western countries don't have a moral objection to buying products from VW, BMW, Hugo Boss, Siemens, or other multinational companies who were 100% complicit in the Holocaust by benefiting form slave labor provided by concentration camps or even outright support of the 3rd Reich.  There are lots of other companies who benefitted from the war effort in Germany (government contracts and reduction of comeptition) that weren't so culpable as well, but I guess there is no need to go further with the point.  So, I would not expect that most Chinese consumers would boycott American products if communism were ever to fall in China. 

nunzy 6 Years · 662 comments

Apple plays ball with the Chicomms because they can make more money that way.  what is good for Wall Street is good for America..