,
Tiago Espinha Gasiba
,
Sathwik Amburi
,
Maria Pinto-Albuquerque
Creative Commons Attribution 4.0 International license
As Large Language Models (LLMs) become increasingly integrated into secure software development workflows, a critical question remains unanswered: can these models not only detect insecure code but also reliably classify vulnerabilities according to standardized taxonomies? In this work, we conduct a systematic evaluation of three state-of-the-art LLMs - Llama3, Codestral, and Deepseek R1 - using a carefully filtered subset of the Big-Vul dataset annotated with eight representative Common Weakness Enumeration categories. Adopting a closed-world classification setup, we assess each model’s performance in both identifying the presence of vulnerabilities and mapping them to the correct CWE label. Our findings reveal a sharp contrast between high detection rates and markedly poor classification accuracy, with frequent overgeneralization and misclassification. Moreover, we analyze model-specific biases and common failure modes, shedding light on the limitations of current LLMs in performing fine-grained security reasoning.These insights are especially relevant in educational contexts, where LLMs are being adopted as learning aids despite their limitations. A nuanced understanding of their behaviour is essential to prevent the propagation of misconceptions among students. Our results expose key challenges that must be addressed before LLMs can be reliably deployed in security-sensitive environments.
@InProceedings{gasparlopes_et_al:OASIcs.ICPEC.2025.4,
author = {Gaspar Lopes, Diogo and Espinha Gasiba, Tiago and Amburi, Sathwik and Pinto-Albuquerque, Maria},
title = {{Can Open Large Language Models Catch Vulnerabilities?}},
booktitle = {6th International Computer Programming Education Conference (ICPEC 2025)},
pages = {4:1--4:14},
series = {Open Access Series in Informatics (OASIcs)},
ISBN = {978-3-95977-393-5},
ISSN = {2190-6807},
year = {2025},
volume = {133},
editor = {Queir\'{o}s, Ricardo and Pinto, M\'{a}rio and Portela, Filipe and Sim\~{o}es, Alberto},
publisher = {Schloss Dagstuhl -- Leibniz-Zentrum f{\"u}r Informatik},
address = {Dagstuhl, Germany},
URL = {https://drops.dagstuhl.de/entities/document/10.4230/OASIcs.ICPEC.2025.4},
URN = {urn:nbn:de:0030-drops-240340},
doi = {10.4230/OASIcs.ICPEC.2025.4},
annote = {Keywords: Large Language Models (LLMs), Secure Coding, CWE Classification, Machine Learning, Software Vulnerability Detection, Artificial Intelligence, Code Analysis, Big-Vul Dataset}
}