Automatic security analysis of SAML-based single sign-on protocols