利用PendingIntent来源混淆来伪装Android SDK认证
Exploiting PendingIntent Provenance Confusion to Spoof Android SDK Authentication
AI总结:
研究发现Android SDK认证中PendingIntent来源混淆漏洞,通过窃取并回放PendingIntent实现身份冒充,提出结合绑定服务IPC与内核级验证的防御方案。
摘要:
一个合作伙伴SDK中的单个认证绕过漏洞会使攻击者获得生态系统中每个合作伙伴的身份--并且数百万个应用都使用恰好存在这种漏洞的SDKs。OWASP 2024移动十大风险将不充分的供应链安全列为第二重要的移动风险,明确将第三方SDKs作为主要攻击向量。跨应用移动SDKs--其中合作伙伴应用程序通过进程间通信(IPC)与平台提供者的应用程序通信--调解了内容发布、支付发起和身份联邦等敏感操作。与嵌入式库不同,跨应用SDKs需要提供商的服务在运行时认证调用的应用程序。一种有时用于此认证的模式依赖于PendingIntent.getCreatorPackage()来验证发送方身份。我们证明这种机制存在根本的来源混淆漏洞:PendingIntent可靠地识别是谁创建了它,但无法证明是谁呈现它--而这一区别对认证至关重要。具有通知访问权限的攻击应用程序可以窃取一个合法合作伙伴的PendingIntent通过NotificationListenerService并回放它以冒充该合作伙伴,完全绕过认证。该攻击成功于可变和不可变的PendingIntents,因为不可变性保护的是令牌的内容,而不是其来源。我们系统地评估了八个Android IPC认证机制,针对一个特定于SDK的威胁模型,并提出了一个结合绑定服务IPC与内核级调用者验证的防御架构,通过Binder.getCallingUid(),并辅以服务器端证书哈希验证。这在提供认证保证的同时,仍能跨合作伙伴生态系统进行扩展。
英文摘要:
A single authentication bypass in a partner SDK grants attackers the identity of every partner in the ecosystem -- and millions of apps use SDKs with exactly this vulnerability. OWASP's 2024 Mobile Top 10 ranks Inadequate Supply Chain Security as the second most critical mobile risk, explicitly identifying third-party SDKs as a primary attack vector. Cross-app mobile SDKs -- where a partner application communicates with a platform provider's application via inter-process communication (IPC) -- mediate sensitive operations such as content publishing, payment initiation, and identity federation. Unlike embedded libraries that execute within a single app's process, cross-app SDKs require the provider's service to authenticate the calling application at runtime. A pattern sometimes used for this authentication relies on PendingIntent.getCreatorPackage() to verify sender identity. We demonstrate that this mechanism exhibits a fundamental provenance confusion vulnerability: a PendingIntent reliably identifies who created it but cannot attest who presents it -- and this distinction is fatal for authentication. An attacker app with notification access can steal a legitimate partner's PendingIntent via NotificationListenerService and replay it to impersonate that partner, bypassing authentication entirely. The attack succeeds against both mutable and immutable PendingIntents because immutability protects the token's contents, not its provenance. We systematically evaluate eight Android IPC authentication mechanisms against an SDK-specific threat model and present a defense architecture combining Bound Service IPC with kernel-level caller verification via Binder.getCallingUid(), supplemented by server-side certificate-hash validation. This provides authentication guarantees while remaining scalable across partner ecosystems.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。