Quantifying Security: Methods, Challenges And Applications