arXivDaily arXiv每日学术速递 周一至周五更新
arXiv周末暂无论文更新,休息一下吧,周末愉快~~
arXiv 1301.0849cs.PLcs.CR
收藏

正则表达式拒绝服务攻击的静态分析

Static Analysis for Regular Expression Denial-of-Service Attacks

James Kirrage, Asiri Rathnayake, Hayo Thielecke

摘要:

正则表达式是一种简洁而富有表现力的语言,用于表达模式。例如,在网络软件中,它们用于输入验证和入侵检测。然而,一些广泛部署的基于回溯的正则表达式匹配器本身容易受到拒绝服务攻击,因为它们的运行时间对于某些输入字符串来说可能是指数级的。本文提出了一种静态分析检测这种脆弱的正则表达式。分析的运行时间与基于模糊的工具相比毫不逊色,即随机生成输入并测量匹配它们所需的时间。与模糊器不同的是,分析可以精确定位漏洞的来源,并生成可能的恶意输入,供程序员在安全测试中使用。此外,该分析在抽象机器中具有坚实的理论基础。在两个大型正则表达式存储库上测试分析表明,该分析能够在几秒钟内找到大量易受攻击的正则表达式。

英文摘要:

Regular expressions are a concise yet expressive language for expressing patterns. For instance, in networked software, they are used for input validation and intrusion detection. Yet some widely deployed regular expression matchers based on backtracking are themselves vulnerable to denial-of-service attacks, since their runtime can be exponential for certain input strings. This paper presents a static analysis for detecting such vulnerable regular expressions. The running time of the analysis compares favourably with tools based on fuzzing, that is, randomly generating inputs and measuring how long matching them takes. Unlike fuzzers, the analysis pinpoints the source of the vulnerability and generates possible malicious inputs for programmers to use in security testing. Moreover, the analysis has a firm theoretical foundation in abstract machines. Testing the analysis on two large repositories of regular expressions shows that the analysis is able to find significant numbers of vulnerable regular expressions in a matter of seconds.

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

↑