Timing side channels have been used to extract cryptographic keys and sensitive documents, even from trusted enclaves. In this paper, we focus on cache side channels created by access to shared code or data in the memory hierarchy. This vulnerability is exploited by several known attacks, e.g, evict+reload for recovering an RSA key and Spectre variants for data leaked due to speculative accesses. The key insight in this paper is the importance of the first access to the shared data after a victim brings the data into the cache. To eliminate the timing side channel, we ensure that the first access by a process to any cache line loaded by another process results in a miss. We accomplish this goal by using a combination of timestamps and a novel hardware design to allow efficient parallel comparisons of the timestamps. The solution works at all the cache levels and defends against an attacker process running on another core, same core, or another hyperthread. Our design retains the benefits of a shared cache: allowing processes to utilize the entire cache for their execution and retaining a single copy of shared code and data (data deduplication). Our implementation in the GEM5 simulator demonstrates that the system is able to defend against RSA key extraction. We evaluate performance using SPECCPU2006 and observe overhead due to first access delay to be 2.17%. The overhead due to the security context bookkeeping is of the order of 0.3%.
翻译:侧端通道已被用于提取加密密钥和敏感文件, 甚至是来自信任的飞地的密钥和敏感文件。 在本文中, 我们关注通过访问共享代码或数据在记忆层中创建的缓存侧道。 这种脆弱性被若干已知袭击所利用, 例如为恢复RSA密钥和因投机访问而泄漏的数据的Spectre变体而将加载流。 本文的关键洞察力是, 在受害者将数据引入缓存后, 首次访问共享数据的重要性。 为了消除时端通道, 我们确保通过一个进程首次访问由另一个进程装入的任何缓存线的缓存线会错失。 我们通过使用一个时间戳和新硬件设计组合来实现这一目标, 以便对时间戳进行高效的平行比较。 解决方案在所有缓存级别都起作用, 防御另一个核心、 同一核心或另一个超强的攻击者进程。 我们的设计保留了共享缓存库的好处: 允许整个缓存程序用于执行, 并保存一个共享代码和数据的单一副本( 数据减少数据) 。 我们使用时间戳和新硬件设计工具来对时间夹进行高效的缓冲 SEM5 的缓存系统进行测试 。 我们在关键的缓存系统上, 可以对缓存系统进行SEMV2号的缓存系统进行测试。 。 我们的运行进行正常的运行的运行为正常运行为正常运行为正常运行为正常运行为正常运行为正常运行进行测试。