added auth_message and auth_type to authenticate