We interact with computer systems daily if not hourly, trusting them with our sensitive data. Computer scientists build these systems and, as we do, we introduce often unintended sources of information leakage into our creations. Some of these appear benign, but in this increasingly connected world, information leaks have consequences. Side channels in software are a nuanced yet potentially devastating mechanism for information leakage. In this thesis, I address key concerns about side channel vulnerabilities in software: how they arise, how much information they leak, and whether their detection and mitigation can be automated.
I develop techniques to detect, quantify and mitigate side-channel vulnerabilities. I draw on an array of program analysis and testing techniques, such as taint analysis, model-counting, CFG analysis, fuzzing, and quantitative information flow. Importantly, I consider that side channel vulnerabilities can arise both statically at the source-code level and dynamically at runtime. With this second observation, I pioneer research into a previously unknown type of software side-channel, JIT-induced timing channels. These side channels arise dynamically at runtime due to an imbalance in the input distribution of a program, transforming the problem of side-channel vulnerabilities in software into one that needs to consider the set of possible runtime states.