Context: Security is vital to software developed for commercial or personal use. Although more organizations are realizing the importance of applying secure coding practices, in many of them, security concerns are not known or addressed until a security failure occurs. The root cause of security failures is vulnerable code. While metrics have been used to predict software vulnerabilities, we explore the relationship between code and architectural smells with security weaknesses. As smells are surface indicators of a deeper problem in software, determining the relationship between smells and software vulnerabilities can play a significant role in vulnerability prediction models. Objective: This study explores the relationship between smells and software vulnerabilities to identify the smells. Method: We extracted the class, method, file, and package level smells for three systems: Apache Tomcat, Apache CXF, and Android. We then compared their occurrences in the vulnerable classes which were reported to contain vulnerable code and in the neutral classes (non-vulnerable classes where no vulnerability had yet been reported). Results: We found that a vulnerable class is more likely to have certain smells compared to a non-vulnerable class. God Class, Complex Class, Large Class, Data Class, Feature Envy, Brain Class have a statistically significant relationship with software vulnerabilities. We found no significant relationship between architectural smells and software vulnerabilities. Conclusion: We can conclude that for all the systems examined, there is a statistically significant correlation between software vulnerabilities and some smells.
Security Smells in Ansible and Chef Scripts: A Replication Study
上下文:安全气味是重复出现的编码模式,表明存在安全漏洞,需要进一步检查。由于基础设施即代码(IaC)脚本(如Ansible和Chef脚本)用于大规模配置基于云的服务器和系统,IaC脚本中的安全气味可用于使恶意用户能够利用所配置系统中的漏洞。目标:本文的目标是通过对Ansible和Chef脚本中的安全气味进行实证研究,帮助从业者在将基础设施开发为代码脚本时避免不安全的编码实践。方法学:我们进行了一项复制研究,我们对1,956个IaC脚本进行了定性分析,以确定用两种语言编写的IaC脚本的安全气味:Ansible和Chef。我们构建了一个名为Security Linter for Ansible and Chef scripts(SLAC)的静态分析工具,用于自动识别从813个开源软件库中收集的50,323个脚本中的安全气味。我们还提交了1,000个随机选择的气味事件的错误报告。结果:我们发现了两个在以前的工作中没有报道的安全气味:在case语句中缺少默认值和没有完整性检查。通过应用SLAC,我们识别出46,600次安全气味,其中包括7,849个硬编码密码。我们观察到94个bug报告中有65个是一致的,这表明Ansible和Chef脚本的安全气味与从业者之间的相关性。结论:我们观察到安全气味在Ansible和Chef脚本中普遍存在,类似于Puppet脚本。我们建议从业者使用(i)代码审查…
Bi-Directional Transformers vs. word2vec: Discovering Vulnerabilities in Lifted Compiled Code
The Beacom College of Computer and Cyber Sciences, Dakota State University(达科他州立大学比科姆计算机与网络科学学院);College of Applied Science & Technology, University of Arizona(亚利桑那大学应用科学与技术学院);College of Computing, Georgia Institute of Technology(佐治亚理工学院计算学院)
Evaluating Software Development Agents: Patch Patterns, Code Quality, and Issue Complexity in Real-World GitHub Scenarios
Centre for Research on Intelligent Software Engineering(智能软件工程研究中心);School of Computing and Information Systems(计算与信息系统学院);Singapore Management University(新加坡管理大学)