沉睡的巨人——通过隐蔽的代码变更激活休眠的Java反序列化Gadget Chains
Sleeping Giants -- Activating Dormant Java Deserialization Gadget Chains through Stealthy Code Changes
AI总结:
本研究评估了通过微小代码变更激活Java反序列化休眠gadget chains的可能性,提出三种隐蔽引入模式,在533个依赖项中26.08%发现可激活的gadget chains,证明其是严重的供应链攻击向量。
摘要:
Java反序列化gadget chains是一项被广泛研究的关键软件弱点。绝大多数已知的gadget chains依赖于软件依赖项中的gadgets。此外,研究表明依赖项中的微小代码变更已经能够启用这些gadget chains。这使得gadget chain检测成为一种纯粹被动的应对措施。即使某个依赖项的部署流水线采用了gadget chain检测,gadget chains仍可能源于其他依赖项中的gadgets。在本研究中,我们评估了微小代码变更启用gadget chains的可能性。这些变更可能是偶然的,也可能是作为供应链攻击的一部分而蓄意为之。具体而言,我们展示了类的可序列化性在依赖项的演化过程中是一个强烈波动的属性。接着,我们调查了攻击者可以隐蔽地将gadgets引入依赖项的三种变更模式。我们将这些模式应用于533个依赖项,并在原始和修改后的依赖项上运行了三个最先进的gadget chain检测器。工具检测到,应用这些修改模式可以在我们选择的26.08%的依赖项中激活/注入gadget chains。最后,我们验证了新检测到的chains。如此,我们在53个依赖项中识别出了可以通过微小代码修改添加的休眠gadget chains。这既表明Java反序列化gadget chains是软件面临的一项广泛存在的责任风险,也证明了休眠gadget chains是一种有利可图的供应链攻击向量。
英文摘要:
Java deserialization gadget chains are a well-researched critical software weakness. The vast majority of known gadget chains rely on gadgets from software dependencies. Furthermore, it has been shown that small code changes in dependencies have enabled these gadget chains. This makes gadget chain detection a purely reactive endeavor. Even if one dependency's deployment pipeline employs gadget chain detection, a gadget chain can still result from gadgets in other dependencies. In this work, we assess how likely small code changes are to enable a gadget chain. These changes could either be accidental or intentional as part of a supply chain attack. Specifically, we show that class serializability is a strongly fluctuating property over a dependency's evolution. Then, we investigate three change patterns by which an attacker could stealthily introduce gadgets into a dependency. We apply these patterns to 533 dependencies and run three state-of-the-art gadget chain detectors both on the original and the modified dependencies. The tools detect that applying the modification patterns can activate/inject gadget chains in 26.08% of the dependencies we selected. Finally, we verify the newly detected chains. As such, we identify dormant gadget chains in 53 dependencies that could be added through minor code modifications. This both shows that Java deserialization gadget chains are a broad liability to software and proves dormant gadget chains as a lucrative supply chain attack vector.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。