paper-with-me

Papers

Is Your AI-Generated Code Really Safe? Evaluating Large Language Models on Secure Code Generation with CodeSecEval

2024-07-02 · Jiexin Wang, Xitong Luo, Liuwen Cao, Hongkui He, Hailin Huang, Jiayuan Xie, Adam Jatowt, Yi Cai

Large language models (LLMs) have brought significant advancements to code generation and code repair, benefiting both novice and experienced developers. However, their training using unsanitized data from open-source repositories, like GitHub, raises the risk of inadvertently propagating security vulnerabilities. Despite numerous studies investigating the safety of code LLMs, there remains a gap in comprehensively addressing their security features. In this work, we aim to present a comprehensive study aimed at precisely evaluating and enhancing the security aspects of code LLMs. To support our research, we introduce CodeSecEval, a meticulously curated dataset designed to address 44 critical vulnerability types with 180 distinct samples. CodeSecEval serves as the foundation for the automatic evaluation of code models in two crucial tasks: code generation and code repair, with a strong emphasis on security. Our experimental results reveal that current models frequently overlook security issues during both code generation and repair processes, resulting in the creation of vulnerable code. In response, we propose different strategies that leverage vulnerability-aware information and insecure code explanations to mitigate these security vulnerabilities. Furthermore, our findings highlight that certain vulnerability types particularly challenge model performance, influencing their effectiveness in real-world applications. Based on these findings, we believe our study will have a positive impact on the software engineering community, inspiring the development of improved methods for training and utilizing LLMs, thereby leading to safer and more trustworthy model deployment.

📄 PDF Abstract BibTeX arXiv:2407.02395

Code (0)

등록된 구현이 없습니다.

Tasks

Code GenerationCode Repair

Similar Papers 제목 키워드 기반

ShoppingComp: Are LLMs Really Ready for Your Shopping Cart?

2025-11-28 · Huaixiao Tou, Ying Zeng, Yuemeng Li, Cong Ma 외 arxiv

We present ShoppingComp, a challenging real-world benchmark for comprehensively evaluating LLM-powered shopping agents on three core capabilities: precise product retrieval, expert-level report generation, and safety cri…

Decision Making

Is Your Code Generated by ChatGPT Really Correct? Rigorous Evaluation of Large Language Models for Code Generation

2023-05-02 · NeurIPS 2023 11 · Jiawei Liu, Chunqiu Steven Xia, Yuyao Wang, Lingming Zhang

Program synthesis has been long studied with recent approaches focused on directly using the power of Large Language Models (LLMs) to generate code. Programming benchmarks, with curated synthesis problems and test-cases,…

Code GenerationHumanEvalProgram Synthesis

Can Large Language Models Really Recognize Your Name?

2025-05-20 · Dzung Pham, Peter Kairouz, Niloofar Mireshghallah, Eugene Bagdasarian 외

Large language models (LLMs) are increasingly being used to protect sensitive user data. However, current LLM-based privacy solutions assume that these models can reliably detect personally identifiable information (PII)…

Privacy Preserving

We Built a Fake News / Click Bait Filter: What Happened Next Will Blow Your Mind!

2017-09-01 · RANLP 2017 9 · Georgi Karadzhov, Pepa Gencheva, Preslav Nakov, Ivan Koychev

It is completely amazing! Fake news and {``}click baits{''} have totally invaded the cyberspace. Let us face it: everybody hates them for three simple reasons. Reason {\#}2 will absolutely amaze you. What these can achie…

Author ProfilingClickbait DetectionWord Embeddings

We Built a Fake News & Click-bait Filter: What Happened Next Will Blow Your Mind!

2018-03-10 · Georgi Karadzhov, Pepa Gencheva, Preslav Nakov, Ivan Koychev

It is completely amazing! Fake news and click-baits have totally invaded the cyber space. Let us face it: everybody hates them for three simple reasons. Reason #2 will absolutely amaze you. What these can achieve at the …

Author Profiling