Securing an application and its infrastructure