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

用于检测恶意 API 请求的 RoBERTa 增强合成方法

RoBERTa-Augmented Synthesis for Detecting Malicious API Requests

Udi Aharon, Revital Marbel, Ran Dubin, Amit Dvir, Chen Hajaj

AI总结:

针对恶意 API 请求检测中训练数据不足的问题,提出受 GAN 启发、基于 RoBERTa 的领域感知流量合成框架,显著提升多数据集上的异常检测 F1 分数。

摘要:

Web 应用和 API 持续面临恶意行为者的威胁,这些行为者试图利用漏洞谋取非法利益。为防御这些威胁,必须拥有能够识别多种恶意行为的异常检测系统。然而,该领域的一个重大挑战是训练数据的可用性有限。现有数据集通常无法充分覆盖现实场景中遇到的多样化 API 结构、参数格式和使用模式。因此,基于这些数据集训练的模型往往难以泛化,并可能无法检测不太常见或新兴的攻击向量。为提高检测准确性和鲁棒性,获取能够捕捉 API 流量真实可变性的更大规模、更具代表性的数据集至关重要。为解决这一问题,我们提出一种受 GAN 启发的学习框架,通过有针对性的、具备领域感知能力的合成来扩展有限的 API 流量数据集。借助自然语言处理(NLP)技术,我们的方法利用基于 Transformer 的架构,尤其是 RoBERTa,增强 API 请求的上下文表示,并生成符合安全特定语义的逼真合成样本。我们在两个基准数据集 CSIC 2010 和 ATRDF 2023 上评估该框架,并将其与先前的数据增强技术进行比较,以评估领域特定合成的重要性。此外,我们将增强数据应用于多种异常检测模型,以评估其对分类性能的影响。我们的方法在 CSIC 2010 上实现最高 4.94% 的 F1 分数提升,在 ATRDF 2023 上实现最高 21.10% 的提升。本工作的源代码可在 https://github.com/ArielCyber/GAN-API 获取。

英文摘要:

Web applications and APIs face constant threats from malicious actors seeking to exploit vulnerabilities for illicit gains. To defend against these threats, it is essential to have anomaly detection systems that can identify a variety of malicious behaviors. However, a significant challenge in this area is the limited availability of training data. Existing datasets often do not provide sufficient coverage of the diverse API structures, parameter formats, and usage patterns encountered in real-world scenarios. As a result, models trained on these datasets often struggle to generalize and may fail to detect less common or emerging attack vectors. To enhance detection accuracy and robustness, it is crucial to access larger and more representative datasets that capture the true variability of API traffic. To address this, we introduce a GAN-inspired learning framework that extends limited API traffic datasets through targeted, domain-aware synthesis. Drawing on techniques from Natural Language Processing (NLP), our approach leverages Transformer-based architectures, particularly RoBERTa, to enhance the contextual representation of API requests and generate realistic synthetic samples aligned with security-specific semantics. We evaluate our framework on two benchmark datasets, CSIC 2010 and ATRDF 2023, and compare it with a previous data augmentation technique to assess the importance of domain-specific synthesis. In addition, we apply our augmented data to various anomaly detection models to evaluate its impact on classification performance. Our method achieves up to a 4.94% increase in F1 score on CSIC 2010 and up to 21.10% on ATRDF 2023. The source codes of this work are available at https://github.com/ArielCyber/GAN-API.

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

↑