Skip to main content
QUICK REVIEW

[论文解读] CopyCat: Controlled Instruction-Level Attacks on Enclaves

Daniel Moghimi, Jo Van Bulck|arXiv (Cornell University)|Feb 19, 2020
Security and Verification in Computing参考文献 71被引用 14
一句话总结

COPYCAT 是一种新颖的确定性、指令级侧通道攻击,针对 Intel SGX 飞地,通过利用架构中断来精确计数执行的指令。通过将此中断计数通道与现有的页表访问泄漏相结合,该攻击实现了最大化的、无噪声的指令级控制流重建,即使在存在防护措施的情况下,也能从加固的密码学库中实现单次追踪的密钥提取。

ABSTRACT

The adversarial model presented by trusted execution environments (TEEs) has prompted researchers to investigate unusual attack vectors. One particularly powerful class of controlled-channel attacks abuses page-table modifications to reliably track enclave memory accesses at a page-level granularity. In contrast to noisy microarchitectural timing leakage, this line of deterministic controlled-channel attacks abuses indispensable architectural interfaces and hence cannot be mitigated by tweaking microarchitectural resources. We propose an innovative controlled-channel attack, named CopyCat, that deterministically counts the number of instructions executed within a single enclave code page. We show that combining the instruction counts harvested by CopyCat with traditional, coarse-grained page-level leakage allows the accurate reconstruction of enclave control flow at a maximal instruction-level granularity. CopyCat can identify intra-page and intra-cache line branch decisions that ultimately may only differ in a single instruction, underscoring that even extremely subtle control flow deviations can be deterministically leaked from secure enclaves. We demonstrate the improved resolution and practicality of CopyCat on Intel SGX in an extensive study of single-trace and deterministic attacks against cryptographic implementations, and give novel algorithmic attacks to perform single-trace key extraction that exploit subtle vulnerabilities in the latest versions of widely-used cryptographic libraries. Our findings highlight the importance of stricter verification of cryptographic implementations, especially in the context of TEEs.

研究动机与目标

  • 开发一类新型可控通道攻击,实现在飞地侧通道泄漏中的指令级分辨率。
  • 证明即使在微体系结构侧通道被缓解的情况下,仍可在指令级别实现确定性、无噪声的控制流泄漏。
  • 表明尽管存在现有的侧通道防护措施,广泛部署的密码学库对单次追踪密钥恢复攻击仍保持脆弱。
  • 挑战一种假设,即粗粒度的页级别监控是可控通道攻击的最大实际分辨率。

提出的方法

  • 利用 SGX-Step 框架强制单指令步进进入受害者飞地,从而实现精确的中断计数。
  • 使用架构中断作为确定性通道,以计数单个飞地代码页内执行的指令数量。
  • 将细粒度的中断计数与粗粒度的页表访问模式结合,作为第二个预言机,以指令级粒度重建控制流。
  • 利用每个中断对应一条执行指令的事实,实现确定性指令计数,而无需依赖时间变化。
  • 将中断计数技术应用于分析模逆和标量乘法等密码原 primitive 的控制流。
  • 开发新型算法攻击,通过分析指令级偏差,从单个控制流追踪中恢复密码学密钥。

实验结果

研究问题

  • RQ1能否将架构中断用作确定性、无噪声的通道,以计数 SGX 飞地内部的指令?
  • RQ2仅使用中断计数和页表访问模式,能在多大程度上重建指令级控制流?
  • RQ3经过微体系结构侧通道防护加固的现代密码学库,是否仍对指令级可控通道攻击保持脆弱?
  • RQ4能否构建出单次追踪、确定性的攻击,从实际实现中恢复密码学密钥?

主要发现

  • COPYCAT 通过使用架构中断作为确定性计数通道,在控制流泄漏中实现了指令级分辨率,消除了测量噪声。
  • 该攻击成功重建了仅相差一条指令的页内和缓存行内分支决策。
  • 在真实世界的密码学库(包括 DSA、ECDSA 和 RSA 密钥生成)上,成功演示了单次追踪密钥提取攻击,即使存在侧通道防护措施。
  • 该攻击绕过了微体系结构防御机制(如缓冲区清空和资源分区),因为它依赖于架构接口,而非微体系结构状态。
  • 即使使用了如始终加法与加倍和指数掩码等技术加固的库,COPYCAT 仍能通过指令级的依赖秘密的控制流将其攻破。
  • 该攻击在 Intel SGX 上通过大量实验得到验证,展示了在实际场景中的可行性与高精度。

更好的研究,从现在开始

从阅读论文到最终审阅,大幅缩短您的研究时间。

无需绑定信用卡

本解读由 AI 生成,并经人工编辑审核。