Gespeichert in:
Bibliographische Detailangaben
Hauptverfasser: Khoury, Raphaël, Avila, Anderson R., Brunelle, Jacob, Camara, Baba Mamadou
Format: Preprint
Veröffentlicht: 2023
Schlagworte:
Online-Zugang:https://arxiv.org/abs/2304.09655
Tags: Tag hinzufügen
Keine Tags, Fügen Sie den ersten Tag hinzu!
_version_ 1866913012430929920
author Khoury, Raphaël
Avila, Anderson R.
Brunelle, Jacob
Camara, Baba Mamadou
author_facet Khoury, Raphaël
Avila, Anderson R.
Brunelle, Jacob
Camara, Baba Mamadou
contents In recent years, large language models have been responsible for great advances in the field of artificial intelligence (AI). ChatGPT in particular, an AI chatbot developed and recently released by OpenAI, has taken the field to the next level. The conversational model is able not only to process human-like text, but also to translate natural language into code. However, the safety of programs generated by ChatGPT should not be overlooked. In this paper, we perform an experiment to address this issue. Specifically, we ask ChatGPT to generate a number of program and evaluate the security of the resulting source code. We further investigate whether ChatGPT can be prodded to improve the security by appropriate prompts, and discuss the ethical aspects of using AI to generate code. Results suggest that ChatGPT is aware of potential vulnerabilities, but nonetheless often generates source code that are not robust to certain attacks.
format Preprint
id arxiv_https___arxiv_org_abs_2304_09655
institution arXiv
publishDate 2023
record_format arxiv
spellingShingle How Secure is Code Generated by ChatGPT?
Khoury, Raphaël
Avila, Anderson R.
Brunelle, Jacob
Camara, Baba Mamadou
Cryptography and Security
In recent years, large language models have been responsible for great advances in the field of artificial intelligence (AI). ChatGPT in particular, an AI chatbot developed and recently released by OpenAI, has taken the field to the next level. The conversational model is able not only to process human-like text, but also to translate natural language into code. However, the safety of programs generated by ChatGPT should not be overlooked. In this paper, we perform an experiment to address this issue. Specifically, we ask ChatGPT to generate a number of program and evaluate the security of the resulting source code. We further investigate whether ChatGPT can be prodded to improve the security by appropriate prompts, and discuss the ethical aspects of using AI to generate code. Results suggest that ChatGPT is aware of potential vulnerabilities, but nonetheless often generates source code that are not robust to certain attacks.
title How Secure is Code Generated by ChatGPT?
topic Cryptography and Security
url https://arxiv.org/abs/2304.09655