All the stuff is ok, few parts are missing.
A - configuring DNS entries for mail.contoso.com and autodiscover.contoso.com
B - how does it work when same URL is assigned to CAS server in another site ?

Sam