Papers
Topics
Authors
Recent
Gemini 2.5 Flash
Gemini 2.5 Flash
41 tokens/sec
GPT-4o
59 tokens/sec
Gemini 2.5 Pro Pro
41 tokens/sec
o3 Pro
7 tokens/sec
GPT-4.1 Pro
50 tokens/sec
DeepSeek R1 via Azure Pro
28 tokens/sec
2000 character limit reached

LLMSecEval: A Dataset of Natural Language Prompts for Security Evaluations (2303.09384v1)

Published 16 Mar 2023 in cs.SE, cs.IR, and cs.LG

Abstract: LLMs like Codex are powerful tools for performing code completion and code generation tasks as they are trained on billions of lines of code from publicly available sources. Moreover, these models are capable of generating code snippets from Natural Language (NL) descriptions by learning languages and programming practices from public GitHub repositories. Although LLMs promise an effortless NL-driven deployment of software applications, the security of the code they generate has not been extensively investigated nor documented. In this work, we present LLMsecEval, a dataset containing 150 NL prompts that can be leveraged for assessing the security performance of such models. Such prompts are NL descriptions of code snippets prone to various security vulnerabilities listed in MITRE's Top 25 Common Weakness Enumeration (CWE) ranking. Each prompt in our dataset comes with a secure implementation example to facilitate comparative evaluations against code produced by LLMs. As a practical application, we show how LLMsecEval can be used for evaluating the security of snippets automatically generated from NL descriptions.

User Edit Pencil Streamline Icon: https://streamlinehq.com
Authors (4)
  1. Catherine Tony (7 papers)
  2. Markus Mutas (2 papers)
  3. Nicolás E. Díaz Ferreyra (18 papers)
  4. Riccardo Scandariato (29 papers)
Citations (33)