BLens:使用集成嵌入的二进制函数对比式描述生成
BLens: Contrastive Captioning of Binary Functions using Ensemble Embedding
AI总结:
提出BLens模型,通过集成多个二进制函数嵌入并结合对比学习与定制transformer生成函数名,显著提升了二进制逆向工程中跨项目泛化能力与函数名预测准确率。
摘要:
函数名能极大地辅助人类逆向工程师,这推动了基于机器学习的被剥离二进制文件中函数名预测方法的发展。该领域目前的许多工作采用transformer,将代码到函数名的过程类比为机器翻译。然而,函数命名模型在泛化到与训练集无关的项目时仍面临挑战。本文采用全新方法,将自动图像描述生成领域的进展迁移到二进制逆向工程领域,使二进制函数的不同部分能够与其名称的各部分相关联。我们提出BLens,它将多个二进制函数嵌入组合为新的集成表示,通过对比学习方法将其与名称表示的隐空间对齐,并使用专为函数名定制的transformer架构生成函数名。实验表明,BLens显著优于现有技术。在按二进制文件划分的常规设置中,我们取得0.79的F1分数,对比为0.70。在强调泛化能力的跨项目设置中,取得0.46的F1分数,对比为0.29。最后,在减少项目间共享组件的实验设置中,取得0.32的F1分数,对比为0.19。
英文摘要:
Function names can greatly aid human reverse engineers, which has spurred the development of machine learning-based approaches to predicting function names in stripped binaries. Much current work in this area now uses transformers, applying a metaphor of machine translation from code to function names. Still, function naming models face challenges in generalizing to projects unrelated to the training set. In this paper, we take a completely new approach by transferring advances in automated image captioning to the domain of binary reverse engineering, such that different parts of a binary function can be associated with parts of its name. We propose BLens, which combines multiple binary function embeddings into a new ensemble representation, aligns it with the name representation latent space via a contrastive learning approach, and generates function names with a transformer architecture tailored for function names. Our experiments demonstrate that BLens significantly outperforms the state of the art. In the usual setting of splitting per binary, we achieve an $F_1$ score of 0.79 compared to 0.70. In the cross-project setting, which emphasizes generalizability, we achieve an $F_1$ score of 0.46 compared to 0.29. Finally, in an experimental setting reducing shared components across projects, we achieve an $F_1$ score of $0.32$ compared to $0.19$.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。