Stack Overflow Considered Helpful! Deep Learning Security Nudges Towards Stronger Cryptography
Felix Fischer, Huang Xiao, Ching-yu Kao, Yannick Stachelscheid, Benjamin Johnson, Danial Razar, Paul Fawkesley, Nat Buckley, Konstantin Böttinger, Paul Muntean, Jens Grossklags
摘要
Stack Overflow is the most popular discussion platform for software developers. However, recent research identified a large amount of insecure encryption code in production systems that has been inspired by examples given on Stack Overflow. By copying and pasting functional code, developers introduced exploitable software vulnerabilities into security-sensitive high-profile applications installed by millions of users every day. Proposed mitigations of this problem suffer from usability flaws and push developers to continue shopping for code examples on Stack Overflow once again. This motivates us to fight the proliferation of insecure code directly at the root before it even reaches the clipboard. By viewing Stack Overflow as a market, implementation of cryptography becomes a decision-making problem. In this context, our goal is to simplify the selection of helpful and secure examples. More specifically, we focus on supporting software developers in making better decisions on Stack Overflow by applying nudges, a concept borrowed from behavioral economics and psychology. This approach is motivated by one of our key findings: For 99.37% of insecure code examples on Stack Overflow, similar alternatives are available that serve the same use case and provide strong cryptography. Our system design that modifies Stack Overflow is based on several nudges that are controlled by a deep neural network. It learns a representation for cryptographic API usage patterns and classification of their security, achieving average AUC-ROC of 0.992. With a user study, we demonstrate that nudge-based security advice significantly helps tackling the most popular and error-prone cryptographic use cases in Android.
问 Lune
几分钟读透这篇 Paper,不用再花一下午。
Lune 能读完全文,也能读引用它的顶会 Paper,讲清它的结论、证据和局限,每一点都注明出自哪篇 Paper。不用硬啃,也不靠猜。
已有 13 篇顶会 Paper 引用了它。别等审稿人问起,先弄清它们发现了什么。
脉络
- Using AI Assistants in Software Development: A Qualitative Study on Security Practices and Concerns 引用了 Stack Overflow Considered Harmful? The Impact of Copy&Paste on Android Application Security
- Using AI Assistants in Software Development: A Qualitative Study on Security Practices and Concerns 引用了 You Get Where You're Looking for: The Impact of Information Sources on Code Security
- "Get in Researchers; We're Measuring Reproducibility": A Reproducibility Study of Machine Learning Papers in Tier 1 Security Conferences 引用了 Realtime Robust Malicious Traffic Detection via Frequency Domain Analysis
- "Get in Researchers; We're Measuring Reproducibility": A Reproducibility Study of Machine Learning Papers in Tier 1 Security Conferences 引用了 Stack Overflow Considered Harmful? The Impact of Copy&Paste on Android Application Security
- "Get in Researchers; We're Measuring Reproducibility": A Reproducibility Study of Machine Learning Papers in Tier 1 Security Conferences 引用了 Neural Network-based Graph Embedding for Cross-Platform Binary Code Similarity Detection
- "Get in Researchers; We're Measuring Reproducibility": A Reproducibility Study of Machine Learning Papers in Tier 1 Security Conferences 引用了 Scalable Graph-based Bug Search for Firmware Images
- CRYLOGGER: Detecting Crypto Misuses Dynamically 引用了 Stack Overflow Considered Harmful? The Impact of Copy&Paste on Android Application Security
- Stack Overflow Considered Harmful? The Impact of Copy&Paste on Android Application Security 引用了 You Get Where You're Looking for: The Impact of Information Sources on Code Security
- LLM Whisperer: An Inconspicuous Attack to Bias LLM Responses 引用了 Stack Overflow Considered Harmful? The Impact of Copy&Paste on Android Application Security
- Neural Network-based Graph Embedding for Cross-Platform Binary Code Similarity Detection 引用了 Scalable Graph-based Bug Search for Firmware Images
引用它的顶会 Paper13
- Realtime Robust Malicious Traffic Detection via Frequency Domain AnalysisChuanpu Fu, Qi Li, Meng Shen, Ke XuCCS 2021 · 194 次引用
- CRYLOGGER: Detecting Crypto Misuses DynamicallyLuca Piccolboni, Giuseppe Di Guglielmo, Luca P. Carloni, Simha SethumadhavanS&P 2021 · 51 次引用
- LLM Whisperer: An Inconspicuous Attack to Bias LLM ResponsesWeiran Lin, Anna Gerchanovsky, Omer Akgul, Lujo Bauer 等CHI 2025 · 23 次引用
- "Get in Researchers; We're Measuring Reproducibility": A Reproducibility Study of Machine Learning Papers in Tier 1 Security ConferencesDaniel Olszewski, Allison Lu, Carson Stillman, Kevin Warren 等CCS 2023 · 19 次引用
- Using AI Assistants in Software Development: A Qualitative Study on Security Practices and ConcernsJan H. Klemmer, Stefan Albert Horstmann, Nikhil Patnaik, Cordelia Ludden 等CCS 2024 · 14 次引用
它引用的 Paper9
- Distillation as a Defense to Adversarial Perturbations Against Deep Neural NetworksNicolas Papernot, Patrick D. McDaniel, Xi Wu, Somesh Jha 等S&P 2016 · 3,275 次引用
- Neural Network-based Graph Embedding for Cross-Platform Binary Code Similarity DetectionXiaojun Xu, Chang Liu, Qian Feng, Heng Yin 等CCS 2017 · 682 次引用
- Scalable Graph-based Bug Search for Firmware ImagesQian Feng, Rundong Zhou, Chengcheng Xu, Yao Cheng 等CCS 2016 · 456 次引用
- You Get Where You're Looking for: The Impact of Information Sources on Code SecurityYasemin Acar, Michael Backes, Sascha Fahl, Doowon Kim 等S&P 2016 · 325 次引用
- Stack Overflow Considered Harmful? The Impact of Copy&Paste on Android Application SecurityFelix Fischer, Konstantin Böttinger, Huang Xiao, Christian Stransky 等S&P 2017 · 293 次引用
相关 Paper
- The Effect of Google Search on Software Security: Unobtrusive Security Interventions via Content Re-rankingFelix Fischer, Yannick Stachelscheid, Jens GrossklagsCCS 2021 · 12 次引用
- Comparing the Usability of Cryptographic APIsYasemin Acar, Michael Backes, Sascha Fahl, Simson L. Garfinkel 等S&P 2017 · 261 次引用
- Listen to Developers! A Participatory Design Study on Security Warnings for Cryptographic APIsPeter Leo Gorski, Yasemin Acar, Luigi Lo Iacono, Sascha FahlCHI 2020 · 39 次引用
- Exploring the Impact of Intervention Methods on Developers' Security Behavior in a Manipulated ChatGPT StudyRaphael Serafini, Asli Yardim, Alena NaiakshinaCHI 2025 · 5 次引用
- "I'm Pretty Expert and I Still Screw It Up": Qualitative Insights into Experiences and Challenges of Designing and Implementing Cryptographic Library APIsJuliane Schmüser, Philip Klostermeyer, Kay Friedrich, Sascha FahlS&P 2025
