Abstract:Automatic exploit generation is a critical method in evaluating the exploitability and assessing the severity of software vulnerabilities. However, due to lack of ability in construction of address leakage events and effective runtime relocation on exploit payloads, current methods generally fail in generating exploits adaptable to environments where the address space layout randomization(ASLR) vulnerability mitigation option is turned on. To solve the above problem, an automatic address leakage sensitive exploit generation method was proposed for vulnerabilities in binary programs. This method is composed of 2 stages, one for automatic construction of vulnerable program state under complete address leakage, the other automatic runtime environment irrelevant exploitation session generation. In the first stage, techniques including dynamic execution monitoring, automatic address leakage sample construction and address leakage guided fuzzing were employed to generate vulnerable program state that can not only trigger all the address leakage events necessary to execute the target payload, but also invoke some vulnerability afterwards. In the second stage, those were performed including exploitable state construction, automatic exploitation template extraction and exploit payload runtime relocation based automatic vulnerability exploitability verification on the vulnerable program state generated by stage 1, exploitation session that can dynamically fit on the runtime environment of the target system automatically constructed. The generated session is then used to automatically evaluate the exploitability of the target vulnerabilities. LeakableExp was implemeted based on the aforementioned techniques and was evaluated on 2 test programs, 14 CTF & RHG challenges and 4 real world programs.The results of the experiments demonstrate that LeakableExp is effective in address leakage test case generation and exploitability evaluation for vulnerabilities under ASLR environments.