We present a new scalable, semi-supervised method for inferring taint analysis specifications by learning from a large dataset of programs. Taint specifications capture the role of library APIs (source, sink, sanitizer) and are a critical ingredient of any taint analyzer that aims to detect security violations based on information flow.
The core idea of our method is to formulate the taint specification learning problem as a linear optimization task over a large set of information flow constraints. The resulting constraint system can then be efficiently solved with state-of-the-art solvers. Thanks to its scalability, our method can infer many new and interesting taint specifications by simultaneously learning from a large dataset of programs (e.g., as found on GitHub), while requiring few manual annotations.
We implemented our method in an end-to-end system, called Seldon, targeting Python, a language where static specification inference is particularly hard due to lack of typing information. We show that Seldon is practically effective: it learned almost $7,000$ API roles from over $210,000$ candidate APIs with very little supervision (less than $300$ annotations) and with high estimated precision ($67%$). Further, using the learned specifications, our taint analyzer flagged more than $20,000$ violations in open source projects, $97%$ of which were undetectable without the inferred specifications.
Tue 25 JunDisplayed time zone: Tijuana, Baja California change
14:00 - 15:30 | Learning SpecificationsPLDI Research Papers at 228AB Chair(s): Michael Pradel TU Darmstadt and Facebook | ||
14:00 20mTalk | Unsupervised Learning of API Aliasing Specifications PLDI Research Papers Jan Eberhardt DeepCode, Switzerland, Samuel Steffen ETH Zurich, Switzerland, Veselin Raychev DeepCode AG, Martin Vechev ETH Zürich Pre-print Media Attached | ||
14:20 20mTalk | Scalable Taint Specification Inference with Big Code PLDI Research Papers Victor Chibotaru DeepCode, Switzerland, Benjamin Bichsel ETH Zurich, Switzerland, Veselin Raychev DeepCode AG, Martin Vechev ETH Zürich Pre-print Media Attached | ||
14:40 20mTalk | Learning Stateful Preconditions Modulo a Test Generator PLDI Research Papers Angello Astorga , P. Madhusudan University of Illinois at Urbana-Champaign, Shambwaditya Saha , Shiyu Wang University of Illinois at Urbana-Champaign, USA, Tao Xie University of Illinois at Urbana-Champaign, USA | ||
15:00 20mTalk | SLING: Using Dynamic Analysis to Infer Program Invariants in Separation Logic PLDI Research Papers Ton Chanh Le Stevens Institute of Technology, Guolong Zheng University of Nebraska Lincoln, ThanhVu Nguyen University of Nebraska-Lincoln |