Fixing Hardware Security Bugs with Large Language Models. Ahmad, B., Thakur, S., Tan, B., Karri, R., & Pearce, H. February, 2023. arXiv:2302.01215 [cs]
Fixing Hardware Security Bugs with Large Language Models [link]Paper  doi  abstract   bibtex   
Novel AI-based code-writing Large Language Models (LLMs) such as OpenAI's Codex have demonstrated capabilities in many coding-adjacent domains. In this work we consider how LLMs maybe leveraged to automatically repair security relevant bugs present in hardware designs. We focus on bug repair in code written in the Hardware Description Language Verilog. For this study we build a corpus of domain-representative hardware security bugs. We then design and implement a framework to quantitatively evaluate the performance of any LLM tasked with fixing the specified bugs. The framework supports design space exploration of prompts (i.e., prompt engineering) and identifying the best parameters for the LLM. We show that an ensemble of LLMs can repair all ten of our benchmarks. This ensemble outperforms the state-of-the-art Cirfix hardware bug repair tool on its own suite of bugs. These results show that LLMs can repair hardware security bugs and the framework is an important step towards the ultimate goal of an automated end-to-end bug repair framework.
@misc{ahmad_fixing_2023,
	title = {Fixing {Hardware} {Security} {Bugs} with {Large} {Language} {Models}},
	url = {http://arxiv.org/abs/2302.01215},
	doi = {10.48550/arXiv.2302.01215},
	abstract = {Novel AI-based code-writing Large Language Models (LLMs) such as OpenAI's Codex have demonstrated capabilities in many coding-adjacent domains. In this work we consider how LLMs maybe leveraged to automatically repair security relevant bugs present in hardware designs. We focus on bug repair in code written in the Hardware Description Language Verilog. For this study we build a corpus of domain-representative hardware security bugs. We then design and implement a framework to quantitatively evaluate the performance of any LLM tasked with fixing the specified bugs. The framework supports design space exploration of prompts (i.e., prompt engineering) and identifying the best parameters for the LLM. We show that an ensemble of LLMs can repair all ten of our benchmarks. This ensemble outperforms the state-of-the-art Cirfix hardware bug repair tool on its own suite of bugs. These results show that LLMs can repair hardware security bugs and the framework is an important step towards the ultimate goal of an automated end-to-end bug repair framework.},
	urldate = {2023-05-10},
	publisher = {arXiv},
	author = {Ahmad, Baleegh and Thakur, Shailja and Tan, Benjamin and Karri, Ramesh and Pearce, Hammond},
	month = feb,
	year = {2023},
	note = {arXiv:2302.01215 [cs]},
	keywords = {\#broken, Computer Science - Cryptography and Security, Jab/\#Pre},
}

Downloads: 0