The Dual Role of Artificial Intelligence and LLM in Cybersecurity

Artificial Intelligence (AI) and Large Language Models (LLMs) are transforming the cybersecurity landscape, taking a dual role as both enablers of defense. This paper explores this duality by distinguishing between AI for Security, where intelligent models enhance threat analysis, intrusion detection, and automated mitigation, and Security for AI, which focuses on securing models themselves against adversarial manipulation, data leakage, and prompt-based exploitation. To empirically evaluate the capabilities of modern LLMs in cybersecurity, we conducted extensive experiments using the newly developed CyberMetric dataset, which assesses cybersecurity knowledge across multiple domains such as cryptography, network defense, and software vulnerabilities. Our evaluation of twenty state-of-the-art LLMs-including GPT-5 Chat, Grok 4 Fast, Qwen3 235B, Gemini 2.5 Flash, and DeepSeek V3.2-demonstrates that the 2025 generation of models achieves near-human performance, with GPT-5 Chat reaching 98.75% accuracy and several open-source models performing within a 2-3% margin. These results highlight the growing maturity of open LLM ecosystems for cybersecurity applications and confirm that modern LLMs are becoming reliable instruments for cyber defense, capable of supporting automated threat analysis, vulnerability assessment, and compliance verification, while also emphasizing the need to ensure their safety, transparency, and resilience against misuse.

Publication Details

Journal
Edinburgh Napier Research Repository (Edinburgh Napier University)
Published
2025-11-27
Primary Topic
Network Security and Intrusion Detection
Type
article
Field-Weighted Citation Impact
0.00
Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
OCT
article

The Dual Role of Artificial Intelligence and LLM in Cybersecurity

Edinburgh Napier Research Repository (Edinburgh Napier University)
Network Security and Intrusion Detection
article

The Dual Role of Artificial Intelligence and LLM in Cybersecurity

article en

Abstract

Artificial Intelligence (AI) and Large Language Models (LLMs) are transforming the cybersecurity landscape, taking a dual role as both enablers of defense. This paper explores this duality by distinguishing between AI for Security, where intelligent models enhance threat analysis, intrusion detection, and automated mitigation, and Security for AI, which focuses on securing models themselves against adversarial manipulation, data leakage, and prompt-based exploitation. To empirically evaluate the capabilities of modern LLMs in cybersecurity, we conducted extensive experiments using the newly developed CyberMetric dataset, which assesses cybersecurity knowledge across multiple domains such as cryptography, network defense, and software vulnerabilities. Our evaluation of twenty state-of-the-art LLMs-including GPT-5 Chat, Grok 4 Fast, Qwen3 235B, Gemini 2.5 Flash, and DeepSeek V3.2-demonstrates that the 2025 generation of models achieves near-human performance, with GPT-5 Chat reaching 98.75% accuracy and several open-source models performing within a 2-3% margin. These results highlight the growing maturity of open LLM ecosystems for cybersecurity applications and confirm that modern LLMs are becoming reliable instruments for cyber defense, capable of supporting automated threat analysis, vulnerability assessment, and compliance verification, while also emphasizing the need to ensure their safety, transparency, and resilience against misuse.

Edinburgh Napier Research Repository (Edinburgh Napier University)
Openalex Percentile: Top 37%
Network Security and Intrusion Detection
AI Navigator

Ask Laika to Summarize, Analyze, and Connect papers live on the map.

Summarize Papers & Methodologies

Extract key findings, datasets, and comparative methods across publications.

Benchmark Rankings & Visual Analytics

Rank top research institutions, authors, funders, topics, and journals by Field-Weighted Citation Impact (FWCI) and paper volume with instant charts.

Connect Distant Disciplines

Bridge topological clusters on the map to find hidden collaborative intersections.

The Dual Role of Artificial Intelligence and LLM in Cybersecurity · Edinburgh Napier Research Repository (Edinburgh Napier University) (2025) | TGRS Research Map | TGRS