Skip to main content
QUICK REVIEW

[Paper Review] Unauthorized Cross-App Resource Access on MAC OS X and iOS

Luyi Xing, Xiaolong Bai|arXiv (Cornell University)|May 26, 2015
Advanced Malware Detection TechniquesComputer Science13 references7 citations
TL;DR

This paper identifies critical security flaws in Apple's macOS and iOS platforms that allow sandboxed malicious apps to perform unauthorized cross-app resource access (XARA) via unprotected inter-app mechanisms like keychain, URL schemes, WebSocket, and NSConnection. The authors demonstrate that these vulnerabilities enable full disclosure of sensitive user data—including passwords, tokens, and private app files—by exploiting weak authentication in app-to-app interactions, and they propose an automated scanner (Xavus) to detect such flaws in apps before deployment.

ABSTRACT

On modern operating systems, applications under the same user are separated from each other, for the purpose of protecting them against malware and compromised programs. Given the complexity of today's OSes, less clear is whether such isolation is effective against different kind of cross-app resource access attacks (called XARA in our research). To better understand the problem, on the less-studied Apple platforms, we conducted a systematic security analysis on MAC OS~X and iOS. Our research leads to the discovery of a series of high-impact security weaknesses, which enable a sandboxed malicious app, approved by the Apple Stores, to gain unauthorized access to other apps' sensitive data. More specifically, we found that the inter-app interaction services, including the keychain, WebSocket and NSConnection on OS~X and URL Scheme on the MAC OS and iOS, can all be exploited by the malware to steal such confidential information as the passwords for iCloud, email and bank, and the secret token of Evernote. Further, the design of the app sandbox on OS~X was found to be vulnerable, exposing an app's private directory to the sandboxed malware that hijacks its Apple Bundle ID. As a result, sensitive user data, like the notes and user contacts under Evernote and photos under WeChat, have all been disclosed. Fundamentally, these problems are caused by the lack of app-to-app and app-to-OS authentications. To better understand their impacts, we developed a scanner that automatically analyzes the binaries of MAC OS and iOS apps to determine whether proper protection is missing in their code. Running it on hundreds of binaries, we confirmed the pervasiveness of the weaknesses among high-impact Apple apps. Since the issues may not be easily fixed, we built a simple program that detects exploit attempts on OS~X, helping protect vulnerable apps before the problems can be fully addressed.

Motivation & Objective

  • To investigate whether app isolation mechanisms on macOS and iOS are effective against unauthorized cross-app resource access (XARA) attacks.
  • To identify and analyze security weaknesses in Apple’s inter-app communication and sandboxing mechanisms that enable such attacks.
  • To develop an automated scanner (Xavus) capable of detecting missing authentication in app binaries to prevent exploitation.
  • To evaluate the real-world impact of these vulnerabilities by testing high-impact apps and demonstrating stealthy, undetected exploit chains.
  • To provide insights and mitigation strategies for improving future OS and app security design.

Proposed method

  • Conducted a systematic security analysis of macOS and iOS to reverse-engineer and test the behavior of inter-app mechanisms like keychain, WebSocket, NSConnection, and URL schemes.
  • Built end-to-end exploit chains targeting high-impact apps (e.g., Facebook, Evernote, WeChat) to demonstrate unauthorized access to credentials and private data.
  • Developed Xavus, an automated binary analysis tool that scans macOS and iOS app binaries to detect missing authentication in inter-app interactions.
  • Exploited the BID-based sandboxing model on macOS by hijacking Apple Bundle IDs to gain access to other apps’ container directories.
  • Used man-in-the-middle techniques on both platforms to stealthily forward stolen tokens to victim apps, evading detection.
  • Validated the scanner’s effectiveness by analyzing hundreds of app binaries, confirming widespread presence of the vulnerabilities.

Experimental results

Research questions

  • RQ1Can sandboxed malicious apps on macOS and iOS bypass isolation mechanisms to access other apps’ sensitive data?
  • RQ2Are Apple’s inter-app communication mechanisms (e.g., keychain, URL schemes, WebSocket, NSConnection) sufficiently protected against unauthorized access?
  • RQ3To what extent are the Apple sandboxing and bundle ID mechanisms vulnerable to privilege escalation via identity spoofing?
  • RQ4Can the absence of app-to-app and app-to-OS authentication lead to widespread, stealthy data exfiltration?
  • RQ5How effective is automated detection of such vulnerabilities in real-world app binaries?

Key findings

  • The keychain service on macOS and iOS is vulnerable to unauthorized access by malicious apps due to insufficient authentication in inter-app access control.
  • URL scheme hijacking on both macOS and iOS allows malicious apps to steal sensitive tokens (e.g., Evernote, iCloud) by impersonating legitimate apps.
  • The NSConnection and WebSocket mechanisms on macOS enable cross-app data exfiltration without proper authentication checks.
  • The BID-based sandboxing model on macOS can be subverted by a malicious app that hijacks another app’s Bundle ID, leading to full access to its private container directory.
  • The authors successfully submitted and had their malicious apps approved by the Apple App Store, proving the vulnerability bypasses Apple’s vetting process.
  • The scanner Xavus detected missing authentication in hundreds of high-impact apps, confirming the widespread nature of the flaw across the ecosystem.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.