Added support for 'Expect' based authentication.