Foundations of Security Analysis and Design III