The annoying, indispensable and game-changing app

A Mysterious Bug is Causing Links to Fail on iOS

Over the weekend, 9to5Mac reported what appears to be a widespread iOS bug that causes links to fail to open. In some cases, long pressing links crashes the app containing the link. What’s worse, rebooting your iOS device or uninstalling third-party apps affected by the bug seems to only correct the problem temporarily.

Ben Collier has been doing some digging and it looks as though the culprit may be Shared Web Credentials, a means by which websites and apps can share login credentials. As Ben explains:

In iOS 9 Apple introduced Universal Links, these allow app developers to associate their website and app, so links to the website can open the app up automatically if installed. For example, following a link to a Guardian article opens up the Guardian app to that specific article instead of their website.

App developers put an app association file on their website which lists which types of URLs the app can open. When you install an app, iOS downloads this associated file and updates your own database of what URLs your installed apps can open. The website and app listing in iTunes are linked by the developer - so it prevents anyone from hijacking your website with their app.

When you tap a link in iOS, the system looks through the database of installed apps supported URLs to see if it matches a pattern an installed app can handle. If nothing matches it opens it up as a standard app.

9to5Mac has been able to replicate the bug by installing the app, which until today, had an unusually large association file. The bug does not appear to be limited to the app, but the unusual size of its association file lead to initial speculation that file size was the culprit. However, further investigation suggest that the problem may be with the Shared Web Credentials daemon itself and is either triggered by a large association file, or becomes corrupt regardless of the size of association files. Whatever the cause, let’s hope that a reliable workaround is found soon and that Apple releases an iOS update that fixes the problem.

We have reached out to Apple for comment regarding the bug and will update this post with whatever additional information we learn.

[Update: 2016-03-29] Based on follow up reports by 9to5Mac and Ben Collier, it appears that large association files are indeed the source of the bug that that causes links to fail to open for some iOS users. According to 9to5Mac:

Sources tell us that Apple is working with high-profile developers to help them understand and better use the universal links APIs.

9to5Mac also quotes a statement it received from Apple PR:

“We are aware of this issue, and we will release a fix in a software update soon.”

Whether the source of this quote is the same as the sources that reportedly told 9to5Mac that Apple is working with ‘high-profile developers’ is unclear.

9to5Mac also reports that the Wikipedia app and Eat24 apps may also trigger the link bug. Unfortunately, there is still no known workaround for the issue. Nor is there a way to tell which apps are affected before installing them.

Ben Collier, whose post yesterday pinpointed the source of the bug, has posted a fix that requires users to complete a dozen steps. The fix appears to be dependent on the timing of the steps, which means that it may require multiple attempts to get it to work.

Unlock MacStories Extras

Club MacStories offers exclusive access to extra MacStories content, delivered every week; it’s also a way to support us directly.

Club MacStories will help you discover the best apps for your devices and get the most out of your iPhone, iPad, and Mac. It’ll also give you access to advanced iOS shortcuts, tips and tricks, and lots more.

Starting at $5/month, with an annual option available.

Join the Club.

A Club MacStories membership includes:

  • MacStories Weekly newsletter, delivered every week on Friday with app collections, tips, iOS workflows, and more;
  • MacStories Unplugged podcast, published monthly with discussions on what we’re working on and more;
  • Monthly Log newsletter, delivered once every month with behind-the-scenes stories, app notes, personal journals, and more;
  • Access to occasional giveaways, discounts, and free downloads.