Cache side channel attacks are increasingly alarming in modern processors due to the recent emergence of Spectre and Meltdown attacks. A typical attack performs intentional cache access and manipulates cache states to leak secrets by observing the victim's cache access patterns. Different countermeasures have been proposed to defend against both general and transient execution based attacks. Despite their effectiveness, they mostly trade some level of performance for security, or have restricted security scope. In this paper, we seek an approach to enforcing security while maintaining performance. We leverage the insight that attackers need to access cache in order to manipulate and observe cache state changes for information leakage. Specifically, we propose Prefender, a secure prefetcher that learns and predicts attack-related accesses for prefetching the cachelines to simultaneously help security and performance. Our results show that Prefender is effective against several cache side channel attacks while maintaining or even improving performance for SPEC CPU 2006 and 2017 benchmarks.
翻译:缓存侧信道攻击因近期Spectre和Meltdown攻击的出现,在现代处理器中日益引发关注。典型攻击通过执行有意的缓存访问并操纵缓存状态,借由观察受害者的缓存访问模式泄露秘密信息。针对通用攻击和瞬态执行攻击,业界已提出多种防御措施。尽管这些方法有效,但大多以一定性能换取安全性,或存在安全范围受限的问题。本文旨在探索既能保障安全又可维持性能的方法。我们基于以下洞察:攻击者必须访问缓存以操纵并观察缓存状态变化,从而实现信息泄露。为此,我们提出Prefender——一种能够学习并预测攻击相关访问的安全预取器,通过预取缓存行来同时提升安全性与性能。实验结果表明,Prefender在SPEC CPU 2006和2017基准测试中,既能有效防御多种缓存侧信道攻击,又能维持甚至提升系统性能。