Cache side-channel attacks exhibit severe threats to software security and privacy, especially for cryptosystems. In this paper, we propose CaType, a novel refinement type-based tool for detecting cache side channels in crypto software. Compared to previous works, CaType provides the following advantages: (1) For the first time CaType analyzes cache side channels using refinement type over x86 assembly code. It reveals several significant and effective enhancements with refined types, including bit-level granularity tracking, distinguishing different effects of variables, precise type inferences, and high scalability. (2) CaType is the first static analyzer for crypto libraries in consideration of blinding-based defenses. (3) From the perspective of implementation, CaType uses cache layouts of potential vulnerable control-flow branches rather than cache states to suppress false positives. We evaluate CaType in identifying side channel vulnerabilities in real-world crypto software, including RSA, ElGamal, and (EC)DSA from OpenSSL and Libgcrypt. CaType captures all known defects, detects previously-unknown vulnerabilities, and reveals several false positives of previous tools. In terms of performance, CaType is 16X faster than CacheD and 131X faster than CacheS when analyzing the same libraries. These evaluation results confirm the capability of CaType in identifying side channel defects with great precision, efficiency, and scalability.
翻译:Cache 侧通道攻击显示对软件安全和隐私的严重威胁,特别是对加密系统而言。在本文中,我们提议CaType,这是用于探测加密软件中缓存侧渠道的新型精细化型工具。与以往的工程相比,CaType提供了以下优点:(1) CaType首次利用x86组装代码的精细类型分析缓存侧渠道。我们评估了几大而有效的改进型号,包括点级颗粒跟踪,区分变量的不同效果、精确的推断类型和高度的可伸缩性。 (2) CaType是加密库中用于探测隐蔽软件中缓存侧渠道的新颖型工具。(3) 从执行角度看,CType使用潜在脆弱控制流分支的缓存式布局,而不是缓存状态,以抑制虚假的正阳性。 我们评估CType在查明真实世界的侧端密码软件中,包括RSA、ElGamal,以及(EC)OSL和Lliggcrypt。 CAtype-T级图书馆的精确性分析工具,其前16个已知的准确性都比Cmape Disal Dreax的准确性都比Cna 更快。