In an algorithmic complexity attack, a malicious party takes advantage of the worst-case behavior of an algorithm to cause denial-of-service. A prominent algorithmic complexity attack is regular expression denial-of-service (ReDoS), in which the attacker exploits a vulnerable regular expression by providing a carefully-crafted input string that triggers worst-case behavior of the matching algorithm. This paper proposes a technique for automatically finding ReDoS vulnerabilities in programs. Specifically, our approach automatically identifies vulnerable regular expressions in the program and determines whether an "evil" input string can be matched against a vulnerable regular expression. We have implemented our proposed approach in a tool called REXPLOITER and found 41 exploitable security vulnerabilities in Java web applications.
翻译:在算法复杂度攻击中,恶意方利用算法的最坏行为导致拒绝服务。一个突出的算法复杂性攻击是常规表达拒绝服务(ReDoS ), 攻击者通过提供精心设计的输入字符串来利用脆弱的正常表达方式, 触发匹配算法的最坏行为。 本文提出了一个在程序中自动发现 ReDoS 弱点的方法。 具体而言, 我们的方法自动识别程序中的脆弱常规表达方式, 并确定“ 邪恶” 输入字符串能否与脆弱的正常表达方式匹配。 我们已经在名为 REXBIPIITER 的工具中应用了我们的建议方法, 并在Java 网络应用程序中发现了41个可以利用的安全弱点 。