arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2604.16832cs.CRcs.PL
收藏

DALC-CT:低级代码轨迹动态分析用于常数时间验证

DALC-CT: Dynamic Analysis of Low-Level Code Traces for Constant-Time Verification

STAM Center, Ira A. Fulton Schools of Engineering(STAM中心,伊拉·A·富尔顿工程学院);Arizona State University(亚利桑那州立大学)

Nges Brian Njungle, Edwin P. Kayang, Mishel J. Paul, Michel A. Kinsy

AI总结:

本文提出DALC-CT工具,通过动态分析低级执行轨迹检测程序是否符合常数时间原则,验证方法基于指令序列比较,能有效识别非常数时间行为。

摘要:

定时侧通道攻击利用程序执行时间的变化来恢复敏感信息。加密实现尤其容易受到这些攻击的影响,因为即使是模幂运算或密钥比较中的微小定时差异也可以被利用来提取高度敏感的信息,如秘密密钥。为了缓解这种威胁,处理敏感信息的程序实现通常需要遵循常数时间原则,确保执行行为不依赖于秘密输入。然而,验证程序的常数时间属性仍然是密码学开发中的主要挑战。形式化方法验证常数时间实现依赖于往往无法捕捉真实执行行为的抽象,而基于定时的测量技术对其他程序和硬件环境的噪声高度敏感。在本文中,我们提出了一种新的验证常数时间程序的方法,基于低级执行轨迹的动态分析。我们的方法为任何给定的二进制和目标函数测量多个输入值的指令序列。任何给定轨迹对的指令混合分布的差异表明偏离常数时间原则和行为。我们开发了一个名为DALC-CT的开源工具,用于使用这种方法验证程序的常数时间属性。我们在一组著名的常数时间和非常数时间示例上评估了它,实现了问题的完美检测。我们的结果表明,通过指令轨迹比较分析程序的逻辑执行,提供了一种轻量且可靠的方法来验证程序的常数时间属性。

英文摘要:

Timing side-channel attacks exploit variations in program execution time to recover sensitive information. Cryptographic implementations are especially vulnerable to these attacks, since even small timing differences in operations such as modular exponentiation or key comparisons can be exploited to extract highly sensitive information, such as secret keys. To mitigate this threat, implementations of programs that handle sensitive information are often expected to adhere to constant-time principles, ensuring that execution behavior does not depend on secret inputs. However, validating the constant-time property of programs remains a major challenge in cryptography development. Formal method approaches to verify constant-time implementations rely on abstractions that often fail to capture real execution behavior, while timing-based measurement techniques are highly sensitive to noise from other programs and even hardware environments. In this work, we propose a novel approach for verifying constant-time programs based on dynamic analysis of low-level execution traces. Our method measures instruction sequences across multiple input values for any given binary and targeted function. Any variations in the instruction mix distribution for any given pair of traces indicate a deviation from the constant-time principle and behavior. We developed an open-source tool called DALC-CT, for the constant-time verification of programs using this approach. We evaluated it on a set of well-known constant-time and non-constant-time examples, achieving a perfect detection of issues. Our results demonstrate that analyzing the logical execution of programs via instruction trace comparisons provides a lightweight and reliable way to verify the constant-time property of programs.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑