As a guest user you are not logged in or recognized by your IP address. You have
access to the Front Matter, Abstracts, Author Index, Subject Index and the full
text of Open Access publications.
With the widespread application of generative large language models (such as ChatGPT) in code generation, the security of their output code has attracted increasing attention. However, the impact of suggest language on the security of generated code has not been fully studied. This paper compares and analyses the Python and Java codes generated by ChatGPT under English and Chinese prompts, and systematically evaluates its security differences. Experiments show that the code vulnerabilities generated by English prompts are significantly less than those generated by Chinese prompts, indicating that the choice of prompt language has an important impact on code security. This finding provides practical guidance for developers to optimize prompt engineering, and it is recommended to give priority to the use of English prompts in scenarios with high security requirements.
This website uses cookies
We use cookies to provide you with the best possible experience. They also allow us to analyze user behavior in order to constantly improve the website for you. Info about the privacy policy of IOS Press.
This website uses cookies
We use cookies to provide you with the best possible experience. They also allow us to analyze user behavior in order to constantly improve the website for you. Info about the privacy policy of IOS Press.