Shanfu Shu

dblp:415/3268 · DBLP profile ↗
← Back
1ranked-venue papers
0as first author
1since 2021 · last 2025
0009-0006-9927-5726ORCID · reported

Domains — the database's venue-derived domains; a paper can count in several

Software engineering, systems software and programming languages · 1 · 1 since 2021

Expertise — from the expertise taxonomy: the topics of the expert's papers under the CCF categories. A weight counts papers with recency: 1 for a paper about the topic, 0.3 when the topic is its context, halved every five years.

Software engineering, system software, and programming languages
1 paper
Program synthesis and code generation · 100%
Network and information security
1 paper
Systems and software security · 100%

Topics — the 3 heaviest of 3, each with the papers that count most for it

TopicWeightPapersLastEvidence papers
Systems and software security › secure software development
secure code generation
0.912025
Improving Co-Decoding Based Security Hardening of Code LLMs Leveraging Knowledge Distillation · IEEE Trans. Software Eng. 2025
Program synthesis and code generation
code generation with language models
0.912025
Improving Co-Decoding Based Security Hardening of Code LLMs Leveraging Knowledge Distillation · IEEE Trans. Software Eng. 2025
Program synthesis and code generation › code generation with language models
secure code generation
0.912025
Improving Co-Decoding Based Security Hardening of Code LLMs Leveraging Knowledge Distillation · IEEE Trans. Software Eng. 2025

Methods — techniques the papers use, named apart from their topics

knowledge distillation · 1.7fine-tuning · 1.7co-decoding · 1.7
YearPublicationVenuePosition
2025 Improving Co-Decoding Based Security Hardening of Code LLMs Leveraging Knowledge Distillation
abstract
Large Language Models (LLMs) have been widely adopted by developers in software development. However, the massive pretraining code data is not rigorously filtered, allowing LLMs to learn unsafe coding patterns. Several prior studies have demonstrated that code LLMs tend to generate code with potential vulnerabilities. The widespread adoption of intelligent programming assistants poses a significant threat to the software development process. Existing approaches to mitigating this risk primarily involve constructing secure data that are free of vulnerabilities and then retraining or fine-tuning the models. However, such an effort is resource intensive and requires significant manual supervision. When the model parameters are too large (e.g., more than 1 billion) or multiple models with the same parameter scale have the same optimization needs (e.g., to avoid outputting vulnerable code), the above work will become unaffordable. To address this challenge, in previous work, we proposed CoSec, an approach to improve the security of code LLMs with different parameters by utilizing an independent and very small parametric security model as a decoding navigator.Despite CoSec’s excellent performance, we found that there is still room for improving: 1) its ability to maintain the functional correctness of hardened targets, and 2) the security of the generated code. To address the above issues, we propose CoSec+, a hardening framework consisting of three phases: 1) Functional Correctness Alignment, which improves the functional correctness of the security base with knowledge disstillation; 2) Security Training, which yields an independent, but much smaller security model; and 3) Co-decoding, where the security model iteratively reasons about the next token along with the target model. Due to the higher confidence that a well-trained security model places in secure and correct tokens, it guides the target base model to generate more secure code, even as it improves the functional correctness of the target base model. We have conducted extensive experiments in several code LLMs (i.e., CodeGen, StarCoderBase, DeepSeekCoder and Qwen2.5-Coder), and the results show that our approach is effective in improving the functional correctness and security of the models. The evaluation results show that CoSec+ can deliver a 0.8% to 37.7% improvement in security across models of various parameter sizes and families; moreover, it preserves the functional correctness of the target base models—achieving functional-correctness gains of 0.7% to 51.1% for most of those models.
Dong Li 0009, Shanfu Shu, Meng Yan 0001, Zhongxin Liu 0002, Chao Liu 0014, Xiaohong Zhang 0002, David Lo 0001
IEEE Trans. Software Eng.2