Types for Coordinating Secure Behavioural Variations